The dm-tool program that is part of x11-misc/lightdm apparently spawns a new lightdm process on every invocation of the "lock" command. On my system I found that after a while, "dm-tool lock" would merely switch to VT8 instead of switching to the lightdm greeter, leaving my session without password protection. There were many ligthdm subprocesses, all using lots of CPU (such that both cores were maxed out).
An example after one invocation of "dm-tool lock":
% ps aux|grep lightdm
root 7565 0.4 1.5 312044 62876 ? SLsl 12:07 0:00 /usr/sbin/lightdm
root 7603 4.7 0.7 146248 31840 tty7 Ssl+ 12:07 0:01 /usr/bin/X :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch
root 7958 0.1 0.1 208428 6280 ? Sl 12:07 0:00 lightdm --session-child 12 19
root 13642 0.6 0.0 162380 3736 ? Sl 12:07 0:00 lightdm --session-child 19 26
marcec 14742 0.0 0.0 14072 960 pts/3 S+ 12:07 0:00 grep lightd
There's the main lightdm process and *two* children, instead of the usual one.
The upstream bug at $URL mentions the same basic symptom I've seen (albeit for an older version of lightdm) and sadly hasn't had any activity.
Steps to Reproduce:
1. invoke "dm-tool lock"
2. log back in
3. run "ps aux|grep lightdm"
4. repeat steps 1 and 2 several times (not sure how many)
The ps output shows two lightdm subprocesses instead of the usual one, after step 4 lightdm stops locking and instead simply switches to another VT (in my case 8). It's possible to switch to the session via Alt-F7 (*no* password protection!).
The ps output shows the main ligthdm process and one subprocess, step 4 should *always* properly lock the session.
% emerge --info lightdm
Portage 220.127.116.11 (default/linux/amd64/13.0, gcc-4.6.3, glibc-2.15-r3, 3.10.7-gentoo x86_64)
System uname: Linux-3.10.7-gentoo-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_4200+-with-gentoo-2.2
KiB Mem: 4047292 total, 200908 free
KiB Swap: 4194300 total, 4175728 free
Timestamp of tree: Tue, 03 Sep 2013 20:45:01 +0000
ld GNU ld (GNU Binutils) 2.23.1
dev-lang/python: 2.7.5-r2, 3.2.5-r2
sys-devel/autoconf: 2.13, 2.69
sys-devel/automake: 1.11.6, 1.12.6, 1.13.4
sys-kernel/linux-headers: 3.9 (virtual/os-headers)
Repositories: gentoo science wagnerflo sunrise overnight ladi proaudio pd-overlay mjoliet
CFLAGS="-O2 -march=native -pipe"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=native -pipe"
EMERGE_DEFAULT_OPTS="--with-bdeps=y --quiet-build=y --nospinner"
FEATURES="assume-digests binpkg-logs buildpkg collision-protect config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox xattr"
GENTOO_MIRRORS="ftp://de-mirror.org/distro/gentoo/ ftp://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ ftp://mirror.muntinternet.net/pub/gentoo/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTDIR_OVERLAY="/usr/local/portage/layman/science /usr/local/portage/layman/wagnerflo /usr/local/portage/layman/sunrise /usr/local/portage/layman/overnight /usr/local/portage/layman/ladi /usr/local/portage/layman/pro-audio /usr/local/portage/layman/pd-overlay /usr/local/portage/marcec"
USE="3dnow 3dnowext X a52 aac acl alsa amd64 avahi berkdb branding bzip2 cairo caps cdinstall cjk cli consolekit cracklib crypt css cups cxx dbus dga djvu dri dssi dts dvd encode exif fbcon ffmpeg fftw flac fortran ftp fuse gdbm gif gmp gnuplot gnutls gtk iconv idn imlib inotify ipv6 jack jackmidi jpeg jpeg2k kipi ladspa lapack lash latex lcms libnotify libsamplerate logrotate lzma mad mjpeg mmx mmxext mng modplug modules mp3 mp4 mpeg mudflap multilib musepack musicbrainz ncurses nfs nls nptl ntp offensive ogg openexr opengl openmp opus osc pam pango pcre pdf plotutils png policykit pulseaudio qt4 quicktime rar readline rtsp samba sasl session sid slang smp sndfile speex spell sse sse2 sse3 ssl startup-notification svg sysfs taglib tcpd theora threads tiff timidity truetype unicode usb vaapi vdpau vim-syntax vorbis vpx webkit wma x264 xattr xcb xcomposite xface xft xml xmp xpm xscreensaver xv xvid zeroconf zlib zsh-completion" ABI_X86="64" ALSA_CARDS="ice1724 hda-intel usb-audio" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en_US en en_GB de" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" QEMU_SOFTMMU_TARGETS="x86_64" QEMU_USER_TARGETS="x86_64" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="radeon vesa" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset: CPPFLAGS, CTARGET, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
x11-misc/lightdm-1.4.0-r2 was built with the following:
USE="gtk introspection -kde -qt4 -razor"
Please don't manually CC maintainers.
(In reply to Tom Wijsman (TomWij) from comment #1)
> Please don't manually CC maintainers.
OK, sorry about that.
Ok thanks for the report. We will track the upstream bug.
I got around to trying new versions of lightdm and found out that lightdm-1.7.16 does *not* show the bug. Neither "dm-tool lock" nor "dm-tool switch-to-greeter" exhibit the behaviour I described, lightdm-1.6.2 however still did. Therefore the yet-to-come stable series 1.8.x ought to be rid of this bug :) .
Perhaps somebody with a launchpad account can add a comment to this effect to the upstream bug?
(As an aside: lightdm >=1.6.2 (or maybe it was lightdm-gtk-greeter-1.6.0) fixed an issue where the greeter background was set to black instead of to the specified image on a borrowed laptop; in contrast, my desktop showed no problems in this regard.)
Unfortunately I have not launchpad account. However, since this appears to be solved in the latest ~testing ebuild we can close this bug.
Thanks for the report and for testing.
(In reply to Markos Chandras from comment #5)
> Unfortunately I have not launchpad account. However, since this appears to
> be solved in the latest ~testing ebuild we can close this bug.
> Thanks for the report and for testing.
Just a FYI: I decided to just create a Launchpad account and have linked the upstream bug to this one and posted a comment there.
Damn it, I spoke too soon.
As of yesterday, I've started seeing this bug again. I noticed it when the screen simply went black after calling "dm-tool lock". I was able to get to the desktop session via Alt-F7 as per the original bug description and sure enough, "ps aux" showed lots of ligthdm session children. After quitting my desktop session (well, window manager), ligthdm just quit (no SEGFAULT, or anything else in syslog, the process apparently just exited). So I was left to restart the xdm service.
After that, I verified that locking via dm-tool switches to a greeter on VT8, so that you can go back to the desktop session with a simple Alt-F7. That, again, shows new session children, but they disappeared after logging in again.
I'm perplexed, because I was certain that I didn't see this bug anymore after the upgrade in comment #4.
I'll attach the list of packages I've upgraded in case you can see anything that might be involved. I'll also attach a log file of me loggin in, locking, and unlocking the session.
Created attachment 360572 [details]
Output of genlop -l --date 2013-09-26
This is the list of packages I upgraded/installed after comment #4.
Created attachment 360574 [details]
The lightdm log
Created attachment 360578 [details]
The lightdm-greeter log from VT7
Created attachment 360580 [details]
The lightdm-greeter log from VT8
I don't think there's anything interesting in the greeter's logs, but thought I would put them here for completions sake. Also, .xsession-errors doesn't contain anything pertaining to lightdm.
The upstream bug was closed as invalid in 2016, with no activity since then (i.e., no more "me too!"s), and I had switched to KDE4 about two years before that, so haven't really cared about this bug in the last 6 years. Hence: Is this bug still reproducible, or can it be closed now? Because I don't know about you, but I'd be glad to get it off of my open bug list ;-) .