Description of problem:
On occasion on some of our systems we have two gnome-screensaver processes running. This means our users are having to log-in twice which annoys and confuses them often in equal measure.
Very difficult to definitively reproduce, just happens on occasion on machines at random times. Sorry I can't help more here.
Steps to Reproduce:
Unknown, hard to reproduce at will.
Once both gnome-screensavers are running this is the output of ps,
[root@coe ~]# ps -ef | grep -i gnome-screensaver
bwalker 1055 1 0 Jul28 ? 00:00:04 /usr/bin/gnome-screensaver --no-daemon
bwalker 1073 1 0 Jul28 ? 00:00:24 gnome-screensaver
Just a single gnome-screensaver process running (probably without --no-daemon flag).
The parent process seems to be init. It would be useful to know what is spawning the extra gnome-screensaver process - any guidelines on how to trace the process life cycle would be very useful indeed.
This bug is mentioned elsewhere in the Linux community in various forums and in various forms, one of which being the following:
my guess is this happening because a user hits ctrl-alt-L or the screensaver key on their keyboard during the log in process. The upstream bug report you found, points out that if gnome-screensaver is started twice in quick succession two can end up running.
gnome-screensaver --no-daemon is probably from dbus-daemon. see:
it gets automatically started if it's accessed over the message bus and it isn't already running (which will happend when you hit ctrl-alt-L, the screensaver key on your keyboard, or run gnome-screensaver-command.
Thanks for that but I can confirm that our users are not hitting ctl+alt+L or any kind of screensaver key.
What would happen if we put that file (/usr/share/dbus-1/services/org.gnome.ScreenSaver.service) aside on our systems?
How can we make sure that only one gnome-screensaver process ever runs?
if you moved that file aside on your system the problem would most likely go away, until the next gnome-screensaver update (when it would get placed back).
The way to make sure only one gnome-screensaver process runs is to backport the patch from the bug you found.
Thank you. I have raised this as a Red Hat Support Case (Case 01168922).
Patched version of gnome-screensaver seems to fix the double gnome-screensaver problem at least for the five machines that this has been tested on: