[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: 'shutdown' options



On Wed, Jun 04, 2003 at 02:09:52PM -0500, Bill Wilson wrote:
> On 04 Jun 2003 20:32:09 +0200
> Carlos Perelló Marín <carlos@pemas.net> wrote:
> 
> > El mié, 04 de 06 de 2003 a las 20:00, Sven Luther escribió:
> > > On Wed, Jun 04, 2003 at 10:02:47AM -0700, Pete Shinners wrote:
> > > > this is more of a gnome than debian question, but...
> > > > 
> > > > how do i enable the "Shutdown" and "Reboot" buttons on the logout 
> > > > dialog? it seems if i am logged in as root they are available, but i'd 
> > > > like to shutdown when i'm normally logged in as well.
> > > 
> > > Look at the archive of this list about a discussion i took part in about
> > > this selfsame subject.
> > 
> > An easy (but really ugly and insecure) solution could be setuid the
> > shutdown command and link it at /bin or /usr/bin
> 
> Didn't see the archived discussion, but this method works for me:
> 
> Create executable /usr/local/sbin/shutdown which does a sudo shutdown:
> 
>     #!/bin/bash
>     sudo /sbin/shutdown $*
> 
> Add users to /etc/sudoers with permission to run /sbin/shutdown.  Eg add line:
> 
>     user    ALL = NOPASSWD: /sbin/shutdown
> 
> Edit /etc/gdm.conf and change the RebootCommand/HaltCommand to use
> /usr/local/sbin/shutdown.
> 
> Run gdmsetup as root and configure gdm to show the system menu.

Well, sure, but the idea is not to have the system menu with the reboot
and halt items, this works without problem, but to be able to do it in
the gnome 2 logout dialog box, without needing to go to gdm, and thus
relaunch X. Or did i miss something, and has gdmsetup any influence on
the gnome logout dialog ?

Friendly,

Sven Luther



Reply to: