How Can I Sysprep a Windows 11 Host with Stubborn Appx Packages?

0
7
Asked By TechNinja42 On

I'm trying to sysprep a previously used Windows 11 Multi-Session host, but I'm running into problems because there are Appx packages installed in the user context that won't go away. I've been using the usual command, `Remove-AppxPackage -allusers %packagename%`, but I'm getting errors saying, 'The package could not be installed because resources it modifies are currently in use.' Even when I run it from SYSTEM context with no users signed in, I still get the same result. I've already deleted the user from the Advanced Users menu and tried `Remove-AppxPackage -user %SID% -package %PackageFullName%`, but that just marks the package for removal upon the user's next login, which will never happen. Manually clearing the registry of any references hasn't helped either. The specific package I'm dealing with is `Microsoft.Ink.Handwriting.Main.en-US.1.0.1`. Any suggestions would be greatly appreciated!

2 Answers

Answered By VirtualMaster88 On

Have you tried preparing a clean image using audit mode? That’s usually the go-to method for setting up images. I know you mentioned issues with audit mode, but that's typically the way to go—even before Appx packages were a thing. The VM's Azure environment might complicate it, but it could still work if you give it another shot!

TechNinja42 -

Thanks for the suggestion! I did try audit mode, but ran into the same issues. Since this is in Azure for AVD, it can be tricky, but I'll give it another go!

Answered By NewbieWizard99 On

This is a common headache since Appx packages are involved. Honestly, if it were me, I'd suggest starting fresh and creating a clean image next time. I know it sounds like a hassle, but it might save you tons of time compared to troubleshooting this.

Related Questions

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.