1752781 Members
5905 Online
108789 Solutions
New Discussion юеВ

Re: sudoers question

 
Sridhar R
Regular Advisor

sudoers question

Hi,

I have installed sudo 1.6.8 in my HP-UX 11.23 server.

After installing, i edited sudoers.sample file which resides in /usr/local/etc by:

#/usr/local/sbin/visudo -f sudoers.sample


I get the sudoers file in the same location, i.e., /usr/local/etc

sudo executes fine when i use it as a user.

But my question is:

Is sudoers file supposed to reside in

/usr/local/etc or in /etc

When i tried to move the file to /etc, sudo doesn't work and points that:

sudoers file is not found in /usr/local/etc.

What could be the done for this!

Kindly Suggest!

Sridhar

7 REPLIES 7
Jeeshan
Honored Contributor

Re: sudoers question

sudoers file should be reside in /opt/iexpress/sudo/etc directory. and there is a link file in /etc.

my sudoers file in /etc is like below
sudoers -> /opt/iexpress/sudo/etc/sudoers
a warrior never quits
Sridhar R
Regular Advisor

Re: sudoers question

OK..

But i dont have iexpress directory in /opt

Thanks!
Patrick Wallek
Honored Contributor

Re: sudoers question

The sudoers file must reside in whatever directory was specified at compile time.

I have seen the sudoers file in /etc, /usr/local/etc and in /opt/iexpress/sudo/etc.

If yours is in /usr/local/etc then that is where it should stay as that location was specified when sudo was compiled.
Ralph Grothe
Honored Contributor

Re: sudoers question

Since one shouldn't edit sudoers directly anyway
I think doesn't really matter where this file actually resides.
I think its place depends on the packager who built the depot.
Had you installed it from the InternetExpress it would have gone beneath /opt/iexpress/sudo/etc.
Whereas I suppose you have installed a depot from an HP Porting Center mirror so that you find yours beneath /usr/local/etc.
If you compile it from the sources you can decide by various --*prefix flags where things should go on install.
Madness, thy name is system administration
likid0
Honored Contributor

Re: sudoers question

and if you want it on etc you can always soft link it
Windows?, no thanks
Sridhar R
Regular Advisor

Re: sudoers question

Hi,

thankx for all the replies.

I downloaded the latest depot file for sudo 1.6.9

Now, i get a sudoers file in /opt/iexpress/sudo/etc directory and in /etc also with a soft link which was exactly the same thing ahsan was telling.

It seems version makes all the differences.

thanks for the replies though!

Sridhar
Sridhar R
Regular Advisor

Re: sudoers question

Thanks!