More About Apache Log File Rotation
June 1, 2005 Posted by KP
As I wrote earlier, I remove old Apache log files by deleting all of them and doing a graceful restart, this is also what Apache documentations suggested, everything works well except that Apache doesn’t release the disk space used by the deleted log files.
As a result, “du” command shows that /var was using 100% disk space, but if I run “df -ma” under /var, it’s only using 23 MB. Postfix can’t receive any emails since disk space was used up, which gave an error message like: “Out: 452 Insufficient system storage”. A non-graceful Apache restart solved the problem.
In Summary
“apachectl graceful” doesn’t work 100% correctly, it holds the disk space used by deleted log files. I didn’t test how it works if the new log file uses different file name.
Related Posts:
- Apache Error Log File
- Log Files
- Move Apache Log Files
- .htaccess error
- Hide Apache and PHP Information in HTTP Headers
Filed Under: Apache