How do I stop init starting getty again?

Tim Cook timcc at csv.viccol.edu.au
Sat Apr 1 02:25:09 AEST 1989


I am currently writing an autobauding getty for DYNIX 3.0 (BSD 4.2-based OS
that runs on Sequent Balances and Symmetrys).  What I would really like to know
is how to stop init from starting a new getty as soon as a getty or login shell
on a terminal exits.

Normally in these situations, the terminal should be hung up; either
terminating an attempt to log on or a login session.  There is in fact a
boolean capability that can be used in /etc/gettytab called 'hc', which means
do NOT hangup on last close (which is what I wan't to happen).  This capability
maps to a bit in the terminal flags (ioctl.h calls it NOHANG).  My getty is
clearing this bit before it calls login, and when the login shell is started,
an 'stty everything' shows that nohang is indeed off.

If anyone out there would like to tell me what the standard getty does to
ensure that init does not start up a new getty, I would be grateful.  A public
domain getty (BSD 4.[23] please) could also be useful.

Regarding public domain gettys, I know of the getty clone recently posted in
alt.sources (I haven't seen it, just saw it mentioned in comp.sources.d), and
if anyone wants my sources, its probably not worth it.  I have only supported
about half the capabilities that are available in /etc/gettytab, and I don't
trust it enough to run it myself yet (acts funny in some situations, including
on our console).  It also only autobauds over 300,600,1200,2400,4800 and 9600,
and at 7 bits, space parity or 8 bits, no parity.  And its only been tested on
one Balance B8K with only one version of DYNIX.

Thanks for any help,

Tim Cook                  e-mail:  timcc at viccol.edu.au
Systems Administrator        (or)  timcc%viccol.edu.au at uunet.uu.net
Victoria College        (or even)  ...!uunet!munnari!viccol.edu.au!timcc
Melbourne AUSTRALIA



More information about the Comp.unix.wizards mailing list