[systemd-devel] Systemd socket activation of DBus in the user session

Léo Gillot-Lamure leo.gillot at navaati.net
Sun Jun 17 16:45:19 PDT 2012


Hello.

I'm trying to get systemd work as the user session supervisor, thus i
want it to launch the dbus daemon for the session. Systemd seems to
require that dbus is socket activated (service units of Type=dbus have a
Require dep on dbus.socket, not on dbus.service), so i created the
relevant .socket and .service unit files. Taking inspiration from the
unit files at the system level, i put "/usr/bin/dbus-daemon --session
--address=systemd: --nofork --systemd-activation" as the ExecStart
command line for the daemon. The session boots up, the dbus daemon is
launched by the socket activation, the gnome panel is properly launched
(trough a unit file) and registers to the bus, messages on the bus are
correctly passed, everything seems fine.
Except the bus-activation of services. For example launching
gnome-terminal doesn't work because it tries to launch something (can't
remember what, maybe it was gconf, or some gvfs stuff) using the bus and
it fails. The result is exactly the same when not using the
--systemd-activation flag. This message
http://lists.freedesktop.org/archives/systemd-devel/2012-May/005301.html
says that it's a dbus bug, because the daemon launches bus-activated
processes with DBUS_SESSION_BUS_ADDRESS==systemd:,guid=<hash> which is
broken.

Thus arise two questions :
- Auke, considering this problem how did you manage to get the
session-wide DBus work in your Meego systemd --user experiment ?
- Dear DBus folks, could this bug be fixed ? Maybe there are already
patches around fixing it ? I could not see any mention of it on the
mailing list.

Thanks,

Léo Gillot-Lamure.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freedesktop.org/archives/systemd-devel/attachments/20120618/bf11e9c5/attachment.pgp>


More information about the systemd-devel mailing list