Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 07-30-2005, 12:28 AM   #1
LQ Newbie
Registered: Aug 2004
Posts: 21

Rep: Reputation: 15
can normal user use shutdown command?

the permission of my shutdown command is already 755, but it say only root can use it, so is there anyway to let normal ppl use it?
also some question that i dont want to open new post:
gnome can set auto login,can auto login be done if i choose command-line interface?(change /etc/inittab file)
Old 07-30-2005, 05:32 AM   #2
Senior Member
Registered: Jul 2004
Location: Lower Rhine region, Germany
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,599

Rep: Reputation: 126Reputation: 126
You can allow normal users to use the shutdown command via "sudo". If you search for sudo and shutdown you should find various results for this.
No clue about your second question
Old 07-30-2005, 06:11 AM   #3
Registered: Oct 2004
Distribution: At home: Ubuntu, Debian Sarge
Posts: 56

Rep: Reputation: 15
Another possibility is making shutdown 'setuid' or 'setguid' (see the chmod man page: 'man chmod') which allows you to run a program with as if you were the owner of the program (in this case it would run as if you were root).
However the sudo approach mentioned by the previous poster provides much more control over who gets to run the command than setuid/setguid and if probably safer if you are concerned about security.

With the second question I dont know either although looking at my inittab I would guess that you need to look at the documentation for getty or look for alternatives. The reason gnome can auto login is because when gdm (the login screen) is run it is already logged in as root, and root can 'su' to any user without being challenged for a password. But looking briefly at inittab i couldnt tell what user getty was running as (probably root, but programs can drop priviledges if they wish so it could be running as low as 'nobody')


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't "shutdown -a -r now" as a normal user, though shutdown.allow exists mnemonic Linux - Software 5 08-15-2005 06:49 PM
normal user running shutdown cblamer Slackware 6 12-21-2003 08:44 PM
can normal user do shutdown? TheOneAndOnlySM Slackware 12 12-17-2003 11:10 PM
Disable reboot/halt/shutdown as normal user carstenbjensen Mandriva 4 09-09-2003 11:42 AM
Normal User Restart and Shutdown InsaneBob Linux - Software 2 08-23-2003 05:47 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:15 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration