-
Notifications
You must be signed in to change notification settings - Fork 8
LDAP Object Deletion
Jiri Formacek edited this page Nov 22, 2024
·
1 revision
Deletion of individual objects:
$Ldap = Get-LdapConnection -LdapServer "mydc.mydomain.com"
Remove-LdapObject -LdapConnection $Ldap `
-Object "cn=User1,cn=Users,dc=mydomain,dc=com"Deletion of directory subtree:
$Ldap = Get-LdapConnection -LdapServer "mydc.mydomain.com" -EncryptionType Kerberos
#With TreeDeleteControl, deletion of objects in container happens on server side
Remove-LdapObject -LdapConnection $Ldap `
-Object "ou=myContainer,dc=mydomain,dc=com" `
-UseTreeDelete