Chris Bradbury

Active Directory

Active Directory

AD OU – Remove Protected From Accidental Deletion

When creating an OU in AD, ticking the Protect from Accidental Deletion box seems like a good idea. Until you go to delete the OU. Even more so if you have multiple nested OUs and just want to delete the top level one. Powershell to the rescue! We can use Read more

By chrisbradbury, 6 years ago March 4, 2020
Active Directory

Powershell AD – Output groups a user is a member of

We occasionally need to make a note of the groups a user is a member of. If they’re going on maternity leave, for example. This script does require the Active Directory Module For Windows PowerShell. $user = “username” Get-ADPrincipalGroupMembership $user | select name  

By chrisbradbury, 9 years ago February 27, 2017