Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 523264 - sys-apps/systemd-216 - systemd[1]: Failed to start Login Service.
Summary: sys-apps/systemd-216 - systemd[1]: Failed to start Login Service.
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo systemd Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-19 20:05 UTC by Juergen Rose
Modified: 2015-09-07 18:25 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Juergen Rose 2014-09-19 20:05:52 UTC
I have here a system, which is not very responsive. Then I detected that the graphical.target and the multi-user.target is dead:

root@gepard:/root(25)# systemctl list-units -t targetUNIT                  LOAD   ACTIVE   SUB    JOB   DESCRIPTION
basic.target          loaded active   active       Basic System
bluetooth.target      loaded active   active       Bluetooth
getty.target          loaded active   active       Login Prompts
graphical.target      loaded inactive dead   start Graphical Interface
local-fs-pre.target   loaded active   active       Local File Systems (Pre)
local-fs.target       loaded active   active       Local File Systems
multi-user.target     loaded inactive dead   start Multi-User System
network-online.target loaded active   active       Network is Online
network.target        loaded active   active       Network
nss-lookup.target     loaded active   active       Host and Network Name Lookups
paths.target          loaded active   active       Paths
remote-fs.target      loaded active   active       Remote File Systems
rpcbind.target        loaded active   active       RPC Port Mapper
slices.target         loaded active   active       Slices
sockets.target        loaded active   active       Sockets
sound.target          loaded active   active       Sound Card
swap.target           loaded active   active       Swap
sysinit.target        loaded active   active       System Initialization
time-sync.target      loaded active   active       System Time Synchronized
timers.target         loaded active   active       Timers


I investigated 'dmesg' and 'journalctl -b', but I did not detect an obvious reason. In contrast to other systems I found a lot of "Failed to start Login Service" messages:

root@gepard:/root(19)# journalctl -b | grep "Failed"
Sep 19 20:05:17 gepard systemd[1]: Failed to subscribe to NameOwnerChanged signal: Connection timed out
Sep 19 20:05:17 gepard systemd[1]: Failed to subscribe to activation signal: Connection timed out
Sep 19 20:05:17 gepard systemd[1]: Failed to register name: Connection timed out
Sep 19 20:05:17 gepard systemd[1]: Failed to set up API bus: Connection timed out
Sep 19 20:05:18 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ColorManager': timed out
Sep 19 20:05:18 gepard systemd[2006]: Failed at step EXEC spawning /usr/sbin/rpc.statd: No such file or directory
Sep 19 20:05:43 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ColorManager': timed out
Sep 19 20:06:47 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:08:18 gepard systemd[1]: Failed to start Login Service.
...
Sep 19 20:30:51 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:32:21 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:33:52 gepard sshd[2849]: pam_systemd(sshd:session): Failed to create session: Message did not receive a reply (timeout by message bus)
Sep 19 20:33:52 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:34:17 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ConsoleKit': timed out
Sep 19 20:34:17 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.PolicyKit1': timed out
Sep 19 20:35:22 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:36:52 gepard systemd[1]: Failed to start Login Service.
...
Sep 19 20:51:55 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:53:25 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:54:55 gepard su[3630]: pam_systemd(su:session): Failed to create session: Message did not receive a reply (timeout by message bus)
Sep 19 20:54:55 gepard systemd[1]: Failed to start Login Service.
Sep 19 20:56:26 gepard systemd[1]: Failed to start Login Service.
...
Sep 19 21:17:29 gepard systemd[1]: Failed to start Login Service.
Sep 19 21:18:59 gepard systemd[1]: Failed to start Login Service.
Sep 19 21:20:06 gepard org.a11y.atspi.Registry[4658]: ** (at-spi2-registryd:4661): WARNING **: Failed to register client: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.gnome.SessionManager was not provided by any .service files
Sep 19 21:20:29 gepard systemd[1]: Failed to start Login Service.
Sep 19 21:22:00 gepard systemd[1]: Failed to start Login Service.
...
Sep 19 21:41:33 gepard systemd[1]: Failed to start Login Service.
Sep 19 21:43:03 gepard systemd[1]: Failed to start Login Service.


root@gepard:/root(29)# systemctl get-default 
graphical.target


root@gepard:/root(30)# systemctl --no-pager show -p "Wants" graphical.target
Wants=display-manager.service


root@gepard:/root(31)# systemctl --no-pager show -p "Wants" multi-user.target
Wants=sendmail.service sshd.service ntpd.service vixie-cron.service remote-fs.target sm-client.service network-wireless.service cups.path nfs-server.service autofs.service rpcbind.service gpm.service gentoo-local-baselayout1.service gentoo-local-99mount.service gentoo-local-07echo_switchto_last.service gentoo-local-06thinkpad.service gentoo-local-05sound.service gentoo-local-04mobilphone.service gentoo-local-03proxy.service gentoo-local-02wlan.service gentoo-local-01lan.service systemd-ask-password-wall.path getty.target systemd-logind.service dbus.service systemd-user-sessions.service


root@gepard:/root(32)# systemctl --failed
  UNIT               LOAD   ACTIVE SUB    DESCRIPTION
● nfs-config.service loaded failed failed Preprocess NFS configuration
● rpc-statd.service  loaded failed failed NFS status monitor for NFSv2/3 locking.


Any hint is appreciated.


Reproducible: Always
Comment 1 Juergen Rose 2014-09-19 20:21:51 UTC
BTW., the systemd-logind.service have the state "activating (start)" while on other systems the state is "active (running)":

root@gepard:/root(48)# systemctl status systemd-logind
● systemd-logind.service - Login Service
   Loaded: loaded (/usr/lib64/systemd/system/systemd-logind.service; static)
   Active: activating (start) since Fri 2014-09-19 22:19:09 CEST; 6s ago
     Docs: man:systemd-logind.service(8)
           man:logind.conf(5)
           http://www.freedesktop.org/wiki/Software/systemd/logind
           http://www.freedesktop.org/wiki/Software/systemd/multiseat
 Main PID: 6084 (systemd-logind)
   Status: "Processing requests..."
   CGroup: /system.slice/systemd-logind.service
           └─6084 /usr/lib/systemd/systemd-logind

Sep 19 22:19:09 gepard systemd-logind[6084]: New seat seat0.
Sep 19 22:19:09 gepard systemd-logind[6084]: Watching system buttons on /dev/input/event2 (Power Button)
Sep 19 22:19:09 gepard systemd-logind[6084]: Watching system buttons on /dev/input/event3 (Video Bus)
Sep 19 22:19:09 gepard systemd-logind[6084]: Watching system buttons on /dev/input/event0 (Lid Switch)
Sep 19 22:19:09 gepard systemd-logind[6084]: Watching system buttons on /dev/input/event1 (Sleep Button)
Sep 19 22:19:09 gepard systemd-logind[6084]: Watching system buttons on /dev/input/event8 (ThinkPad Extra Buttons)
Sep 19 22:19:09 gepard systemd-logind[6084]: New session c1 of user root.
Sep 19 22:19:09 gepard systemd-logind[6084]: New session 1 of user rose.
Comment 2 Mike Gilbert gentoo-dev 2014-09-19 21:42:13 UTC
> Sep 19 20:34:17 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ConsoleKit': timed out

You should probably disable/remove consolekit. You seem to be throwing a lot of logind and dbus related errors, so maybe that's it.
Comment 3 Juergen Rose 2014-09-20 11:17:51 UTC
(In reply to Mike Gilbert from comment #2)
> > Sep 19 20:34:17 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ConsoleKit': timed out
> 
> You should probably disable/remove consolekit. You seem to be throwing a lot
> of logind and dbus related errors, so maybe that's it.

It seems that some of my installed packages depend on consolekit:

root@gepard:/usr/src/linux(18)# emerge -pv --depclean consolekit

Calculating dependencies... done!
  sys-auth/consolekit-0.4.6 pulled in by:
    lxde-base/lxdm-0.4.1-r9 requires sys-auth/consolekit
    net-misc/networkmanager-0.9.8.10-r1 requires sys-auth/consolekit
    sys-auth/pambase-20140313 requires >=sys-auth/consolekit-0.4.6[pam]
    x11-apps/xdm-1.1.11-r3 requires sys-auth/consolekit

>>> No packages selected for removal by depclean
Packages installed:   3641
Packages in world:    805
Packages in system:   44
Required packages:    3641
Number to remove:     0

root@gepard:/usr/src/linux(19)# equery d consolekit
 * These packages depend on consolekit:
gnome-base/gdm-3.12.2 (!systemd ? >=sys-auth/consolekit-0.4.5_p20120320-r2)
gnome-base/gnome-control-center-3.12.1-r1 (sys-auth/consolekit)
gnome-base/gnome-session-3.12.1 (!systemd ? sys-auth/consolekit)
kde-base/kdm-4.11.12 (consolekit ? sys-auth/consolekit)
lxde-base/lxdm-0.4.1-r9 (consolekit ? sys-auth/consolekit)
net-misc/networkmanager-0.9.8.10-r1 (consolekit ? sys-auth/consolekit)
sys-apps/accountsservice-0.6.37 (!systemd ? sys-auth/consolekit)
sys-auth/pambase-20140313 (consolekit ? >=sys-auth/consolekit-0.4.6[pam])
sys-auth/polkit-0.112-r2 (!systemd ? sys-auth/consolekit[policykit])
x11-apps/xdm-1.1.11-r3 (consolekit ? sys-auth/consolekit)

At http://www.gossamer-threads.com/lists/gentoo/user/288842 I found a discussion about slow ssh rekeying. It was suggested to comment the "-session optional pam_systemd.so" line in /etc/pam.d/system-auth. What do you think is the better solution, to try to reemerge lxdm, networkmanager, pambase, xdm, gdm, gnome-control-center, gnome-session, accountsservice and polkit with "USE=-consolekit" and then delete consolekit ot to comment out the line in /etc/pam.d/system-auth?
Comment 4 Juergen Rose 2014-09-20 12:05:38 UTC
(In reply to Juergen Rose from comment #3)
> (In reply to Mike Gilbert from comment #2)
> > > Sep 19 20:34:17 gepard dbus[1830]: [system] Failed to activate service 'org.freedesktop.ConsoleKit': timed out
> > 
> > You should probably disable/remove consolekit. You seem to be throwing a lot
> > of logind and dbus related errors, so maybe that's it.
> 
> It seems that some of my installed packages depend on consolekit:
> 
> root@gepard:/usr/src/linux(18)# emerge -pv --depclean consolekit
> 
> Calculating dependencies... done!
>   sys-auth/consolekit-0.4.6 pulled in by:
>     lxde-base/lxdm-0.4.1-r9 requires sys-auth/consolekit
>     net-misc/networkmanager-0.9.8.10-r1 requires sys-auth/consolekit
>     sys-auth/pambase-20140313 requires >=sys-auth/consolekit-0.4.6[pam]
>     x11-apps/xdm-1.1.11-r3 requires sys-auth/consolekit
...

> At http://www.gossamer-threads.com/lists/gentoo/user/288842 I found a
> discussion about slow ssh rekeying. It was suggested to comment the
> "-session optional pam_systemd.so" line in /etc/pam.d/system-auth. What do
> you think is the better solution, to try to reemerge lxdm, networkmanager,
> pambase, xdm, gdm, gnome-control-center, gnome-session, accountsservice and
> polkit with "USE=-consolekit" and then delete consolekit ot to comment out
> the line in /etc/pam.d/system-auth?


After adding "-consolekit" to kdm, lxdm, networkmanager, pambase and xdm in /etc/portage/package.use I could delete consolekit with 'emerge -v --depclean consolekit'. After rebooting the graphical.target and the multi-user.target is still dead.
Comment 5 Juergen Rose 2014-09-20 12:19:28 UTC
There are still "Failed to start Login Service" messages in the journal:

root@gepard:/root(2)# journalctl -xb | grep -i fail
Sep 20 14:00:31 gepard kernel: acpi PNP0A03:00: _OSC failed (AE_NOT_FOUND); disabling ASPM
Sep 20 14:00:31 gepard kernel: acpi PNP0A08:00: _OSC failed (AE_SUPPORT); disabling ASPM
Sep 20 14:00:31 gepard kernel: intel ips 0000:00:1f.6: failed to get i915 symbols, graphics turbo disabled until i915 loads
Sep 20 14:00:31 gepard systemd[1]: Cannot add dependency job for unit display-manager.service, ignoring: Unit display-manager.service failed to load: No such file or directory.
Sep 20 14:02:53 gepard kernel: iwlwifi 0000:03:00.0: Direct firmware load failed with error -2
Sep 20 14:02:53 gepard kernel: iwlwifi 0000:03:00.0: Direct firmware load failed with error -2
Sep 20 14:02:53 gepard systemd[1]: Failed to subscribe to NameOwnerChanged signal: Connection timed out
Sep 20 14:02:53 gepard systemd[1]: Failed to subscribe to activation signal: Connection timed out
Sep 20 14:02:53 gepard systemd[1]: Failed to register name: Connection timed out
Sep 20 14:02:53 gepard systemd[1]: Failed to set up API bus: Connection timed out
Sep 20 14:02:53 gepard systemd[1]: Unit nfs-config.service entered failed state.
Sep 20 14:02:53 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Sep 20 14:02:53 gepard systemd[1]: Unit sendmail.service entered failed state.
Sep 20 14:02:54 gepard dbus[1814]: [system] Failed to activate service 'org.freedesktop.ColorManager': timed out
Sep 20 14:02:54 gepard systemd[2000]: Failed at step EXEC spawning /usr/sbin/rpc.statd: No such file or directory
-- The process /usr/sbin/rpc.statd could not be executed and failed.
Sep 20 14:02:54 gepard systemd[1]: Unit rpc-statd.service entered failed state.
Sep 20 14:03:19 gepard dbus[1814]: [system] Failed to activate service 'org.freedesktop.ColorManager': timed out
Sep 20 14:03:51 gepard sshd[2067]: pam_systemd(sshd:session): Failed to create session: Connection timed out
Sep 20 14:04:24 gepard systemd[1]: Failed to start Login Service.
-- Subject: Unit systemd-logind.service has failed
-- Unit systemd-logind.service has failed.
-- The result is failed.
Sep 20 14:04:24 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Sep 20 14:05:54 gepard systemd[1]: Failed to start Login Service.
-- Subject: Unit systemd-logind.service has failed
-- Unit systemd-logind.service has failed.
-- The result is failed.
Sep 20 14:05:54 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Sep 20 14:06:50 gepard sshd[2400]: pam_systemd(sshd:session): Failed to create session: Connection timed out
Sep 20 14:07:24 gepard systemd[1]: Failed to start Login Service.
-- Subject: Unit systemd-logind.service has failed
-- Unit systemd-logind.service has failed.
-- The result is failed.
Sep 20 14:07:24 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Sep 20 14:08:55 gepard systemd[1]: Failed to start Login Service.
-- Subject: Unit systemd-logind.service has failed
-- Unit systemd-logind.service has failed.
-- The result is failed.
...
Sep 20 14:14:56 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Sep 20 14:16:26 gepard su[2877]: pam_systemd(su:session): Failed to create session: Message did not receive a reply (timeout by message bus)
Sep 20 14:16:26 gepard systemd[1]: Failed to start Login Service.
-- Subject: Unit systemd-logind.service has failed
-- Unit systemd-logind.service has failed.
-- The result is failed.
Sep 20 14:16:26 gepard systemd[1]: Unit systemd-logind.service entered failed state.
Comment 6 Juergen Rose 2014-09-20 12:32:35 UTC
Now I coomented out the 
-session        optional        pam_systemd.so
line in /etc/pam.d/system-auth and rebooted the system. The subsequent login is much faster. It does not hang a long time at "rekeying". But graphical.target and the multi-user.target is still dead and there are still messages about "Failed to start Login Service".
Comment 7 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2014-10-30 09:04:52 UTC
Could you try -217, please? Otherwise, we certainly should move this upstream.
Comment 8 Juergen Rose 2014-10-30 14:55:53 UTC
(In reply to Michał Górny from comment #7)
> Could you try -217, please? Otherwise, we certainly should move this
> upstream.

Can't check now due to Bug 527406.
Comment 9 Mike Gilbert gentoo-dev 2014-10-30 15:16:04 UTC
(In reply to Juergen Rose from comment #8)
> Can't check now due to Bug 527406.

Which has been fixed. Sync your portage tree.
Comment 10 Pacho Ramos gentoo-dev 2015-09-07 18:25:08 UTC
Please retry with 225