SUMMARY: /var file system 100%

2007-12-24 20:13:00

Hi Gurus,

Thx a ton for the timely response., Most of them suggested similar steps.
Here r a couple of them.
Do any of u Guys have automated scripts which does these, Pls send if you
have one, It would be of great help

Regards,
Ravi

Here are the replies:
1.) /var/tmp - directory, can be emptied
/var/crash - directory, can be emptied
/var/adm/*tmp* - accounting files, can be zeroed with "cat /dev/null >
/var/adm/wtmp" etc.

DO NOT fall into the trap of deleting anything out of /var/sadm since all of
this information is crucial and irreplaceable.

finally, if you want to find your largest files, try these commands:

du -sk /directory/* | sort -rn | head
- display ten largest files or subdirectories in a directory

find /directory -size +2000 -exec ls -l {} \; 2> /dev/null
- display all files greater than a megabyte in size below /directory

find /directory -size +2000 -exec du -sk {} \; sort -rn | head
- display ten largest files below /directory

______
/_____/\ Justin Stringfellow
/____ \\ \ Starfire Support Engineer
/_____\ \\ / Sun Microsystems
/_____/ \/ / / Guillemont Park
/_____/ / \//\
\_____\//\ / / Tel. : +44 (0)870 6003222
\_____/ / /\ /
\_____/ \\ \
\_____\ \\
\_____\/

check your /var/mail for incoming mail
check your /var/spool/mqueue for outgoing mail
check your /var/spool/lp for print jobs
look for core files

you can create a directory for your incoming mail on a different partition
and link it to /var/mail

Alon Friedman

2. ) I would look at /var/tmp.

There are a lot of log files in there that can get huge. Find the biggest
ones and consider writing a cron job which periodically reduces them.

For instance a cron job could run once or twice a week at midnight which
simply does:

cp /dev/null /var/tmp/HUGE.LOGS

----- Original Message -----
From: "Ravi Sandesh" <takka_666 at hotmail.com>
To: "Sun Managers List" <codeprof at codeprof.com>
Sent: Thursday, June 28, 2001 5:58 PM
Subject: \var file system 100%

> Hi Gurus,
>
> I hae a few sparc ultra 10s.The \var file systems keeps getting full .Is
> there any way I can stop this from happening.
> Also when it gets full are there specific files or directories I need to
> delete.
> Any pointers would be helpful..
>
>
> Thx
> Ravi
>
>
>
>
> _______________________________________________
> codeprof mailing list
> codeprof at codeprof.com
> http://www.codeprof.com/execute/ask/?codeinfoid=4828
>

Comments

Got something to say?

You must be logged in to post a comment.