How do you unlock a root account in Linux?

How do you unlock a root account in Linux?
Answer
The simplest method to disable root user login is to change its shell from /bin/bash or /bin/bash (or any other shell that permits user login) to /sbin/nologin , in the /etc/passwd file, which you can open for editing using any of your favorite command line editors as shown. Save the file and close it.
 

Tìm kiếm

Back
Top