编写自动AD控制器和林,无需用户交互,例如目录服务密码 [英] Scripting an automatic AD controller and forest without user interaction such as Directory Services password

查看:92
本文介绍了编写自动AD控制器和林,无需用户交互,例如目录服务密码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨:



我的基本脚本如下




#AD DS部署的Windows PowerShell脚本





导入模块ADDSDeployment

Install-ADDSForest`
$
-CreateDnsDelegation:$ false`

-DatabasePath" C:\ Windows \ NTDS" `
$
-DomainMode" Win2012R2" `
$
-DomainName" local.ca" `
$ $ $ b -DomainNetbiosName" LOCAL" `
$
-ForestMode" Win2012R2" `
$
-InstallDns:$ true`

-LogPath" C:\ Windows \NTDS" `
$
-NoRebootOnCompletion:$ false`

-SysvolPath" C:\ Windows \ SYSVOL" `
$
-Force:$ true



这会在林中创建我的域控制器。问题是它要求提供目录服务密码,然后确认关闭所述密码。我需要它做的是自动嵌入那些并且根本不问任何问题。 



简单地说我想运行一个脚本在没有任何用户交互的情况下创建林和域控制器



解决方案

您好jnlaw,


关于
Install-ADDSForest
相当有启发性。您可能想要添加-SafeModeAdministratorPassword参数(查找该参数的文档以避免后面的一些痛苦)。


干杯,

Fred


Hi:

I have a basic script as follows

#
# Windows PowerShell script for AD DS Deployment
#

Import-Module ADDSDeployment
Install-ADDSForest `
-CreateDnsDelegation:$false `
-DatabasePath "C:\Windows\NTDS" `
-DomainMode "Win2012R2" `
-DomainName "local.ca" `
-DomainNetbiosName "LOCAL" `
-ForestMode "Win2012R2" `
-InstallDns:$true `
-LogPath "C:\Windows\NTDS" `
-NoRebootOnCompletion:$false `
-SysvolPath "C:\Windows\SYSVOL" `
-Force:$true

This creates my domain controller as first in forest. Problem is that it asks for a directory services password and then for confirmation off said password. What I need it to do is automatically have those embedded and ask no questions at all. 

Simply put I want to run a script that creates the forest and domain controller without ANY user interaction

解决方案

Hi jnlaw,

the official documentation on Install-ADDSForest is rather illuminating. You may want to add the -SafeModeAdministratorPassword parameter (look up the documentation for that parameter to save yourself some pain in the posterior).

Cheers,
Fred


这篇关于编写自动AD控制器和林,无需用户交互,例如目录服务密码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆