Sysprep Fails on 20H2

Joe Dry 26 Reputation points
2021-01-16T16:34:45.267+00:00

Bit of help on Sysprep needed. I'm trying to capture a master image from Hyper-V (Windows 10 Pro 20H2) and I'm having issues to do with the windows store apps.

I have run:
Get-AppxPackage -AllUsers | Remove-AppxPackage
and
Get-AppxProvisionedPackage -online | Remove-AppxProvisionedPackage -online

and I still get this in the logs:2021-01-16 15:47:06, Error SYSPRP Package Microsoft.549981C3F5F10_1.1911.21713.0_x64__8wekyb3d8bbwe was installed for a user, but not provisioned for all users. This package will not function properly in the sysprep image.
2021-01-16 15:47:06, Error SYSPRP Failed to remove apps for the current user: 0x80073cf2.
2021-01-16 15:47:06, Error SYSPRP Exit code of RemoveAllApps thread was 0x3cf2.
2021-01-16 15:47:06, Error SYSPRP ActionPlatform::LaunchModule: Failure occurred while executing 'SysprepGeneralizeValidate' from C:\Windows\System32\AppxSysprep.dll; dwRet = 0x3cf2
2021-01-16 15:47:06, Error SYSPRP SysprepSession::Validate: Error in validating actions from C:\Windows\System32\Sysprep\ActionFiles\Generalize.xml; dwRet = 0x3cf2
2021-01-16 15:47:06, Error SYSPRP RunPlatformActions:Failed while validating Sysprep session actions; dwRet = 0x3cf2
2021-01-16 15:47:06, Error [0x0f0070] SYSPRP RunDlls:An error occurred while running registry sysprep DLLs, halting sysprep execution. dwRet = 0x3cf2
2021-01-16 15:47:06, Error [0x0f00d8] SYSPRP WinMain:Hit failure while pre-validate sysprep generalize internal providers; hr = 0x80073cf2

I cannot uninstall this package individually either, help would be much appreciated.

Joe

Windows 10
Windows 10
A Microsoft operating system that runs on personal computers and tablets.
11,734 questions
Windows 10 Setup
Windows 10 Setup
Windows 10: A Microsoft operating system that runs on personal computers and tablets.Setup: The procedures involved in preparing a software program or application to operate within a computer or mobile device.
1,949 questions
{count} vote

Accepted answer
  1. Tyler Fleming 101 Reputation points
    2021-02-05T21:56:03.22+00:00

    I am running into this issue as well, where the resolution steps found in this article (https://learn.microsoft.com/en-us/troubleshoot/windows-client/deployment/sysprep-fails-remove-or-update-store-apps) do not solve the issue.

    Edit: Solution (for now), copied from my comment below.

    I have been able to successfully get sysprep to work BUT it required that I never open the start menu. Win + X and Powershell are your friend. The issue is specifically opening the Windows Start menu because that kicks off all the Windows Store/Appx Updates on the machine. You CAN use file explorer and what not. I have a theory that you could probably also use the Cortana Search (by click the Magnifying Glass icon and NOT the start menu) as well; but haven't tested that yet.

    2 people found this answer helpful.

7 additional answers

Sort by: Most helpful
  1. RS4KING 191 Reputation points
    2021-03-04T15:51:43.593+00:00

    I came across these errors in my log, so I decided to run the powershell command to remove the Packages. I did the first one, cleared the log (for easier reading), ran the sysprep and got another error for another Appx Package. I did the PS command to remove that package, cleared the log, ran the sysprep again etc. I had to keep doing this for like 15 different apps.

    Finally the sysprep did its thing and restarted, just when I thought it was going to work, it loaded back into Windows and my start menu was all jacked up. It kept telling me "Critical Error - your start menu suffered a critical error" any time I tried to click on Start. I tried to reinstall shellexperience via PS and nothing worked, so I ended up just reinstalling a fresh copy of Windows 10 again and came back to the drawing board.

    I'm going to try what TylerFleming suggested and not click the start menu at all. After the fresh install of Windows, I'm going to use alt-x and kick off windows updates via command prompt. If I can at least capture an Image with the latest updates and no programs, I would call it a win. Thanks for your suggestions.


  2. Luis Vital Almeida 1 Reputation point
    2021-04-14T23:10:54.917+00:00
    0 comments No comments

  3. John Carlson 11 Reputation points
    2023-11-19T17:46:48.3033333+00:00

    Have you tried Audit mode?

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.