We help IT Professionals succeed at work.

Server 2012 R2 'The User Profile Service failed the sign-in.' Event ID 1505, 1508, and 1509.

Hello,

I've been trying numerous suggestions found on Experts Exchange and other forums, but have not been able to eliminate this issue yet.

Issue:
Server 2012 R2 "The User Profile Service failed the sign-in.  User profile cannot be loaded.”  after imaging server from backup.
   System specs are Xeon X5670 2.93ghz and 64 GB RAM and about 25 users logging in via RDS.

Log seems to indicate it is error 1505, 1508, and 1509
    Windows cannot load the user's profile but has logged you on with the default profile for the system.
     DETAIL - Insufficient system resources exist to complete the requested service.
   
    Windows was unable to load the registry. This problem is often caused by insufficient memory or insufficient security rights.
    DETAIL - The process cannot access the file because it is being used by another process.
    for C:\Users\[user]\AppData\Local\Microsoft\Windows\\UsrClass.dat

   Windows was unable to load C:\Users\[user]\AppData\Local\Microsoft\Windows\\UsrClass.dat.





Occurrence:
   Happens usually when users login after the weekend.  A server restart from the Admin account clears out the error.  We have
   not been able to recreate the error as of now.

Attempted Fixes:
   1. Changed permissions on c:\Users\Default to "Replace all child object permission entries with inheritable permission entries
   from this object"

   2. Ran DISM to cleanup image - image health was restored.

   3. Ran system file checker - no errors.

   4. Ran Array Diagnostic for HD health - OK.

   5. Ran Delprof2 - no inactive profiles listed.

   6.  Looked into suggestion below of ctfmon.exe or another process bogging down resources.  Nothing in log or process explorer
   suggests this is the issue yet, and the machine has pretty good specs for the level of use it gets. I have setup a Performance
  Monitor Data Collector Set to look at processors and memory moving forward.
  Link

  7.  Looked at Server 2003 Registry fix as possibility, but have not attempted as I do not see anything relating to this and Server 2012 R2.Server 2003 Fix

   8. Looked at HKEYUSERS .Default Registry for large keys that could cause loading issues– nothing largest key I exported was 2 MB. HKEYUSERS Resgistry

We did have another log-in hang issue that was related to Malwarebytes - the program file folder had grown to  30+gb.  Uninstalling and reinstalling seemed to clear up that issue.  There seems to be some coincidences with long scans running and perhaps locking down these files perhaps?

Future things I will be trying:
   Replace the Default user folder from a working version of same OS - done as of 2020-02-25 with no reoccurrences of issue yet.
   Removing or disabling features of malwarebytes.
   Rebuild Active Directory and RDS
   
Any help troubleshooting is greatly appreciated.
Comment
Watch Question

System Administrator
CERTIFIED EXPERT
Distinguished Expert 2018
Commented:
Solutions that usually work for me:
1. Change permissions on C:\Users\Default
OR
2. Copy C:\Users\Default from another server

So when you get a chance, try to copy the folder from a working machine.

I read that deleting C:\Users\\Default\AppData\Local\Microsoft or deleting all *.sqm files under C:\Users\Default\AppData\Local\Microsoft should solve the issue as well but I haven't got a chance to test it.

Author

Commented:
Copied C:\Users\Default from another server as of last night (2020-02-24), no issues yet.  Will probably have to see if it lasts through the weekend.  Thanks!
Hello ThereSystem Administrator
CERTIFIED EXPERT
Distinguished Expert 2018

Commented:
I am glad to hear that.