Loginctl session not terminated after X logout

If none of the more specific forums is the right place to ask

Loginctl session not terminated after X logout

Postby noober1983 » 2020-07-31 02:42

Hi.
I run Testing with XFCE. I've noticed that whenever I log out from an X session (let's call it Session A) and log in to another one (Session B), then some services are not available on B; in particular, when running xfce4-session-logout, only the "Log out" option is enabled. I found some post about this elsewhere (one of them is a Debian bug report from 2 years ago, but it is unclear whether or not it was resolved):
https://discourse.nixos.org/t/user-sessions-never-terminate-after-xsession-logout/1320
https://superuser.com/questions/1102242/why-systemd-doesnt-try-to-stop-some-processes-on-session-termination
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=897221
By running loginctl terminate-session <session-id> everything goes back to normal. In the first of the post it is suggested editing the file /etc/lsystem/ogind.conf and uncomment the line that says
Code: Select all
KillUserProcesses=yes

It is actually set to "no" by default. Apparently this is a good idea for some servers so that some essential processes keep running; setting the above doesn't work for me. If I log into X Session B, then in order to suspend/hibernate/shutdown the system I have either to log in as root in some terminal, or log out and back into Session A, which is annoying. Whenever I log out from Session A I get the following:
Code: Select all
SESSION  UID USER     SEAT  TTY
      1 1000 userA seat0   
      2 1001 userB
2 sessions listed.

So only Session A is "seated", which I believe means it has control over the X session in its entirety (perhaps this is where I am wrong). Is there a way around this? What I want is for Session A to terminate, with all its processes, upon Logging out from XFCE. The users are set not to linger and I have the above configuration on /etc/systemd/logind.conf. Thanks!
Quid non intellegas aut tace aut disce.
noober1983
 
Posts: 68
Joined: 2012-04-03 00:12
Location: MX

Return to General Questions

Who is online

Users browsing this forum: No registered users and 15 guests

fashionable