199 lines
6.9 KiB
Groff
199 lines
6.9 KiB
Groff
|
.\" Copyright 1991 - 1994, Julianne Frances Haugh
|
|||
|
.\" All rights reserved.
|
|||
|
.\"
|
|||
|
.\" Redistribution and use in source and binary forms, with or without
|
|||
|
.\" modification, are permitted provided that the following conditions
|
|||
|
.\" are met:
|
|||
|
.\" 1. Redistributions of source code must retain the above copyright
|
|||
|
.\" notice, this list of conditions and the following disclaimer.
|
|||
|
.\" 2. Redistributions in binary form must reproduce the above copyright
|
|||
|
.\" notice, this list of conditions and the following disclaimer in the
|
|||
|
.\" documentation and/or other materials provided with the distribution.
|
|||
|
.\" 3. Neither the name of Julianne F. Haugh nor the names of its contributors
|
|||
|
.\" may be used to endorse or promote products derived from this software
|
|||
|
.\" without specific prior written permission.
|
|||
|
.\"
|
|||
|
.\" THIS SOFTWARE IS PROVIDED BY JULIE HAUGH AND CONTRIBUTORS ``AS IS'' AND
|
|||
|
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|||
|
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|||
|
.\" ARE DISCLAIMED. IN NO EVENT SHALL JULIE HAUGH OR CONTRIBUTORS BE LIABLE
|
|||
|
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|||
|
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
|
|||
|
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
|
|||
|
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|||
|
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
|
|||
|
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|||
|
.\" SUCH DAMAGE.
|
|||
|
.\"
|
|||
|
.\" $Id: useradd.8,v 1.2 2003/04/26 13:24:16 kloczek Exp $
|
|||
|
.\"
|
|||
|
.TH USERADD 8
|
|||
|
.SH <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
useradd \- <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> <20><> <20><> Ѷ
|
|||
|
.SH <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
.TP 8
|
|||
|
.B useradd
|
|||
|
.\" .RB [ -A
|
|||
|
.\" .RI { method | \fBDEFAULT\fR "},... ]"
|
|||
|
.RB [ -c
|
|||
|
.IR comment ]
|
|||
|
.RB [ -d
|
|||
|
.IR home_dir ]
|
|||
|
.br
|
|||
|
.RB [ -e
|
|||
|
.IR expire_date ]
|
|||
|
.RB [ -f
|
|||
|
.IR inactive_time ]
|
|||
|
.br
|
|||
|
.RB [ -g
|
|||
|
.IR initial_group ]
|
|||
|
.RB [ -G
|
|||
|
.IR group [,...]]
|
|||
|
.br
|
|||
|
.RB [ -m " [" -k
|
|||
|
.IR skeleton_dir ] " |" " " -M ]
|
|||
|
.RB [ -s
|
|||
|
.IR shell ]
|
|||
|
.br
|
|||
|
.RB [ -u
|
|||
|
.IR uid " ["
|
|||
|
.BR -o ]]
|
|||
|
.RB [ -n ]
|
|||
|
.RB [ -r ]
|
|||
|
.I login
|
|||
|
.TP 8
|
|||
|
.B useradd
|
|||
|
\fB-D\fR
|
|||
|
[\fB-g\fI default_group\fR]
|
|||
|
[\fB-b\fI default_home\fR]
|
|||
|
.br
|
|||
|
[\fB-f\fI default_inactive\fR]
|
|||
|
[\fB-e\fI default_expire_date\fR]
|
|||
|
.br
|
|||
|
[\fB-s\fI default_shell\fR]
|
|||
|
.SH <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
.SS <EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> \fB-D\fR <20><> <20><> , \fBuseradd\fR ָ <20><> ʹ <20><> <20><> <20><> <20><> <20><> ָ <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> <20><> ֵ and ʹ <20><> ϵ ͳ <20><> <20><> Ԥ <20><> ֵ .
|
|||
|
<EFBFBD><EFBFBD> ʹ <20><> <20><> <20><> <20><> <20><> <20><> <20><> һ Щ ϵ ͳ <20><> <20><> <20><> ʹ <20><> <20><> Ŀ ¼ <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ʼ <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> Щ <20><> <20><> <20><> <20><> <20><> <20><> <20><><EFBFBD><EFBFBD> ѡ <20><> ָ <20><> <20><> <20><> <20><> <20><> Ϊ Red Hat Linux <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ÿ <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> <20><> <20><> <20><> <20><> <20><> group , <20><> <20><> <20><> <20><> \fB-n\fR
|
|||
|
ѡ <20><> <20><>
|
|||
|
\fBuseradd\fR <20><> ʹ <20><> <20><> ѡ <20><> Ϊ
|
|||
|
.\" .IP "\fB-A {\fImethod\fR|\fBDEFAULT\fR},..."
|
|||
|
.\" The value of the user's authentication method.
|
|||
|
.\" The authentication method is the name of a program which is responsible
|
|||
|
.\" for validating the user's identity.
|
|||
|
.\" The string \fBDEFAULT\fR may be used to change the user's authentication
|
|||
|
.\" method to the standard system password method.
|
|||
|
.\" This is a comma-separated list of program names.
|
|||
|
.\" It may include \fBDEFAULT\fR exactly once.
|
|||
|
.IP "\fB-c \fIcomment\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> password <20><> <20><> ˵ <20><> <20><> <20><>
|
|||
|
.IP "\fB-d \fIhome_dir\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ÿ <20><> <20><> <20><> ʱ <20><> ʹ <20><> <20><> \fIhome_dir\fR <20><>
|
|||
|
Ԥ <20><> ֵ Ϊ \fIdefault_home\fR <20><> \fIlogin\fR <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ʱ Ŀ ¼
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><>
|
|||
|
.IP "\fB-e \fIexpire_date\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ֹ <20><> <20><> <20><> <20><> <20><> <20><> ָ <20><> <20><> ʽ Ϊ \fIMM/DD/YY\fR <20><>
|
|||
|
.IP "\fB-f \fIinactive_days\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ͣ Ȩ <20><>
|
|||
|
<EFBFBD><EFBFBD> ֵ Ϊ 0 ʱ <20><> <20><> <20><> <20><> <20><> <20><> ͣ Ȩ <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> ֵ Ϊ -1 ʱ <20><> <20><> <20><> <20><> <20><> <20><> <20><> Ԥ <20><> ֵ Ϊ -1
|
|||
|
.IP "\fB-g \fIinitial_group\fR"
|
|||
|
group <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> Ϊ ʹ <20><> <20><> <20><> <20><> <20><> ʼ Ⱥ <20><> (group) <20><>
|
|||
|
Ⱥ <20><> <20><> <20><> Ϊ <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
Ⱥ <20><> <20><> <20><> Ҳ <20><> Ϊ <20><> <20><> <20><> <20><> <20><> Ⱥ <20><> <20><>
|
|||
|
Ԥ <20><> <20><> Ⱥ <20><> <20><> <20><> Ϊ 1 <20><>
|
|||
|
.IP "\fB-G \fIgroup,[...]\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ʹ <20><> <20><> Ϊ <20><> һ <20><> groups <20><> <20><> Ա <20><>
|
|||
|
ÿ <20><> Ⱥ <20><> ʹ <20><> "," <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> Ԫ <20><>
|
|||
|
Ⱥ <20><> <20><> ͬ \fB-g\fR ѡ <20><> <20><> <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> ֵ Ϊ ʹ<><CAB9> <20><> <20><> <20><> ʼ Ⱥ <20><> <20><>
|
|||
|
.IP \fB-m\fR
|
|||
|
ʹ <20><> <20><> Ŀ ¼ <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> ʹ <20><> \fB-k\fR ѡ <20><> \fIskeleton_dir\fR <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> Ŀ
|
|||
|
¼ <20><> <20><>
|
|||
|
Ȼ <20><> <20><> \fI/etc/skel\fR Ŀ ¼ <20><> <20><> <20><> <20><> Ҳ <20><> <20><> <20><> <20><> ȥ ȡ <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> \fIskeleton_dir\fR or \fI/etc/skel\fR <20><> Ŀ ¼ Ҳ <20><> ͬ <20><> <20><> ʹ <20><> <20><>
|
|||
|
Ŀ ¼ <20><> һ һ <20><> <20><> <20><>
|
|||
|
The \fB-k\fR ͬ \fB-m\fR
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> Ŀ ¼ <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> Ϊ Ԥ <20><> ֵ <20><>
|
|||
|
.IP \fB-M\fR
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> ʹ <20><> <20><> Ŀ ¼ <20><> <20><> ʹ \fI/etc/login.defs\fR ϵ ͳ <20><> <20><> <20><> Ҫ <20><>
|
|||
|
<EFBFBD><EFBFBD> ʹ <20><> <20><> Ŀ ¼ <20><>
|
|||
|
.IP \fB-n\fR
|
|||
|
Ԥ <20><> ֵ ʹ <20><> <20><> Ⱥ <20><> <20><> ʹ <20><> <20><> <20><> <20><> <20><> <20><> ͬ <20><> <20><> ѡ <20><> <20><> ȡ <20><> <20><> Ԥ
|
|||
|
<EFBFBD><EFBFBD> ֵ <20><>
|
|||
|
.IP \fB-r\fR
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ϵ ͳ <20><> <20><> <20><> ϵ ͳ <20><> <20><> <20><> UID <20><> <20><> <20><> <20><> <20><> ϵ
|
|||
|
ͳ <20><> <20><> \fI/etc/login.defs\fR.
|
|||
|
<EFBFBD><EFBFBD> UID_MIN <20><> <20><> С <20><> ע <20><> \fBuseradd\fR <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> ʹ <20><> <20><> Ŀ ¼
|
|||
|
<EFBFBD><EFBFBD> Ҳ <20><> <20><> <20><> <20><> <20><> ¼ <20><> \fI/etc/login.defs\fR. <20><> <20><> <20><> ֵ <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> Ҫ <20><> ʹ <20><> <20><> Ŀ ¼ <20><> <20><> <20><> ָ <20><> \fB-m\fR <20><> <20><> <20><> <20><> <20><> ϵ
|
|||
|
ͳ <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> RED HAT <20><> <20><> <20><> <20><> <20><> ѡ <20><> <20><>
|
|||
|
.IP "\fB-s \fIshell\fR"
|
|||
|
ʹ <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> shell <20><> <20><> <20><>
|
|||
|
Ԥ <20><> Ϊ <20><> <20><> д <20><> <20><> <20><> ϵ ͳ <20><> <20><> <20><> ָ <20><> Ԥ <20><> <20><> <20><> <20><> shell <20><>
|
|||
|
.IP "\fB-u \fIuid\fR"
|
|||
|
ʹ <20><> <20><> <20><> ID ֵ <20><> <20><> <20><> Ϊ Ψ һ <20><> ID ֵ <20><> <20><> <20><> <20><> \fI-o\fR ѡ <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> Ϊ <20><> ֵ<><D6B5>Ԥ <20><> Ϊ <20><> С <20><> <20><> С <20><> 99 <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
0~99 <20><> ͳ <20><> <20><> <20><> <20><> <20><> ϵ ͳ <20><> <20><> ʹ <20><> <20><>
|
|||
|
|
|||
|
.SS <EFBFBD><EFBFBD> <EFBFBD><EFBFBD> Ԥ <EFBFBD><EFBFBD> ֵ
|
|||
|
<EFBFBD><EFBFBD> \fB-D\fR ѡ <20><> <20><> <20><> ʱ <20><> \fBuseradd\fR <20><> <20><> <20><> <20><> <20><> Ԥ <20><> ֵ <20><> <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> ʽ <20><> <20><> Ԥ <20><> ֵ <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> ѡ <20><> Ϊ <20><>
|
|||
|
.IP "\fB-b \fIdefault_home\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> ʹ <20><> <20><> <20><> <20><> Ŀ ¼ <20><> ǰ һ <20><> Ŀ ¼ <20><>
|
|||
|
ʹ <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> \fIdefault_home\fR <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> ʹ <20><> <20><> <20><> Ŀ ¼ <20><>
|
|||
|
<EFBFBD><EFBFBD> Ȼ ʹ <20><> \fB-d\fI <20><> <20><> <20><> ѡ <20><> <20><> Ч <20><>
|
|||
|
.IP "\fB-e \fIdefault_expire_date\fR"
|
|||
|
ʹ <20><> <20><> <20><> <20><> ͣ ֹ <20><> <20><> <20><>
|
|||
|
.IP "\fB-f \fIdefault_inactive\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> <20><> <20><> ͣ Ȩ <20><>
|
|||
|
.IP "\fB-g \fIdefault_group\fR"
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> ʼ Ⱥ <20><> <20><> <20><> ID <20><>
|
|||
|
Ⱥ <20><> <20><> <20><> Ϊ <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
Ⱥ <20><> I D Ҳ <20><> Ϊ <20><> <20><> <20><> <20><> <20><> Ⱥ <20><> <20><>
|
|||
|
.IP "\fB-s \fIdefault_shell\fR"
|
|||
|
ʹ <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> shell <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> <20><> ʹ <20><> <20><> shell.
|
|||
|
.PP
|
|||
|
<EFBFBD><EFBFBD> <20><> ָ <20><> <20><> <20><> <20><> <20><> <20><> \fBuseradd\fR <20><> ʾ Ŀ ǰ Ԥ <20><> <20><> ֵ <20><>
|
|||
|
.SH ע <EFBFBD><EFBFBD>
|
|||
|
ϵ ͳ <20><> <20><> <20><> <20><> <20><> <20><> <20><> \fI/etc/skel\fR Ŀ ¼ <20><> <20><> <20><> ʹ <20><> <20><> <20><> <20><> <20><> <20><>
|
|||
|
.br
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><>useradd<64><64> <20><> Red Hat <20><> <20><> <20><>
|
|||
|
.SH <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> ʹ <20><> <20><> <20><> NIS Ⱥ <20><> <20><> <20><>
|
|||
|
<EFBFBD><EFBFBD> <20><> <20><> <20><> NIS <20><> <20><> <20><> <20><> ִ <20><> <20><>
|
|||
|
.SH <EFBFBD><EFBFBD> <EFBFBD><EFBFBD>
|
|||
|
\fI/etc/passwd\fR \- ʹ <20><> <20><> <20><> <20><> <20><> Ѷ
|
|||
|
.br
|
|||
|
\fI/etc/shadow\fR \- ʹ <20><> <20><> <20><> <20><> <20><> Ѷ <20><> <20><>
|
|||
|
.br
|
|||
|
\fI/etc/group\fR \- Ⱥ <20><> <20><> Ѷ
|
|||
|
.br
|
|||
|
\fI/etc/default/useradd\fR \- <20><> <20><> <20><> Ѷ
|
|||
|
.br
|
|||
|
\fI/etc/login.defs\fR \- ϵ ͳ <20><> <20><> <20><> <20><>
|
|||
|
.br
|
|||
|
\fI/etc/skel\fR \- <20><> <20><> <20><> <20><> <20><> <20><> Ŀ ¼
|
|||
|
.SH SEE ALSO
|
|||
|
.BR chfn (1),
|
|||
|
.BR chsh (1),
|
|||
|
.BR groupadd (8),
|
|||
|
.BR groupdel (8),
|
|||
|
.BR groupmod (8),
|
|||
|
.BR passwd (1),
|
|||
|
.BR userdel (8),
|
|||
|
.BR usermod (8)
|
|||
|
.SH AUTHOR
|
|||
|
Julianne Frances Haugh (jfh@tab.com)
|