Version for print

How do I manually defragment Active Directory?

Windows 2000 servers running Directory Services (DSs) perform a directory online defragmentation every 12 hours by default as part of the garbage-collection process. This defragmentation only moves data around the database file (ntds.dit) and doesn’t reduce the file’s size.

To create a new, smaller ntds.dit file and to enable offline defragmentation, perform the following steps.

  1. Back up Active Directory (AD) (see the FAQ How do I back up Active Directory and the System State?).
  2. Reboot the server, select the OS option, and press F8 for advanced options.
  3. Select the Directory Services Restore Mode option, and press Enter. Press Enter again to start the OS.
  4. Win2K will start in safe mode, with no DS running.
  5. Use the local SAM’s administrator account and password to log on.
  6. You’ll see a dialog box that says you’re in safe mode. Click OK.
  7. From the Start menu, select Run and type cmd.exe
  8. In the command window, you’ll see the following text. (Enter the commands in bold.)
    C:\> ntdsutil
    ntdsutil: files
    file maintenance:info
    ....
    file maintenance:compact to c:\temp
  9. You’ll see the defragmentation process. If the process was successful, enter quit
    quit
  10. to return to the command prompt.
  11. Then, replace the old ntds.dit file with the new, compressed version. (Enter the commands in bold.)
    C:\> copy c:\temp\ntds.dit %systemroot%\ntds\ntds.dit
  12. Restart the computer, and boot as normal.

1st Security Center

Internet Security Tweak Pro

Security Officer

Internet Explorer Security

Dark Files

Security Department

1st Security Center

Internet Security Tweak Pro

Security Officer for Windows

Internet Explorer Security

Dark Files

Security Department

Security FAQ

Windows Privacy Tools - http//www.privacywindows.com

Security Officer | Internet Explorer Security | Dark Files | Security Department | Magic Basket
Products | Technical Support | Free Downloads