root user and use sudo root privileges difference (rpm)

Baidu Encyclopedia: https: //baike.baidu.com/item/sudo/7337623 fr = aladdin?

sudo command

Function: to execute commands as root identity

Syntax: sudo other instructions

User: the user is root joined "/ etc / sudoers' file

1. In addition to root root password I know, but without the need to use root privileges by other users know, because when using sudo, enter the password required is "the users own password."

2. All the user instructions are executable sudo specification in "/ etc / sudoers" this file, root can easily control the entire system.

Execute sudo su - to root difference between the user and the root user:

Ordinary users to use sudo to execute commands that only root can execute permissions, with the implementation of the root user is not the same, because this time he is still common user environment variables.

Use su - to root user or some environment variables and login as root is not the same. In addition, they uid is not the same, only euid is the same.

PS: Changing the root password

Please log in using the first user created using sudo passwd root to change the root password ps:. To enter a password, which is run sudo password for the user.

 

Transfer: https: //blog.csdn.net/skc361/article/details/17097963

Guess you like

Origin www.cnblogs.com/olivertian/p/10983459.html