www.cendio.com
Bug 5950 - many applications fail to start with new systemd (common dbus)
: many applications fail to start with new systemd (common dbus)
Status: NEW
: ThinLinc
Server OS
: pre-1.0
: PC Unknown
: P2 Normal
: LowPrio
Assigned To:
:
:
:
: 6190
  Show dependency treegraph
 
Reported: 2016-07-08 15:55 by
Modified: 2017-08-02 09:51 (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From cendio 2016-07-08 15:55:47
They've moved the session D-Bus in to one that is shared between all sessions
for a user. This seems to wreak havoc with Gnome that has many D-Bus activated
programs. E.g. gnome-terminal and nautilus no longer work.

This was seen on Fedora 24.

Upstream bug:

https://bugzilla.redhat.com/show_bug.cgi?id=1353953
------- Comment #1 From cendio 2016-07-08 16:09:15 -------
Hacking this in to the start of tl-dbus-launch.sh seems to solve the issue:

if [ "${DBUS_SESSION_BUS_ADDRESS}" = "unix:path=/run/user/`id -u`/bus" ]; then
    DBUS_SESSION_BUS_ADDRESS=""
fi
------- Comment #2 From cendio 2016-07-08 16:28:27 -------
An alternative approach is suggested here:

https://bugzilla.redhat.com/show_bug.cgi?id=1281675

The workaround they've come up with to fix the problem of sharing
systemd/dbus-daemon between sessions is to send it information about how env
should look like.

Looking at Fedora 24 I can see them running this when a session is started:

systemctl --user import-environment DISPLAY XAUTHORITY

if which dbus-update-activation-environment >/dev/null 2>&1; then
        dbus-update-activation-environment DISPLAY XAUTHORITY
fi

Running that in ThinLinc also fixes things.
------- Comment #3 From cendio 2016-07-11 11:00:40 -------
Note that this is currently broken even without ThinLinc so upstream may revert
this lunacy. See the upstream bug.
------- Comment #4 From cendio 2016-07-11 11:36:19 -------
See also this bug and the upstream bugs it refers to:

https://bugzilla.redhat.com/show_bug.cgi?id=1353723
------- Comment #5 From cendio 2016-08-25 10:17:08 -------
We'll have a look if this affects Ubuntu 16.04.
------- Comment #6 From cendio 2016-08-25 17:08:21 -------
(In reply to comment #5)
> We'll have a look if this affects Ubuntu 16.04.

Ubuntu 16.04 is not affected by this from what I can tell. I can use
gnome-terminals, gedits and nautilus in multiple sessions independently.
DBUS_SESSION_BUS_ADDRESS is unique across two (one local, one ThinLinc)
simultanous sessions for the same user.
------- Comment #7 From cendio 2017-02-27 15:52:48 -------
Also affects xfce. tl-notify fails to work because Xfce's notification daemon
isn't properly spawned from dbus:

> Feb 27 15:48:49 ossman.lkpg.cendio.se dbus-daemon[18959]: [session uid=1016 pid=18959] Activating via systemd: service name='org.freedesktop.Notifications' unit='xfce4-notifyd.service' requested by ':1.60' (uid=1016 pid=19709 comm="/usr/bin/python3 /bin/d-feet " label="unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023")
> Feb 27 15:48:49 ossman.lkpg.cendio.se systemd[18763]: Starting XFCE notifications service...
> Feb 27 15:48:49 ossman.lkpg.cendio.se xfce4-notifyd[19886]: Unable to init server: Could not connect: Connection refused
> Feb 27 15:48:49 ossman.lkpg.cendio.se xfce4-notifyd[19886]: cannot open display: 
> Feb 27 15:48:49 ossman.lkpg.cendio.se systemd[18763]: xfce4-notifyd.service: Main process exited, code=exited, status=1/FAILURE
> Feb 27 15:48:49 ossman.lkpg.cendio.se systemd[18763]: Failed to start XFCE notifications service.
> Feb 27 15:48:49 ossman.lkpg.cendio.se systemd[18763]: xfce4-notifyd.service: Unit entered failed state.
> Feb 27 15:48:49 ossman.lkpg.cendio.se systemd[18763]: xfce4-notifyd.service: Failed with result 'exit-code'.
> Feb 27 15:50:49 ossman.lkpg.cendio.se dbus-daemon[18959]: [session uid=1016 pid=18959] Failed to activate service 'org.freedesktop.Notifications': timed out (service_start_timeout=120000ms)
------- Comment #8 From cendio 2017-02-27 16:08:34 -------
Filed a new bug for xfce:

https://bugzilla.redhat.com/show_bug.cgi?id=1427197
------- Comment #9 From cendio 2017-03-09 15:18:41 -------
Ubuntu is now affected, see bug 6190.
------- Comment #10 From cendio 2017-08-02 09:50:55 -------
Also affects OpenSUSE.