Operating System - HP-UX
1833515 Members
3182 Online
110061 Solutions
New Discussion

Activation of Shutdown log

 
David Tang_1
Advisor

Activation of Shutdown log

Hi all,
Can anyone help me as to how I can start the shutdown log for my system? It is running on HP-UX 10.20. Thanks all in advance.
8 REPLIES 8
Kofi ARTHIABAH
Honored Contributor

Re: Activation of Shutdown log

You have to create a file called /etc/shutdownlog with permissions rw-r--r-- owned by root.
# touch /etc/shutdownlog
# chown root:bin /etc/shutdownlog
# chmod 644 /etc/shutdownlog

see the thread:

http://forums.itrc.hp.com:80/cm/QuestionAnswer/1,1150,0x74fea14d9abcd4118fef0090279cd0f9,00.html
nothing wrong with me that a few lines of code cannot fix!
David Tang_1
Advisor

Re: Activation of Shutdown log

The file already exist and have the right permission but the owner and group is bin. So do I just need to change the owner to root? Do I need to change the group as well to root?
Thanks
Rainer_1
Honored Contributor

Re: Activation of Shutdown log

shutdown messages to /etc/shutdownlog are written by reboot.
There is no need to chown root of /etc/shutdownlog.

See 'man 1m reboot'
federico_3
Honored Contributor

Re: Activation of Shutdown log

At shutdown time a message is written in /etc/shutdownlog if it exists ( automatically, without activation). If it does not exist , create it and all will be OK.


Federico
Cheryl Griffin
Honored Contributor

Re: Activation of Shutdown log

Rethink changing the owner of /etc/shutdownlog, I checked multiple systems and found the owner and group as bin bin.

In addition, check /var/adm/shutdownlog. You will find that this file is a transitional link to /etc/shutdownlog.

If it is there, you might try removing that file and using tlinstall which will recreate the transitional link.

Reboot and check /etc/shutdownlog. Was it updated? If not, check /etc/rc.log which is the boot log. Are there any errors reported?
"Downtime is a Crime."
f. halili
Trusted Contributor

Re: Activation of Shutdown log

Verify the permissions on /etc/shutdownlog match the default:
-rw-r--r-- 1 bin bin 1113 Jan 27 12:05 /etc/shutdownlog


derekh
David Tang_1
Advisor

Re: Activation of Shutdown log

Everthing seems to be in place, but there was a shutdown that was logged in rc.log but not in shutdownlog. May I know is there anything else I need to check? Thanks.
Madhu Sudhan_1
Respected Contributor

Re: Activation of Shutdown log

Did you shutdown after the changes ? :) If so did you shutdown or reboot command ?

According to man pages, only reboot(1M) makes an entry in /etc/shutdownlog shutdown(1M) -not mentioned in man pages.

Also try using sam to shutdown.

...Madhu

Think Positive