Sysprep was not able to validate your Windows installation. Sysprep can be really useful if you want to save up some time and automatically deploy an operating system on a group of computers. On a machine running Windows 8, 8.1, 10 or even Windows Server 2012, 2012R2 or 2016 you can get an error when syspreping the machine. However, when you are faced with one of its issues, it can be, at times, an obstacle to pass. You can learn how to deal with the issue by going through this article.
So, look in C:\Windows\System32\Sysprep\Panther and open the “setupact.log” file:
Error [0x0f0036] SYSPRP spopk.dll:: Sysprep will not run on an upgraded OS. You can only run Sysprep on a custom (clean) install version of Windows.
Error [0x0f0082] SYSPRP ActionPlatform::LaunchModule: Failure occurred while executing ‘Sysprep_Clean_Validate_Opk’ from C:\Windows\System32\spopk.dll; dwRet = 0x139f
Error SYSPRP SysprepSession::Validate: Error in validating actions from C:\Windows\System32\Sysprep\ActionFiles\Cleanup.xml; dwRet = 0x139f
Error SYSPRP RunPlatformActions:Failed while validating SysprepSession actions; dwRet = 0x139f
Error [0x0f0070] SYSPRP RunExternalDlls:An error occurred while running registry sysprep DLLs, halting sysprep execution. dwRet = 0x139f
Error [0x0f00d8] SYSPRP WinMain:Hit failure while pre-validate sysprep cleanup internal providers; hr = 0x8007139f
What we see here is that for some reason Windows thinks it has been upgraded.
Well, if you navigate to the file specified in the error message and go through it, you will find the possible cause of the error. In different scenarios, it can vary, therefore, for a basic insight, it is often due to the following factors:
- Windows Store apps: In some cases, the error occurs if you have downloaded an app from the Windows Store which is preventing the tool. Mostly, Candy Crush and Twitter were found to be the culprits.
- Default Windows apps: Another reason due to why the error occurs can be the removal of default Windows applications. If you have, prior to running Sysprep, removed any Windows default app, that might be the cause of the error.
Solution 1: Windows Registry Editor
Navigate to:
HKEY_LOCAL_MACHINE\SYSTEM\Setup\
In the Setup node you will find a REG_DWORD «Upgrade» with a value of probably “0” (meaning not an upgrade…)
Just delete the «Upgrade» key and you are good to go!
Solution 2: Installing Default Windows Apps
You will have to install the default applications again. Here’s how to do it:
- Go to the Start Menu, type in Windows Powershell, right-click on it and select ‘Run as an administrator’ or right-click on Start Menu and select Windows PowerShell (Admin).
- Once the Window Powershell loads up, paste in the following command and press Enter:
Get-AppxPackage -AllUsers| Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"}
Solution 3: Creating a New Administrator Account (non-domain solution)
Some users have reported that upon creating a new administrator account and then deleting all the old ones, their issue was resolved. Here’s how to do it:
- Press Windows Key + I to open Settings.
- Go to Accounts and then navigate to Family & other users.
- Click Add someone else to this PC.
- Afterward, click I don’t have this person’s sign-in information. Creating New Local User Account
- Then, click on ‘Add user without a Microsoft account’ and enter a username of your choice and password.
- Click on the newly created account and select Change account type.
- On the pop-up, from the list under Account type, choose Administrator and then click OK. Changing User Account Type
- Restart your system and login using the newly created account.
- Press Windows Key + I again and go to Accounts.
- Switch to the Family & other users tab and select your old account.
- Click ‘Remove’ to remove the user account.
- Restart your system again and then try to run Sysprep.