1755087 Members
4278 Online
108829 Solutions
New Discussion юеВ

Terminal Port Option

 
SOLVED
Go to solution
Dhananjay Dhane
Occasional Contributor

Terminal Port Option

Hi,
I would like to know how to set up terminal port option to make it permanent on system. It should not change after system reboot and should work for all logins

Regards,
Dhananjay
4 REPLIES 4
RAC_1
Honored Contributor

Re: Terminal Port Option

Give more details on what you are trying to do.

What terminal option you are talkign about??

Anil
There is no substitute to HARDWORK
Dhananjay Dhane
Occasional Contributor

Re: Terminal Port Option

I can't type @ and # character when I logon to HP-UX 11 system. I need to set terminal port option erase and kill which are currently configured to # and @ respectively. This I want it to be effective for all logins.
Sandman!
Honored Contributor

Re: Terminal Port Option

The erase and kill characters are usually set to the key and . In order to make this the default behavior for all logins add the following lines to the the /etc/profile on your system:

# stty erase

# stty kill

Verify that erase and kill characters have been set to the key and by doing...

# stty -a

cheers!
Bill Hassell
Honored Contributor
Solution

Re: Terminal Port Option

The problem is that the stty command cannot be run before you login. Until a couple of years ago, there was no way to change this. Now (at 10.20, 11.00, 11.11 and beyond), you can use the /dev/ttyconf device file. Note that for older systems (11.00 and earlier), you need to be up to date on network and datacomm patches. Here is the technique:

/sbin/stty erase "^H" kill "^U" intr "^C" eof "^D" -parity ixoff < /dev/ttyconf

This has the effect of setting the defaults in the driver *prior* to login, whether datacomm or network. The docs say that this is a one time change and survives a reboot but I have found an occasional failure on the older systems, so I put the above command into cron and run it once a night.

If you are using real datacomm devices (ie, serial port) you can also change the default baud rate from 300 to 9600 or whatever...anything that stty can change will become the new driver defaults with ttyconf. Note that the console is unique and will not be changed until the next reboot. All other connections are immediately changed.


Bill Hassell, sysadmin