1748011 Members
5114 Online
108757 Solutions
New Discussion юеВ

File System Full /var

 
Harsha
Occasional Contributor

File System Full /var

Hi,
We've a machine where in it shows 100% file system usage for /var file system thro' bdf command, but actually if you go in to the /var directory and do a du -sk of each files and folders, doesn't appears to be using all the space allocated to /var file system.
Ex: /var is a 2GB file system.
du -sk under /var shows the disk space utilized to be around 600MB and odd. So what could be the problem here and where is the remaining space allocated to /var getting utilized?

Thanks in Advance for your Answers.
9 REPLIES 9
Luk Vandenbussche
Honored Contributor

Re: File System Full /var

Hi,

You can cleanup the follwing directories

/var/tmp
/var/adm/crash

Look for core files in /var

find /var -name core* -print
Cleanup also this files
Henk Geurts
Esteemed Contributor

Re: File System Full /var

hallo Harscha
when files that are in use are deleted , the space it occupied still remaines "in use".
did you remove (log)files under /var ?

if yes , thy to find out which processes were connected to the files. stop and restart these processes and space will have been free-ed.
regards.
MarkSyder
Honored Contributor

Re: File System Full /var

Via SAM you can trim log files:

/var/adm/btmp
/var/adm/sulog
/var/adm/wtmp
/var/adm/cron/log (and OLDlog)
/var/adm/lp/log
/var/adm/syslog/maillog
/var/adm/syslog/syslog.log

or if you're feeling brave you could null them on the command line (I prefer to trim because you still have the most recent messages available to refer to). Do NOT delete any of these files.

You've already been given a good answer regarding the discrepancy between bdf and du so I won't repeat it.

Mark Syder (like the drink but spelt different)
The triumph of evil requires only that good men do nothing
Jayasuntar
Valued Contributor

Re: File System Full /var

Please check any print queue penind, or core dump files. And remove them.

Regards

Jay
Cem Tugrul
Esteemed Contributor

Re: File System Full /var

http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=981357
Our greatest duty in this life is to help others. And please, if you can't
Chan 007
Honored Contributor

Re: File System Full /var

Harsha,

I think you have a rouge process running on /var.

1. check the df -i and see you have free inodes, which you will have many.

2. do fuser -cu /var and know the process. Just kill those.

3. Sometimes it may require to shutdown and start the application that uses var (which you get it from fuser)
on killing / stopping and starting the application you will find it fine.

cheers ...007
Sivakumar TS
Honored Contributor

Re: File System Full /var


Dear Harsha,

It may be being used as the temporary space by any of the running process.

Hope this helps !

With Regards,

Siva.
Nothing is Impossible !
Hoang Chi Cong_1
Honored Contributor

Re: File System Full /var

Hi
First of all, you need to assign point to everyone who takes time help you:
http://forums1.itrc.hp.com/service/forums/publicProfile.do?userId=CA614859&forumId=1

In order to cleanup the /var filesystem, as above ideas, you can remove content of /var/preserve/
#rm -f /var/preserve/*

This directory contain all of vi editor recover files.

You can check out for all large files in /var:
find /var -xdev -type f -size +1000 -exec ll {} \;

If can not remove any large file, you need to extend /var filesystem!

Goodluck!
Hoang Chi Cong

Looking for a special chance.......
Harsha
Occasional Contributor

Re: File System Full /var

Hi,
I did a work around to sort out the disk space issue. I'd moved the /var/adm/sw/save directory to a filesystem where I'd enough space and linked to the new location. I didn't found any core files not any log files of huge size to remove or trim.After I'd requested for a restart as the machine was residing in a remote place and it's a pre-production server. Finally the system is up and running fine without any problems.

Thanks Again for your precious time in answering to my question.

Regards,
-Harsha-