当前位置:主页 > 服务器 > Linux >

apache的access.log和error.log减肥

时间:2020-10-27 15:46:21 | 栏目:Linux | 点击:

怀疑是有其他的爬虫,明天都在爬我的几个网站。

在网上找找了给access.log和error.log减肥的方法

如下

CustomLog "|D:/thridparty-system/java/apache2/bin/rotatelogs.exe D:/thridparty-system/java/apache2/logs/access_%Y_%m_%d.log 86400 480" common

ErrorLog "|D:/thridparty-system/java/apache2/bin/rotatelogs.exe D:/thridparty-system/java/apache2/logs/error_%Y_%m_%d.log 86400 480"
一切就这么简单,这样这两个日志文件每天都会起一个新文件,就不至于单个文件太大,打不开,而无法看到日志信息了.

您可能感兴趣的文章:

相关文章