Disable some web server access logs


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