Skip to main content
3 of 4
added 125 characters in body
usual me
  • 151
  • 1
  • 3

When can a user do `sudo su` but not `sudo su -`?

The following happened to me:

$ sudo su - superman Sorry, user clarkkent is not allowed to execute '/bin/su - superman' as root in krypton101. 

However the following worked fine:

$ sudo su superman 

When is it useful to allow a user to do sudo su but not sudo su -? How is this setting set / unset? I read this page but it didn't help.

More details:

  • I am not the administrator
  • I don't have access to /etc/sudoers
  • the distribution is Centos 7
usual me
  • 151
  • 1
  • 3