Solved

PowerShell - Quest - How to Remove a group from multiple machines.

Posted on 2013-01-09
2
749 Views
Last Modified: 2013-01-10
I just got great help from Subsun on adding a group to multiple machines ( link below) , now Id also would like to be able to remove a group from multiple machines .

Thank you for all the help !

http://www.experts-exchange.com/Programming/Languages/Scripting/Powershell/Q_27989227.html
0
Comment
Question by:MilesLogan
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 40

Accepted Solution

by:
Subsun earned 500 total points
ID: 38760005
You just need to change Add to Remove
GC C:\Servers.txt | %{

$domain="YourDomain.com"
$group = "YourGroup"

([adsi]"WinNT://$_/Administrators,group").Remove("WinNT://$domain/$group,group")
}

Open in new window

0
 
LVL 2

Author Closing Comment

by:MilesLogan
ID: 38763873
Thank you !
0

Featured Post

Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Active Directory security has been a hot topic of late, and for good reason. With 90% of the world’s organization using this system to manage access to all parts of their IT infrastructure, knowing how to protect against threats and keep vulnerabil…
Recently, Microsoft released a best-practice guide for securing Active Directory. It's a whopping 300+ pages long. Those of us tasked with securing our company’s databases and systems would, ideally, have time to devote to learning the ins and outs…
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles from a Windows Server 2008 domain controller to a Windows Server 2012 domain controlle…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…
Suggested Courses

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question