Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I obviously have the privilege to shutdown through dbus, cuz it works in XFCE4, but in KDE4, I only have an option to logout.

Any thoughts?

I start kde4 with dbus-launch --exit-with-session startkde

EDIT

Yes, I got Active=yes from systemctl, but removing the dbus-launch stopped docky from launching, and .. shutdown option still not available

share|improve this question
add comment

1 Answer

Using dbus-launch is no longer needed with systemd. You need to make sure that when running startx that Xwindows is launched on the say TTY. This will insure that you preserve the login session. Below I've listed some notes on setting up systemd --user sessions.

startx

Users should first set up systemd-logind to manage their session. If systemd is running as the system init daemon, then this is already happening.

Next, the user must launch systemd by putting the following in their ~/.xinitrc.

systemd --user

If the user is not launching the window manager through systemd --user, then

systemd --user &

should be used and launched like anything else in ~/.xinitrc, before execing the window manager.

After starting X, the user can check whether their session is now being managed by systemd-logind with the following command:

$ loginctl --no-pager show-session $XDG_SESSION_ID | grep Active

If this command prints Active=yes, then the user is now using systemd-logind to manage their session. The user should remove any instances of ck-launch-session or dbus-launch from their ~/.xinitrc, as those commands are unneeded.

More information on this can be found here

share|improve this answer
    
No luck, see my updates –  warl0ck Mar 12 '13 at 10:18
    
are you running systemd --user in your .xinitrc –  cinelli Mar 12 '13 at 20:57
    
It blocks, so I ran systemd --user & instead, prior to startkde –  warl0ck Mar 13 '13 at 0:11
    
Place systemd --user & in your .xinitrc and remove all dbus related lines. So your .xinitrc should show. `systemd --user & <newline> exec startkde –  cinelli Mar 13 '13 at 0:21
    
If this does not work. Then install KDM and systemctl enable kdm.service (to enable starting at boot) followed by systemctl start kdm.service. Or you could just reboot and test that the service unit starts at boot. –  cinelli Mar 13 '13 at 0:24
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.