Since I switched to Wayland on Debian11/KDE starting the computer from standby in around 90% of cases shows a black screen and one needs to use ctrl+alt+f{id} and run loginctl unlock-session {id2} to be able to switch back to the running session by pressing ctrl+alt+F1.

This is a security issue because one can resume the session without having to enter the password if it has been entered before and this still hasn't been fixed for Debian11/KDE.

The session is shown with the who command. I think configuring $TMOUT (which isn't set by default) as recommended elsewhere would also log out the current session, not just the inactive terminal session/s.

How can I log out (automatically or not) all inactive terminal sessions (exclusively) which I started to be able to resume from standby due to the Wayland-KDE/Debian11 bugs?


1 Answer 1


TMOUT causes idle interactive shells to exit, it doesn’t close desktop sessions.

If you don’t want to have to remember to log out from your “rescue” VTs, it seems like a good solution to me: your rescue VT will automatically log out after however many seconds you specify in TMOUT (e.g. 120 — note that this will affect terminal emulators too, so don’t choose too small a value).

You could also replace your rescue shell with loginctl:

exec loginctl ...

That way, once loginctl completes, you’ll be logged out of your rescue VT.


You must log in to answer this question.

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