1837395 Members
3470 Online
110116 Solutions
New Discussion

how to add sudo users

 
Binu_5
Regular Advisor

how to add sudo users

Hi
I have a nis master server and 3 slave servers ..How to enable sudo acces to the users ..Where is sodoers file located in NIS server

Thanks
Binu
8 REPLIES 8
sreejith_4
Frequent Advisor

Re: how to add sudo users

Hi,

Download the sudo packages for HP from the following link

http://hpux.connect.org.uk/hppd/cgi-bin/search?package=on&description=on&term=sudo&Search=Search

Thanks
Sreejith M
Sudeesh
Respected Contributor

Re: how to add sudo users

There is no support for making an NIS/NIS+ map/table out of
the sudoers file at this time. A good way to distribute the
sudoers file is via rdist(1). It is also possible to NFS-mount
the sudoers file.



Sudeesh
The most predictable thing in life is its unpredictability
Binu_5
Regular Advisor

Re: how to add sudo users

Hi Sudeesh

I have NIS USER who want to acces a particular workstation useing ssh..
Where to add his user name ????
Is it in NIS server ...??Where is the location?
Is it in Workstion ???Can you tell me te location

Thanks
Binu
Sudeesh
Respected Contributor

Re: how to add sudo users

Hi,
For giving sudo access you need to have users entry in sudoers file. Though most of the documentation say it is /etc/sudoers, in my HPUX system file is located at /var/opt/sudo/sudoers (dont know why!!). Following link may give you more idea.
http://www.courtesan.com/sudo/man/sudoers.html

I need to check few things, in the case of NIS user who is logged in and want to invoke sudo. Will get back.

Regarding ssh access I dont have much idea.


Sudeesh

The most predictable thing in life is its unpredictability
Sudeesh
Respected Contributor

Re: how to add sudo users

I just confirmed it !!
If you are a NIS user then can't invoke sudo, because sudo use standard libc getpw* routines.

One work around I could suggest is to create a local group in /etc/group (eg:sudouser) and add the required NIS users to that group. Then go and allow sudo access to this group by putting an entry for that group in sudoers file.

Hope this help you solve your issue.

Sudeesh

The most predictable thing in life is its unpredictability
Binu_5
Regular Advisor

Re: how to add sudo users

Hi

my sudo user need only mkdir and rmdir
can you let me know the syntax
in /etc/sudoeres file

How will WILL ADD THE PARTICULAR GROUP for a particular access in /etc/sutoers

Thanks
Binu
Sudeesh
Respected Contributor

Re: how to add sudo users

typical sudoers entry will look like
= ,

in our case you can put
%sudouser ALL = /usr/bin/rmdir, /usr/bin/mkdir

All users in group sudouser is allowed to execute /usr/bin/rmdir and /usr/bin/mkdir on all machines.



Sudeesh
The most predictable thing in life is its unpredictability
Binu_5
Regular Advisor

Re: how to add sudo users

I have added the NIS user in /etc/sudoers file works fine

Thanks
Binu