Results 1 to 8 of 8
Hey Guys,
I've been pulling my hair out on trying to find out why my var partition steadily keeps filling up. Up to the point where it fills up 100% ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 10-26-2005 #1Just Joined!
- Join Date
- Aug 2005
- Posts
- 4
Apache filling up Var partition
Hey Guys,
I've been pulling my hair out on trying to find out why my var partition steadily keeps filling up. Up to the point where it fills up 100% and my postgresql and sendmail server's stop.
I've just about found the culprit, ie. Apache. Once i restart the apache server the partition goes back to about 50%.
Does anyone have an idea as to why this happens or how to sort this problem out.
Thanks.
- 10-26-2005 #2
could it be the apache logs?
Brilliant Mediocrity - Making Failure Look Good
- 10-26-2005 #3
I was thinking logs also, but that doesn't make sense if the partition drops down to 50% when it is shutdown...the logs would stay there regardless of whether the daemon was running or not...
I guess I would start taking an inventory of whats on that partition when apache is off versus on...maybe that will point you in the direction of where the size increase is coming from...just sounds weird...Join the Open Source Revolution. Support GNU/Linux.
Find me at: www.deeksworld.com
Registered GNU/Linux User #395777
- 10-27-2005 #4Just Joined!
- Join Date
- Oct 2005
- Location
- North Carolina, USA
- Posts
- 45
I'm wondering if there are any CGIs running on the server. Doesn't perl, for example, write temp files to /var/tmp during file uploads? Or maybe just some errant script writing to a file, not closing?
- 10-27-2005 #5Just Joined!
- Join Date
- Aug 2005
- Posts
- 4
It doesnt seem to be the logs... They add to the size increase but once they are deleted then the partition shrinks a bit.... Then starts growing again...... The logs aren't then created until the next apache restart.could it be the apache logs?
I'm moving towards this..... maybe some unlinked file(s) that doesnt get freed up until the next reboot......Or maybe just some errant script writing to a file, not closing?
But how to get around this....
- 10-27-2005 #6
You need to find out what is being written and why you're running out of space. With a near full /var, cd to /var/html (or wherever your apache document root is stored) and do:
to see which directories are the most full, and work your way down the directory tree to see what is going on.Code:du -sh *
Linux user #126863 - see http://linuxcounter.net/
- 04-16-2010 #7Just Joined!
- Join Date
- Apr 2010
- Posts
- 1
Hi,
We are also experiencing the same issue and have found that its the deleted open log files (gets generated with logrotation) are actually occupying the disk space which can be seen with the following command:
lsof | grep /var
This will show you the files with deleted tag on the right. Actually, when the logs are rotated those logs are still accessed by the respective application and when logrotation tries to delete the logs after log rotation it actually doesn't gets deleted and occupy the space. When we restart apache2 the deleted open log files gets closed and the space is returned back.
Let me know if you find any permanent fix for the same.
Thx, Ramesh Daryani
- 04-16-2010 #8forum.guy
- Join Date
- May 2004
- Location
- arch linux
- Posts
- 18,733
Hello and welcome, Ramesh!

This thread is almost 5 years old so I'm going to lock it, but please feel free to start a new thread of your own if you are having any problems that you need help with.oz



