FsLogix - Unclean logoff causing locked files until server reboot

Much R 101 Reputation points
2021-01-13T16:29:50.18+00:00

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?

Windows for business | Windows Client for IT Pros | User experience | Remote desktop services and terminal services
Windows for business | Windows Client for IT Pros | User experience | FSLogix
{count} votes

106 answers

Sort by: Most helpful
  1. daniel reid 1 Reputation point
    2021-05-05T07:53:11.73+00:00

    In an effort to keep this thread active I'd just like to describe our current situation.

    We have recently deployed FSLogix in our environment. As discussed in this thread, in our case, it seems to be that when a user is logged off due to inactivity (set to 8 hours in our environment) then two things happen, one is that sometimes the profile disk will stay attached on that machine until it is administratively removed. The second issue I'm finding, through reading the ODFC logs, is that when the user is logged off due to inactivity the following logs are displayed when trying to detach the container, saying that the "User is not a member of the include group" even though it they definitely are (and had been using FSLogix during that session).

    [12:32:12.701][tid:00000dac.00001abc][INFO] ===== Begin Session: Detach Outlook Data Folder Container: George
    [12:32:12.701][tid:00000dac.00001abc][INFO] Configuration Read (DWORD): SOFTWARE\Policies\FSLogix\ODFC\Enabled. Data: 1
    [12:32:12.701][tid:00000dac.00001abc][INFO] Include group SID: S-1-5-21-2421605326-1487003826-3486927839-16969
    [12:32:12.701][tid:00000dac.00001abc][INFO] Exclude group SID: S-1-5-21-2421605326-1487003826-3486927839-16970
    [12:32:12.701][tid:00000dac.00001abc][INFO] Reason set to 1: User is not a member of the include group
    [12:32:12.701][tid:00000dac.00001abc][INFO] Reason set to 1: User is not a member of the include group
    [12:32:12.701][tid:00000dac.00001abc][INFO] User is not a member of the include group
    [12:32:12.716][tid:00000dac.00001abc][INFO] Do not handle this session
    [12:32:12.716][tid:00000dac.00001abc][INFO] ===== End Session: Detach Outlook Data Folder Container: George

    Once this has happened I've found that I'm having to go into the registry and remove the session key for that users SID and then the next time they log in it will work as normal. Otherwise it will say a log message similar to "The container is already connected to another session" and the profile will not load.

    Today we've implemented a workaround in the way of a scheduled task that polls the server every 30 minutes to see if there is any profile disk attached to the machine for a user that's not currently logged in, if there is then it detaches the disk. It also clears out the Session registry keys for any user that isn't currently logged on. I'll let you know how I get on with this script and whether or not it stops the issues occurring.


  2. CitrixMember 6 Reputation points
    2021-05-05T10:16:54.853+00:00

    See this link Stephanos, Marco and Fredrik describes the situation

    https://www.meinekleinefarm.net/caution-fslogix-2009-2-9-7621-30127-profiles-wont-logoff-completely/

    0 comments No comments

  3. Dlo 96 Reputation points
    2021-05-05T10:54:12.473+00:00

    I will have to check on the GPO for the registry change not sure we use it either.

    We have VHD's that get hung randomly and also folders not deleted and also the registry key issue.

    We did try the fix Microsoft gave us in our dev environment but we had to put the server in test mode but the small tests we did was a bit better.
    They said this is a fix for the windows search feature so not a patch for fslogix itself.

    Sadly it will be rolled into a monthly update for windows and they are not sure when. I am pressing them for a date so we can try this in a bigger environment instead of our smaller test one. As it puts a water mark on the desktop saying test mode so we didnt want to roll this out to a big area.


  4. Micheal Thompson 1 Reputation point
    2021-05-13T12:31:29.343+00:00

    I am still experiencing this issue as of 13/05/2021.

    Multiple customers experiencing this, it's random. Did anyone find a fix for this yet? I see some people mentioning to just roll back to release 2004 of FSLogix should I try this?

    I am also going to try the registry key people who have previously mentioned CleanUpInvalidSessions.

    Did have one customer who was running 2 Citrix VDAs and this was happening daily have since removed a VDA and increased the Ram/CPU of the single VDA to match that of 2 VDA servers. And it doesn't happen anymore? Yes, I have concurrent sessions enabled.

    Weird...


  5. Robert Berggren 1 Reputation point
    2021-05-28T07:24:27.62+00:00

    Does anyone have an update on this? Unfortunately not very good. Will have to revert to rebooting my seesion hosts every night now until this is resolved.

    0 comments No comments

Your answer

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