none
Rename and Add Computer to Domain with Single reboot RRS feed

  • Question

  • Dear Team,

    Could you please share the VB script to rename the current computer and add the same computer to domain with Single reboot.

    i have went through the below link,

    https://social.technet.microsoft.com/Forums/scriptcenter/en-US/d4901973-501d-4685-8e18-ddbb4d2ba450/join-domain-script?forum=ITCG

    it joins the domain only, additionally i need to rename the current host and it needs to add to the domain with Single reboot.

    My requirement is :

    1. Call Rename-Computer
    2. Call Join-Computer To Domain
    3. Restart

    Also if we run next time or second time. It should add with old host hostname [which we provided first time].

     Kindly help.

     -Mohan



    Monday, July 18, 2016 4:40 AM

Answers

  • Dear Team,

    Could you please share the VB script to rename the current computer and add the same computer to domain with Single reboot.

    i have went through the below link,

    https://social.technet.microsoft.com/Forums/scriptcenter/en-US/d4901973-501d-4685-8e18-ddbb4d2ba450/join-domain-script?forum=ITCG

    it joins the domain only, additionally i need to rename the current host and it needs to add to the domain with Single reboot.

    My requirement is :

    1. Call Rename-Computer
    2. Call Join-Computer To Domain
    3. Restart

    Also if we run next time or second time. It should add with old host hostname [which we provided first time].

     Kindly help.

     -Mohan



    Hi,

    people answering on the forum don't belong to a support team, they do to help and they do it in their free time.

    Please read this: This forum is for scripting questions rather than script requests

    What you're asking can be done with powershell: http://stackoverflow.com/questions/6217799/rename-computer-and-join-to-domain-in-one-step-with-powershell


    This post is provided AS IS with no warranties or guarantees, and confers no rights.
    ~~~
    Questo post non fornisce garanzie e non conferisce diritti

    Monday, July 18, 2016 8:29 AM