Simpler Navigation for Servers and Operating Systems
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
Operating System - Tru64 Unix
Showing results for 
Search instead for 
Did you mean: 

BIG wtmp file


BIG wtmp file

Can anybody suggest , how to trim wtmp file on running system.
TRU64 - V4
wtmp file size more than 800mb.

Thanks in advance...
Points to be given.
Don't cry because it's over, smile because it happened
Venkatesh BL
Honored Contributor

Re: BIG wtmp file

did u check the manpage of 'wtmp'?
Han Pilmeyer
Esteemed Contributor

Re: BIG wtmp file

Typically this is done by the logclean command in crontab every Sunday.

However this involves taking a copy of the current log file and compressing it. Considering the size of the file, you might want to use the /usr/sbin/acct/nulladm command instead.

If you want to be really safe, then you could turn off accounting first, e.g.:

/sbin/init.d/acct stop
/usr/sbin/acct/nulladm /var/adm/wtmp
/sbin/init.d/acct start

Re: BIG wtmp file

Copy existing to new file and compress it

run "/usr/sbin/acct/nulladm /var/adm/wtmp"

to Clear /var/adm/wtmp
you can insert this command it to crontab

Re: BIG wtmp file

Thanks to everyone.

Don't cry because it's over, smile because it happened