Operating System - HP-UX
1833776 Members
2107 Online
110063 Solutions
New Discussion

Re: getty process for console keeps dying

 
Clarence J
Frequent Advisor

getty process for console keeps dying

Hello Everyone,

I have a getty process for the console that dies frequently. When I do a init q the process will run for a few seconds and then die off. Hoe do I enure that the getty process is running fine. Why does it die off?

Thks for all help!
11 REPLIES 11
Steven Sim Kok Leong
Honored Contributor

Re: getty process for console keeps dying

Hi,

Can you verify that you have this exact same entry in your /etc/inittab:

cons:123456:respawn:/usr/sbin/getty console console # system console

Hope this helps. Regards.

Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
Michael Tully
Honored Contributor

Re: getty process for console keeps dying

Hi,

First check the setup of the console
Check the /etc/inittab file

cons:123456:respawn:/usr/sbin/getty console console

Also check if /dev/console is:
crw--w--w- 1 root sys 0 0x000000 Sep 5 13:39 /dev/console

You can recreate /dev/console with:
insf -evd cn

HTH
-Michael
Anyone for a Mutiny ?

Re: getty process for console keeps dying

What hardware it is ?
I have seen with mux board the getty process dying it their is problem with mux board. It may be problem with serial port which is your case is console.
Clarence J
Frequent Advisor

Re: getty process for console keeps dying

Hello Everyone,

Thanks for all the responses. It's been very helpful. I checked the entry in /etc/inittab and there was an entry:

cons:123456:respawn:/usr/sbin/getty console console # system console

However, when I listed the /dev/console it showed:

# cd /dev
# ll console
crw--w--w- 1 root tty 0 0x000000 Nov 21 14:13 console

with group belonging to "tty". Is this right?

Re: getty process for console keeps dying

The ls output you have listed looks to be fine.
the group tty should be okay.
Clarence J
Frequent Advisor

Re: getty process for console keeps dying

Manish, you suspect it is the mux board problem? So, I shld get it changed?
Wodisch
Honored Contributor

Re: getty process for console keeps dying

Hello Clarence,

check the contents of your "/etc/gettydefs". the should be a line/paragraph starting with "console" - check this or post it to the forums. You may compare it to the "original" in "/usr/newconfig/etc/gettydefs" to detect changes.
You can check it with "getty -c 2>&1 | more", too...

HTH,
Wodisch
Clarence J
Frequent Advisor

Re: getty process for console keeps dying

contents in /usr/newconfig/etc/gettydefs

# This entry is used for the console
#

console # B9600 SANE CLOCAL CS8 ISTRIP IXANY TAB3 HUPCL
# B9600 SANE CLOCAL CS8 ISTRIP IXANY TAB3 HUPCL
#Console Login: #console

contents in /etc/gettydefs:

#
# This entry is used for the console
#

console # B9600 SANE CLOCAL CS8 ISTRIP IXANY TAB3 HUPCL
# B9600 SANE CLOCAL CS8 ISTRIP IXANY TAB3 HUPCL
#Console Login: #console

There doesn't seem to appear any difference.
Michael Tully
Honored Contributor

Re: getty process for console keeps dying

Hi,

In patch PHCO_23876 there is some fixes
in regards to 'getty', I am not sure
whether this will fix your particular
problem, but you should check anyway.
This patch is for HPUX 11. (You didn't
mention what your OS level was)
Only other thing I can suggest is that
your console part could be flakey....

-Michael


Anyone for a Mutiny ?
Bill Hassell
Honored Contributor

Re: getty process for console keeps dying

The getty process for the console will restart automatically as long as there is no other processes (like login) using the port. It is perfectly normal for getty on the console to disappear as soon as you type the user name.

The prupose of s getty is to watch for characters on an unused port. Once characters have been seen (like Return), getty passes control of the port to login.

Rather than looking for getty, look for the console:

ps -ef | grep console

As long as some process is using the port, getty is happy and won't be restarted. Now if no one is typing on the console, then you indeed have a defective terminal--it is probably running away with garbage characters.

This is keeping login busy trying to get a valid user id. Disconnect the terminal, then kill whatever process is using the console. getty will start automatically. To verify this, kill the new getty and another will appear automatically (that's respawn means in inittab).


Bill Hassell, sysadmin

Re: getty process for console keeps dying

As Bill has mentioned the messages comes if any enter or key is pressed from terminal .
This may be due to defective terminal or port on mux has gone bad and it is sending regular request.

Try replacing terminal or mux board if you have any spare.