0
votes

I'm fairly new to puppet and still getting familiar with it. I'm trying to install AD, promote the server to DC and create OU and some users with "jriviere/windows_ad" module (https://forge.puppet.com/jriviere/windows_ad).

I succeed in installing the AD but always fail when configuring forest (Promoting to DC) with the following error.

Error: 'Import-Module ADDSDeployment; Install-ADDSForest -Force -DomainName devops.local -DomainMode 6 -DomainNetbiosName devops -ForestMode 6 -DatabasePath c:\windows\ntds -LogPath c:\windows\ntds -SysvolPath c:\windo\sysvol -SafeModeAdministratorPassword (convertto-securestring 'P@ssw0rd' -asplaintext -force) -InstallDns' returned 1 instead of one of [0] Error: /Stage[main]/Windows_ad::Conf_forest/Exec[Config ADDS]/returns: change from notrun to 0 failed: 'Import-Module ADDSDeployment; Install-ADDSForest -Force-DomainName devops.local -DomainMode 6 -DomainNetbiosName devops -ForestMode 6 -DatabasePath c:\windows\ntds -LogPath c:\windows\ntds -SysvolPath c:\windows\sysvol -SafeModeAdministratorPassword (convertto-securestring 'P@ssw0rd' -asplaintext -force) -InstallDns' returned 1 instead of one of [0]

Notice: /Stage[main]/Windows_ad/Anchor[windows_ad::end]: Dependency Exec[ConfigADDS] has failures: true Warning: /Stage[main]/Windows_ad/Anchor[windows_ad::end]: Skipping because of failed dependencies

I can provide the parameters used but they are a lot and I don't want this thread to be long for no reason.

No matter what parameters I change it still fails, I tried promoting it manually or with power-shell script of the VM itself and I succeeded without any problems.

Any help is appreciated as I'm beginning to give up.

1
Your error message is pretty clear.. Install-ADDSForest -Force -DomainName devops.local -DomainMode 6 -DomainNetbiosName devops -ForestMode 6 -DatabasePath c:\windows\ntds -LogPath c:\windows\ntds -SysvolPath c:\windo\sysvol -SafeModeAdministratorPassword (convertto-securestring 'P@ssw0rd' -asplaintext -force) -InstallDns' returned 1 instead of one of [0]Maximilian Burszley
yes I'm aware that its clear, and as I said I tried the same steps with the same parameters with power-shell and it succeeded. My question is why is it failing with puppet?Mostafa Ossama

1 Answers

0
votes

I used this and worked fine. First run puppet module install puppetlabs-dsc on Puppet master