How to disable apache logs

To diapachesable apache logs (access and error log) to avoid excessive writes on local server just open your /etc/apache2/apache2.conf file and change the following two configurations:
Change the ErrorLog to:
ErrorLog /dev/null
Now, open /etc/apache2/conf.d/other-vhosts-access-log and comment the following line
#CustomLog /var/log/apache2/other_vhosts_access.log vhost_combined
In addition, you might have to change these files:
/etc/apache2/sites-available/default-ssl
/etc/apache2/sites-available/default
and change the ErrorLog and comment out the CustomLog:
ErrorLog /dev/null
#CustomLog ${APACHE_LOG_DIR}/access.log combined

If you have more VirtualHosts, you need to make the same configuration for them.

Source; lleess

Comments

comments

Comments are Disabled