none
Automatic restart after domain join in MDT 2012: How to stop?

    Question

  • Is there an easy way to stop the reboot after DomainJoin that's now present in MDT 2012 deployments? The reboot behavior didn't happen in MDT 2010 and it's kind of annoying. Since our GPO policies change the name of the default administrator, autologin is broken upon reboot. There's a few ways to get around that - traditionally I've used batch scripts before the reboot to change the reg entry for the admin- but I was just curious if there's something even easier.

    From the BDD.log on an example device:

    JoinDomain Succeeded ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    Initiating a reboot. ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    Property LTISuspend is now =  ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    Property SMSTSRetryRequested is now = true ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    Property SMSTSRebootRequested is now = true ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    ZTIDomainJoin processing completed successfully. ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)
    Event 41001 sent: ZTIDomainJoin processing completed successfully. ZTIDomainJoin 6/21/2012 10:11:15 AM 0 (0x0000)


    -Nick O.

    Thursday, June 21, 2012 6:27 PM

Answers

  • Only 2 ways I can think of

    1 - Don't use ZTIDomainJoin.wsf and create your own custom script to join the domain that doesn't reboot

    2 - Modify ZTIDomainJoin.wsf to not reboot.

    For option 2 to it's lines 189 and 190 that you would want to comment out as this functionality is coded into the script without an optional parameter to suppress the reboot.

    Personally, I hate to modify the provided scripts as it means you have to remember what was changed and then re-hack the scripts when there's a new release but it's down to personal preference and the issue you're having though really.

    • Marked as answer by Nick Ourso Thursday, June 21, 2012 8:20 PM
    Thursday, June 21, 2012 6:37 PM

All replies

  • Only 2 ways I can think of

    1 - Don't use ZTIDomainJoin.wsf and create your own custom script to join the domain that doesn't reboot

    2 - Modify ZTIDomainJoin.wsf to not reboot.

    For option 2 to it's lines 189 and 190 that you would want to comment out as this functionality is coded into the script without an optional parameter to suppress the reboot.

    Personally, I hate to modify the provided scripts as it means you have to remember what was changed and then re-hack the scripts when there's a new release but it's down to personal preference and the issue you're having though really.

    • Marked as answer by Nick Ourso Thursday, June 21, 2012 8:20 PM
    Thursday, June 21, 2012 6:37 PM
  • You can also have a staging OU that blocks all your GPOs (and therefore prevent the local admin rename).

    Here's a blog post by Johan Arwidmark that explain what group policies break deployment using MDT.
    http://www.deployvista.com/Default.aspx?tabid=78&EntryID=147

    Thursday, June 21, 2012 7:45 PM
  • Thanks for thetips.

    Looks like modifying the ZTIDomainJoin.wsf will be easiest for me. I've already modified the script to account for a legal disclaimer, so I'm comfortable wiith the change. I'll just be sure to make a copy of the default script.


    -Nick O.


    • Edited by Nick Ourso Thursday, June 21, 2012 8:21 PM
    Thursday, June 21, 2012 8:21 PM