This is a slightly difficult issue to describe precisely but I'll do my best. About six weeks ago, my installation of Catalina (10.15.7, MacBook Pro 13" 2020 / MacBookPro16,2) started to exhibit some strange behaviour when left running overnight (or possibly: when left running unattended for several hours).

Sometimes, but by no means every day, I'll return to the machine in the morning and wake the screen to see a grey lock screen (no background image) and a prompt that will often only accept my password (i.e. not Touch ID). Upon unlocking the machine I'll see a series of errors and password prompts, which seem to be stuck in a loop (or maybe there are just enough of them queued up that it seems like a loop). These messages include:

Unapproved caller. SecurityAgent may only be invoked by Apple software
Unrecoverable error. SecurityAgent was unable to create requested mechanism builtin:unlock-keychain.
accountsd wants to use the “login” keychain. Please enter the keychain password.
callservicesd wants to use the “login” keychain. Please enter the keychain password.
identityservicesd wants to use the “login” keychain. Please enter the keychain password.
CallHistorySyncHelper wants to use the “login” keychain. Please enter the keychain password.
assistantd wants to use the “login” keychain. Please enter the keychain password.
CommCenter wants to use the “login” keychain. Please enter the keychain password.

The system will give the appearance of being usable but isn't really. Symptoms include:

  • Finder and Dock repeatedly restarting
  • Generally unable to interact with menubar, e.g. to shut down
  • Inconsistent ability to tab between apps and interact with or quit them
  • Unable to start new apps from Dock or menubar shortcuts (icons just bounce for a while)

So far I have never been able to cleanly shut down the machine in this state and have had to power it off using the Touch ID / power button.

When booting back up, everything seems fine except sometimes Touch ID preferences have been reset (i.e. I have to enrol my finger again) and on one occasion my saved Bluetooth devices, except for mouse and keyboard, were deleted. For what it's worth, it does seem that if I "catch" the problem quickly enough, e.g. returning to the machine late at night, the damage is more limited and Touch ID is not always reset, however the other issues remain. I have also tried putting the machine into standby overnight by closing the lid, rather than leaving it running, but at least once the issue has still occurred (presumably the machine is waking up at some point overnight to do something).

I'm a bit stumped as to how to diagnose this. My hunch is that it's something to do with the system somehow losing access to Keychain – based on mentions in the error messages above. I did have iCloud Keychain enabled previously, but disabled it a couple of weeks ago, and the issue has happened at least once since then.

An answer to another question mentions Keychain permissions – these are mine, in case they're relevant:

# /Library/Keychains:
0 drwxr-xr-x   9 root  wheel             288B  9 Feb 08:07 Keychains

# /Library/Keychains/System.keychain
248 -rw-r--r--  1 root  wheel   120K  7 Jan 13:16 /Library/Keychains/System.keychain

# ~/Library/Keychains/ [with redactions]
total 928
  0 drwx--x--x   7 james  staff   224B 14 Feb 10:07 .
  0 drwx------@ 85 james  staff   2.7K 10 Feb 12:22 ..
  0 -r--r--r--   1 james  staff     0B  7 Dec  2020 .XXXXXXXXXX
  0 -r--------   1 james  staff     0B  7 Dec  2020 .XXXXXXXXXX
  0 drwx------  11 james  staff   352B 14 Feb 09:06 XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
880 -rw-r--r--@  1 james  staff   439K 14 Feb 10:07 login.keychain-db
 48 -rw-------   1 james  staff    23K 14 Feb 09:41 metadata.keychain-db

Any light that anyone might be able to shed on this would be much appreciated! I have a TODO list item to upgrade to Big Sur, at which stage this might become moot, but until then I would really like to understand it better and avoid having to do these forced-shutdowns every now and then.

Thanks for reading and if I can provide any more info or data please ask.

  • If you start your Mac in safe mode (support.apple.com/HT201262) to delete system caches, and then restart, does the problem go away?
    – jaume
    Feb 23, 2022 at 10:03
  • 1
    @jaume Minus one point for me for not knowing that just booting in Safe Mode would cause a cache clear – very useful. The machine has been on for two nights so far with no issues... I'll give it a few more days and report back. Thanks for your suggestion!
    – BigglesZX
    Feb 26, 2022 at 9:42
  • Thanks for your feedback, I'm glad I could help. If this trick solves the issue, I'll add an answer.
    – jaume
    Feb 26, 2022 at 11:34
  • 1
    @jaume Unfortunately I was greeted by the grey lockscreen this morning – but the system was much more responsive and I was able to quit apps before having to force a shutdown, as a normal one wouldn't work. I saw a new error in addition to some of the "accountsd" errors above. This was: "This Mac can't connect to iCloud because of a problem with <my email address>". But couldn't open System Preferences to attempt to resolve!
    – BigglesZX
    Feb 27, 2022 at 9:56

1 Answer 1


My wife has this problem on Macbook Air with Catalina. Every few days. On research, it has been reported since 2014. In her case, the gray popup repeats after dismissal. Using RETURN to dismiss it continuously, it eventually goes away, but the system locks up, the finder crashes, and Apple Mail is locked up as well. After reboot, going into System Preferences->Apple ID, with the yellow triangle (she only has one apple ID), clicking on the triangle gives the dialogue to re-login to the apple ID. After logging in the triangle was removed. This overlapped with our credit card on file with apple needing to have the corrected date and CVV after getting a new one.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .