In RedHatLinux, you only need to add a line in the file/etc/pam. d/TPD: (the third line in the example) authrequiredpam_succeed_if.so & n
You only need to add a line in the file/etc/pam. d/TPD in RedHat Linux: (the third line in this example)
Auth required pam_succeed_if.so user! = Root quiet
You can use the vi editor.
This idea comes from the Mechanism in Fedora 10.
In Fedora 10, by default, the root user cannot log in through the graphic interface.
Let's take a look at the content in the initial/etc/pam. d/TPD in Fedora 10: (observe the third line)
If you comment out the third line (as shown below, add a # sign before the line), the system can log on to the system through the root user interface after the file is saved. Therefore, the third line is the main code that controls whether the root user can log on from the graphic interface.