[comp.soft-sys.andrew] rs6000 AIX 3.1 typescript

kriso@NORTHSTAR.DARTMOUTH.EDU (Kris Olander) (01/28/91)

A while back I asked a couple of questions regarding some peculiarities
of typescript on our HP9000 systems run hp/ux 7.0.  We are now seeing
the same thing on our rs6000s running AIX3.1.

?QUESTION?:  have the modifications suggested to me by Todd Inglett
                               been incorporated in any of the patches???

I've enclosed Todd's comments below.  Also, I've checked the tscript.c code
and I didn't see any rs6000 or hp/ux ifdefs that would indicate that
Todd's suggestions have been implemented.

Do the Andrew folks recommend the modifications that Todd suggests?

Also, what #define flags are used to specify the rs6000 arch. type?  I've
seen #define IBMR2 in our local config files.


Excerpts from mail: 20-Dec-90 Re: typescript on hp300_ux7..
tinglett@ibm.com (2199+0)

>>> Keywords: tty, job control

>>> Typescript is giving me the following warning when it starts up.
>>> -------------
>>> Warning: no access to tty; thus no job control in this shell...
>>> --------------

>>> Also, I'm getting command echos every time I type a command.
>>> 'echo' isn't set in my shell.  As a matter of fact, when I type 'set echo',
>>> I get two echos.  I've seen this in the past, the only difference seems to
>>> be that now, I see the command as I'm typing it in, and also after hitting
>>> carriage return.

>>> -Kris Olander



> There are 2 problems here.  First, csh does not have a controlling
> terminal.  That is why it prints the Warning:... message.  It needs a
> controlling terminal to do job control.  Second, the pty is not in
> REMOTE mode.  That is why everything is getting echoed.

> Try changing the code in tscript.c, typescript__InitializeObject to call
> GetPtyandName (see the #if for SY_AIX221) and have it close(ptyChannel)
> before the fork.  Then, in the child do a ptyChannel = open(ptyname, 2) 
> (again, see the #if for SY_AIX221).  This second open must be done after
> a setpgrp().  Do a ps and see which processes have controlling
> terminals.  It is ok for typescript to be missing a terminal, but the
> csh must have one.  Also, you should be able to echo foobar > /dev/tty
> in the typescript.  I am assuming here that HP/UX has System V type
> rules for inheriting a controlling terminal.

> To solve the REMOTE problem, check your manuals for the TIOCREMOTE mode
> under the pty man page.  There is a hack in typescript__InitializeObject
> to set this mode.  Perhaps HP has changed the encoding of ioctls.  Try
> coding the ioctl without a hack like that (i.e. using TIOCREMOTE).  If
> you cannot get this to work, I can send you code that allows the pty to
> stay in normal mode.

> -todd inglett


-Kris Olander

gk5g+@ANDREW.CMU.EDU (Gary Keim) (01/29/91)

Excerpts from misc: 28-Jan-91 rs6000 AIX 3.1 typescript Kris
Olander@northstar.d (2672)

> A while back I asked a couple of questions regarding some peculiarities
> of typescript on our HP9000 systems run hp/ux 7.0.  We are now seeing
> the same thing on our rs6000s running AIX3.1.

> ?QUESTION?:  have the modifications suggested to me by Todd Inglett
>                                been incorporated in any of the patches???


ANSWER: yes, Todd's modifications have been incorporated into the
sources.  We are testing those changes at this moment.  They should be
out in patch.10.

Gary Keim
ATK Group