Here: http://wiki.xfce.org/tips is a tip for shuting down the PC through the power button (ACPI).
But it don't work as it seems that xfce4-user-session-shutdown.sh no longer exists.
So is there any other way to do it or was this tip useless couse init 0 is clean enough?
I believe most of that scripts functionality has been moved over to xfce4-session, run xfce4-session in a Terminal and you should have several options of logging out, rebooting or shutting down
thanks, but it is xfce4-session-logout.
it's strange: starting xfce4-session-logout as logged in user works (like in //EDIT³) but sudoing the command to the user gives me the following error:
No protocol specified
** (xfce4-session-logout:6441): CRITICAL **: Kann Sitzungsbus »D-Bus« nicht kontaktieren: dbus-launch failed to autolaunch D-Bus session: No protocol specified
Autolaunch error: X11 initialization failed.
//EDIT²: I start it this way:
sudo -H -u <user> xfce4-session-logout --display=:0 --halt --fast
//EDIT³: I finaly got it:
su -c 'XAUTHORITY=/home/$LOGNAME/.Xauthority DISPLAY=:0 xfce4-session-logout --halt --fast' $LOGGED_IN_USER;
but it just logs me out of the X-Session and doesn't shutdown.
hah Sorry bout that, didn't even catch the typo. Are you sure your in the correct groups that have permission to shutdown?
If I shutdown through the Xfce shutdown mechanism (Start -> Log off -> Shutdown (I think, I translated it from german to english right now)) it works so I think permissions aren't the problem here.