Ubuntu/debian: Is there a way to give permissions for users to use SHUTDOWN command?
Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Thank you !! I am gonna try the modern trick, and let you know. Sounds very good.
# cat sudoers
Code:
# /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.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL) ALL
# Uncomment to allow members of group sudo to not need a password
# (Note that later entries override this, so you might need to move
# it further down)
# %sudo ALL=NOPASSWD: ALL
shy ALL=(ALL) NOPASSWD:/sbin/shutdown
shy ALL=(ALL) NOPASSWD:/sbin/reboot
Last edited by frenchn00b; 02-11-2010 at 04:48 AM.
As MBybee said you need to use sudo.
What window manager are you using?.
The reason i ask is because i do something very similar to shutdown/restart Fluxbox from a menu entry.
As MBybee said you need to use sudo.
What window manager are you using?.
The reason i ask is because i do something very similar to shutdown/restart Fluxbox from a menu entry.
I added sudo before : and it works
above I placed a link how to make it without sudo :
Code:
chmod +s /sbin/shutdown
thank you !!
Cool for my mythtv box with lirc remote control!!
That's actually setuid - basically you're saying that any user who executes the command does so as the owner of the command (root).
Quick, but it is a bit dangerous as a fix-all.
That's actually setuid - basically you're saying that any user who executes the command does so as the owner of the command (root).
Quick, but it is a bit dangerous as a fix-all.
oh really? thank you for hte infromation..
I didnt do chmod +s /sbin/shutdown
Excellent to see! You might want to mark the thread as solved for anyone who comes looking. I know I wasn't able to find any instructions for tinywm in the first couple searches I did.
As MBybee said you need to use sudo.
What window manager are you using?.
The reason i ask is because i do something very similar to shutdown/restart Fluxbox from a menu entry.
tinywm for mythtv .. it is nice
all goes via nut's n bolt and .xinitrc
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.