Xfce Forum

Sub domains
 

You are not logged in.

#1 2015-01-26 09:00:17

jody
Member
Registered: 2015-01-26
Posts: 9

LogOut Dialog: most buttons disabled

Hi
I run XFCE on gentoo 3.16.5
Until recently the Dialog opened when selecting the "Log Out" menu item contained the buttons
Log Out, Restart, Shut Down, Suspend and Hibernate,
all of whichwere enabled (and functioning)

Now, after some updates, the same Dialog only shows
  Log Out, Restart, Shut Down and Suspend
(i.e. no more hibernate) and oonly "Log Out" is enabled, all others are disabled.

It is as if my user has no permission to power off or restart  the computer anymore.

Furthermore, when i type sudo pm-hibernate, it seems to start normal hibernation
(/var/log/message says "Jan 22 18:00:38 aim-triops kernel: PM: Hibernation image created (1484930 pages copied)")
but it immediately restarts before actually shutting down.

I have not changed the kernel in the time between the two behaviors.

I have pm-utils 1.4.1-r6 and upower-pm-utils 0.9.23-r2

How can i get the "normal" behavior back?

Thank You
  Jody

Edit:
In '/var/log/pm-suspend' i found the lines:
(* many success messages for hibernate *)

Running hook /usr/lib64/pm-utils/sleep.d/99video hibernate hibernate:
/usr/lib64/pm-utils/sleep.d/99video hibernate hibernate: success.
Thu Jan 22 18:01:09 CET 2015: performing hibernate
/usr/lib64/pm-utils/pm-functions: line 321: echo: write error: No such device
Thu Jan 22 18:01:12 CET 2015: Awake.
Thu Jan 22 18:01:12 CET 2015: Running hooks for thaw

(* many messages about thawing *)

Last edited by jody (2015-01-26 09:16:12)

Offline

#2 2015-01-26 11:47:33

cmcanulty
Member
From: Beulah, Michigan
Registered: 2014-05-10
Posts: 216

Re: LogOut Dialog: most buttons disabled

Right click name on panel and cl properties and check the items you want to show in the list

Offline

#3 2015-01-26 16:16:31

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,151

Re: LogOut Dialog: most buttons disabled

Problem 1 - Grayed out buttons:
Usually, this is the result of an issue with policykit or consolekit. Do you have them installed and/or have they been updated properly?
Also, how do you start xfce4? What command and where/how?

Problem 2 - Hibernate issues:
Really not an Xfce issue, but you should look further into:

/usr/lib64/pm-utils/pm-functions: line 321: echo: write error: No such device

...as its probably the reason why its not working. (Is your swap file properly set up?)

Offline

#4 2015-01-28 10:33:44

jody
Member
Registered: 2015-01-26
Posts: 9

Re: LogOut Dialog: most buttons disabled

Thank You for your replies.

Regarding hibernation: it turned out that my swap  partition was not active (don't know why, because i *know* i used 'swapon' during installation).
So after a 

swapon /dev/sda3

the swap was active again:

$ cat /proc/swaps
  Filename				Type		Size	Used	Priority
  /dev/sda3                               partition	25166984	0	-1

and manual hibernation works now ("hibernate" now also turns up on the button panel for "Log Out...").

The buttons are stilll greyed out though.

I do have consolekit 0.4.6 installed.
Is there perhaps some configuration for it i have to change?

xfce is started via the lightDM (which is set as DISPLAYMANAGER in /etc/conf.d/xdm)

Offline

#5 2015-01-28 11:39:39

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,151

Re: LogOut Dialog: most buttons disabled

Not a gentoo use, but as a test, I would disable lightdm and start xfce manually via either:

startxfce4

...or

startxfce4 --with-ck-launch

...to see if the buttons are enabled.

If it works, I would look at finding where in the lightdm configs it starts xfce and adjust accordingly. Or possibly a bug with lightdm?

BTW, are you using systemd?

Offline

#6 2015-01-28 14:26:44

jody
Member
Registered: 2015-01-26
Posts: 9

Re: LogOut Dialog: most buttons disabled

No, i'm not using systemd. still sticking to OpenRC...

Regarding consolekit:

 $ ck-list-sessions
Session5:
	unix-user = '1010'
	realname = '(null)'
	seat = 'Seat1'
	session-type = ''
	active = TRUE
	x11-display = ':0'
	x11-display-device = '/dev/tty7'
	display-device = ''
	remote-host-name = ''
	is-local = TRUE
	on-since = '2015-01-28T10:09:16.774654Z'
	login-session-id = '3'
Session6:
	unix-user = '1010'
	realname = '(null)'
	seat = 'Seat1'
	session-type = ''
	active = FALSE
	x11-display = ':0'
	x11-display-device = '/dev/tty7'
	display-device = ''
	remote-host-name = ''
	is-local = TRUE
	on-since = '2015-01-28T10:09:17.234563Z'
	login-session-id = '3'

Is it normal that one has two Sessions (i'm only logged in one: directly via the console)?
I notice that one says  "active = true" and the other one says "active = FALSE".
Which session would be the "real" one?

I'll try starting manually later - have to wait for a computation to finish

Offline

#7 2015-01-28 16:36:13

jody
Member
Registered: 2015-01-26
Posts: 9

Re: LogOut Dialog: most buttons disabled

I manually started with

startxfce4 --with-ck-launch

In this case all buttons in the "Log Out..."-panel are enabled, but "Hibernate" is missing.
In the "click-on-user-name menu", the entries "Lock Screen", "Suspend", "Shut Down", "Restart" and "Log Out..." are enabled,
and the entries "Switch User" and "Hibernate" are disabled.

In this case i also have two sessions shown by 'ck-list-sessions', one "active = FALSE" and one "active = TRUE"

Offline

#8 2015-01-28 21:38:00

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,151

Re: LogOut Dialog: most buttons disabled

Then it must be something amiss with the lightdm configuration. My guess is its not running the xfce session properly. Kind of groping in the dark here, but do you have an xfce.desktop xsessions file anywhere that lightdm is referencing? Or do you start xfce through your .xinitrc file?

As for Switch-User being disabled, it is hard-coded to run gdmflexiserver which is no longer available. As a workaround, create the file /usr/local/bin/gdmflexiserver with the following content:

#!/bin/bash
dm-tool switch-to-greeter

...and make it executable. This will use lightdm's switch user functionality, which takes you back to the login screen when activated. If you enter the credentials of an already logged-in user, you will be re-entered into that session. If you enter credentials of a user that is not logged in, a second login session will be created for that user.

As for hibernate being disabled, I'm not sure about gentoo, but in Xubuntu, for example, you have manually enable it through a policy kit directive. Perhaps the same exists for gentoo.

Note: you can always run:

xfce4-power-manager --dump

...to get a report on your authorizations for these events.

Offline

#9 2015-01-29 00:27:05

ozjd
Member
From: Hawkesbury NSW Australia
Registered: 2012-02-05
Posts: 560
Website

Re: LogOut Dialog: most buttons disabled

I was seeing the hibernate option greyed out after xfce4-power-manager was updated to the latest version, 1.4.2 under Fedora 20. Sorry I can't help how it was solved as in 21 it is fine with the same version. With older versions of the power manager it was also fine as it was under KDE.

Offline

#10 2015-01-29 07:52:00

jody
Member
Registered: 2015-01-26
Posts: 9

Re: LogOut Dialog: most buttons disabled

@ozjd:I am using version 1.3.0 of xfce4-power-manager....

I found out that when i stop xdm, log in as "myself" and then call 'startx', i can hibernate, suspend and shut down from the "Log Out ..." menu (i.e. everything is as expect it to be).
My .xinitrc is

exec ck-launch-session startxfce4

which is slightly different from the command you suggested to me in an earlier post.

So my problem boils down to how to tell lightDM to use this way to start xfce...

Offline

#11 2015-01-29 11:30:41

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,151

Re: LogOut Dialog: most buttons disabled

What are the contents of /etc/env.d/90xsession and what session files (and their contents) exist in /etc/X11/Sessions?
Maybe there is something there that specifies how Xfce is to run.

EDIT: One other thing you might want to try...
If you look at the contents of the startxfce4 executable, you see:

if test "x$*" != "x"
then
  OPTS=""
  for OPT in $*
  do
    if test "x$OPT" = "x--help"
    then
      # print help and exit
      echo "Usage:"
      echo "  startxfce4 [OPTIONS...]"
      echo
      echo "Options:"
      echo "  --help                   Show help options"
      echo "  --with-ck-launch         Start xfce4-session inside a"
      echo "                           ConsoleKit session"
      echo

      exit 0
    elif test "x$OPT" = "x--with-ck-launch"
    then
      # try to launch xfce4-session with ck-launch-session in xinitrc
      XFCE4_SESSION_WITH_CK="1"
      export XFCE4_SESSION_WITH_CK
    else
      # append
      OPTS="$OPTS $OPT"
    fi
  done

...so basically, to start Xfce within a ConsoleKit session, XFCE4_SESSION_WITH_CK="1" is exported. Maybe you can try adding this to your system environment file (is it /etc/env.d/xx in gentoo?) and see if it helps.

Last edited by ToZ (2015-01-29 11:46:48)

Offline

#12 2015-02-02 09:44:31

jody
Member
Registered: 2015-01-26
Posts: 9

Re: LogOut Dialog: most buttons disabled

I have had no /etc/env.d/90xsession; i created one with the contents

XFCE4_SESSION_WITH_CK="1"
XSESSION="startxfce4 --with-ck-launch"

which did not change anything after rebooting (everything still grayed). Then i tried a /etc/env.d/90xsession with the contents

XFCE4_SESSION_WITH_CK="1"
XSESSION="exec ck-launch-session startxfce4"

(i.e. the same launch command as in my .xinitrc) which also had no noticeable effects after a reboot.

In /etc/X11/Sessions i only have

ls -l  /etc/X11/Sessions/
total 12
lrwxrwxrwx 1 root root    5 Dec  9 17:03 Xfce -> Xfce4
-rwxr-xr-x 1 root root   11 Dec  9 17:03 Xfce4
-rwxr-xr-x 1 root root 2223 Feb  2 09:47 Xsession

/etc/X11/Sessions/Xfce4 only contains the line

startxfce4

When i changed this to

startxfce4 --with-ck-launch

everything was still grayed out after rebooting.

/etc/X11/Sessions/Xsession contains a lot of statements about xkbmap ad sysmodmap, and at the bottom:

if [ -x "$startup" ]; then
	exec "$startup"
elif [ -x "$HOME/.Xclients" ]; then
	exec "$HOME/.Xclients"
elif [ -x /etc/X11/xinit/Xclients ]; then
	exec /etc/X11/xinit/Xclients
elif [ -x /etc/X11/Xclients ]; then
	exec /etc/X11/Xclients
else
	exec ck-launch-session startxfce4
fi

Further up, $startup is defined as $HOME/.xsession

I do have a $HOME/.xsession and its conetnts are

exec ck-launch-session startxfce4

I It is really strange: if i start via lightdm, it looks as if xfce4 is started with "exec ck-launch-session startxfce4", but the buttons stay grayed;
when i manually start it (i.e. startx which reads my .xinitrc, which has the contents  "exec ck-launch-session startxfce4" everything is as it should be...

Offline

#13 2015-02-02 11:51:54

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 8,151

Re: LogOut Dialog: most buttons disabled

Is there anything in the lightdm log files (possibly in /var/log/lightdm)?

Otherwise, maybe worth creating a gentoo bug report for this. There was this old bug that looks similar. Perhaps it has returned in some form?

Offline

#14 2015-03-16 07:20:59

cpc
Member
Registered: 2015-03-16
Posts: 3

Re: LogOut Dialog: most buttons disabled

I think (what works for me) your ~/.xsession (that's $HOME/.xsession) file should have :

exec startxfce4 --with-ck-launch

you can test that with

$ startx

Gentoo Xfce HOWTO

Last edited by cpc (2015-03-16 07:37:18)

Offline

Board footer

Powered by FluxBB