Windows Server TechCenter > Windows Server Forums > Setup Deployment > WDS: Creating computer AD accounts under specific OU with down-level clients
Ask a questionAsk a question
 

AnswerWDS: Creating computer AD accounts under specific OU with down-level clients

  • Wednesday, April 23, 2008 9:26 AMQuitch Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    I think I have my terminology correct here Wink

     

    With Windows Vista you can create an unattend.xml file which will allow them to be joined to the domain and filed under a particular OU immediately. Very handy for the application of GPOs during first boot.

     

    Is there a way this can be done for down-level clients e.g. Windows XP?

Answers

  • Wednesday, April 23, 2008 11:42 PMStuart Hudman Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

     

    In the sysprep.inf file, you can use the following section :

     

    [Identification]
        MachineObjectOU="OU=London,OU=UK,DC=example,DC=com"

     

     

    You could always pre-stage the computer acccounts in the domain, before you join them...that way, they will go where you want.

     

     

    If you actually want ALL computer accounts to be created in a certain OU (oppose to the default Computer container), you can use the REDIRCMP command which will make the defined OU, the default. You only need to do this once in your domain:

     

    SYNTAX:

    redircmp CONTAINER-DN

     

    where CONTAINER-DN is the distinguished name of the container that will become the default location for newly created computer objects 

    Note: The domain functional level must be at least Windows Server 2003

    for example REDIRCMP OU=London,OU=UK,DC=example,DC=com

     

     

    Stuart Hudman

     

     

     

  • Friday, April 25, 2008 10:39 AMChang Yin Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hello,

     

    Many thanks to Stuart for sharing these information.

     

    Yes, you can use the sysprep.inf file to join your computer to a specified OU after you add that entry into the file. However, please note that in this way, the computer name will not be generated into a customized format automatically. So you may need to manually name it during the installation.

     

    Just for your reference, if you want the computer name to be generated automatically and the computer to be added into the specified OU, and if you don't want to create the computer account manually in the Active Directory, you can try the following steps:

     

    Step 1.

    =====

     

    Open the Windows Deployment Services console, in the left pane, navigate to "Windows Deployment Services\<ServerName>" node, and right-click this node. Click Properties and then click the Directory Services tab. On this tab, you can change the computer naming format and set the location where client computer accounts will be created.

     

    Step 2.

    =====

     

    Configure the sysprep.inf file. At a minimum, the sysprep.inf should look like:

     

    [Identification]

    DoOldStyleDomainJoin=Yes

     

    [Networking]

     

    [UserData]

     

    Put this sysprep.inf file under the path "RemoteInstall\Images\<ImageGroupName>\<ImageName>\$OEM$\$1\Sysprep" (you may need to create \<ImageName>\$OEM$\$1\Sysprep folder). Please confirm that this is the only unattend answer file that associated with the image.

     

    For more details about this, please refer to:

     

    Automating the Domain Join and Computer Naming:

    http://technet2.microsoft.com/windowsserver2008/en/library/6636ff28-4dd4-4b7a-aba6-387655b602711033.mspx?mfr=true

     

    Now, during the deployment, the computer account will be generated automatically as the settings you specified in step 1.

     

    Good luck.

     

    Best regards,

    Chang Yin

All Replies

  • Wednesday, April 23, 2008 11:42 PMStuart Hudman Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

     

    In the sysprep.inf file, you can use the following section :

     

    [Identification]
        MachineObjectOU="OU=London,OU=UK,DC=example,DC=com"

     

     

    You could always pre-stage the computer acccounts in the domain, before you join them...that way, they will go where you want.

     

     

    If you actually want ALL computer accounts to be created in a certain OU (oppose to the default Computer container), you can use the REDIRCMP command which will make the defined OU, the default. You only need to do this once in your domain:

     

    SYNTAX:

    redircmp CONTAINER-DN

     

    where CONTAINER-DN is the distinguished name of the container that will become the default location for newly created computer objects 

    Note: The domain functional level must be at least Windows Server 2003

    for example REDIRCMP OU=London,OU=UK,DC=example,DC=com

     

     

    Stuart Hudman

     

     

     

  • Friday, April 25, 2008 10:39 AMChang Yin Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer

    Hello,

     

    Many thanks to Stuart for sharing these information.

     

    Yes, you can use the sysprep.inf file to join your computer to a specified OU after you add that entry into the file. However, please note that in this way, the computer name will not be generated into a customized format automatically. So you may need to manually name it during the installation.

     

    Just for your reference, if you want the computer name to be generated automatically and the computer to be added into the specified OU, and if you don't want to create the computer account manually in the Active Directory, you can try the following steps:

     

    Step 1.

    =====

     

    Open the Windows Deployment Services console, in the left pane, navigate to "Windows Deployment Services\<ServerName>" node, and right-click this node. Click Properties and then click the Directory Services tab. On this tab, you can change the computer naming format and set the location where client computer accounts will be created.

     

    Step 2.

    =====

     

    Configure the sysprep.inf file. At a minimum, the sysprep.inf should look like:

     

    [Identification]

    DoOldStyleDomainJoin=Yes

     

    [Networking]

     

    [UserData]

     

    Put this sysprep.inf file under the path "RemoteInstall\Images\<ImageGroupName>\<ImageName>\$OEM$\$1\Sysprep" (you may need to create \<ImageName>\$OEM$\$1\Sysprep folder). Please confirm that this is the only unattend answer file that associated with the image.

     

    For more details about this, please refer to:

     

    Automating the Domain Join and Computer Naming:

    http://technet2.microsoft.com/windowsserver2008/en/library/6636ff28-4dd4-4b7a-aba6-387655b602711033.mspx?mfr=true

     

    Now, during the deployment, the computer account will be generated automatically as the settings you specified in step 1.

     

    Good luck.

     

    Best regards,

    Chang Yin

  • Friday, October 16, 2009 3:20 PMjamesreeve Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    Hello,

     

    Many thanks to Stuart for sharing these information.

     

    Yes, you can use the sysprep.inf file to join your computer to a specified OU after you add that entry into the file. However, please note that in this way, the computer name will not be generated into a customized format automatically. So you may need to manually name it during the installation.

     

    Just for your reference, if you want the computer name to be generated automatically and the computer to be added into the specified OU, and if you don't want to create the computer account manually in the Active Directory, you can try the following steps:

     

    Step 1.

    =====

     

    Open the Windows Deployment Services console, in the left pane, navigate to "Windows Deployment Services\<ServerName>" node, and right-click this node. Click Properties and then click the Directory Services tab. On this tab, you can change the computer naming format and set the location where client computer accounts will be created.

     

    Step 2.

    =====

     

    Configure the sysprep.inf file. At a minimum, the sysprep.inf should look like:

     

    [Identification]

    DoOldStyleDomainJoin=Yes

     

    [Networking]

     

    [UserData]

     

    Put this sysprep.inf file under the path "RemoteInstall\Images\<ImageGroupName>\<ImageName>\$OEM$\$1\Sysprep" (you may need to create \<ImageName>\$OEM$\$1\Sysprep folder). Please confirm that this is the only unattend answer file that associated with the image.

     

    For more details about this, please refer to:

     

    Automating the Domain Join and Computer Naming:

    http://technet2.microsoft.com/windowsserver2008/en/library/6636ff28-4dd4-4b7a-aba6-387655b602711033.mspx?mfr=true

     

    Now, during the deployment, the computer account will be generated automatically as the settings you specified in step 1.

     

    Good luck.

     

    Best regards,

    Chang Yin

    Hi
    I want to get wds to create machine accounts in my ou created at root called "Imaged Machines". I have the option set under the WDS console to do this. However, it seems it's ignoring this setup and Sysprep itself is creating the machine name, and, I guess, creating the accont in the computers folder. I can tell this because the name format does not match the format selected in the wds console.
    So I think this happens because I embed the sysprep.inf file in the image itself (copy to c:\sysprep) on the image before I sysprep the machine.
    Is this where I'm going wrong?  I guess I have to copy the sysprep file to the wds server and include it in the $OEM$ structure?




    James Reeve MCSE