 |
 |
| Windows Server Tips: |
|
 |
 |

ACTIVE DIRECTORY ADMINISTRATION
Tools for quick recovery of deleted Active Directory objects
Gary Olsen, Contributor 11.08.2005
Rating: -4.52- (out of 5)




|
Perhaps one of the most feared utterances of a system admin is "Oops!" Fortunately there is an "undelete" for many operations in applications. In Windows 2003, there is also an "undelete" for quick recovery of deleted objects, although it is not widely known. Here is a quick procedure you can use to reanimate deleted Active Directory objects.
Background
When an object is deleted in Active Directory, it is really just "tombstoned." That is, the object and its mandatory attributes are moved to the Deleted Objects folder -- a sort of death row for objects. Every 15 minutes, the Garbage Collector (or Executioner) comes along and checks to see if the object's Tombstone Lifetime has expired. The Tombstone Lifetime is the period of time the object can remain in the Deleted Objects folder before it is purged from the database. This is 60 days by default, although Microsoft now recommends 120 days. If the Tombstone Lifetime has expired, it purges the object from AD.
The Tombstone Lifetime can be changed by using the ADSIEdit tool. Go to cn=directory Service,cn=windowsNT,cn=services,cn=configuration,dc=company,dc=com (replace dc=company,dc=com with your domain name). Right click on the CN=Directory Service folder and select Properties. Find Tombstone Lifetime in the attribute list, click the Edit button and enter the number of days in the value field.
So you hear one of your fellow admins say "oops -- I just deleted an object that I shouldn't have." You could do an authoritative restore of that object, but what a t
To continue reading for free, register below or login
To read more you must become a member of SearchWindowsServer.com
');
// -->

ime-consuming pain that is! A much faster way is simply to use the LDP.exe tool to recover it:
Now that you have the Deleted Objects folder displayed, let's reanimate one of the objects. In the following example, we have a user, Forest Gump, who was deleted from CN=Users,dc=qtest,dc=cpqcorp,dc=net. In Figure 2, we see the Deleted Objects folder expanded, and in Figure 3 we see the deleted user Forest Gump. Note the \0ADEL: in the name. All deleted users are flagged with this. Note also in Figure 3 that one of the attributes on Forest Gump is the isDeleted attribute, which is set to True. This attribute only exists on deleted users, making it easy to find them with an LDAP search. To reanimate Forest Gump, do the following:
Obviously, this method would be too laborious to do a hundred or so deleted users (authoritative restore could be used for that task), but to recover a few objects, it is quick, easy, hard to mess up and free! At least in my experience, if you don't get the information correct in the modify dialog, the operation fails. As far as I know -- and I've messed a few up -- it doesn't corrupt the object, although there is surely a way to do that.
So keep an eye on those shoot-from-the-hip administrators, but now you won't have a coronary when you hear them say, "Oops!"
Gary Olsen is a systems software engineer for Hewlett-Packard in Global Solutions Engineering. He authored Windows 2000: Active Directory Design and Deployment and co-authored Windows Server 2003 on HP ProLiant Servers.
 |

|
|
 |
|
 |
 |
 |
 |
| TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of . |
|
| |
All Rights Reserved, , TechTarget |
|
|
|
|
|