Mick's IT Blogs

Mick's IT Blogs

26 January 2012

"The Computer Restarted unexpectedly or encountered an unexpected error" during sysprep

Posted By: Mick Pletcher - 10:20 AM
The error "The Computer Restarted unexpectedly or encountered an unexpected error" is an annoying error that completely stops the sysprep setup process. The system does not need to be rebuilt. The issue that caused it on one of the machines we encountered this on was due to the fact that some profiles had been deleted from the file structure, but the registry entries were left in tact. In order to fix this issue, you will need to change the registry key HKLM/SYSTEM/SETUP/STATUS/ChildCompletion Setup.exe from 1 to 3. This will allow the sysprep process to complete. The drivers will not be installed and likely, the system will not be joined to a domain, if applicable. The main thing is that the OS can now be booted up and logged into. Here is the contents of a reg file that will change it for you.

In order to get to the registry, when the above listed error appears, hit Shift-F10. This will bring up a command prompt window. Type regedit and then make the registry change. At that point, reboot the machine and it should boot up into Windows 7.

NOTE: This was performed on a Windows 7 64-bit machine. Per a reply to this blog, it was also confirmed to work on Windows Server 2008.

 Windows Registry Editor Version 5.00  
 [HKEY_LOCAL_MACHINE\SYSTEM\Setup\Status\ChildCompletion]  
 "setup.exe"=dword:00000003  

Copyright © 2013 Mick's IT Blogs™ is a registered trademark.