NOLOGIN(5) BSD File Formats Manual NOLOGIN(5)NAME
nologin -- file disallowing and containing reason for disallowing logins
DESCRIPTION
The file /etc/nologin, if it exists, causes the login procedure, used by programs such as login(1), to terminate. The program may display
the contents of /etc/nologin to the user before exiting.
This file is a simple mechanism to temporarily prevent incoming logins. As such, the file /etc/nologin is created by shutdown(8) five min-
utes before system shutdown, or immediately if shutdown is in less than five minutes. The file /etc/nologin is removed just before
shutdown(8) exits.
To disable logins on a per-account basis, see nologin(8).
The file /etc/nologin has no affect on the login procedure for the root user.
FILES
/etc/nologin The nologin file resides in /etc.
EXAMPLES
NO LOGINS: System going down at 18:22
SEE ALSO login(1), ftpd(8), nologin(8), rshd(8), shutdown(8), sshd(8)BSD December 9, 2005 BSD
Check Out this Related Man Page
NOLOGIN(5) BSD File Formats Manual NOLOGIN(5)NAME
nologin -- disallow logins
DESCRIPTION
Programs such as login(1) disallow logins if the nologin file exists. The programs display the contents of nologin to the user if possible
and interrupt the login sequence. This makes it simple to temporarily prevent incoming logins systemwide.
To disable logins on a per-account basis, investigate nologin(8).
SECURITY
The nologin file is ignored for user root by default.
IMPLEMENTATION NOTES
The nologin feature is implemented through login.conf(5), which allows to change the pathname of the file and to extend the list of users
exempt from temporary login restriction.
PAM-aware programs can be selectively configured to respect nologin using the pam_nologin(8) module via pam.conf(5).
The nologin file will be removed at system boot if it resides in /var/run and cleanvar_enable is set to ``YES'' in rc.conf(5), which is
default. Therefore system reboot can effectively re-enable logins.
FILES
/var/run/nologin default location of nologin
SEE ALSO login(1), login.conf(5), pam.conf(5), rc.conf(5), nologin(8), pam_nologin(8), shutdown(8)BSD May 10, 2007 BSD
if a user login and never shutdown or exit...how do you set an automatic shutdown or timeout if the user leave the session on for 20 minutes?
thanks (3 Replies)
Hey,
I was wondering if there was an easy way to give a nonroot user shutdown privileges? I've been reading lots about it but it's all long and complicated for what i need to do. Really i just need this user to beable to run one command shutdown -h now and thats it. Oh yeah and i'm running... (4 Replies)
I want to make a script to shutdown a unixware computer from other user then root. In Sco version i use "as root" but in the unixware i don't know.
Please help me.
10x (12 Replies)
is the nologin shell available in AIX 5.2? I am familiar with the nologin shell in linux and restricting shell access but still allowing ftp etc. Can this be done in AIX? I have not been able to locate any documentation. Thanks in advance (5 Replies)
I want to temporarily disable a user account on HP-UX at the start of a script and renable the account at the end of the script. What would be the best method on HP-UX to temporarily disable a user account? I know of the passwd -l option that will lock the account, but I do not see a flag for... (4 Replies)
Hello everyone
I have to limit the root logins on my aix box (aix 5.3)
I change the value on the /etc/security/user
default (login and rlogin) change to false
and add to root (rlogin and login = false)
I tried in different ways but I got the same.
Root still can login
I try algo... (6 Replies)
Hi All,
This is actually a good interview question.
On linux, the permissions and group for 'shutdown' and 'cat' is the same.
-rwxr-xr-x 1 root root 18K 2008-05-21 10:43 shutdown
-rwxr-xr-x 1 root root 17K 2007-01-30 19:51 cat
Then why is it that a... (5 Replies)
Hi all,
Has anyone ever been burned by editing /etc/default/security with vi? or should this only be edited inside of SAM or some such tool?
I want to turn on /etc/nologin as a tool to lock out all users but keep my system in multi mode for DB maintenance. TIA -KJ
PS I have been... (3 Replies)
Hi,
I am using Red Hat Enterprise Linux ES release 4 (Nahant Update 5). Here I have created one user with /sbin/nologin shll such that login is not possible only ftp is possible. But I want to do another thing that the user can not roam around after ftp.
I had tried one way.
in... (4 Replies)
Hello,
from last few days my laptop is not whutting down properly.. when ever i ty to shutdown it restarts again.. what may be problem?? antivirus is updated till date.. and i use windows xp sp2....
regards,
deepak. (5 Replies)
Dear all,
cannot login to a HP unix server using root as well as other logins.
Even root also cannot enter. It seems that they have changed some permissions in /
Any way of recovering the system or getting logged in .
Thanks in advance
Rj (8 Replies)
Ok got a strange one here. None of my user accounts are able to login into the system. When trying to ssh to the server i get the following.
Could not chdir to home directory /home/<homedir>: Permission denied
/bin/sh: Permission denied
I checked the permissions on the home directory and even... (7 Replies)
Yes, it's that minefield again. I'm building an AJAX database interface which uses maria/mysql logins instead of keeping a bunch of its own private logins, to try and keep it simple.
The thorny bit is, of course, the passwords. Doing this requires it to remember passwords between sessions, not... (4 Replies)
Hi
Part of our security audit we found that following system account's had shells configured;
sync
halt
shutdown
I believe this can be achieved by following commands:
chsh -s /sbin/nologin (user)
usermod -s /sbin/nologin (user)
However, I would like simple script to... (5 Replies)