Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 481016 - x11-misc/slim: prefer pam_systemd.so over internal CK support
Summary: x11-misc/slim: prefer pam_systemd.so over internal CK support
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Ian Stakenvicius (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on: 478258
Blocks:
  Show dependency tree
 
Reported: 2013-08-14 09:30 UTC by Marek Szuba
Modified: 2013-08-27 05:27 UTC (History)
2 users (show)

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 Marek Szuba archtester gentoo-dev 2013-08-14 09:30:45 UTC
Hello,

On a system running systemd (tested on the latest version marked stable on amd64, i.e. 204), upgrading consolekit to latest stable version 0.4.6 causes services implicitly depending on CK to fail. For example, trying to log in to X using x11-misc/slim results in the following errors in the journal:

dbus[3277]: [system] Activating via systemd: service name='org.freedesktop.ConsoleKit' unit='console-kit-daemon.service'
dbus[3277]: [system] Activation via systemd failed for unit 'console-kit-daemon.service': Unit console-kit-daemon.service failed to load: No such file or directory. See system logs and 'systemctl status console-kit-daemon.service' for details.

The problem stems from the fact that even though the consolekit-0.4.6 tarball provides appropriate service units, line 105 of consolekit-0.4.6.ebuild explicitly prevents them from being merged in order to "avoid collision with system-logind". At the same time the D-Bus configuration file /usr/share/dbus-1/system-services/org.freedesktop.ConsoleKit.service, which still is installed, explicitly refers to one of the now-missing units.

I have not attempted to fix the problem yet because I am not aware of what exactly the problem regarding collisions with logind is. A workaround restoring the system to usable state is to downgrade sys-auth/consolekit to version 0.4.5_p20120320-r1, which is both stable and still available.
Comment 1 RedEyedMan 2013-08-14 10:49:30 UTC
I comfirm this. Downgraded consolekit to sys-auth/consolekit-0.4.5_p20120320-r1
Comment 2 Pacho Ramos gentoo-dev 2013-08-15 19:58:18 UTC
Doesn't slim work with logind? The removal was on purpose to ensure logind is not run at the same time of consolekit (for example, accountservices was trying to launch consolekit even with logind running -> I reported it to upstream some days ago and they fixed the problem to not try to use consolekit in that environment)
Comment 3 RedEyedMan 2013-08-17 13:20:32 UTC
(In reply to Pacho Ramos from comment #2)
> Doesn't slim work with logind? The removal was on purpose to ensure logind
> is not run at the same time of consolekit (for example, accountservices was
> trying to launch consolekit even with logind running -> I reported it to
> upstream some days ago and they fixed the problem to not try to use
> consolekit in that environment)

Slim is working with logind.
Comment 4 Pacho Ramos gentoo-dev 2013-08-17 13:25:04 UTC
In that case, you should open an upstream report asking them to not try to start consolekit when running in systemd
Comment 5 Samuli Suominen (RETIRED) gentoo-dev 2013-08-17 14:47:15 UTC
(In reply to Galym Kerimbekov from comment #3)
> Slim is working with logind.

Nope, slim as it's in Portage doesn't have anykind of logind support.
and systemd users should pick a display manager that works with logind.
I'll just convert this to feature request for the slim maintainer, I saw
Fedora had logind patch for slim in their mailing list some weeks ago,
for instance.
Comment 6 Samuli Suominen (RETIRED) gentoo-dev 2013-08-17 14:51:53 UTC
as in, systemd users shouldn't enable USE="consolekit" to force slim to fallback to pam_systemd.so module, like it would do with a normal text login
Comment 7 Samuli Suominen (RETIRED) gentoo-dev 2013-08-21 19:42:13 UTC
Marek,

try updated 0.4.6 with USE="-systemd-units", it removes also the line you mentioned in Comment #0
or if you want, you can always enable USE="systemd-units" to retain the old behavior 0.4.5* had, which is to install the units
Comment 8 Ian Stakenvicius (RETIRED) gentoo-dev 2013-08-22 20:08:22 UTC
I've put a new version of slim in the tree, 1.3.5-r3, which contains a runtime flag to disable consolekit checks even when they're compiled in.  I've also added that option to the systemd .service file.

Both of these in combation should allow slim to be built with USE="consolekit" but still operate as expected when started under systemd.

The package is currently masked as I don't have systemd installed, so please test and I will unmask it.
Comment 9 Arnaud Vallette d'Osia 2013-08-24 16:14:20 UTC
(In reply to Ian Stakenvicius from comment #8)
> I've put a new version of slim in the tree, 1.3.5-r3

Working fine here Stakenvicius : thanks

x11-misc/slim-1.3.5-r3  USE="consolekit pam -branding"
sys-apps/systemd-204  USE="acl firmware-loader gudev introspection keymap kmod
 pam policykit tcpd -audit -cryptsetup -doc -gcrypt -http -lzma -openrc -python
 -qrcode (-selinux) -static-libs {-test} -vanilla -xattr"
 PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7"

keep on the good work!
Comment 10 Ian Stakenvicius (RETIRED) gentoo-dev 2013-08-26 14:41:51 UTC
Sweet;  unmasking.  Thanks for the test!

+  22 Aug 2013; Ian Stakenvicius <axs@gentoo.org>
+  +files/slim-1.3.5-disable-ck-for-systemd.patch, +slim-1.3.5-r3.ebuild:
+  if slim is started from its systemd service file then don't let it try to set
+  up a consolekit session