]>
Commit | Line | Data |
---|---|---|
beb61b07 | 1 | .TH NOLOGIN 8 "November 2019" "util-linux" "System Administration" |
88407b93 KZ |
2 | .SH NAME |
3 | nologin \- politely refuse a login | |
4 | .SH SYNOPSIS | |
5 | .B nologin | |
6 | .RB [ \-V ] | |
7 | .RB [ \-h ] | |
8 | .SH DESCRIPTION | |
9 | .B nologin | |
10 | displays a message that an account is not available and exits non-zero. It is | |
fd2e45b7 | 11 | intended as a replacement shell field to deny login access to an account. |
88407b93 | 12 | .PP |
3a60b1c2 | 13 | If the file /etc/nologin.txt exists, nologin displays its contents to the |
88407b93 KZ |
14 | user instead of the default message. |
15 | .PP | |
16 | The exit code returned by | |
17 | .B nologin | |
18 | is always 1. | |
19 | .PP | |
20 | .SH OPTIONS | |
beb61b07 SK |
21 | \fB\-c\fR, \fB\-\-command\fR \fIcommand\fR |
22 | .br | |
23 | \fB\-\-init-file\fR | |
24 | .br | |
25 | \fB\-i\fR \fB\-\-interactive\fR | |
26 | .br | |
27 | \fB\-\-init-file\fR \fIfile\fR | |
28 | .br | |
29 | \fB\-i\fR, \fB\-\-interactive\fR | |
30 | .br | |
31 | \fB\-l\fR, \fB\-\-login\fR | |
32 | .br | |
33 | \fB\-\-noprofile\fR | |
34 | .br | |
35 | \fB\-\-norc\fR | |
36 | .br | |
37 | \fB\-\-posix\fR | |
38 | .br | |
39 | \fB\-\-rcfile\fR \fIfile\fR | |
40 | .br | |
41 | \fB\-r\fR, \fB\-\-restricted\fR | |
42 | .IP | |
43 | These shell command-line options are ignored to avoid nologin error. | |
a174eefb | 44 | .IP "\fB\-h\fR, \fB\-\-help\fR" |
b4362b6f | 45 | Display help text and exit. |
a174eefb | 46 | .IP "\fB-V\fR, \fB\-\-version\fR" |
b4362b6f | 47 | Display version information and exit. |
88407b93 KZ |
48 | .SH NOTES |
49 | .B nologin | |
fd2e45b7 | 50 | is a per-account way to disable login (usually used for system accounts like http or ftp). |
88407b93 | 51 | .BR nologin (8) |
fd2e45b7 OO |
52 | uses /etc/nologin.txt as an optional source for a non-default message, the login |
53 | access is always refused independently of the file. | |
88407b93 KZ |
54 | .PP |
55 | .BR pam_nologin (8) | |
56 | PAM module usually prevents all non-root users from logging into the system. | |
57 | .BR pam_nologin (8) | |
fd2e45b7 | 58 | functionality is controlled by /var/run/nologin or the /etc/nologin file. |
88407b93 KZ |
59 | .SH AUTHORS |
60 | .UR kzak@redhat.com | |
61 | Karel Zak | |
62 | .UE | |
63 | .SH SEE ALSO | |
64 | .BR login (1), | |
65 | .BR passwd (5), | |
66 | .BR pam_nologin (8) | |
67 | .SH HISTORY | |
68 | The | |
69 | .B nologin | |
70 | command appeared in 4.4BSD. | |
71 | .SH AVAILABILITY | |
72 | The nologin command is part of the util-linux package and is available from | |
d673b74e | 73 | .UR https://\:www.kernel.org\:/pub\:/linux\:/utils\:/util-linux/ |
88407b93 KZ |
74 | Linux Kernel Archive |
75 | .UE . |