FILL BLANK
The presence of what file will temporarily prevent all users except root from logging into a system? (Specify the full name of the file, including path.)
A. /sbin/nologin
FILL BLANK
The presence of what file will temporarily prevent all users except root from logging into a system? (Specify the full name of the file, including path.)
A. /sbin/nologin
/sbin/nologin is per-account set to a user in /etc/passwd
https://man7.org/linux/man-pages/man8/nologin.8.html
pam_nologin(8) PAM module usually prevents all non-root users
from logging into the system. pam_nologin(8) functionality is
controlled by /var/run/nologin or the /etc/nologin file
Creating the /etc/nologin File
Create this file to disallow user logins and notify users when a system will be unavailable for an extended period of time because of a system shutdown or routine maintenance.
hi
/etc/nologin to prevent all users excpt the root from loggin into the system.
usermod -s /sbin/nologin username –> set the default shell for a specific user to nologin.
hi
/etc/nologin to prevent all users excpt the root from loggin into the system.
usermod -s /sbin/nologin username –> set the default shell for a specific user to nologin.
https://docs.oracle.com/cd/E19683-01/806-4078/6jd6cjs41/index.html
How to Temporarily Disable User Logins
Become superuser or assume an equivalent role.
Create the /etc/nologin file by using an editor.
# vi /etc/nologin
Include a message about system availability.
Close and save the file.
yes u are right.
/sbin/nologin or /usr/sbin/nologin is to block the login for a single user.
/etc/nologin block all user except root.
But this file must be created
that’s not the correct answer! The file is /etc/nologin