UUCP Port Turnaround
guy at gorodish.UUCP
guy at gorodish.UUCP
Thu Feb 12 20:27:47 AEST 1987
>The HDB uugetty will not work on 4.? machines because of the mechanism used
>to check locks.
If this refers to the comment
/* It will only work on USG systems at least 5.0 or systems */
/* that permit kill(0, pid). */
in the "uugetty" source and the comment
* check to see if the lock file exists and is still active
* - use kill(pid,0) - (this only works on ATTSV and some hacked
* BSD systems at this time)
in "ulockf.c", note that 4.[23]BSD *are* systems that permit
"kill(0,pid)" and, as such, support this just fine. However,
"uugetty" also requires other administrative goo from S5, so it won't
just drop in, and you'd better be able to use it on *all* ports if
you're running vanilla 4.2BSD, since its "init" always runs "getty"
on all ports.
I'm not sure I care for the notion of something that's almost, but
not quite, the same as "getty"; the two programs can easily get out
of sync. I've seen solutions proposed where you have two "devices"
associated with a terminal port, one for dialing out and one for
other uses.
"getty" opens the "other uses" device and waits for the open to
complete, i.e. it waits for carrier to come up.
"uucp", etc. open the "dialing out" device, which does *not* wait
for carrier to come up (since most auto-call units these days are
driven by writing stuff to the modem directly before carrier is
established). If this succeeds, then the modem will (one hopes) give
a busy signal as soon as it's told to pick up the phone and start
dialing, and perhaps will refuse to answer the phone as soon as the
program doing the dialing tells it that it's about to start using it
to dial out. (The kernel could, conceivably, refuse to acknowledge
carrier coming up if the dialout device is open, but this means the
dialing program couldn't wait for carrier to come up after dialing
without closing the dialout device.)
If "getty" is waiting for the open to complete, and somebody dials
in, causing the open to complete, all opens of the dialout device are
blocked (they return EBUSY or something like that). This tells
"uucp", etc. to try again later or try another port. When the dialin
device is closed, dialout opens are again permitted.
This pretty much obviates the need for changes to "getty", etc..
More information about the Comp.unix.questions
mailing list