[arch-general] console-kit session not activates properly
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this? -- J.
On 25-11-2011 15:15, János Illés wrote:
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this?
I had problems too and the solution I found was to do it like this: if [[ $(tty) == /dev/tty1 ]]; then startx &> /dev/null & sleep 15 logout fi The sleep seems to be needed in order for *kit to work. I'm using xfce though. -- Mauro Santos
On Fri, 25 Nov 2011 17:16:31 +0000 Mauro Santos <registo.mailling@gmail.com> wrote:
On 25-11-2011 15:15, János Illés wrote:
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this?
I had problems too and the solution I found was to do it like this:
if [[ $(tty) == /dev/tty1 ]]; then startx &> /dev/null & sleep 15 logout fi
The sleep seems to be needed in order for *kit to work. I'm using xfce though.
The sleep is needed to avoid a race condition: logout happens before the policykit starts. What I don't understand is why ck doesn't complain about an empty utmp entry? I though you have to keep your user logged in, so that "w" returns something. I suspect, you won't be able to use Upower to shutdown... -- Leonid Isaev GnuPG key ID: 164B5A6D Key fingerprint: C0DF 20D0 C075 C3F1 E1BE 775A A7AE F6CB 164B 5A6D
On Fri, Nov 25, 2011 at 11:25, Leonid Isaev <lisaev@umail.iu.edu> wrote:
On Fri, 25 Nov 2011 17:16:31 +0000 Mauro Santos <registo.mailling@gmail.com> wrote:
On 25-11-2011 15:15, János Illés wrote:
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this?
I had problems too and the solution I found was to do it like this:
if [[ $(tty) == /dev/tty1 ]]; then startx &> /dev/null & sleep 15 logout fi
The sleep seems to be needed in order for *kit to work. I'm using xfce though.
The sleep is needed to avoid a race condition: logout happens before the policykit starts. What I don't understand is why ck doesn't complain about an empty utmp entry? I though you have to keep your user logged in, so that "w" returns something. I suspect, you won't be able to use Upower to shutdown...
-- Leonid Isaev GnuPG key ID: 164B5A6D Key fingerprint: C0DF 20D0 C075 C3F1 E1BE 775A A7AE F6CB 164B 5A6D
To all: Forgive my noise. Similar problem, probably different solution. PBKAC. Myra -- Life's fun when your sick and psychotic!
On Fri, Nov 25, 2011 at 18:25, Leonid Isaev <lisaev@umail.iu.edu> wrote:
The sleep is needed to avoid a race condition: logout happens before the policykit starts. What I don't understand is why ck doesn't complain about an empty utmp entry? I though you have to keep your user logged in, so that "w" returns something. I suspect, you won't be able to use Upower to shutdown...
Thank you both, added a sleep to the script and now it works fine. I use halt for shutdown, which i do rarely, i mostly just suspend to ram so I only noticed the polcy/console-kit error because of the failing automount. -- J.
On 25-11-2011 17:25, Leonid Isaev wrote:
On Fri, 25 Nov 2011 17:16:31 +0000 Mauro Santos <registo.mailling@gmail.com> wrote:
On 25-11-2011 15:15, János Illés wrote:
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this?
I had problems too and the solution I found was to do it like this:
if [[ $(tty) == /dev/tty1 ]]; then startx &> /dev/null & sleep 15 logout fi
The sleep seems to be needed in order for *kit to work. I'm using xfce though.
The sleep is needed to avoid a race condition: logout happens before the policykit starts. What I don't understand is why ck doesn't complain about an empty utmp entry? I though you have to keep your user logged in, so that "w" returns something. I suspect, you won't be able to use Upower to shutdown...
I can shutdown/reboot/suspend just fine from the xfce logout dialog so no problem there. When I started having this problem, which was quite a while ago, I have figured that something about *kit/ck/whatever needed to start or get started before I could logout, since using startx manually would work fine (I'm not in the power group btw). -- Mauro Santos
2011/11/25 János Illés <ijanos@gmail.com>
Hi, I have a bit of a trouble with proper policy-kit settings. I’m running a standalone openbox session for desktop usage. For login I have a simple script in my .zprofile file, which will start the X server if I log in from the first virtual terminal (which is what I’m doing 99% of the time). if [[ `tty` == "/dev/tty1" ]]; then startx &! logout fi my xinitrc is the following: exec ck-launch-session dbus-launch openbox-session The problem is that in the X session the consolekit session’s is-local and active properties are FALSE hence the removable device automount breaks (I guess it could affect other things I dont use) If I start the X server with startx manually from the tty2 after logging in, both values will be TRUE and device automounting works fine. Should I switch to a proper login manager or is there a quick/easy fix for this? -- J.
J I'm having a similar problem. Check your boot log to see if dbus started properly. I'm having some of the same problems and am gathering info from logs etc. If dbus failed try to start it with [ sudo /etc/rc.d/dbus start ] see if automounting works, it did for me. Myra -- Life's fun when your sick and psychotic!
participants (4)
-
János Illés
-
Leonid Isaev
-
Mauro Santos
-
Myra Nelson