| Previous | Next |
| ERROR_DS_OBJ_CLASS_VIOLATION | ERROR_DS_CANT_ON_RDN |
ERROR_DS_CANT_ON_NON_LEAF
ERROR_DS_CANT_ON_NON_LEAF (8213) is an Active Directory Domain Services error. The operation targeted an Active Directory object that still has child objects. Directory operations such as deletion are restricted when removing the parent would orphan a subtree.
What to check
- Inspect the target DN and enumerate its direct children before changing anything.
- Decide whether the intended operation applies to the parent only, its children, or the whole subtree.
- Do not use a tree delete on a production container until protected or critical objects have been identified.
Useful command
Get-ADObject -SearchBase "<ObjectDN>" -SearchScope OneLevel -Filter *
Microsoft: Set-ADObject · Microsoft: Directory Service system error codes · Microsoft: DCDiag
Looking for a different code? Search another status or error code.