Apache reset/delete logs

http://httpd.apache.org/docs/1.3/misc/howto.html#logreset

The correct procedure is to move the logfile, then signal Apache to tell it to reopen the logfiles.

Apache is signaled using the SIGHUP (-1) signal. e.g.

mv access_log access_log.old
kill -1 `cat httpd.pid`

Note: httpd.pid is a file containing the process id of the Apache httpd daemon, Apache saves this in the same directory as the log files.

(httpd.pid is in /var/run on plesk)

This entry was posted in computing, linux. Bookmark the permalink.

Leave a Reply