Hello Luca Brunner,
The recurring temporary profile issue in your RDSH farm is indeed caused by stale registry hives under HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList that block User Profile Disks from mounting. The supported approach is to clear those orphaned keys and force the session hosts to rebuild the profile mapping. You can use a PowerShell script that enumerates all subkeys in ProfileList, checks for ProfileImagePath values pointing to C:\Users\TEMP or to non‑existent paths, and then removes those keys. For example:
powershell
$profileList = "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList"
Get-ChildItem $profileList | ForEach-Object {
$path = (Get-ItemProperty $_.PSPath).ProfileImagePath
if ($path -like "*TEMP*" -or !(Test-Path $path)) {
Remove-Item $_.PSPath -Recurse -Force
}
}
Run this on the affected RDSH hosts, then reboot to release any locked hives. This ensures UPDs can mount cleanly on next logon. Always back up the registry before executing, and confirm no active sessions are using those profiles. If the issue persists across the farm, you may need to apply the script consistently to all hosts and validate that the User Profile Service is healthy.
If my answer is useful for you, please hit Accept the answer to support me.
Thank you,
HL.