1

Is there other file like /etc/sudoers where I assign sudo permissions to the users or groups that I have created?. I have this server that has a user that is not root but when I look at sudoers file there is nothing there saying that this user can do sudo, so I'm little confused about this.

I have this output from group

$ more /etc/group
root::0:
other::1:root
bin::2:root,daemon
sys::3:root,bin,adm
adm::4:root,daemon
uucp::5:root
mail::6:root
tty::7:root,adm
lp::8:root,adm
nuucp::9:root
staff::10:
daemon::12:root
sysadmin::14:
games::20:
smmsp::25:
gdm::50:
upnp::52:
xvm::60:
netadm::65:
mysql::70:
openldap::75:
webservd::80:
postgres::90:
slocate::95:
unknown::96:
nobody::60001:
noaccess::60002:
nogroup::65534:
aiuser::61:
ftp::21:
pkg5srv::97:
oinstall::1001:
dba::502:oracle
oper::503:oracle

And this output from id:

$ id oracle
uid=100(oracle) gid=1001(oinstall)
3
  • And what output do you get from sudo -l as the oracle user?
    – MadHatter
    Commented Jan 29, 2014 at 13:23
  • sudo -l User oracle may run the following commands on this host: (ALL) ALL
    – kiduxa
    Commented Jan 29, 2014 at 13:25
  • But where is this specified?
    – kiduxa
    Commented Jan 29, 2014 at 13:25

2 Answers 2

5

Some of the more recent distributions have a default /etc/sudoers file that makes use of the #include and/or #includedir directives.

That allows you to build a sudo configuration from multiple files, which in many cases will simplify configuration management.

## Read drop-in files from /etc/sudoers.d (the # here does not mean a comment)
#includedir /etc/sudoers.d

sudo rights for your oracle user might be set in /etc/sudoers.d/oracle or similar.

1
  • yes, you are right. There is a file in /etc/sudoers.d that says oracle ALL=(ALL) ALL. Thanks!
    – kiduxa
    Commented Jan 29, 2014 at 13:37
2

The sudoers man page says

The sudoers policy module determines a user's sudo privileges. It is the default sudo policy plugin. The policy is driven by the /etc/sudoers file or, optionally in LDAP.

So they are your choices, either in the sudoers file (or optionally an included file) or in LDAP.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .