Domain Join Ou
Join computer to domain and specify ou path with powershell.
Domain join ou. Ou oupath specifies the organizational unit ou under which you want to create the account. Thankfully we can automate this with powershell when we join the computers to the domain. Add computer domainname domain cred domain administrator passthru oupath ou xxx dc domain dc domain.
When you join a computer to the domain it will by default go the computers folder. Enter the full path distinguished name to the organizational unit ou the computer accounts are to be created. Idealy i would like to use ps to join the domain like you have listed but based on the first 3 letters of the computer name typed in join specific ous for instance if your name name was par1234 join the paris ou if the computer name was aus1234 join the australian ou.
For example enter ou mine dc contoso dc com. This must occur before the the apply windows setting task which will in turn consume the value of the osddomainouname variable and populate the unattend xml file in use so that when windows setup runs and joins the domain it will join it to the ou specified in this variable. In other way.
Don t enter quotation marks. Best practice is to pre create the computer account in ad before joining to domain. Enter the fully qualified domain name fqdn the devices are to join.
This way machine s will not be bothered with policies during the. Deploying machines which join the domain into an ou that has policies residing under that ou can cause much pain during deployment. You can use power shell cmdlet.
You must specify the full rfc 1779 distinguished name of the ou. If you do not specify this parameter then netdom join uses the domain to which the current computer belongs. Etc but if this is too difficult to do then i could do with a drop down.