Sets the characteristics of ports.
getty [ -r | -u ] PortName
The getty command sets and manages terminal lines and ports. The getty command is run by the init command. The getty command is linked to the Terminal State Manager program. The Terminal State Manager program provides combined terminal control and login functions.
Note: The getty command is not entered on the command line.
When invoked as the
getty command, the Terminal State Manager program provides the
normal port management functions that include:
|Bidirectional use||Allows terminal lines to be used to initiate and accept connections.|
|Line speed||Sets the baud rates for sending and receiving.|
|Parity||Sets the parity to be even, odd or none.|
|Delays||Sets the delays for carriage return, tab, new line, and form feed.|
|Character set mapping||Sets the character set mapping for case, tabs, and carriage control.|
|Logger Program||Specifies the program used to log the user into the system. If the attribute is set, the Secure Attention Key (SAK) processing is disabled. If the attribute is not set, it defaults to /usr/sbin/login. The logger attribute is contained within the Object Data Manager (ODM) database.|
|Character and line erase||Sets the keystroke used for character and line erase.|
|Echoing mode||Sets the echo to local or remote.|
When the getty command is invoked, the following steps occur:
Note: If the Secure Attention Key sequence is typed during a user login, the user is logged into the trusted shell (if the system is configured where that port is trusted and the user is allowed on the trusted path).
|-r||Makes the port available for shared (bi-directional) use. If the lock is unsuccessful, the getty command waits until the lock is available and then exits. If the lock is successful, the getty command waits for a byte of data on the port after locking the port.|
|-u||Makes the port available for shared (bi-directional) use. If the lock is unsuccessful, the getty command waits until the lock is available and then exits.|
Access Control: This program should be installed as a program in the Trusted Computing Base, executable by any user and setuid to root.
To enable logging onto tty0, add the following line to the /etc/inittab file:
tty0:2:respawn: /usr/sbin/getty /dev/tty0
This command initializes the port /dev/tty0 and sets up the characteristics of the port.
|/usr/sbin/getty||Contains the getty command.|
|/etc/locks||Contains lock files that prevent multiple uses of communications devices and multiple calls to remote systems.|
|/usr/sbin/login||The login command.|
|/usr/bin/setmaps||The setmaps command.|
The login command, setgroups command, shell command, su command, telinit or init command, tsm command.
Object Data Manager (ODM) Overview for Programmers in AIX 5L Version 5.1 General Programming Concepts: Writing and Debugging Programs.