[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-linux
Subject:    Re: [kde-linux] Need help with shutdown and reboot
From:       Mark Phillips <mark () phillipsmarketing ! biz>
Date:       2004-08-29 20:29:07
Message-ID: 41323C93.7050706 () phillipsmarketing ! biz
[Download RAW message or body]

James Richard Tyrer wrote:

> Mark Phillips wrote:
>
>> James Richard Tyrer wrote:
>>
>>> Mark Phillips wrote:
>>>
>>>> I just installed Debian Sarge and I am using KDE 3.2. I would like 
>>>> to be able to shutdown and reboot the system without entering the 
>>>> root password each time. 
>>>
>>>
>>>
>>>
>>> If you are using KDM, you need to configure KDM to allow users to 
>>> shutdown.
>>>
>>> In the Login Manager KCM on the "Shutdown" tab choose:
>>>
>>>     Local: Everybody
>>>
>>> -- 
>>> JRT
>>>
>>> ___________________________________________________
>>> This message is from the kde-linux mailing list.
>>> Account management:  https://mail.kde.org/mailman/listinfo/kde-linux.
>>> Archives: http://lists.kde.org/.
>>> More info: http://www.kde.org/faq.html.
>>>
>> I tried that first, and it had no effect. How can I fix it?
>>
> This is strange.  I say this because KDM runs as root so if you tell 
> KDM to shut down, it has root privileges and it should do it -- it is 
> its responsibility to control who can shut down.
>
> Exactly how are you asked for the root password?  Is it the KDESU 
> dialog or is it something else?
>
> -- 
> JRT
> ___________________________________________________
> This message is from the kde-linux mailing list.
> Account management:  https://mail.kde.org/mailman/listinfo/kde-linux.
> Archives: http://lists.kde.org/.
> More info: http://www.kde.org/faq.html.
>
gdm is running as the login manager.

I also tried using sudo. I setup sudoers so that anyone can shutdown the 
system without a password - it works from the command line. I then 
edited gdm.conf and added /usr/bin/sudo in front of the /sbin/ shutdown 
entry, but it still asks for the root password.

sudoers:
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#

# Host alias specification

# User alias specification

# Cmnd alias specification

# User privilege specification
root    ALL=(ALL) ALL
ALL     ALL=NOPASSWD: /sbin/shutdown -h now
ALL     ALL=NOPASSWD: /sbin/shutdown -r now

gdm.conf (the relevant section):

# Reboot, Halt and suspend commands, you can add different commands
# separated by a semicolon and gdm will use the first one it can find
RebootCommand=/usr/bin/sudo /sbin/shutdown -r now "Rebooted from gdm menu."
HaltCommand=/usr/bin/sudo /sbin/shutdown -h now "Halted from gdm menu."
SuspendCommand=/usr/bin/apm --suspend

Thanks!

Mark

___________________________________________________
This message is from the kde-linux mailing list.
Account management:  https://mail.kde.org/mailman/listinfo/kde-linux.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic