Refer to this blog post ( Configuring the Windows R2 Active Directory recycle bin) to successfully enable the ad Recycle Bin,
Experimental Results Summary: With the LDP.exe tool to enable and restore are unsuccessful, with the Power shell command succeeded, the steps are as follows:
1. Enable Recycle Bin command
Enable-adoptionalfeature–identity ' cn=recycle Bin feature,cn=optional features,cn=directory Service,CN=Windows NT,CN =services,cn=configuration, dc=contoso,dc=com ' –scope forestorconfigurationset–target ' contoso.com '
2. View Recycle Bin Status
Get-adoptionalfeature-filter {name-like "*"}
3. View object Status
Get-adobject-searchscope Subtree-filter {name-like "*"}-includedeletedobjects
or Get-adobject-searchscope subtree-filter {name-like "*user1*"}-includedeletedobjects
Delete the User1 user account.
~ ~ Before deletion:
Deleted:
Distinguishedname:ou=test,dc=contoso,dc=com
Name:test
Objectclass:organizationalunit
Objectguid:610b87d9-77e4-48be-8b1d-dbd58ca9d7c8
Deleted:
Distinguishedname:cn=user1,ou=test,dc=contoso,dc=com
Name:user1
Objectclass:user
Objectguid:7b24079e-06a8-4d98-9566-e9e9454676c6
~ ~ After deletion:
Deleted:true
Distinguishedname:ou=test\0adel:610b87d9-77e4-48be-8b1d-dbd58ca9d7c8,cn=delet
Ed Objects,dc=contoso,dc=com
Name:test
Del:610b87d9-77e4-48be-8b1d-dbd58ca9d7c8
Objectclass:organizationalunit
Objectguid:610b87d9-77e4-48be-8b1d-dbd58ca9d7c8
Deleted:true
Distinguishedname:cn=user1\0adel:7b24079e-06a8-4d98-9566-e9e9454676c6,cn=dele
Ted Objects,dc=contoso,dc=com
Name:user1
Del:7b24079e-06a8-4d98-9566-e9e9454676c6
Objectclass:user
Objectguid:7b24079e-06a8-4d98-9566-e9e9454676c6
4. Restore deleted containers or OUs or users:
(If you have an OU that contains users that needs to be restored, you must restore the OU before you restore the user)
Restore-adobject-identity 610b87d9-77e4-48be-8b1d-dbd58ca9d7c8
Restore-adobject-identity 7b24079e-06a8-4d98-9566-e9e9454676c6
Restore succeeded, Ou yeh!
This article is from the "Starry Dot" blog, so be sure to keep this source http://fanxing.blog.51cto.com/189800/1954789
"Experience sharing" Windows R2 Active Directory Recycle Bin