changed /bin/login to /usr/bin/login
[unix-history] / usr / src / libexec / getty / ttys.5
CommitLineData
452cf41c
KB
1.\" Copyright (c) 1985 The Regents of the University of California.
2.\" All rights reserved.
3.\"
4.\" Redistribution and use in source and binary forms are permitted
5.\" provided that the above copyright notice and this paragraph are
6.\" duplicated in all such forms and that any documentation,
7.\" advertising materials, and other materials related to such
8.\" distribution and use acknowledge that the software was developed
9.\" by the University of California, Berkeley. The name of the
10.\" University may not be used to endorse or promote products derived
11.\" from this software without specific prior written permission.
12.\" THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR
13.\" IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
14.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
15.\"
16.\" @(#)ttys.5 6.5 (Berkeley) %G%
6d85239e 17.\"
3892b435 18.TH TTYS 5 ""
6d85239e
KM
19.AT 3
20.SH NAME
21ttys \- terminal initialization data
22.SH DESCRIPTION
23The
24.I ttys
3892b435 25file contains information that is used by various routines to initialize
452cf41c
KB
26and control the use of terminal special files.
27This information is read with the
3892b435
KM
28.IR getttyent (3)
29library routines.
5dc2d425
KM
30There is one line in the
31.I ttys
32file per special file.
3892b435 33Fields are separated by tabs and/or spaces.
452cf41c
KB
34Fields comprised of more than one word should be enclosed in double
35quotes (``"'').
36Blank lines and comments may appear anywhere in the file; comments
37are delimited by hash marks (``#'') and new lines.
38Any unspecified fields will default to null.
39.PP
40The first field is the terminal's entry in the device directory, ``/dev''.
41.PP
3892b435
KM
42The second field of the file is the command to execute for the line,
43typically
6d85239e 44.IR getty (8),
5dc2d425 45which performs such tasks as baud-rate recognition, reading the login name,
6d85239e 46and calling
3892b435 47.IR login (1).
9a843f03 48It can be, however, any desired command, for example
597e0114 49the start up for a window system terminal emulator or some other
026d867c 50daemon process, and can contain multiple words if quoted.
452cf41c
KB
51.PP
52The third field is the type of terminal usually connected to that
53tty line, normally the one found in the
3892b435
KM
54.IR termcap (5)
55data base file.
452cf41c
KB
56The environmental variable ``TERM'' is initialized with the value by
57either
58.IR getty (8)
59or
60.IR login (1).
61.PP
597e0114 62The remaining fields set flags in the
3892b435
KM
63.I ty_status
64entry (see
65.IR getttyent (3))
597e0114
JL
66or specify a window system process that
67.IR init (8)
3892b435 68will maintain for the terminal line.
452cf41c
KB
69.PP
70As flag values, the strings ``on'' and ``off'' specify that
597e0114 71.I init
452cf41c
KB
72should (should not) execute the command given in the second field,
73while ``secure'' (if ``on'' is also specified) allows users with a
74uid of 0 to login on
75this line.
76These flag fields should not be quoted.
77.PP
78The string ``window='' may be followed by a quoted command
597e0114
JL
79string which
80.I init
452cf41c
KB
81will execute
82.B before
83starting the command specified by the second field.
84.SH EXAMPLES
3892b435 85.nf
452cf41c
KB
86# root login on console at 1200 baud
87console "/sbin/getty std.1200" vt100 on secure
88# dialup at 1200 baud, no root logins
89ttyd0 "/sbin/getty d1200" dialup on # 555-1234
90# Mike's terminal: hp2621
91ttyh0 "/sbin/getty std.9600" hp2621-nl on # 457 Evans
92# John's terminal: vt100
93ttyh1 "/sbin/getty std.9600" vt100 on # 459 Evans
94# terminal emulate/window system
95ttyv0 "/usr/new/xterm -L :0" vs100 on window="/usr/new/Xvs100 0"
96# Network pseudo ttys -- don't enable getty
9a843f03
MK
97ttyp0 none network
98ttyp1 none network off
3892b435 99.fi
6d85239e
KM
100.SH FILES
101/etc/ttys
102.SH "SEE ALSO"
452cf41c 103login(1), getttyent(3), ttyslot(3), gettytab(5), termcap(5), getty(8), init(8)