-->

Previous | Table of Contents | Next

Page 1257

Part VIII:

Administration
and Privileged
Commands

Page 1258

intro

intro—Introduction to administration and privileged commands.

DESCRIPTION

This chapter describes commands that either can be or are only used by the superuser, such as daemons and machine or hardware-related commands.

AUTHORS

Look at the header of the manual page for the authors and copyright conditions. Note that these can be different from page to page.

Linux, 24 July 1993

adduser, addgroup

adduser, addgroup—Add a user or group to the system.

SYNOPSIS


adduser [--system [--home directory] [--group]] [--quiet]

 [--force-badname] [--help] [--version] [--debug] username

adduser [--quiet] [--force-badname] [--help] [--version]

[--debug] username group

adduser [--group] [--quiet] [--force-badname] [--help]

[--version] [--debug] group

DESCRIPTION

adduser and addgroup add users and groups to the system according to information provided in the configuration file /etc/adduser.conf. adduser and addgroup automatically determine the UID or GID and place the entity in the password or group file as appropriate.

If necessary, adduser creates a home directory for the new user, copies "skeletal" user files to it from /etc/skel, and allows the system administrator to set an initial password and finger information for the user.

Because it needs to be able to write to such files as /etc/passwd, adduser can only be run as root.

Generally, there are two types of users and groups on a system: those users that log into the system and those "non-user" accounts and groups that exist for various system tasks and projects. Henceforth, user will refer to the login type and system user or group will refer to the type used for system maintenance and projects.

By default, each user in Debian GNU/Linux is given a corresponding group with the same name and ID, allowing people easily to give access to their home directories to others. This option can be turned off in the configuration file, in which case each user is, by default, added to a group called users.

Under Debian GNU/Linux, IDs less than or equal to 100 are allocated by the base system maintainer for various purposes. IDs from 101 to the value specified in the configuration file (1000, by default) are used for system users and groups. IDs greater than 1000 are reserved for users and their corresponding groups.

When invoked with a single name, adduser creates a user with that name. When given two names, adduser assumes that the first name represents an existing user and that the second name represents an existing group. In this case, the user is added to the group.

Page 1259

OPTIONS

--system Create a system user. This user will be assigned the shell /bin/false and have an asterisk in the password field. Unless otherwise specified, the user will be placed in the group nogroup. Skeletal configuration files will not be copied into the user's home directory.
--home directory When used with --system, this uses directory as the user's home directory, rather than the default specified in the configuration file. If the directory does not exist, it is created.
--group When combined with —system, a group with the same name and ID as the system user is created. If not combined with --system, a group with the given name is created. This is the default action if the program is invoked as addgroup.
--quiet Suppress progress messages.
--force-badname By default, user and group names are required to consist of a lowercase letter followed by one or more lowercase letters or numbers. This option forces adduser or addgroup to be more lenient.
--help Display brief instructions.
--version Display version and copyright information.
--debug Display a large quantity of debugging information.

SEE ALSO


adduser.conf(5)

COPYRIGHT

Copyright(c) 1995, Ted Hajek, with a great deal borrowed from the original Debian adduser, copyright(c) 1994, Ian Murdock. adduser is free software; see the GNU General Public License version two or later for copying conditions. There is no warranty.

Debian GNU/Linux version 1.94

agetty

agetty—Alternative Linux getty.

SYNOPSIS


agetty [-ihL] [-l login_program] [-m] [-t timeout] port baud_rate,... [term]

agetty [-ihL] [-l login_program] [-m] [-t timeout] baud_rate,... port [term]

DESCRIPTION

agetty opens a tty port, prompts for a login name, and invokes the /bin/login command. It is usually invoked by init(8).

agetty has several non-standard features that are useful for hard-wired and for dial-in lines:

Adapts the tty settings to parity bits and to erase, kill, end-of-line, and uppercase characters when it reads a login name. The program can handle 7-bit characters with even, odd, none, or space parity and 8-bit characters with no parity. The following special characters are recognized: @ and Control+U (kill); #, Del and Backspace (erase); carriage return and line feed (end of line).

Optionally deduces the baud rate from the CONNECT messages produced by Hayes-compatible modems.

Optionally does not hang up when it is given an already opened line (useful for call-back applications).

Optionally does not display the contents of the /etc/issue file (System V only).

Page 1260

Optionally invokes a non-standard login program instead of /bin/login.

Optionally turns on hardware flow control.

Optionally forces the line to be local with no need for carrier detect.

This program does not use the /etc/gettydefs (System V) or /etc/gettytab (SunOS 4) files.

ARGUMENTS

port A path name relative to the /dev directory. If a _ is specified, agetty assumes that its standard input is already connected to a tty port and that a connection to a remote user has already been established. Under System V, a _ port argument should be preceded by a _.
baud rate,... A comma-separated list of one or more baud rates. Each time agetty receives a break character, it advances through the list, which is treated as if it were circular. Baud rates should be specified in descending order, so that the null character (Ctrl+@) can also be used for baud rate switching.
term The value to be used for the TERM environment variable. This overrides whatever init(8) may have set and is inherited by login and the shell.

OPTIONS

-h Enable hardware (RTS/CTS) flow control. It is left up to the application to disable software (XON/XOFF) flow protocol where appropriate.
-i Do not display the contents of /etc/issue before writing the login prompt. Terminals or communications hardware might become confused when receiving lots of text at the wrong baud rate; dial-up scripts might fail if the login prompt is preceded by too much text.
-l login_program Invoke the specified login program instead of /bin/login. This allows the use of a non-standard login program (for example, one that asks for a dial-up password or that uses a different password file).
-m Try to extract the baud rate the connect status message produced by some Hayes-compatible modems. These status messages are of the form: "<junk><speed><junk>". agetty assumes that the modem emits its status message at the same speed as specified with (the first) baud rate value on the command line.
Because the -m feature might fail on heavily loaded systems, you still should enable break processing by enumerating all expected baud rates on the command line.
-t timeout Terminate if no username could be read within timeout seconds. This option should probably not be used with hard-wired lines.
-L Force the line to be a local line with no need for carrier detect. This can be useful when you have a locally attached terminal where the serial line does not set the carrier detect signal.

EXAMPLES

This section shows sample entries for the /etc/inittab file.

For a hard-wired line:


tty1:con80x60:/sbin/agetty   9600   tty1

For a dial-in line with a 9600/2400/1200 baud modem:


ttyS1:dumb:/sbin/agetty      -mt60 ttyS1 9600,2400,1200

Previous | Table of Contents | Next