Error in Sudo | Unix Linux Forums | UNIX for Dummies Questions & Answers

  Go Back    


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

Error in Sudo

UNIX for Dummies Questions & Answers


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 01-25-2013
Scarlet Scarlet is offline
Registered User
 
Join Date: Dec 2011
Last Activity: 25 February 2013, 1:43 PM EST
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Error in Sudo

Hi,
I have installed sudo on Solaris 10 (sparc). When I try to add a user I get the following:

Code:
-bash-3.00$ sudo addusr scarlet sudo
sudo: /usr/local/etc/sudoers.d is owned by uid 2, should be 0
Password:

I entered a password, thinking it was for the sudo user but it failed. Then I entered the used the root password and that failed also. I su to root and I got the following:

Code:
root# sudo addusr scarlet sudo
sudo: not found

Can someone help me please?

Thank you.
Scarlet

Last edited by Scott; 01-26-2013 at 11:34 PM.. Reason: Code tags
Sponsored Links
    #2  
Old 01-25-2013
Corona688 Corona688 is offline Forum Staff  
Mead Rotor
 
Join Date: Aug 2005
Last Activity: 22 October 2014, 6:34 PM EDT
Location: Saskatchewan
Posts: 19,649
Thanks: 818
Thanked 3,345 Times in 3,133 Posts
When sudo asks you for a password, it generally asks you for your own password, not somebody else's. Sudo uses it's configuration file to decide who's permitted to do what, and the users only need to prove they are themselves (not some random guy who saw an open terminal and sat down at your computer).
Sponsored Links
    #3  
Old 01-25-2013
vbe's Avatar
vbe vbe is offline Forum Staff  
Moderator
 
Join Date: Sep 2005
Last Activity: 23 October 2014, 4:40 AM EDT
Location: Switzerland - GE
Posts: 5,834
Thanks: 162
Thanked 414 Times in 389 Posts
Look at the man pagess of visudo, and sudo for the correct usage...

Quote:
sudo: /usr/local/etc/sudoers.d is owned by uid 2, should be 0
Meaning it was not correctly installed, sudo is very sensible to file permisssions...

If you scarlet have right to use sudo you can check out by typing:

Code:
 sudo -l

    #4  
Old 01-26-2013
Scarlet Scarlet is offline
Registered User
 
Join Date: Dec 2011
Last Activity: 25 February 2013, 1:43 PM EST
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Hi,
After editing sudoers, I keep getting the following error:

Code:
sudo: parse error in /usr/local/etc/sudoers near line 74
sudo: no valid sudoers sources found, quitting
sudo: unable to initialize policy plugin

How do I fix this?

Thanks again.

Regards
Scarlet

Last edited by Scott; 01-26-2013 at 11:35 PM.. Reason: Please use code tags
Sponsored Links
Closed Thread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Error - sudo: no tty present and no askpass program specified steadyonabix UNIX for Advanced & Expert Users 2 08-15-2012 01:18 PM
Error message of sudo apt-get programAngel UNIX for Dummies Questions & Answers 2 06-09-2012 05:53 PM
Need help with a weird sudo error. H3jck Ubuntu 1 04-28-2012 06:58 PM
sudo su error karayan UNIX for Advanced & Expert Users 6 11-19-2008 02:18 PM
Sudo error rainbow_bean AIX 1 02-28-2008 06:00 AM



All times are GMT -4. The time now is 09:46 AM.