xref: /original-bsd/share/man/man8/adduser.8 (revision c3e32dec)
1.\" Copyright (c) 1980, 1991, 1993
2.\"	The Regents of the University of California.  All rights reserved.
3.\"
4.\" %sccs.include.redist.man%
5.\"
6.\"     @(#)adduser.8	8.1 (Berkeley) 06/05/93
7.\"
8.Dd
9.Dt ADDUSER 8
10.Os BSD 4
11.Sh NAME
12.Nm adduser
13.Nd procedure for adding new users
14.Sh DESCRIPTION
15A new user must choose a login name, which must not already appear in
16.Pa /etc/passwd
17or
18.Pa /etc/aliases .
19It must also not begin with the hyphen
20.Ql Fl
21character.
22It is strongly recommended that it be all lower-case, and not contain
23the dot
24.Ql \&.
25character, as that tends to confuse mailers.
26An account can be added by editing a line into the passwd file; this
27must be done with the password file locked e.g. by using
28.Xr chpass 1
29or
30.Xr vipw 8 .
31.Pp
32A new user is given a group and user id.
33Login and user id's should be unique across the system, and often across
34a group of systems, since they are used to control file access.
35Typically, users working on similar projects will be put in the same groups.
36At the University of California, Berkeley, we have groups for system staff,
37faculty, graduate students, and special groups for large projects.
38.Pp
39A skeletal account for a new user
40\*(lqernie\*(rq
41might look like:
42.Bd -literal
43ernie::25:30::0:0:Ernie Kovacs,508 Evans Hall,x7925,
44	642-8202:/a/users/ernie:/bin/csh
45.Ed
46.Pp
47For a description of each of these fields, see
48.Xr passwd 5 .
49.Pp
50It is useful to give new users some help in getting started, supplying
51them with a few skeletal files such as
52.Pa \&.profile
53if they use
54.Pa /bin/sh ,
55or
56.Pa \&.cshrc
57and
58.Pa \&.login
59if they use
60.Pa /bin/csh .
61The directory
62.Pa /usr/share/skel
63contains skeletal definitions of such files.
64New users should be given copies of these files which, for instance,
65use
66.Xr tset 1
67automatically at each login.
68.Sh FILES
69.Bl -tag -width /etc/master.passwdxx -compact
70.It Pa /etc/master.passwd
71user database
72.It Pa /usr/share/skel
73skeletal login directory
74.El
75.Sh SEE ALSO
76.Xr chpass 1 ,
77.Xr finger 1 ,
78.Xr passwd 1 ,
79.Xr aliases 5 ,
80.Xr passwd 5 ,
81.Xr pwd_mkdb 8 ,
82.Xr vipw 8
83.Sh BUGS
84User information should (and eventually will) be stored elsewhere.
85.Sh HISTORY
86The
87.Nm
88command appeared in
89.Bx 3.0 .
90