X2Go Bug report logs - #1046
x2go session causes dbus conflicts with logged in desktop on Fedora 24

version graph

Package: x2goserver; Maintainer for x2goserver is X2Go Developers <x2go-dev@lists.x2go.org>; Source for x2goserver is src:x2goserver.

Reported by: Andy Wang <dopey@moonteeth.com>

Date: Sat, 25 Jun 2016 03:35:01 UTC

Severity: normal

Merged with 1083

Found in version 4.0.1.19

Full log


Message #10 received at 1046@bugs.x2go.org (full text, mbox, reply):

Received: (at 1046) by bugs.x2go.org; 10 Mar 2017 08:07:10 +0000
From ionic@ionic.de  Fri Mar 10 09:07:09 2017
X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on
	ymir.das-netzwerkteam.de
X-Spam-Level: 
X-Spam-Status: No, score=-2.0 required=3.0 tests=BAYES_00,DKIM_SIGNED,
	DKIM_VALID,DKIM_VALID_AU,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham
	autolearn_force=no version=3.4.1
Received: from localhost (localhost [127.0.0.1])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTP id 3D2DE5DAD0
	for <1046@bugs.x2go.org>; Fri, 10 Mar 2017 09:07:09 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at ymir.das-netzwerkteam.de
Received: from ymir.das-netzwerkteam.de ([127.0.0.1])
	by localhost (ymir.das-netzwerkteam.de [127.0.0.1]) (amavisd-new, port 10024)
	with ESMTP id EQt5kNpptuRi for <1046@bugs.x2go.org>;
	Fri, 10 Mar 2017 09:07:01 +0100 (CET)
Received: from Root24.de (powered.by.root24.eu [5.135.3.88])
	by ymir.das-netzwerkteam.de (Postfix) with ESMTP id 2127E5DACF
	for <1046@bugs.x2go.org>; Fri, 10 Mar 2017 09:06:56 +0100 (CET)
Received: from nopileos.local (178.162.222.41.adsl.inet-telecom.org [178.162.222.41])
	by mail.ionic.de (Postfix) with ESMTPSA id 73E514F002E1;
	Fri, 10 Mar 2017 09:06:55 +0100 (CET)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=ionic.de; s=default;
	t=1489133215; bh=yiyyzbXLfc52jB9u9PEe3RqglaOUE2meEZEKV0fQmz0=;
	h=Subject:To:References:From:Date:In-Reply-To:From;
	b=n3HYqbcCobC7stwg+lllmpm4Cpcx/EYEVI+dW/DGzKVBG85hzG6UOnU0GsyKuLXCI
	 awcaQ2zoPcqvqeIz1zQD44BKdx39YlvwjH9584apJmDNpyXiB6zRMiLkGOXj4VCf74
	 xQO97m4lj5/zYIiYRzWHYznyQN9PUdwNgzf54EzY=
Subject: Re: x2go session causes dbus conflicts with logged in desktop on
 Fedora 24
To: Andy Wang <dopey@moonteeth.com>, 1046@bugs.x2go.org,
 René Genz <liebundartig@freenet.de>
References: <CAGjaHhvetz3KfxWj+_96UFYZZEHU1XFgAuyX=tOYTXP=BvEVQg@mail.gmail.com>
From: Mihai Moldovan <ionic@ionic.de>
Message-ID: <9c410235-e96e-727a-b0e2-be38b6a48620@ionic.de>
Date: Fri, 10 Mar 2017 09:06:46 +0100
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:45.0)
 Gecko/20100101 Thunderbird/45.7.1
MIME-Version: 1.0
In-Reply-To: <CAGjaHhvetz3KfxWj+_96UFYZZEHU1XFgAuyX=tOYTXP=BvEVQg@mail.gmail.com>
Content-Type: multipart/signed; micalg=pgp-sha512;
 protocol="application/pgp-signature";
 boundary="IPvsPEC05QIh461ruono26p4ffhB5qgjf"
[Message part 1 (text/plain, inline)]
Control: reassign -1 x2goserver 4.0.1.19
Control: reassign 1083 x2goserver 4.0.1.19
Control: merge -1 1083


On 25.06.2016 05:30 AM, Andy Wang wrote:
> From the error, I this appears to be resolved by using a custom session script
> in x2go and making sure to call: unset DBUS_SESSION_BUS_ADDRESS
> 
> For example:
> #!/bin/sh
> unset DBUS_SESSION_BUS_ADDRESS
> # redirect to /dev/null due to x2go bug 914
> /usr/bin/mate-session > /dev/null
> 
> Doing some digging, it looks like the dbus socket
> (/usr/lib/systemd/user/dbus.socket) on fedora 24 (dbus-1.11.2-1.fc24.x86_64)
> does this:
> ExecStartPost=-/usr/bin/systemctl --user set-environment
> DBUS_SESSION_BUS_ADDRESS=unix:path=%t/bus
> 
> And sets the DBUS_SESSION_BUS_ADDRESS for all logins for your user.
> 
> This same workaround appears to be what tigervnc used as their permanent solution:
> https://github.com/TigerVNC/tigervnc/commit/c071e493a093d7ee9a568729dd2e151f5cd3d749
> 
> So I think this is the proper solution.

Yes, we should probably also unset DBUS_SESSION_BUS_ADDRESS. If this env
variable is set, dbus-launch won't be used by the Xsession scripts (at least on
Debian, I didn't check Fedora or others) - otherwise dbus-launch will be used,
which is what we really want.


Merging the two bug reports.

This said, I guess I should do this in x2goruncommand, not in the Xsession
script directly.


However, this only fixes problems with full desktop sessions. I believe that we
should also unset DBUS_SESSION_BUS_ADDRESS and wrap all other commands in
dbus-launch. Does that make sense? Or does anyone have a justified veto?


And then, I have to take special care of pubapps sessions, which by default do
not spawn any command. Starting a new dbus session for each command spawned in a
pubapps session would be wrong. The situation is quite complicated in that case,
as there is no common command that is launched and stays available for the whole
session. (What happens essentially is that x2goagent is started and then kept
running, even if no other programs are currently running. Programs are then
executed by the client application, but there's no real concept of a session.)
I have to come up with something to make pubapps sessions behave in a sane way
related to DBUS.



Mihai

[signature.asc (application/pgp-signature, attachment)]

Send a report that this bug log contains spam.


X2Go Developers <owner@bugs.x2go.org>. Last modified: Wed Oct 30 13:00:03 2024; Machine Name: ymir.das-netzwerkteam.de

X2Go Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.