System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

/var/adm/btmps file is missing - please help

 
SOLVED
Go to solution
johnnymac_1
Advisor

/var/adm/btmps file is missing - please help

Very new to HP-UX. I just started and discovered after doing a man page on last that my btmps file (/var/adm) is gone. Can anyone tell me how to create the file and ensure the permissions are correct? A million thanks,
Johnny Mac
5 REPLIES
Tim Nelson
Honored Contributor
Solution

Re: /var/adm/btmps file is missing - please help

> /var/adm/btmps

chmod 600 /var/adm/btmps

log in with another session and there should now be some size to the file.

johnnymac_1
Advisor

Re: /var/adm/btmps file is missing - please help

Mr. Nelson you are a life saver that worked. One more question. When I performed a last the response is WTMPS_FILE begins at Mon July 21 21:33:33. The file date is for today and the size continues to grow. Is there a way to save the file off and create a new file, if so how does one go about that?
Pete Randall
Outstanding Contributor

Re: /var/adm/btmps file is missing - please help

Sure. Just copy it using "cp /var/adm/wtmps /location_desired", then repeat the "> /var/adm/wtmps".


Pete

Pete
Vivek Bhatia
Trusted Contributor

Re: /var/adm/btmps file is missing - please help

Hi Johnny

You can make a copy of the old file bby running the command below.
#mv /var/adm/wtmp /var/adm/wtmp.backup

And if you want to see the information from the old file for example /var/adm/wtmp.backup .Then you need run the below command.


#last -f /var/adm/wtmp.backup

And i think you forgot to assign points to the valueable replies.

Thanks
Vivek Bhatia
johnnymac_1
Advisor

Re: /var/adm/btmps file is missing - please help

All of the responses to this thread were perfect. A million thanks to all those that provided the advise. All of you are lifesavers.

John