1844097 Members
2089 Online
110227 Solutions
New Discussion

var cleanups

 
avsrini
Trusted Contributor

var cleanups

dear all
Let us refresh once again. What are the files
we can safely remove from the var directory.
except /var/tmp.

thanx in advance
srini
Be on top.
4 REPLIES 4
Michael Tully
Honored Contributor

Re: var cleanups

Hi,

The best place to look for files to be trimmed, i.e. log files can be found in sam.

sam --> Routine Tasks --> System Log Files

Also file in /var/tombstones, keep the last five, the rest can be removed.

-Michael
Anyone for a Mutiny ?
Printaporn_1
Esteemed Contributor

Re: var cleanups

Hi,

- if don't want to keep panic information can clear files in
/var/adm/crash
- use sam to trim logfile.
- use cleanup -n -c 1 to clear old saved patches.
- clear request in print queue /var/spool/lp/request by cancel hung print jobs.
- clear mail box in /var/mail/ by delete old mail.
enjoy any little thing in my life
Patrick Wallek
Honored Contributor

Re: var cleanups

If you want to clean up patch information from /var/adm/sw area then have a look at the 'cleanup' utility. It is available for 10.20 and 11.X.

Do a 'man cleanup' for more information.

DO NOT EVER remove anything from /var/adm/sw manually via the rm command. You do that and you installed products database will be screwed and a restore will be in order so that you can actually install applications and patches again. Not fun!
John Bolene
Honored Contributor

Re: var cleanups

Why exclude /var/tmp? Or is that one that you know how to deal with?

I normally clean /var/tmp of files older than 30 days, use sam to trim the syslog at /var/adm/syslog/syslog.log, clean any old print jobs out of /var/spool/lp, clean old cron stuff out of /var/spool/cron/tmp, and of course any /var/adm/crash files not needed.
It is always a good day when you are launching rockets! http://tripolioklahoma.org, Mostly Missiles http://mostlymissiles.com