3

When I lock my screen with ControlCommandQ and return after more than 10 minutes, macOS has closed all my open apps and tries to restore them, which often leaves my applications in half restored states.

This did not happen before. Also a few times I have been logged out randomly, causing the same issue.

I'm using macOS High Sierra 10.13.6.

Security and Privacy settings:

  • Advanced, Log out after x minutes is not checked.

Any guesses for why this happens?

  • I have logs for the timespan when a log out happens randomly whilst I am using the mac. (sudo log collect). Which logs/processes would indicate the reason? – zino Feb 20 at 10:43
  • .......have you tried turning it off and on again? Also, what does Control Command Q do? It's not listed here: support.apple.com/en-ca/HT201236 – Sam Feb 21 at 4:01
  • Well it randomly logs me out closing all my programs. Its frustrating when Im in the middle of something with many windows. I have turned it off fully many times. Ctrl Cmd Q is lock screen, look under the Apple icon menu (top left). – zino Feb 21 at 21:39
  • Try re-installing macOS – Sam Feb 22 at 0:50
1

My first guess is that your "windowserver" process had crashed. It provides support for login/logout, user-switching, and animation effects. If it crashes, every application you have open will also be terminated.

Check for "loginwindow" or "windowserver" errors in your system log, or go to /Library/Logs/DiagnosticReports and look for crash reports that contain the keyword "window".

If it's not the fault, you may have to contact Apple. You may reach them at support.apple.com/contact or bugreport.apple.com.

0

From Why does High Sierra quit all my programs when I lock and close the laptop?:

After some experimentation I've found I can work around this issue by allowing the screen to fully lock before closing the laptop.

Locking is taking my Macbook around 5-10 seconds which seems pretty crazy considering it was new last year; however this situation is much preferable to all my programs having crashed every time I open it.

  • I never close the mac book; its attached to an external monitor. – zino Feb 24 at 22:19
0

Try reinstalling macOS, if some system process is at fault for this then reinstalling your OS may fix it.

-1

Open System Preferences from the Apple menu in the top-left corner. Open the "Security & Privacy" preference pane. Click on the "Advanced..." button in the bottom-right corner. You may need to unlock the pane using the padlock icon in the bottom-left corner.

I think you'll find "Log out after XX minutes of inactivity" ticked. Untick it.

Reference: https://apple.stackexchange.com/a/140077

New contributor
FDisk is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

You must log in to answer this question.

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