I am trying to run an MDT task sequence that will sysprep only with no capture as per https://scriptimus.wordpress.com/2012/03/16/mdt-2012-sysprep-and-shutdown/, but the computer is being shutdown right after sysprep runs and MDT then hangs at running sysprep step and never completes.
I see in the logs that it is running the sysprep command with the /quit switch and not the /shutdown switch, so I would expect MDT to simply exit sysprep when done and complete the final steps on the task sequence including lti cleanup before shutting down.
I am using the latest Server 2019 iso image from February 2021 to build this reference image.
Here are the final log entries where the deployment hangs:
Property SysprepPendingFileRenameOperations is now = OnlyRebootOnce LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
No Pending File Rename Operations (isEmpty). LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
Cleaning up Autologon registry values LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
The unattend.txt file was not found. LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
Found existing unattend.xml at C:\MININT\unattend.xml LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
Property OSDAnswerFilePath is now = C:\MININT\unattend.xml LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
Copying C:\MININT\unattend.xml to C:\windows\system32\sysprep\unattend.xml LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
About to run command: C:\windows\system32\sysprep\sysprep.exe /quiet /generalize /oobe /quit /unattend:C:\windows\system32\sysprep\unattend.xml LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
Command has been started (process ID 1412) LTISysprep 3/5/2021 12:46:45 PM 0 (0x0000)
ZTI Heartbeat: command has been running for 0 minutes (process ID 1412) LTISysprep 3/5/2021 12:46:46 PM 0 (0x0000)
Event 41003 sent: ZTI Heartbeat: command has been running for 0 minutes (process ID 1412) LTISysprep 3/5/2021 12:46:46 PM 0 (0x0000)
Regards,
DLofstedt