Help me to edit sudo file | Unix Linux Forums | Solaris

  Go Back    


Solaris The Solaris Operating System, usually known simply as Solaris, is a Unix-based operating system introduced by Sun Microsystems. The Solaris OS is now owned by Oracle.

Help me to edit sudo file

Solaris


Closed Thread    
 
Thread Tools Search this Thread Display Modes
    #1  
Old 03-06-2013
welcome23 welcome23 is offline
Registered User
 
Join Date: Mar 2013
Last Activity: 12 March 2013, 9:04 AM EDT
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Help me to edit sudo file

I am trying to edit sudoers file by running the command #visudo. But it is not opening and error showing like 'it is read only filesystem'.

Than I changed the permissions of /etc/sudoers file to 640 and modified it(after I change the permission to 440). Than it is modified successfully. But sudo access is not working.

After investigating I found that in /usr/local/etc/sudoers file, the modified fields are not updated. Even it is not allowing to change the permissions of this file. I tried it as a root user.

Please help me to resolve this issue.
Sponsored Links
    #2  
Old 03-07-2013
DGPickett DGPickett is offline Forum Advisor  
Registered User
 
Join Date: Oct 2010
Last Activity: 29 August 2014, 5:00 PM EDT
Location: Southern NJ, USA (Nord)
Posts: 4,409
Thanks: 8
Thanked 538 Times in 516 Posts
Did you modify it using visudo after chmod?

Man Page for sudoers (all Section 5) - The UNIX and Linux Forums

CAVEATS
The sudoers file should always be edited by the visudo command which
locks the file and does grammatical checking. It is imperative that
sudoers be free of syntax errors since sudo will not run with a
syntactically incorrect sudoers file.
Sponsored Links
    #3  
Old 03-10-2013
MadeInGermany MadeInGermany is offline Forum Advisor  
Registered User
 
Join Date: May 2012
Last Activity: 1 September 2014, 6:21 AM EDT
Location: Simplicity
Posts: 1,849
Thanks: 119
Thanked 535 Times in 484 Posts
Supposed your sudo|visudo commands use /usr/local/etc/sudoers,
then check its file system with

Code:
df /usr/local/etc/sudoers

If this is NFS then one must edit|visudo it on a machine with trusted root access.
Trusted root: the NFS server exported the file system with root=machine .
Maybe there is another sudo installation that takes another sudoers that is on the local disk?
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
Sudo and edit other user's info. linuxadmin UNIX for Advanced & Expert Users 1 12-04-2012 04:16 AM
ssh foo.com sudo command - Prompts for sudo password as visible text. Help? fluoborate Shell Programming and Scripting 9 11-02-2011 02:18 PM
Best way to edit a file skunky Shell Programming and Scripting 13 12-21-2010 12:20 PM
Script to Edit the file content and create new file sudesh.ach Shell Programming and Scripting 1 06-22-2009 05:46 AM
Edit value in File sewood Shell Programming and Scripting 1 03-18-2008 02:11 AM



All times are GMT -4. The time now is 07:21 AM.