View previous topic :: View next topic |
Author |
Message |
DZoom Tux's lil' helper
Joined: 13 Jun 2010 Posts: 79
|
Posted: Sun Oct 23, 2011 5:38 pm Post subject: no active consolekit session but session-id [SOLVED] |
|
|
*EDIT*
for me it turned out, it was a slim/session-management issue. see last post for details
__________________________________________
Hi,
as i can't modify my former thread i had to open a new one (sorry).
still trying to fix the automounting-problem i have.
after following several guides (e.g. https://forums.gentoo.org/viewtopic-t-858965.html) i ended up modifying my slim login command and adapt my kernel configuration:
relevant kernel options:
Code: |
hal dzm # zgrep -E 'AUDITSYSCALL|PM_RUNTIME|USB_SUSPEND' /proc/config.gz
CONFIG_AUDITSYSCALL=y
CONFIG_PM_RUNTIME=y
CONFIG_USB_SUSPEND=y |
rc-update show
Code: |
hal dzm # rc-update show
alsasound | boot
bootmisc | boot
consolekit | default
cupsd | default
dbus | default
devfs | sysinit
dhcpcd | default
dmesg | sysinit
fsck | boot
hostname | boot
hwclock | boot
keymaps | boot
killprocs | shutdown
local | default
localmount | boot
modules | boot
mount-ro | shutdown
mpd | default
mtab | boot
net.eth0 | default
net.lo | boot
netmount | default
procfs | boot
root | boot
savecache | shutdown
sshd | default
swap | boot
sysctl | boot
syslog-ng | default
termencoding | boot
udev | sysinit
udev-postmount | default
urandom | boot
xdm | default |
slim login command
Code: |
login_cmd exec /usr/bin/dbus-launch /bin/bash -login ~/.xinitrc |
ck-list-sessions printout:
Code: |
hal dzm # ck-list-sessions
Session1:
unix-user = '1000'
realname = '(null)'
seat = 'Seat2'
session-type = ''
active = FALSE
x11-display = ':0.0'
x11-display-device = ''
display-device = ''
remote-host-name = ''
is-local = TRUE
on-since = '2011-10-23T17:27:18.185985Z'
login-session-id = '1' |
.xinitrc of my user:
Code: |
thunar --daemon &
conky &
# polkit agent
/usr/libexec/polkit-gnome-authentication-agent-1 &
# finally: start fluxbox
exec startfluxbox |
still: the active-flag in the single existing consolekit session is set to false
what else do i have to check?
Last edited by DZoom on Tue Oct 25, 2011 12:47 pm; edited 1 time in total |
|
Back to top |
|
|
the_mgt Apprentice
Joined: 05 Aug 2005 Posts: 259 Location: Germany, near Hannover
|
Posted: Mon Oct 24, 2011 11:31 am Post subject: |
|
|
From the guide you mentioned above, this was the last part that initially helped me to get it going:
Quote: | If you use simple display manager without built-in ConsoleKit support, such as XDM or SLIM, you also need to change:
/etc/pam.d/system-login from this:
Code: | session optional pam_ck_connector.so nox11 |
To this:
Code: | session optional pam_ck_connector.so |
|
It worked for about half a week and then stopped without me changing any config file. Sometimes Nautilus/gvfs is able to automount usbsticks now, but the whole thing just simply sucks and is a waste of time. Seems to be only working fine with kde/gnome. I want HAL back, that one just worked. _________________ Citadel Groupware | Avahi Howto |
|
Back to top |
|
|
DZoom Tux's lil' helper
Joined: 13 Jun 2010 Posts: 79
|
Posted: Mon Oct 24, 2011 4:12 pm Post subject: |
|
|
the_mgt wrote: | From the guide you mentioned above, this was the last part that initially helped me to get it going:
Quote: | If you use simple display manager without built-in ConsoleKit support, such as XDM or SLIM, you also need to change:
/etc/pam.d/system-login from this:
Code: | session optional pam_ck_connector.so nox11 |
To this:
Code: | session optional pam_ck_connector.so |
|
It worked for about half a week and then stopped without me changing any config file. Sometimes Nautilus/gvfs is able to automount usbsticks now, but the whole thing just simply sucks and is a waste of time. Seems to be only working fine with kde/gnome. I want HAL back, that one just worked. |
i didn't mention it, but i already changed that.
stillt: doesn't work.
thinking about adding hal to my system for the purpose of automounting. that simply worked. period.
can't be the solution though |
|
Back to top |
|
|
freddan n00b
Joined: 28 Sep 2011 Posts: 7
|
|
Back to top |
|
|
anti-s n00b
Joined: 29 Oct 2005 Posts: 12 Location: Norway
|
Posted: Mon Oct 24, 2011 5:10 pm Post subject: |
|
|
This is my guide, and I removed the working Xinitrc script I used. I've created one that might work for you.
Please do look at the article at section [fix runtime services] (That did the trick for me I think).
Code: | #!/bin/sh
# Start your apps
thunar --daemon &
conky &
# test for an existing bus daemon, just to be safe, or launch a new one
if test -z "$DBUS_SESSION_BUS_ADDRESS" ; then
eval `dbus-launch --sh-syntax --exit-with-session`
echo "D-Bus per-session daemon address is: $DBUS_SESSION_BUS_ADDRESS"
fi
# Start polickyit
/usr/libexec/polkit-gnome-authentication-agent-1 &
# Start WM
exec ck-launch-session startfluxbox
|
|
|
Back to top |
|
|
DZoom Tux's lil' helper
Joined: 13 Jun 2010 Posts: 79
|
Posted: Tue Oct 25, 2011 12:45 pm Post subject: |
|
|
thanks to freddan and anti-s i got it working somehow. here are the steps i performed. the diff from anti's guide; e.g. i don't understand why anti-s emerged slim when he seems not to use it in his guide?
essentially the solution (for me) was to let slim do the session setup stuff and get away from the manual service-loading of ck-launch session or dbus-launch, etc.
here are the 10 steps i took.
i just confirmed they work by updating the gentoo-fluxbox installation on my macbook.
be aware, this steps worked for my environment only! this means: gentoo-sources 3.0.6; slim as login manager; fluxbox for my session; thunar as file manager and the overall goal of being able to automount external devices again...
1.
i followed this guide: https://forums.gentoo.org/viewtopic-t-858965.html
also added "-hal" to my global useflags.
furthermore i followed a lot of other guides, but none of them worked...
------------------------------
2.
rebuilt kernel (in my case: 3.0.6) with necessary options:
Code: |
CONFIG_AUDITSYSCALL=y
menuconfig entry here:
General setup --->
[*] Auditing support
[*] Enable system-call auditing support
CONFIG_PM_RUNTIME=y
menuconfig entry here:
Power management and ACPI options --->
[*] Run-time PM core functionality
CONFIG_USB_SUSPEND=y
menuconfig entry here:
Device Drivers --->
[*] USB support --->
{*} Support for Host-side USB
[*] USB runtime power management (autosuspend) and wakeup |
------------------------------
3.
backed up my old slim.conf.
it was important for me, as i didn't want to start with a bare config after updating.
instead i just wanted to reuse the welcome message, theme, etc.
------------------------------
4.
(re-)emerged the relevant packages.
Code: |
emerge -av1 --noconfmem consolekit pambase shadow sys-fs/udisks sys-power/upower x11-misc/slim sys-auth/polkit gnome-extra/polkit-gnome udev gnome-base/gnome-keyring gnome-base/libgnome-keyring gnome-base/gvfs |
------------------------------
5.
checked if services are loaded at runlevel default
Code: |
hal dzm # rc-update show | grep -E 'consolekit|dbus|xdm'
consolekit | default
dbus | default
xdm | default |
due to a ton of other guides they already were loaded at default runlevel.
------------------------------
6.
adapted my /etc/slim.conf
most important: the login line, which i adapted from
Code: |
login_cmd exec /bin/bash -login /usr/share/slim/Xsession %session |
to:
Code: |
login_cmd exec /bin/bash -login /usr/share/slim/Xsession fluxbox |
my slim tried to use Xsession as default session.
not a good option, but will work for my environment.
i must admit i don't understand why slim does that:
the field "sessions" only contains the entry "fluxbox"; but still i had to choose my fluxbox session explicitly before login.
otherwise a default Xsession would be loaded.
as i didn't want that; plus fluxbox is the only available session on this machine i directly manipulated the login command as shown above. risky on one hand, working for me on the other hand.
------------------------------
7.
removed nox11 flag from /etc/pam.d/system-login.
after editing the line looked like this:
Code: |
session optional pam_ck_connector.so |
------------------------------
8.
moved all relevant entries from .xinitrc to .fluxbox/startup (thunar --daemon &; conky &; ...).
for me, before the line
i had to add these lines:
Code: |
# start thunar as daemon for faster startup
thunar --daemon &
# start conky because it looks cool
conky &
# set mouse sens for razer lachesis
xset m 1 0
# polkit agent
/usr/libexec/polkit-gnome-authentication-agent-1 & |
------------------------------
9.
removed my .xinitrc
------------------------------
10.
reboot and checked if i had an active consolekit session.
as i had an active session, i just tried if mounting of devices worked for my user. it did. |
|
Back to top |
|
|
|