Brian J. Tarricone
bjt23 at cornell.edu
Fri Feb 15 18:48:22 PST 2008
Patryk Zawadzki wrote:
> On Feb 16, 2008 2:28 AM, Brian J. Tarricone <bjt23 at cornell.edu> wrote:
>> Patryk Zawadzki wrote:
>>> Would it make sense to have a per-user bus aside from the session bus?
>> The session bus *is* per-user. Well, assuming the user is only logged
>> in once, which is probably a safe assumption, no? The desktop
>> environment/X init script/whatever is responsible for starting it when X
>> is started.
> Actually it's per session and in case your session dies (should not
> happen but does) or in case where one client goes frenzy and does not
> exit you end up with 10 or so dbus instances.
See 'man dbus-launch', specifically the --exit-with-session option.
That should cause the session daemon to quit if X exits.
> Having it started by
> ConsoleKit would remove the burden of having to start it in Xinit and
> would allow CK to notify dbus when the number of client sessions
> changes (so it only dies if there are no connected clients and no
> active sessions). This would allow new scenarios like logging in
> remotely using ssh and checking the printing queue that was started
> before leaving or using remote graphical login to fiddle with some
> other user service that was already started.
This somewhat highlights what IMHO is one of the worst things about
dbus: its reliance on environment variables to tell clients how to
contact the session bus. If CK starts the session bus, how do the
appropriate env vars propagate into the desktop session? You could
solve this by having CK start the session as well, but that sounds like
a bit of a big change, no?
More information about the xdg