SUMMARY: console grabbing

From: Dave Mitchell (
Date: Wed Feb 17 1993 - 01:41:27 CST


My original questions were:

1) if someone "grabs" your console, eg does a "cmdtool -C" from an X-terminal,
   how do you grab it back
2) How do you stop someone grabbing it in the first place



the main thing here is that if a program grabs the console then quits,
the console returns to the _original_ tty (ie /dev/console), rather than the
previous tty. So, running a cmtool -C then quitting will grab the console
from whoever has currently grabbed it, then return it to the original "owner".


Two main ways of stopping it happening in the first place.

a) install sun patch 100513-01 which I believe only allows the owner of
   /dev/console to change the console to another tty (ie to use the
   TIOCCONS ioctl).

> Sun Patch ID: 100513-01, Jumbo tty patch
> Sun Bug IDs: 1008324, 1040722, 1048128, 1060689, 1064320, 1069768, 1070495
> SunOS release: 4.1, 4.1.1, 4.1.2, 4.1.3
> Synopsis: This patch is a consolidation of patches 100225-02, 100194-02,
> 100397-01, 100188-02 (TIOCCONS), 100358-01, and 100414-01; it also
> includes a fix for bugid 1064320. As such this patch supersedes
> these previous patches.
> Problem Description:
> Bug 1064320 - in a 4/110 with ALM-2, null characters are not echoed
> with a Hayes Smartmodem1200.
> Bug 1008324 - TIOCCONS can be used to re-direct console output/input
> away from "console" (for obsolete patch 100188-02).

b) several people suggested putting wrappers around cmdtool etc to stop it
Some people suggested educating users instead, but I cant see that working
with my users :-)

Well, I havent had time to try any of these yet, but I think I'll be installing
the patch sometime.

Thanks to everyone.,

This Week's Hall of Fame:

John Hasley <hasley@edu.bgsu.andy>
stern@COM.Sun.East.sunne (Hal Stern - NE Area Systems Engineer)
        (I could have sworn I've heard that name before somewhere ... :-)
Casper Dik <casper@nl.uva.fwi> (Tim Evans)
Geert Jan de Groot <>
Robert Evans <>
Dave Plummer <> (Michael J Maciolek)
dennett@COM.Kodak (Charles R. Dennett)
Peter Shipley <shipley@COM.tfs>
trinkle@edu.purdue.cs (Daniel Trinkle)
kevin%kalli%ups@COM.Sun.Aus.fourx (Kevin Sheehan {Consulting Poster Child}) (LDC - Luis E. Mun~oz)
Mike Raffety <>
birger@no.sdata.vest (Birger A. Wathne)
Mr T Crummey (DIJ) <>
fabrice@com.pure (Fabrice Guerini)
Christopher Davis <ckd@org.eff>

This archive was generated by hypermail 2.1.2 : Fri Sep 28 2001 - 23:07:29 CDT