sysprep windows 11 pro

Noordeen Uthman 21 Reputation points
2025-10-10T19:46:09.5733333+00:00

Hi all, trying to sysprep a Windows 11 pro device, but am unable to uninstall or clear out MS Zune music, it keeps coming back with an error message. Even when I run the various PowerShell commands.

Would really appreciate some help.

Windows for business | Windows Client for IT Pros | Devices and deployment | Configure application groups
{count} votes

Answer accepted by question author
  1. Finn Dang 715 Reputation points Independent Advisor
    2025-10-10T21:32:00.0933333+00:00

    Hello Noordee,

    That Zune Music entry is the modern Media Player app. Sysprep can choke if a Store app is installed/updated for any user or still provisioned. Remove both the installed and provisioned copies, then run Sysprep.

    Steps (elevated PowerShell):

    # 1) Optional but recommended: prevent Store auto-updates during prep
    reg add HKLM\SOFTWARE\Policies\Microsoft\WindowsStore /v AutoDownload /t REG_DWORD /d 2 /f
    
    # 2) Remove the app for all users
    Get-AppxPackage -AllUsers *ZuneMusic* | Remove-AppxPackage -AllUsers
    Get-AppxPackage -AllUsers Microsoft.MediaPlayer* | Remove-AppxPackage -AllUsers
    
    # 3) Remove it from the image so it doesn’t return for new users
    Get-AppxProvisionedPackage -Online |
      Where-Object {$_.DisplayName -like "*ZuneMusic*" -or $_.DisplayName -like "Microsoft.MediaPlayer*"} |
      Remove-AppxProvisionedPackage -Online
    

    DISM alternative (if PowerShell says it’s provisioned/immutable):

    dism /online /Get-ProvisionedAppxPackages | findstr /I zune
    dism /online /Remove-ProvisionedAppxPackage /PackageName:<name from command above>
    

    Reboot (still offline if possible) and run:

    C:\Windows\System32\Sysprep\Sysprep.exe /generalize /oobe /shutdown

    If Sysprep still fails, post the exact Sysprep error line from C:\Windows\System32\Sysprep\Panther\setuperr.log and the output of:

    Get-AppxPackage -AllUsers *ZuneMusic*,Microsoft.MediaPlayer* | Select Name, PackageFullName
    Get-AppxProvisionedPackage -Online | Where DisplayName -match "Zune|MediaPlayer" | Select DisplayName, PackageName
    

    so we can pinpoint the remaining package. I hope you find this helpful!
    Regards,
    Finn.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

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