Hi all,
There is a way to specify the OU where to force ESX to join AD by using the -Domain domain.com/OU1/OU2/OU3
But I have not been able to to make it working with OU containing spacelike -Domain "MyDomain.com/My first OU/Second OU"
Any Idea will be welcome...
Use single quotes if there are spaces.
Something like this
Get-VMHost -Name esx1.mydomain.test |
Get-VMHostAuthentication |
Set-VMHostAuthentication -Domain 'mydomain.test/ESXi Servers' -JoinDomain -Username "administrator@mydomain.test" -Password "password"
This adds the ESXi host to the correct OU
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I'm depressed:smileycry:... Can not make it working inside a script, while it works well from a command prompt...
Powershell and strings has always been a grey area for me...
Perhaps attach your script so we can have a look ?
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
I'm more depressed :smileycry:... This whole story was just a typo on the long OU path we are using...
Thks a lot to LucD for his always positive & quick feedback.