Forum Discussion
Christiaan_Brinkhoff
Microsoft
Jul 31, 2020(Azure) Virtual Desktop Optimization Tool now available
Optimizing images has always been an important component of preparing images as part of a traditional Remote Desktop Services (RDS) infrastructure or virtual desktop infrastructure (VDI)....
FreekBloemhof
Aug 01, 2020Brass Contributor
Nice work! Was testing the script for a while already and implmenting it to production at the moment.
I did several customizations for my needs:
- Used
$((Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ReleaseId).ReleaseId) to get the acurate Windows version
- Removed the *.log deletion at line 223 (we need logs!)
- Removed the reboot warning/config at the end of the script (want to run unattended)
- Adjusted AppXPackages.json, don't want all AppX packages get removed
- Adjusted Autologgers.json, removed the RadioMgr part (gave an error)
Please consider to built in something for customization like in the Citrix Optimizer.
After removal of the AppX packages, users with an existing profile got a lot of orphaned shortcuts in their startmenu, is there a solution for this?
Robert_Smith
Aug 03, 2020Copper Contributor
Hello FreekBloemhof ,
To prevent changes to existing user profiles on virtual desktop, either do not apply to session hosts that host local profiles, or modify the input file 'Appxpackages.json' and change the value 'VDIState' to "enabled" for each app you wish to keep. For example to keep the Sticky Notes app, change this:
{
"AppxPackage": "Microsoft.MicrosoftStickyNotes",
"VDIState": "Disabled",
"URL": "https://www.microsoft.com/en-us/p/microsoft-sticky-notes/9nblggh4qghw",
"Description": "Notetaking app"
},
to this (for Stick Notes as an example):
{
"AppxPackage": "Microsoft.MicrosoftStickyNotes",
"VDIState": "Enabled",
"URL": "https://www.microsoft.com/en-us/p/microsoft-sticky-notes/9nblggh4qghw",
"Description": "Notetaking app"
},
To fix the existing profiles, you should be able to reinstall the app(s) from the Store app, which is not removed because it is real difficult to get back. You can go through the Appx input file and you can find the URL to each app in the input file.
I hope this is helpful.
Thanks,
Robert M. Smith
- FreekBloemhofAug 18, 2020Brass Contributor
Robert_Smith thanks for your reply, but I already found that out. It is lijke Roger1175 says. We have a list of orphaned shortcuts in the startmenu for existing users (with an FSLogix profile).
I would like to remove those shortcuts/apps without resetting the profile of the users.
What I also noticed, Windows Search is beeing disalbed. From optimizing point of view I kinda get this, but it decreases the user experience a lot on Windows 10.
- Robert_SmithSep 01, 2020Copper Contributor
FreekBloemhof I have a tool that has repaired the Start Menu for another customer and does not removed user pinned items from their Start Menu. Save the following as a batch file and have the user run this (does not require elevation):
start /wait taskkill /IM StartMenuExperienceHost.exe /F rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\AC" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\AppData" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\LocalCache" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\LocalState" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\RoamingState" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\Settings" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\SystemAppData" rd /S /Q "%UserProfile%\Appdata\Local\Packages\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\TempState" Start C:\Windows\SystemApps\Microsoft.Windows.StartMenuExperienceHost_cw5n1h2txyewy\StartMenuExperienceHost.exe
- Robert_SmithAug 18, 2020Copper Contributor
Have the user open Task Manager, then end the following two processes:
- ShellExperienceHost.exe
- StartMenuExperienceHost.exe
Have them check the Start Menu and let us know the results.
- MNellenDec 21, 2020Copper Contributor
Can't get this fix to work. ShellExperienceHost.exe is not running, shutting down the StartMenuExperienceHost.exe is not helping.
Any idea how to fix that? I'm running 2004.
- tilikumtimAug 13, 2020Brass Contributor
I'm trying to reinstall the snip & sketch tool from the MS Store, but get the message 'Try again later. Something happened at our end. '
- Roger1175Aug 03, 2020Brass Contributor
Robert_Smith thanks for the information here about the Appx packages but I don't think you answer the question about how we can clean up these leftover artifacts in the case where we DO want to remove these apps but local user profiles already exist on the session host. Is there no way to do this?