ecometer

Disable some web server access logs

(Hosting)
#82

Heavy traffic can lead to web server access logs becoming very large. It is therefore recommended that you disable all except those that are essential. By limiting the number of events registered in the application’s log, we avoid writing to the disk, which minimizes CPU consumption and the storage space needed.

Configure the Apache logs as follows:

SetEnvIf Request_URI \\".(ico|pdf|flv|jpg|jpeg|png|gif
|js|css|gz|swf|txt)$\\" dontlog SetEnvIf Request_URI \\"^/rss/\\" dontlog
CustomLog /var/log/apache/access.log combined env=!dontlog
This best practice should only be applied if it is coherent with your project's specifications.
Under CC-By-NX-SA license