Skip to main content
  • Place orders quickly and easily
  • View orders and track your shipping status
  • Create and access a list of your products
  • Manage your Dell EMC sites, products, and product-level contacts using Company Administration.

Windows Server:域控制器故障后的 Active Directory 数据库修复

Summary: 如何在域控制器发生故障后修复 Windows Server 操作系统中的 Active Directory?

This article may have been automatically translated. If you have any feedback regarding its quality, please let us know using the form at the bottom of this page.

Article Content


Symptoms

本文介绍 Windows Server 操作系统上的 Active Directory 修复。


 

 

问题:

启动时,Windows Server 2003 Active Directory 域控制器 (DC) 在登录提示之前显示一条类似于下面的消息:

Application popup: lsass.exe - System Error : Security Accounts Manager initialization failed because of the following error: Directory Service cannot start. Error Status: 0xc00002e1. Please click OK to shutdown this system and reboot into Directory Services Restore Mode, check the event log for more detailed information.

Active Directory (AD) 数据库已损坏;服务器无法对 AD 域成员进行身份验证,无法引导至正常模式。

 

解决方案:

如果没有最近的系统状态备份,可以使用下面的步骤进行 AD 恢复尝试。

1.在目录服务还原模式 (DSRM) 下重新启动 DC。

    a. 服务器启动时,在系统 BIOS 和硬件服务(如 PERC、iDRAC)初始化完成后按 F8 键。 

    b. 从启动菜单中选择“Directory Services Restore Mode”并按 Enter 键。


2.从 Windows 开始按钮选择运行并键入“cmd”,打开命令提示符。

    键入“ESENTUTL /g C:\windows\NTDS\ntds.dit /!10240 /8 /o”并按 Enter 键,执行初始完整性检查。

SLN289101_en_US__1W_ad__repair1_JM_V2

    在数据库不一致的情况下,将会返回错误信息,例如“results CORRUPTED, -1206”。

3.接下来,键入“NTDSUTIL”并按 Enter 键。  这将启动 NTDS 工具集。

    a. 在提示符处键入“Files”,然后按 Enter 键进入 NTDS 文件管理实用程序

b. 在 file maintenance: 提示符下,键入“info”,然后按 Enter 键,显示所有 AD 数据库相关文件的位置。

SLN289101_en_US__2W_ad__repair2_JM_V1

4.在 file maintenance: 提示符下,键入“Recover”并按 Enter 键。  这将启动 AD 数据库的“软”恢复。

SLN289101_en_US__3W_ad__repair3_JM_V1

 

提醒:除极少数例外情况外,此步骤还不足以解决问题;这主要是诊断问题深度的预备步骤。

    在每个提示符下都输入“quit”,直到返回到命令 (C:\<路径>) 提示符。

5.从命令提示符下,键入“ESENTUTL /ml c:\windows\ntds\edb”,查看 AD 数据库日志文件。

SLN289101_en_US__4W_ad__repair4_JM_V1

    如果此步骤失败,请分别发出以下命令并按 Enter 键:

    a.“DEL *.log

b.“DEL *.chk

然后继续执行步骤 6。

6.从命令提示符下,键入“ESENTUTL /p C:\Winnt\NTDS\ntds.dit /!10240 /8 /o”,然后按 Enter 键,对 AD 数据库
执行“硬”恢复。

SLN289101_en_US__5W_ad__repair5_JM_V1

 

警告:成功完成后,ESENTUTL /p 会将数据库返回到其上次提交事务的状态。最近的更改可能会丢失;因此,从日常备份进行完整的系统状态还原是恢复 AD 服务器的最佳做法。

7.从命令提示符下,键入“ESENTUTL /g C:\Winnt\NTDS\ntds.dit /!10240 /8 /o”,然后按 Enter 键,确保数据库一致性。

SLN289101_en_US__6W_ad__repair6_JM_V1

8.返回到 NTDSUTIL 提示符(参见步骤 3)并键入“sem dat ana”(“Semantic Database Analysis”的截短形式)并按 Enter 键。
    从 semantic checker: 提示符下,键入“go”并按 Enter 键。

SLN289101_en_US__7W_ad__repair7_JM_V1

    如果检测到问题,请键入“go fix”并按 Enter 键。

9.完成所有步骤后,在正常模式下重新启动服务器。

 

其它信息:

http://support.microsoft.com/kb/258062

 


Cause

Resolution

Article Properties


Affected Product

Servers, Microsoft Windows 2008 Server R2, Microsoft Windows 2008 Server Service Pack 2, Microsoft Windows 2012 Server, Microsoft Windows 2012 Server R2

Last Published Date

08 Oct 2021

Version

4

Article Type

Solution