Add All Members of an OU to a Security Group

 

Get-ADUser -SearchBase ‘OU=Source-OU,OU=PNL,DC=pnl,DC=com’ -Filter * | 
ForEach-Object {Add-ADGroupMember -Identity ‘SG-Test-Group’ -Members $_ }

 

 

DIsable LAPS

  Turn all items to disabled in LAPS GPO    Remove LAPS passwords Get-ADComputer -Filter * -SearchBase “OU=Servers,DC=mydomain,DC=com” | Se...

Mais vistos