Bulk rename Active Directory groups

#get-qadgroup -searchroot “OU=groups,DC=domain,DC=local” | where {$_.name -like ’00_*’} | % { Rename-qadobject -Identity $_ -NewName ($_.Name -Replace “^00_”, “00_test”) }

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s