On Tue, 2014-11-04 at 11:40 +0100, Maciej Wereski wrote:
> 04.11.2014 o 10:35 Jussi Laako <[email protected]> wrote:
> 
> > On 3.11.2014 10:52, Maciej Wereski wrote:
> >> Since systemd v212 DBUS_SESSION_BUS_ADDRESS is set per user in
> >> [email protected]. As long as xserver is pulled by default.target in
> >> /usr/lib/systemd/user, it will have DBUS_SESSION_BUS_ADDRES set.
> >
> > That would be generally bad idea, because it may lead to unexpected  
> > start of Xserver or inability to run more than one X session with the  
> > same user.
> >
> > This kind of stuff should be launched inside session, not as a user  
> > service (singleton per logged in user, regardless of number of logins).
> >
> > This is one of the areas were are now trying to clean up in Tizen where  
> > there is horrible mess between user and session services!
> 
> Well, currently user-session-launch uses PAM and logind to login user.  
> logind starts [email protected], which pulls default.target, which in turn  
> pulls dbus.service for user. This has address always set to  
> /run/user/%U/dbus/user_bus_socket. I haven't seen any other dbus session  
> instances being run.
> 
> Having this set in one place is better solution, than setting this in  
> multiple service files, scripts and other environment files. What's more  
> one bus per user may also has it benefits. In the future, when we'll stop  
> abusing systemd --user to launch and every session has it's own dbus  
> session, it'll be easier to change that in one place.

If I interpret the last sentence correctly, you think that it would be a
good idea to some day run a separate dbus daemon instance for each
session. My gut feeling is that most services that use D-Bus are "user
services" by nature, and will likely break in a multi-session
environment if there's no bus for the "user scope". There may also be
"session services" depending on a "session bus", but I can't name any.
If there are both "user services" and "session services", and we need to
support multiple session buses running simultaneously, then we will
continue have a mess... Perhaps in that case we need two layers of dbus
daemons for each user, one for the user bus and N for the session buses,
but that sounds messy too...

I hope that it will turn out that we will only ever need a single user
bus, and there will be no need for separate session buses.

-- 
Tanu
_______________________________________________
Dev mailing list
[email protected]
https://lists.tizen.org/listinfo/dev

Reply via email to