Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] xfce4 "shut down" "restart" button are disabled
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 1:56 am    Post subject: Reply with quote

I also use slim, and everything works. My /etc/slim.conf is completely stock, and pasted here.

In my case, ck-launch-session is invoked by xinitrc through the file /etc/X11/xinitrc/xinitrc.d/90-consolekit , which is owned by sys-auth/consolekit-0.4.5-r1 . I have also pasted that here.

In /etc/X11/xinitrc/xinitrc.d there should also be a file 80-dbus, which is owned by sys-apps/dbus (in my case dbus-1.4.12).

If you make your setup completely consistent with mine, it will be interesting if it doesn't work.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 2:27 am    Post subject: Reply with quote

Jaglover wrote:
Can't tell, I do not use any login managers. However, if you choose Xsession, will it source .xinitrc?


I'm almost there. Xsession is screwed up.
I stopped xdm
Commented out from /etc/conf.d/xdm
#DISPLAYMANAGER="xdm"

login as user, run startx and all the buttons are there working.
But it does not work with displaymanager.
_________________
#Thelma
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 3:44 am    Post subject: Reply with quote

Hypnos wrote:
I also use slim, and everything works. My /etc/slim.conf is completely stock, and pasted here.

In my case, ck-launch-session is invoked by xinitrc through the file /etc/X11/xinitrc/xinitrc.d/90-consolekit , which is owned by sys-auth/consolekit-0.4.5-r1 . I have also pasted that here.

In /etc/X11/xinitrc/xinitrc.d there should also be a file 80-dbus, which is owned by sys-apps/dbus (in my case dbus-1.4.12).

If you make your setup completely consistent with mine, it will be interesting if it doesn't work.


Where do you find these files? I don't have them ???
/etc/X11/xinitrc/xinitrc.d/90-consolekit ?
sys-auth/consolekit-0.4.5-r1 ?
/etc/X11/xinitrc/xinitrc.d ?
_________________
#Thelma
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 5958
Location: Saint Amant, Acadiana

PostPosted: Wed Dec 14, 2011 3:50 am    Post subject: Reply with quote

As expected, 90-consolekit is provided by sys-auth/consolekit.
Code:
$ equery b 90-consolekit
 * Searching for 90-consolekit ...
sys-auth/consolekit-0.4.5-r2 (/etc/X11/xinit/xinitrc.d/90-consolekit)


Maybe you should do emerge -1 consolekit.
_________________
Please learn how to denote units correctly!

Political Correctness is all about replacing imaginary injustice with real injustice.
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 4:23 am    Post subject: Reply with quote

Jaglover wrote:
As expected, 90-consolekit is provided by sys-auth/consolekit.
Code:
$ equery b 90-consolekit
 * Searching for 90-consolekit ...
sys-auth/consolekit-0.4.5-r2 (/etc/X11/xinit/xinitrc.d/90-consolekit)


Maybe you should do emerge -1 consolekit.


same setup here:
sys-auth/consolekit-0.4.5-r1 (/usr/bin/ck-launch-session)
sys-auth/consolekit-0.4.5-r1 (/etc/X11/xinit/xinitrc.d/90-consolekit)

the 80-dbus is in dir: /etc/X11/xinit/xinitrc.d/
re-emerging consolekit did not help but I'm trying to find out how to generate plugdev group as I don't have one.
_________________
#Thelma
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 4:50 am    Post subject: Reply with quote

Is your /etc/slim.conf the same as mine? Then logging in from slim should make the shutdown/reboot buttons work in xfce4-session.

One "trick" I've seen on the forums is to rebuild the software stack (dbus dbus-glib polkit consolekit pambase) with the "--noconfmem" switch, to make sure to overwrite any configuration files and relieve any incompatible settings.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 5:26 am    Post subject: Reply with quote

Hypnos wrote:
Is your /etc/slim.conf the same as mine? Then logging in from slim should make the shutdown/reboot buttons work in xfce4-session.

One "trick" I've seen on the forums is to rebuild the software stack (dbus dbus-glib polkit consolekit pambase) with the "--noconfmem" switch, to make sure to overwrite any configuration files and relieve any incompatible settings.


The only difference is in slim.conf is that you have: current_theme default
and I have: current_theme slim-gentoo-simple
but that should not make any difference.
I have re-emerge these package with "--noconfmem" switch but it did not make any difference.

Here are my USE flags, do you see anything conflicting?
Code:
USE="-gnome qt4 -hal -arts -berkdb X gtk -qt3 -kde -minimal dvd alsa cdr cups apache2 ssl foomaticdb ppds mysql -acl java tiff jpeg png lock session startup-notification thunar usb udev scanner gimp gimpprint cgi fam nptl trutype kpathsea type1 spell consolekit dbus pam policykit semantic-desktop"


Now, I'm looking how to install plugdev group but I can not fine much information. Hal is obsolete.
_________________
#Thelma
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 5:36 am    Post subject: Reply with quote

I've added plugdev group and added myself to it but it make no difference.

# groupadd -r plugdev
# usermod -a -G plugdev joseph

When I plug the a USB I see it shows up on the desktop but I can not mount it as user.
_________________
#Thelma
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 5:38 am    Post subject: Reply with quote

Referring to ssuominen's thread:

* Do you have CONFIG_AUDITSYSCALL enabled in your kernel config?

* Also rebuilt shadow with "--noconfmem" ?

* Have the following line in /etc/pam.d/system-login :

Code:
session      optional   pam_ck_connector.so


In order to add the plugdev group and add yourself to it, just do

Code:
# groupadd plugdev
# usermod -a -G plugdev josephsys

_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 5:55 am    Post subject: Reply with quote

Hypnos wrote:
Referring to ssuominen's thread:

* Do you have CONFIG_AUDITSYSCALL enabled in your kernel config?

* Also rebuilt shadow with "--noconfmem" ?

* Have the following line in /etc/pam.d/system-login :

Code:
session      optional   pam_ck_connector.so


In order to add the plugdev group and add yourself to it, just do

Code:
# groupadd plugdev
# usermod -a -G plugdev josephsys


Have done all the above.
CONFIG_AUDITSYSCALL is IN the kernel
rebuild shadow with "--noconfmem"
/etc/pam.d/system-login I have:
Code:
auth      required   pam_tally2.so onerr=succeed
auth      required   pam_shells.so
auth      required   pam_nologin.so
auth      include      system-auth
             
account      required   pam_access.so
account      required   pam_nologin.so
account      include      system-auth
account      required   pam_tally2.so onerr=succeed
 
password   include      system-auth
 
session         optional        pam_loginuid.so
session      required   pam_env.so
session      optional   pam_lastlog.so
session      include      system-auth
session      optional   pam_ck_connector.so nox11
session      optional   pam_motd.so motd=/etc/motd
session      optional   pam_mail.so


Nothing works, this problem sucks :-(
_________________
#Thelma
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 5:58 am    Post subject: Reply with quote

When I run as root:
Code:
# xfce4-session-logout --halt
I get
Quote:
Unable to contact D-Bus session bus.

Did not receive a reply. Possible cause include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken

_________________
#Thelma
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 6:03 am    Post subject: Reply with quote

My line from /proc/config.gz :

Code:
CONFIG_AUDITSYSCALL=y


One last idea: get rid of "nox11" from the relevant line in /etc/pam.d/system-login (more here). Log out/log back in to test.

If it still doesn't work, PM ssuominen or post to his thread on this topic -- he may have better insights on how to debug the problem.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 6:12 am    Post subject: Reply with quote

Hypnos wrote:
My line from /proc/config.gz :

Code:
CONFIG_AUDITSYSCALL=y


One last idea: get rid of "nox11" from the relevant line in /etc/pam.d/system-login (more here). Log out/log back in to test.

If it still doesn't work, PM ssuominen or post to his thread on this topic -- he may have better insights on how to debug the problem.


WOW, it worked! :-)
You are my hero today, thank you.

What does "nox11" do?
I can mount USB stick and access it as well. I would never come up with this solution on my own.

I have the this setting on my other systems and I can log IN/OUT.
_________________
#Thelma
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 6:37 am    Post subject: Reply with quote

Joseph_sys wrote:
What does "nox11" do?


I suppose that it means "don't apply this line to graphical logins," which obviously is problematic in this case.

I have no idea why it would even be there in the first place.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 1:03 pm    Post subject: Reply with quote

Hypnos wrote:
Joseph_sys wrote:
What does "nox11" do?


I suppose that it means "don't apply this line to graphical logins," which obviously is problematic in this case.

I have no idea why it would even be there in the first place.


On all my other systems I have this line:
session optional pam_ck_connector.so nox11

and everything works, so what made a difference in this case.
I have even disable "PAM no" in sshd.conf and it makes no difference.
_________________
#Thelma
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 1:33 pm    Post subject: Reply with quote

Have you not updated those systems in a while? Perhaps if you upgrade their consolekit it won't work anymore.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Hypnos
Advocate
Advocate


Joined: 18 Jul 2002
Posts: 2887
Location: Omnipresent

PostPosted: Wed Dec 14, 2011 1:40 pm    Post subject: Reply with quote

Also, looking around the web, the "nox11" tag is to prevent conflicts with gdm (which has its own internal consolekit), but then would cause the system consolekit to not work with slim.
_________________
Personal overlay | Simple backup scheme
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 1:41 pm    Post subject: Reply with quote

Hypnos wrote:
Have you not updated those systems in a while? Perhaps if you upgrade their consolekit it won't work anymore.

No, this is not the case. All systems are running consolekit-0.4.5-r1
_________________
#Thelma
Back to top
View user's profile Send private message
Joseph_sys
Advocate
Advocate


Joined: 08 Jun 2004
Posts: 2506
Location: Edmonton, AB

PostPosted: Wed Dec 14, 2011 2:29 pm    Post subject: Reply with quote

Found it!
emerging slim, there is a note:
Quote:
* You should also remove the 'nox11' flag from the pam_ck_connector.so module
* in /etc/pam.d/system-login if you have not already done so.
* (this is safe, it will be default in the next version of pambase)

and from one of the developers
Code:
This is for display managers without built-in ConsoleKit support, such as XDM or SLIM:

session optional pam_ck_connector.so

And this one is for everything else:

session optional pam_ck_connector.so nox11

_________________
#Thelma
Back to top
View user's profile Send private message
Clad in Sky
l33t
l33t


Joined: 04 May 2007
Posts: 841
Location: Germany

PostPosted: Wed Dec 06, 2017 11:53 am    Post subject: Reply with quote

Has this become relevant again with the "elogind" use flag?
Since emerging a new version of Cinnamon together with its new dependency elogind a week or so ago, I had strange permission problems.
Trying to fix by deleting "nox11".

Edit: Doesn't seem to fix it. :(
Edit 2: OK, seems to have nothing to do with elogind, since this and consolekit are mutually exclusive.
Edit 3: It WAS elogind, which I had as a USE flag for polkit, because Cinnamon was telling me I needed this. consolekit + elogind do not mix well. Removing the dependency (and Cinnamon, for that matter) solved the problem. Just in case anyone else is having this issue.
_________________
Kali Ma
Now it's autumn of the aeons
Dance with your sword
Now it's time for the harvest
Back to top
View user's profile Send private message
rh
n00b
n00b


Joined: 19 Sep 2006
Posts: 55

PostPosted: Sun Dec 10, 2017 7:22 am    Post subject: Reply with quote

Joseph_sys wrote:
But where is setting in Slim to set " ck-launch-session startxfce4"


Slim is light on documentation.

When I used it, slim 1.3.6 looked for installed desktop environments in /usr/share/xsessions (this had a setting in slim.conf), and used the Exec= from .desktop file of the session you choose as aŕgument to .xinitrc. So .xinitrc was the answer to your question, though it might depend on your slim.conf settings.

An example might help.
I have a /usr/share/xsessions/kodi.desktop with line
Quote:
Exec=kodi-standalone

When I choose Kodi session, slim will execute ~/.xinitrc kodi-standalone
In .xinitrc I can run commands like this:
Code:
case $1 in
kodi-standalone)
        exec ck-launch-session kodi-standalone
        ;;
*)
        echo "Catchall session: "$1 >> .xsession-errors
        exec $1
        ;;
esac

I hope this helps.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum