"systemd --user" and child processes fail to exit when user logs out
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
systemd (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
This concerns systemd 245.2-1ubuntu2 in Ubuntu focal.
I am using the Xfce desktop. After the user logs out from a desktop session, numerous desktop-related processes are left over. Here is a listing, taken over twenty minutes after logout:
skunk 853 0.0 0.2 18912 10300 ? Ss 17:55 0:00 /lib/systemd/
skunk 854 0.0 0.0 103304 3496 ? S 17:55 0:00 (sd-pam)
skunk 881 0.0 0.1 8076 5324 ? Ss 17:55 0:00 /usr/bin/
skunk 970 0.0 0.1 305364 6776 ? Ssl 17:55 0:00 /usr/libexec/
skunk 975 0.0 0.1 7352 4452 ? S 17:55 0:00 /usr/bin/
skunk 979 0.0 0.1 230196 5900 ? Sl 17:55 0:00 /usr/lib/
skunk 992 0.0 0.1 239704 7676 ? Ssl 17:55 0:00 /usr/libexec/gvfsd
skunk 997 0.0 0.1 378332 6444 ? Sl 17:55 0:00 /usr/libexec/
skunk 1133 0.0 0.1 156116 5596 ? Sl 17:56 0:00 /usr/libexec/
skunk 1139 0.0 0.1 236884 4828 ? Sl 17:56 0:00 /usr/libexec/
skunk 1186 0.0 0.8 59324 34792 ? S 17:56 0:00 /usr/bin/python3 /usr/share/
skunk 1201 0.0 0.6 391676 25688 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1224 0.0 0.8 616644 35492 ? Sl 17:56 0:00 /usr/libexec/
skunk 1235 0.0 0.7 708928 30512 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1243 0.0 0.2 314744 8980 ? Sl 17:56 0:00 /usr/libexec/
skunk 1271 0.0 0.7 681460 29344 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1302 0.0 0.1 43968 6432 ? Ss 17:56 0:00 /usr/lib/
skunk 1322 0.0 0.2 313872 9076 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1327 0.0 0.1 235684 6468 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1331 0.0 0.1 237956 6876 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1335 0.0 0.1 235864 5760 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1339 0.0 0.2 316716 8800 ? Ssl 17:56 0:00 /usr/libexec/
skunk 1347 0.0 0.1 313684 7836 ? Sl 17:56 0:00 /usr/libexec/
skunk 1353 0.0 0.1 162128 6028 ? Ssl 17:56 0:00 /usr/libexec/
When a user logs out of the system, all processes associated with the login session should be terminated (barring the use of nohup(1) or the like).
If I sent a SIGINT to the "systemd --user" process above (PID 853), then all the processes promptly go away. This needs to occur on logout.
Thank you for your bug report, do you have that user logged in from a VT or ssh maybe?
What's the output of
$ loginctl list-sessions
(log as another user to try the comment)