This is still not fixed. Just did a new Citrix install, 2203 LTSR on W2019 with latest Fslogix version (FSLogix 2201 hotfix 2 (2.9.8228.50276).
Credentials folders are still not deleted on logoff.
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Problem is described by M4deman under unclean-logoff-causing-locked-files-until-server-reboot
It seems to have something to do with the 2009 version.
The latest version of FSLogix is installed whats-new
Description
After a user logoff, the "System" Process (PID 4) locks the following folders:
C:\Users\local_username\AppData\Local\Microsoft\Credentials
C:\Users\local_username\AppData\Roaming\Microsoft\Credentials
The user is completely logged of, according to Task Manager.
In the FSLogix Profile Log file I can see the following:
[07:53:55.601][tid:00000c90.0000ce44][ERROR:00000020] Delete profile failed for sid S-1-5-21-3364776539-3721753400-1968955100-1179, Cleaning up manually. (Der Prozess kann nicht auf die Datei zugreifen, da sie von einem anderen Prozess verwendet wird.)
The last sentence means that the process cannot access the file, because another process already uses it.
Also the whole "local_username" folder cannot be deleted:
[08:23:15.479][tid:00000c90.0000bcc4][WARN: 00000005] Failed to delete C:\Users\local_usename (Access is denied)
Access Denied
Does someone have any info on this behaviour?
This is still not fixed. Just did a new Citrix install, 2203 LTSR on W2019 with latest Fslogix version (FSLogix 2201 hotfix 2 (2.9.8228.50276).
Credentials folders are still not deleted on logoff.
We have the same issue with LTSR 2203 CU1, Server 2019, and latest version of FSLogix. Opened a ticket with support and they blamed the Citrix DLLs, specifically the special redirection DLL SfrHook
I just ended up closing the ticket rather than going down that rabbit hole.
Right now, I keep removing exclusions from our Redirections.xml. All the folders that it's complained about so far have mostly been empty. Every week it's a new folder so we'll see if I ever find the center of the lollipop.
Not sure if it helps anyone, but for two customers I have excluded the c:\windows\system32\lsass.exe process from Microsoft Defender (process exclusion in Defender GPO). This is the process keeping the credentials folder locked.
And it seems like the issue is gone. 9 days already without issues and every single profile is being deleted at logoff. No local_ directories that are left behind. No more black screens on login or stuck VHDX files. One environment is rebooted only one time each week and showed no more issues at all so I'm a happy camper for now, until the next issue.
This may not help everyone as I am sure there's more than one issue.
New verison is out - 2210!
Making a sanity check in powershell. Seeing if refcount is non-zero but the user is logged out. I take out the "DOMAIN\" part of the user. I wish the logon denials were logged when auditing is turned on.
# profilecheck.ps1
function sid2user {
param($id)
$SID = New-Object System.Security.Principal.SecurityIdentifier($id)
$objUser = $SID.Translate([System.Security.Principal.NTAccount])
$objUser.Value -replace 'DOMAIN\\'
}
$qusers = quser
get-itemproperty HKLM:\SOFTWARE\Microsoft\Windows` NT\CurrentVersion\ProfileService\References\* refcount |
select @{n='Sid';e={$_.pschildname}},
@{n='User';e={sid2user $_.pschildname}},
@{n='Refcount';e={$_.refcount[0]}},
@{n='LoggedOut';e={-not [bool]($qusers|select-string (sid2user $_.pschildname))}}
# end profilecheck.ps1
$avd = 0..4 | % tostring avd-0
icm $avd profilecheck.ps1 | ? refcount | ? loggedout | ft
Sid User Refcount LoggedOut PSComputerName RunspaceId
--- ---- -------- --------- -------------- ----------
S-2-6-31-1423303271-3025932689-4187700767-524288 abc123 3 True AVD-3 84594543-d151-53ee-ca1e-ec8a5186ca22