Operating System - HP-UX
1752307 Members
5238 Online
108786 Solutions
New Discussion юеВ

Re: who command not working in hpux 11.11

 
avizen9
Esteemed Contributor

who command not working in hpux 11.11

HI i am having issue with who command, it doest show any output today, when i use
who -a

it showing below output not sure what is wrong, please let me know if someone got any clue here, thanks,

Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
Empty slot.
11 REPLIES 11
Dennis Handly
Acclaimed Contributor

Re: who command not working in hpux 11.11

Your /etc/utmp* file may be corrupted.
avizen9
Esteemed Contributor

Re: who command not working in hpux 11.11

how to re-create that file, what exectly the command is?
SKR_1
Trusted Contributor

Re: who command not working in hpux 11.11

What is the output of

who -u
who -r

Thanks

SKR
avizen9
Esteemed Contributor

Re: who command not working in hpux 11.11

who -u = no output
who -r = can get out put with run leve etc. info,

who -d also working fine.
VK2COT
Honored Contributor

Re: who command not working in hpux 11.11

Hello,

a) Do you have patch PHNE_36196 installed (original patch was PHNE_24829)? That patch
deals with telnet kernel and telnetd and
fixes issues that caused telnet to corrupt
/etc/utmp as well.

b) Stopping and starting utmpd might help:

/sbin/init.d/utmpd stop
/sbin/init.d/utmpd start

c) Some workarounds have involved bringing
the system down to single user mode, and then:

# cat /dev/null >/etc/utmp[x]

... and rebooting. This requires manual
intervention.

Cheers,

VK2COT
VK2COT - Dusan Baljevic
Dennis Handly
Acclaimed Contributor

Re: who command not working in hpux 11.11

>how to re-create that file, what exactly the command is?

The file is not there?
Just touch the file and make it owned by root:sys and writable by the owner and readable by any.
Dennis Handly
Acclaimed Contributor

Re: who command not working in hpux 11.11

Here are the permissions of my /etc/utmp* files:
-rw-r--r-- 1 root root 2580 Jan 5 06:31 /etc/utmp
-rw-r--r-- 1 root root 8260 Jan 5 06:31 /etc/utmpx

If utmpx doesn't have size 0, you might be able to write a program to convert to the utmp format.

avizen9
Esteemed Contributor

Re: who command not working in hpux 11.11

HI all,
file permission is correct,
i can not reboot server,
i could not found /sbin/init.d/utmpd in my server,

any other clue? thanks,
Dennis Handly
Acclaimed Contributor

Re: who command not working in hpux 11.11

>file permission is correct

What are the file sizes?

>I could not found /sbin/init.d/utmpd in my server

utmpd(1M) is only there on 11.23 and later.