How to obtain root permission under rhel7

rhel7 get root privileges

Steps :

sudo passwd root
[Enter the current user password]
[There may be a warning prompt]
[Enter the new Root password]
su Enter the root password to get root privileges.
Then enter su directly and then enter the password

After the configuration is complete, I have actually obtained root privileges, but in order to test the effect after the restart, I restarted the virtual machine.
Then enter: su + password, you can still get root without any problem.
Insert picture description here

Guess you like

Origin blog.csdn.net/qq_39689711/article/details/103149443