What are the differences between
SU connects you as root.
The terminal will remain as root for the session.
With sudo (superuser do) you can perform operations as root while connected as a regular user.
Sudo (superuser do) allows a system administrator to give certain users (or groups of users) the ability to run some (or all) commands as root while logging all commands and arguments. Sudo operates on a per-command basis.
It is not a replacement for the shell.
Features include: the ability to restrict what commands a user may run on a per-host basis, copious logging of each command (providing a clear audit trail of who did what), a configurable timeout of the sudo command, and the ability to use the same configuration file (sudoers) on many different machines.
visudo is a command-line utility that allows editing of the
The su command, also referred to as substitute user, super user, or switch user, allows a computer operator to change the current user account associated with the running virtual console.
By default, and without any other command line argument, this will elevate the current user to the superuser of the local system.
When run from the command line, su asks for the target user's password, and if authenticated, grants the operator access to that account and the files and directories that account is permitted to access.
Additionally, one can switch to another user who is not the superuser
root is the user name or account that by default has access to all commands and files on a Linux or other Unix-like operating system. It is also referred to as the root account, root user and the superuser.
The word root also has several additional, related meanings when used as part of other terms.
One of these is the root directory, which is the top level directory on a system. That is, it is the directory in which all other directories, including their subdirectories, and files reside. The root directory is designated by a forward slash (
Also it may refers to the user root which is the adminstrator of the system with full privileges.
A chroot is an operation that changes the apparent root directory for the current running process and its children. for example if you chroot
Uses of chroots
The following are some possible uses of chroots: