sudo

What is sudo?

The sudo command is a program for unix-based operating systems that give system users the possibility to run programs with special privileges, most often these are root-privileges

The abbreviation of sudo is Super user do

How to use sudo

# syntax
sudo <OPTIONS> <USER>

##### examples
su # try to become the user "root", use of sudo is not needed
sudo su # try to become the user "root" 
sudo "testuser" # try to become the user "testuser"

sudo service apache2 start # try to start apache2 with root privileges (if you can run sudo as root user) 
sudo -l # list users privileges or check a specific command
sudo -l -l # same as -l but longer format 
sudo --version # checks the current version of sudo

Last updated