LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Apache access_log grows too fast (https://www.linuxquestions.org/questions/linux-software-2/apache-access_log-grows-too-fast-274698/)

HermanTheSheep 01-06-2005 03:06 PM

Apache access_log grows too fast
 
hi, i have apache 2.0.52 and its been running very well for about a month now. My access_log is the problem, i get alot of annoying requests, i think its the webdav exploit (lots of \x90\x90 gibberish). these requests are far from small and after about a week my access log is around 250MB :mad:

what is the best way to stop this, can i stop requests with "\x90" in them from appearing in the log or how can i rotate logs automatically and more often? thanks for any help :)

rbochan 01-06-2005 05:20 PM

I have a similiar issue myself, and here's what I do...

Once a day or so, I have cron run this:
cat /dev/null > /var/log/apache/access.log

It empties out the log file, but it keeps apache's necessary perms and such to keep it logging properly. In conjunction with that, I have the file set to be sent to an offsite storage first before it's emptied. That way I have a record of the log for my own purposes. I also do this for the error log, since it tends to grow rather quickly as well.

twantrd 01-06-2005 05:33 PM

Or rotate the log earlier.

-twantrd

HermanTheSheep 01-10-2005 11:29 AM

Thanks i never thought of "cat /dev/null > access_log"

i had noticed apache stops logging correctly if you play around with the log files


All times are GMT -5. The time now is 03:27 AM.