After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 731654 - gdm-session-worker [pam/gdm-launch-environment] persists after stopping gdm
gdm-session-worker [pam/gdm-launch-environment] persists after stopping gdm
Status: RESOLVED OBSOLETE
Product: gdm
Classification: Core
Component: general
3.12.x
Other Linux
: Normal normal
: ---
Assigned To: GDM maintainers
GDM maintainers
Depends on:
Blocks:
 
 
Reported: 2014-06-14 13:16 UTC by Laurent Bigonville
Modified: 2018-05-24 11:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
pstree for left-behind process (3.40 KB, text/plain)
2016-04-21 15:40 UTC, jackieb
Details

Description Laurent Bigonville 2014-06-14 13:16:49 UTC
Hello,

On my Debian machine, running systemd, when I'm stopping gdm there is a gdm-session-worker [pam/gdm-launch-environment] that seems to stay forever.

When restarting gdm, I'm ending up with two of these processes


gdm: 3.12.2
Comment 1 Philipp Reinkemeier 2016-02-12 07:50:23 UTC
I can confirm this issue. The process gdm-session-worker [pam/gdm-launch-environment] also prevents some other remaining processes related to gdm to shutdown. Once it gets killed manually, all the remaining process go away too.

At least for me, the issue is not exactly reproducible. If i start a fresh new gdm and stop it immediately afterwards, without logging in inbetween, then shutdown of gdm works correctly. However, once i start a gnome session via gdm and logout of that session, then trying to stop gdm via a tty shows the behavior described above.

I can provide a log (via journalctl) or a list of the other processes if needed.
Comment 2 jackieb 2016-04-21 15:39:44 UTC
This also happens when GNOME Shell crashes

For each crash, a gdm-session-worker process with ppid 1 remains
- it is active and logging to syslog

For each crash, an additional process is left behind

Normally, two wroker processes exist with the parent being gdm:
s -fC gdm-session-worker | cat                                         
UID        PID  PPID  C STIME TTY          TIME CMD
root      1286  1275  0 07:51 ?        00:00:00 gdm-session-worker [pam/gdm-launch-environment]
root      1903  1275  0 07:51 ?        00:00:00 gdm-session-worker [pam/gdm-password]

ps -fp 1275 | cat
UID        PID  PPID  C STIME TTY          TIME CMD
root      1275     1  0 07:51 ?        00:00:00 /usr/sbin/gdm3

when gdm3 goes away, one of the workers remain with ppid 1
Comment 3 jackieb 2016-04-21 15:40:50 UTC
Created attachment 326503 [details]
pstree for left-behind process
Comment 4 Ray Strode [halfline] 2016-04-21 16:05:36 UTC
so we have this in the code:

        prctl (PR_SET_PDEATHSIG, SIGTERM);•

I guess, then, it must be ignoring SIGTERM.

Does adding the patch from bug 755291 help?
Comment 5 jackieb 2016-04-22 19:19:57 UTC
So, this has been around for close to a year now, right?

I just reinstalled gnome-shell because it keeps crashing

In this new and improved desperate attempt to have GNOME running at all, gdm fails to restart. Apparently the remaining processes, that has been known about for almost a year, prevents gdm from starting.

sudo systemctl restart gdm
- is ineffective

get-around
fortunately, while gnome shell is crashed, virtual consoles work
in a virtual console (control+option+fn+F1)
sudo killall --user gdm
sudo killall gdm-session-worker
sudo systemctl restart gdm
Comment 6 jackieb 2017-01-12 18:42:46 UTC
One can use lightdm in the meantime

This has been broken since 3.18 in 2015
Comment 7 jackieb 2017-01-12 19:15:17 UTC
The bug 755291 patch went into 3.19.4

gdm still cannot be restarted
sudo systemctl restart gdm.service

echo Observed on $(date --utc --rfc-3339=date) && echo $(lsb_release --description --codename --short) && uname --nodename --kernel-release --kernel-version && for _P in gnome-session libwayland-server0 lightdm; do dpkg --status $_P | egrep "^(V|Pa)"; done
Observed on 2017-01-12
Ubuntu 16.10 yakkety
c93 4.8.0-32-generic #34-Ubuntu SMP Tue Dec 13 14:30:43 UTC 2016
Package: gnome-session
Version: 3.20.2-1ubuntu7
Package: libwayland-server0
Version: 1.11.0-2
Package: lightdm
Version: 1.19.5-0ubuntu1

It’s a known problem since 2 years in bug 747339
Comment 8 jackieb 2017-01-12 19:25:35 UTC
the gdm3 version is
Package: gdm3
Version: 3.20.1-1ubuntu2
Comment 9 GNOME Infrastructure Team 2018-05-24 11:03:16 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gdm/issues/201.