| 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% |
| 17 | .\" |
| 18 | .TH TTYS 5 "" |
| 19 | .AT 3 |
| 20 | .SH NAME |
| 21 | ttys \- terminal initialization data |
| 22 | .SH DESCRIPTION |
| 23 | The |
| 24 | .I ttys |
| 25 | file contains information that is used by various routines to initialize |
| 26 | and control the use of terminal special files. |
| 27 | This information is read with the |
| 28 | .IR getttyent (3) |
| 29 | library routines. |
| 30 | There is one line in the |
| 31 | .I ttys |
| 32 | file per special file. |
| 33 | Fields are separated by tabs and/or spaces. |
| 34 | Fields comprised of more than one word should be enclosed in double |
| 35 | quotes (``"''). |
| 36 | Blank lines and comments may appear anywhere in the file; comments |
| 37 | are delimited by hash marks (``#'') and new lines. |
| 38 | Any unspecified fields will default to null. |
| 39 | .PP |
| 40 | The first field is the terminal's entry in the device directory, ``/dev''. |
| 41 | .PP |
| 42 | The second field of the file is the command to execute for the line, |
| 43 | typically |
| 44 | .IR getty (8), |
| 45 | which performs such tasks as baud-rate recognition, reading the login name, |
| 46 | and calling |
| 47 | .IR login (1). |
| 48 | It can be, however, any desired command, for example |
| 49 | the start up for a window system terminal emulator or some other |
| 50 | daemon process, and can contain multiple words if quoted. |
| 51 | .PP |
| 52 | The third field is the type of terminal usually connected to that |
| 53 | tty line, normally the one found in the |
| 54 | .IR termcap (5) |
| 55 | data base file. |
| 56 | The environmental variable ``TERM'' is initialized with the value by |
| 57 | either |
| 58 | .IR getty (8) |
| 59 | or |
| 60 | .IR login (1). |
| 61 | .PP |
| 62 | The remaining fields set flags in the |
| 63 | .I ty_status |
| 64 | entry (see |
| 65 | .IR getttyent (3)) |
| 66 | or specify a window system process that |
| 67 | .IR init (8) |
| 68 | will maintain for the terminal line. |
| 69 | .PP |
| 70 | As flag values, the strings ``on'' and ``off'' specify that |
| 71 | .I init |
| 72 | should (should not) execute the command given in the second field, |
| 73 | while ``secure'' (if ``on'' is also specified) allows users with a |
| 74 | uid of 0 to login on |
| 75 | this line. |
| 76 | These flag fields should not be quoted. |
| 77 | .PP |
| 78 | The string ``window='' may be followed by a quoted command |
| 79 | string which |
| 80 | .I init |
| 81 | will execute |
| 82 | .B before |
| 83 | starting the command specified by the second field. |
| 84 | .SH EXAMPLES |
| 85 | .nf |
| 86 | # root login on console at 1200 baud |
| 87 | console "/sbin/getty std.1200" vt100 on secure |
| 88 | # dialup at 1200 baud, no root logins |
| 89 | ttyd0 "/sbin/getty d1200" dialup on # 555-1234 |
| 90 | # Mike's terminal: hp2621 |
| 91 | ttyh0 "/sbin/getty std.9600" hp2621-nl on # 457 Evans |
| 92 | # John's terminal: vt100 |
| 93 | ttyh1 "/sbin/getty std.9600" vt100 on # 459 Evans |
| 94 | # terminal emulate/window system |
| 95 | ttyv0 "/usr/new/xterm -L :0" vs100 on window="/usr/new/Xvs100 0" |
| 96 | # Network pseudo ttys -- don't enable getty |
| 97 | ttyp0 none network |
| 98 | ttyp1 none network off |
| 99 | .fi |
| 100 | .SH FILES |
| 101 | /etc/ttys |
| 102 | .SH "SEE ALSO" |
| 103 | login(1), getttyent(3), ttyslot(3), gettytab(5), termcap(5), getty(8), init(8) |