1832351 Members
2431 Online
110041 Solutions
New Discussion

sudo / sudoers questions

 
SOLVED
Go to solution
JLee_1
Advisor

sudo / sudoers questions

Hi,

I'm trying to get sudo configured on my 11.11 server, and I can't quite get it working. I'm trying to allow two user id's to execute two things (/sbin/powermt & a shell script) as root, without authentication. I'm not overly familiar with the syntax needed in the sudoers file, so I'm wondering if that's my issue. Here's what I've tried to use to grant access to /sbin/powermt.


user1 ALL=NOPASSWD: /sbin/powermt


"user1" gets prompted to authenticate when I try to execute the command:

# sudo /sbin/powermt

We trust you have received the usual lecture from the local System
Administrator. It usually boils down to these three things:

#1) Respect the privacy of others.
#2) Think before you type.
#3) With great power comes great responsibility.

Password:

And it doesn't accept the user's password, or the root password. If anyone has any feedback or suggestions I'd be greatful. Thanks in advance.


4 REPLIES 4
Uday_S_Ankolekar
Honored Contributor

Re: sudo / sudoers questions

Try using ...

user1 ALL=/sbin/powermt

Goodluck,

-USA..
Good Luck..
Kathy Khaghani
Advisor
Solution

Re: sudo / sudoers questions

Hi Jlee,

I just tried that and it worked. You probably have already done this but check the permission on /sbin/powermt
and the user1's entry in /etc/passwd file.

also you could test this:

user1 ALL =NOPASSWD: ALL

to see if it works for somthing like

sudo ls

good luck kathy
JLee_1
Advisor

Re: sudo / sudoers questions

Thanks for the quick response guys, I really appreciate it.

Kathy - that worked great, and I was able put my two individual commands in there. Thanks!
JLee_1
Advisor

Re: sudo / sudoers questions

***