A fatal error occurred while trying to sysprep the machine

The following messages may be logged in the Setuperr.log file:

[0x0f0082] SYSPRP LaunchDll:Failure occurred while executing ‘C:\Windows\system32\msdtcprx.dll,SysPrepDtcCleanup’, returned error code -2146434815[gle=0x000000b7][0x0f0070] SYSPRP RunExternalDlls:An error occurred while running registry sysprep DLLs, halting sysprep execution. dwRet = -2146434815[gle=0x000000b7][0x0f00a8] SYSPRP WinMain:Hit failure while processing sysprep cleanup providers; hr = 0x80100101[gle=0x000000b7].

Fix 0x0f0082, 0x0f0070, 0x0f00a8 Sysprep errors

We will be taking a look at the following fixes to get rid of Sysprep errors 0x0f0082, 0x0f0070 and 0x0f00a8,

1] Using Command Prompt

This error is caused due to the MSDTC Service being malfunctioned or not working properly. To resolve this issue, you need to Uninstall and then Reinstall the MDSTC Service. Run Command Prompt as Administrator and execute the following command:

This will uninstall the MSDTC Service on your computer. Now, in order to install the MSDTC Service, you need to type in the following command in the Command Prompt command line,

Now, all you need to do is close the Command Prompt window and check if this has fixed your issues. This method has proven to be an effective fix for a number of users. Both of these are fixes that apply to other versions of the Windows operating system including Windows 10, but this error is mostly encountered on Windows 7. Read: Sysprep was not able to validate your Windows installation.

2] Check Registry Settings

Hit the WINKEY+R button combination to launch the Run utility, type in regedit and hit Enter. Once Registry Editor opens, navigate to the following key-

Now, check if you find a DWORD value named as SkipRearm.  Double-click on it and change its Value data to as 1. Reboot your computer for the changes to take effect. Read: A fatal error occurred while trying to sysprep the machine. Let us know if our suggestions helped.