使用非 DHCP DNS 服务器安装无人值守的 Windows 7:域加入失败,声称找不到域

gro*_*wse 7 active-directory unattended windows-7 waik

我正在尝试构建一个无人值守的 Windows 7 图像脚本,它将执行简单的域加入。问题是 DHCP 提供的 DNS 服务器对我的域一无所知,因此我需要在UnattendedJoin任务运行之前将 DNS 服务器设置为知道该域的内容。我Microsoft-Windows-DNS-Clientunattend.xml.

我现在知道正在设置 DNS 设置,因为Local Area Connection一旦 Win7 机器启动,NIC IP 设置就是正确的。但是,它永远不会进入域。报的具体错误是:

[DJOIN.EXE] Unattended Join: Begin
[DJOIN.EXE] Unattended Join: Loading input parameters...
[DJOIN.EXE] Unattended Join: AccountData = [NULL]
[DJOIN.EXE] Unattended Join: UnsecureJoin = [NULL]
[DJOIN.EXE] Unattended Join: MachinePassword = [secret not logged]
[DJOIN.EXE] Unattended Join: JoinDomain = [domain.example.com]
[DJOIN.EXE] Unattended Join: JoinWorkgroup = [NULL]
[DJOIN.EXE] Unattended Join: Domain = [DOMAIN]
[DJOIN.EXE] Unattended Join: Username = [domainuser]
[DJOIN.EXE] Unattended Join: Password = [secret not logged]
[DJOIN.EXE] Unattended Join: MachineObjectOU = [OU=Clients,OU=Bucket,DC=example,DC=domain,DC=com]
[DJOIN.EXE] Unattended Join: DebugJoin = [true]
[DJOIN.EXE] Unattended Join: DebugJoinOnlyOnThisError = [NULL]
[DJOIN.EXE] Unattended Join: Enabled DC Locator ETW tracing. Log file: C:\Windows\Panther\UnattendGC\UnattendedJoinDCLocator.etl
[DJOIN.EXE] Unattended Join: Checking that auto start services have started.
[DJOIN.EXE] Unattended Join: Joining domain [domain.example.com]...
[DJOIN.EXE] Unattended Join: Calling DsGetDcName for domain.example.com...
Unattended Join: DsGetDcName failed: 0x54b, last error is 0x0, will retry in 5 seconds...
Run Code Online (Sandbox Code Playgroud)

此错误似乎意味着“我找不到域”。奇怪的是,如果我在安装完成后尝试手动加入域,它运行良好。因此,出于某种原因,即使之前正确设置了 DNS 设置(我可以在日志文件的更深处看到),DJOIN.EXE也没有使用它们。

这里发生了什么?

小智 1

在这种情况下,有几个选项可以帮助您将计算机加入域。

\n\n

首先,由于网络设置是在专门阶段中设置的,因此您可以稍后在将计算机加入域的过程中运行脚本。在 oobesystem 阶段,您可以使用 \xe2\x80\x98FirstLogonCommands\xe2\x80\x99 设置下的 \xe2\x80\x98SynchronousCommand\xe2\x80\x99 设置,该设置是 Microsoft-Windows-Shell-Setup 组件的一部分运行脚本将计算机加入域。

\n\n

另一种选择是使用脱机域加入,如本 TechNet 文章中所述:\xe2\x80\x98脱机域加入 (Djoin.exe) 分步指南\xe2\x80\x99

\n\n

如需帮助满足您的部署需求的更多分步指南和视频,请访问TechNet 上 Springboard 系列的交付和部署 Windows 7以及交付和部署 Windows 8页面。

\n\n

希望这可以帮助,

\n