Domain Controller in Directory Services Restore Boot Loop

Written by Allen White on. Posted in Microsoft, SBS2008/2011, Server 2003, Server 2008

IT Problem

Came across this issue a few days back on a SBS2008 Server and it took AGES after going through the usual diag routes to get it resolved, the clients Domain Controller after a reboot booted into directory services restore mode.

(Update:I believe this error was down to the user removing snapshots manually that veeam had created when it had failed to backup. Manually deleting the snapshots caused the issues.)

Strange I thought, so another reboot and the same, directory services restore mode.The domain controller was in a directory services restore mode loop.Then the diag process started , did an AD database integrity check, did a scan disk of the volume, CHKDSK /f. Ran MSconfig and set it to boot into normal mode. I also noted that under the environment variable section under My Computer > Advanced, there was a variable saying SAFEBOOT – DSREPAIR, so I deleted that. no success.

It was with reluctance that I then tried to do a restore of active directory, so once i restored to a week old backup , guess what…it did EXACTLEY THE SAME. I just could not understand what was happening. Finally I did the steps below and after a reboot the server came up clean.

IT Solution

The first thing you need to do it locate your “boot” folder, most of the time it is on the root of C however on my server which was a HP ml350 G7 it was on a hidden drive. So if this is the case Right click Computer > Manage > Disk Management. Then right click the volume and allocate it a drive letter.

Ok, so go to that drive then CD into the boot folder. We then need to run the commands below.

	bcdedit /set safeboot dsrepair

	bcdedit /deletevalue safeboot

	shutdown -f -r

What this does is clear the DSrepair status from the registry so the server can boot normally, in msconfig if you set the server to boot normal it does not effect this registry key.

You should now find that your domain controller does not boot into directory services restore mode.

 
Allen White
at
Allen is a Consultant for ITPS in the North East of England and holds the following accreditations. MCSA, MCSE, MCTS, MCITP, CCA, CCSP, VCP 4,5 and HP ASE, AIS - Network Infrastructure.

ITPS provides strategic IT consultancy, implementation, data centre provision and unified communications, as well as support services and workspace and disaster recovery. If you require a consultation then please contact me via the contacts section or direct on 07931222991, add me on linkedin. https://uk.linkedin.com/in/allenwhiteconsultant0001

Tags:

Comments (10)

  • Travis

    |

    Fantastic article, I just had nearly the exact issue on a SBS2008 DC and my search terms eventually let me here. Failed Veeam jobs, stuck in DSRM, etc… I didn’t think about resetting the boot mode in the BCD store like that. I had tried all of the same things and was nearly to the point of restoring the DC VM from backup. Great job!

    Reply

    • Allen White

      |

      Glad to help Travis, I thought I cannot be the only one who has had this, took me days to fix it initialy and like you was close to a DC restore and the problems that that brings.

      Reply

  • RP

    |

    You’ve just saved my night, Sir. After patching the server hung on configuring system and needed a kick (aka reset) in the pants, but then it went into the DSRM loop.

    Your little trick set things straight and it’s likely that I’ll get to bed on time (I work the overnight shift).

    Reply

  • yossi Amara

    |

    man you are the it pro just saved me on sbs2011 that run on vmware after 2 ours of hard work with no luck until crossed over your awesome idea
    thanks alot

    Reply

  • Nate D

    |

    Worked perfectly, I had a similar issue with a reboot loop on a 2008R2 Domain Controller. Server came up nicely after running the commands. Thanks again!

    Reply

  • Scott McKenzie

    |

    As per the others above, had exactly the same issue… thankfully I found this BEFORE attempting the AD restore.

    Reply

    • Allen White

      |

      Excellent, glad to help. I remember spending days on this before finding the fix.

      Reply

  • Andy

    |

    Good fix. When I see this I usually login to the local server account and run msconfig. Click the boot tab and uncheck safe boot.

    Reply

  • JK

    |

    Awesome, saved me in a failed VMware to HyperV migration for a 2008 DC.

    Reply

  • Daniel B

    |

    Thank you! Thank you! Thank you! Saved my day. Our SBS 2011 on VMWare needed this fix after a restore from a Veeam backup.

    Reply

Leave a comment

Categories

(c) Techieshelp.com. Please be aware, all information is provided freely, any information used is done so at your risk and Techieshelp will not be held responsible for any issue that may occur.
!-- BuySellAds On-Site Shopping Cart -->