On Tuesday 15 Oct 2002 12:25 pm, Roman Korcek wrote: > Hey Derek, > > >> I have a very similar question - in 9.0 I can't run shutdown as a > >> regular user anymore - says command not found. So I guessed it's in > >> /sbin which isn't in a regular user's path so I typed /sbin/shutdown > >> -r now but bash said only root can do that. Shutdown has r-x > >> permission for all, so, I wonder, what setting/file do I need to > >> change in order to be able to run shutdown as a regular user? > > > > Shutdown is under the control of PAM (Permissions access module?) > > > > If you look at /usr/bin/shutdown you will see it is in fact a symlink to > > an application called 'consolehelper' > > > > Consolehelper is a wrapper which looks at the name of the symlink it was > > called from (in this case shutdown) and looks it up in /etc/pam.d > > If it finds a file in there with the same name as the symlink it applies > > the authentication tests it finds there. If authentication passes > > consolehelper will pass control over to the requested application. ( > > /sbin/shutdown) > > > > /etc/pam.d/shutdown contains :- > > > > #%PAM-1.0 > > auth sufficient /lib/security/pam_rootok.so > > auth required /lib/security/pam_console.so > > #auth required /lib/security/pam_stack.so service=system-auth > > account required /lib/security/pam_permit.so > > > > In your case I think it is the last line which is stopping you running > > shutdown. Probably because of your security level. If you ask for high > > security, then that is what you get :) > > Thank you for the answer, but I set the lowest security level at > install (I think it was "Medium"). > > So what do I neeed to do? Commment out the last line?
No I do not think that would help. You have to 'pass' a test to get access to the command. If you have medium security I do not understand why your system should behave differently to mine (also medium) My ordinary users can use shutdown without a problem. Have you ever had high security?, or did you upgrade instead of install? It might be worth taking a look at /etc/security/console.apps I have a zero byte file in there called shutdown. It may be that at higher security levels that file does something. You could also try editing /etc/pam.d/shutdown like this :- #%PAM-1.0 auth sufficient /lib/security/pam_rootok.so auth required /lib/security/pam_console.so auth required /lib/security/pam_stack.so service=system-auth #account required /lib/security/pam_permit.so I think you will then be prompted for a password before shutdown derek
Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com