Is there any way to find real tty under shell layers?

Stephen J. Friedl friedl at vsi.UUCP
Sun Mar 6 21:32:32 AEST 1988


Hi,

     Does anybody know any way to find out the "real" terminal
name when running under shell layers in Sys V?  We use shl
here all the time, but we have software that keys on the real
port name as a session identifier and to identify things like
the type of the terminal on that physical port.  Once we create
a new layer we immediately su(1) to a new user (root or one of
our project ids) and we can't get the tty name.

     I know I could kludge something with having shl write
a little pid record to a file, then the children look for that
file and match it with their parent pid and go from there but
I would prefer a direct way if possible with ioctl(2) or something.

     Any suggestions?
-- 
Life : Stephen J. Friedl @ V-Systems, Inc./Santa Ana, CA   *Hi Mom*
CSNet: friedl%vsi.uucp at kent.edu  ARPA: friedl%vsi.uucp at uunet.uu.net
uucp : {kentvax, uunet, attmail, ihnp4!amdcad!uport}!vsi!friedl



More information about the Comp.unix.wizards mailing list