dbus failure to connect to the session bus

Shawn Rutledge shawn.t.rutledge at gmail.com
Tue Apr 8 19:47:01 CEST 2008

On Tue, Apr 8, 2008 at 2:15 AM, Tilman Baumann <tilman at baumann.name> wrote:
> > I modified cat /etc/X11/Xsession for now:
> >
> > echo "$DBUS_SESSION_BUS_ADDRESS" > /tmp/dbus-session

Then BTW I set the variable in /etc/profile so it's always set when I
log in over SSH.
export DBUS_SESSION_BUS_ADDRESS=`cat /tmp/dbus-session`

> > IMO there must be some way to discover this DBUS address.
> >
>  I find this approach very useful and simple. I was about to suggest
> something similar.
>  I would propose that everything that makes some system-wide usable
> environment should also write a 'export FOO=BAR' into
> /volatile-memory/..../environ.d/FOO
>  /etc/profile could then source them all.

Yeah that's a decent idea.

There is /var/run/dbus too, which has some info about the system DBUS
daemon, but apparently the Xsession script does not have permission to
write there.  (I tried)

>  Openmoko is not multiuser. There is no reason why a ssh user should not be
> able to start X programs or use gconf and dbus.
>  So what abut making DISPLAY, DBUS_SESSION_BUS_ADDRESS and so on system
> wide?

It would be even better if the environment variable somehow wasn't
needed.  Even for a multiuser system, if we assume each user has only
one DBUS session daemon running (which might not always be true, or is
it?), then it could be possible for a user to discover his own session
daemon which was already running, when he logs in again.  It could be
as simple as including the username as part of the file that has the
information.  But I'm not much of a dbus expert yet, so don't know if
there are other ways they already thought of, to get this information.

DBus appeared to be necessary for my Display Scheme project to become
useful on the phone, so I wrote a Chicken Scheme extension for it:


More information about the openmoko-devel mailing list