[comp.os.aos] CLEARDEVICE

lbsrdrt@cc.brunel.ac.uk (David Thomas) (10/11/89)

Is there anyway round the problem that you can only use CLEARDEVICE
from the Master Console (Pid 2) ?

I'd like to be able to clear IAC lines that lock up, from another user
console.

David Thomas
Brunel University Library

kohli@gemed (Mr. Bad Judgment) (10/12/89)

On 11 Oct 89 10:46:30 GMT, lbsrdrt@cc.brunel.ac.uk (David Thomas) writes:
DG>Is there anyway round the problem that you can only use CLEARDEVICE
DG>from the Master Console (Pid 2) ?
DG>
DG>I'd like to be able to clear IAC lines that lock up, from another user
DG>console.
DG>

you only need to be at the OP console
if the terminal in question can't be
owned by you.  that is, if the console
line is currently owned by exec (i.e.,
enabled), you can disable it from any
terminal (assuming you can login as
OP), "assign @con#" (to establish "ownership"),
then do the cleardevice command, deassign,
and re-enable.  if becoming OP is a problem,
you may want to construct a secure OP daemon of
some kind which you could send messages to
via the "control" command, and it would then
do all the dirty work.

if the console line is not currently
owned by exec, simply proceed with "assign"
command, followed by cleardevice, etc.

if exec owns the line and you are unable
to disable it (because of noise pending on
the line), i'm not sure what your away-from-
the-OP-console alternatives are.

i believe that "ownership" in this context
refers strictly to whether or not your process
owns the console line, which is why it is not
merely sufficient to be OP (which is EXEC's
username) to clear enabled lines.

jim kohli
ge medical systems
we bring dog things to life (tm)

guestx@wave4.webo.dg.com (Guest login for misc) (10/18/89)

Turning on SYSMGR mode will let you issue the call. Unfortunately 
you can't do this through the CLI. What you should do is write a 
little program to turn on SYSMGR through the ?SYSPRV call and then 
issue the ?CLRDV call. BTW, you will need a profile with SYSMGR privilege
in order to turn on SYSMGR mode. 

Standard disclaimers apply. (I know nothing, NOTHING - Sgt. Schultz)

Don Lehman
AOS/VS II Development.
Internet: don@tzone.ceo.dg.com