[ILUG] Problem with removing apache logs

Niall O Broin niall at linux.ie
Mon Nov 12 10:54:11 GMT 2001


I had a problem on a box with removing some large apache logs. I don't run
a logrotate script on the box, though if you follow this, you'll see why I
don't think it would have helped. I stopped apache, deleted the log files,
and started apache again, but the space used by the deleted files had not
been returned to the free space. I had a version of lsof on the box but it
was old (wrong kernel version) so a reboot was the quickest option to get
back on the air. But why didn't the space get returned to the filesystem ?
As I mentioned, I had stopped apache, and this is why I don't think a
logrotate script would have helped - all it does is move the log files and
send HUP to apache. If a non-existent apache process can hang on to a file,
I don't imagine a little HUP is going to bother it :-)



Niall





More information about the ILUG mailing list