From: Johan Förberg on

Iv'e a problem with X11 / GNOME on FreeBSD 7.2. If this is not the
proper group to post this, would you please direct me?

I have conigured FreeBSD to start gdm when I boot, and then gdm to log
me in as a normal (wheel) user. Everything works out well, except when I
want to shutdown the computer, GNOME only gives me the option to
'suspend' or 'hibernate', and all those options acutally do are log me
out. The built-in help system directs me to an internet site which
returns 404 not found. I have googled the problem, but not found
anything relevant.

Is there any alternative to # shutdown now ? I have gathered that
running X11 as root is a bad thing.

Version info:
gnome2-2.26.0
gdm-2.26.0_1

Johan F�rberg
From: Patrick Lamaizière on
Johan F�rberg :

> I have conigured FreeBSD to start gdm when I boot, and then gdm to log
> me in as a normal (wheel) user. Everything works out well, except when I
> want to shutdown the computer, GNOME only gives me the option to
> 'suspend' or 'hibernate', and all those options acutally do are log me
> out. The built-in help system directs me to an internet site which
> returns 404 not found. I have googled the problem, but not found
> anything relevant.

You can try this to allow hald to shutdown :
http://forums.freebsd.org/showthread.php?t=6268

OTH.
From: Warren Block on
Johan Förberg <johan(a)forberg.se> wrote:
>
> Iv'e a problem with X11 / GNOME on FreeBSD 7.2. If this is not the
> proper group to post this, would you please direct me?
>
> I have conigured FreeBSD to start gdm when I boot, and then gdm to log
> me in as a normal (wheel) user. Everything works out well, except when I
> want to shutdown the computer, GNOME only gives me the option to
> 'suspend' or 'hibernate', and all those options acutally do are log me
> out. The built-in help system directs me to an internet site which
> returns 404 not found. I have googled the problem, but not found
> anything relevant.
>
> Is there any alternative to # shutdown now ? I have gathered that
> running X11 as root is a bad thing.
>
> Version info:
> gnome2-2.26.0
> gdm-2.26.0_1

Gnome may be different, but for xfce4, I use this:

Add a proc entry in /etc/fstab:

proc /proc procfs rw 0 0

Add matches to /usr/local/etc/PolicyKit/PolicyKit.conf:

<match action="org.freedesktop.hal.power-management.shutdown">
<return result="yes"/>
</match>
<match action="org.freedesktop.hal.power-management.reboot">
return result="yes"/>
</match>

That would allow all users. It could be set to work for specific users
(untested):

<match user="myuser1|myuser2">
...as above...
</match>

--
Warren Block * Rapid City, South Dakota * USA
From: Warren Block on
Warren Block <wblock(a)wonkity.com> wrote:
> Johan Förberg <johan(a)forberg.se> wrote:
>>
>> Iv'e a problem with X11 / GNOME on FreeBSD 7.2. If this is not the
>> proper group to post this, would you please direct me?

Forgot to add a link to the FreeBSD HAL FAQ:

http://www.freebsd.org/gnome/docs/halfaq.html

--
Warren Block * Rapid City, South Dakota * USA
From: Giorgos Keramidas on
On 26 Jan 2010 20:38:22 GMT, Warren Block <wblock(a)wonkity.com> wrote:
> Gnome may be different, but for xfce4, I use this:
>
> Add a proc entry in /etc/fstab:
>
> proc /proc procfs rw 0 0
>
> Add matches to /usr/local/etc/PolicyKit/PolicyKit.conf:
>
> <match action="org.freedesktop.hal.power-management.shutdown">
> <return result="yes"/>
> </match>
> <match action="org.freedesktop.hal.power-management.reboot">
> return result="yes"/>
> </match>
>
> That would allow all users. It could be set to work for specific
> users (untested):
>
> <match user="myuser1|myuser2">
> ...as above...
> </match>

This should work for hald-controlled environments. I just checked and
saw that our X11 chapter in the Handbook does not include an example of
"PolicyKit.conf" options for shutdown/reboot. I'll try to add one.