How can I stop Apache2 from log certain warning messages?

Posted on

How can I stop Apache2 from log certain warning messages? – Problems with loading a website are often blamed on the Internet connection, but even the most perfectly set up network cannot help if there is no service to reply at your destination. One of the most popular HTTP servers used for this task is Apache2. Much of Apache’s popularity can be attributed to its easy installation and use, but never the less it is possible to run into problems with even the easiest of the software. If you’ve encountered an issue loading your web page, follow these simple troubleshooting methods outlined in this guide to attempt to get your web server back up and working again. Below are some tips in manage your apache2 server when you find problem about apache-2.2, setenv, , , .

On my Apache ErrorLog file I see many times this warning message:

[Wed Aug 23 17:27:25.146025 2017] [:error] [pid 14989] [client 66.249.76.54:44935] PHP Warning:  Illegal offset type in isset or empty in /var/www/html/blog/wp-content/plugins/ilab-media-tools/classes/tools/s3/ilab-media-s3-tool.php on line 1012

I tried on Github to ask help from author (as many others) but nothing.

Apache print this warning every minute, is there a way to filter this annoying message warning?

Adjust the level of error_reporting in your php.ini file to the desired level to prevent the messages from getting generated in the first place, if you can’t/won’t fix the actual code that is triggering such messages.

By default everything except run-time notices get logged:

 error_reporting = E_ALL & ~E_NOTICE 

but maybe all you want are the fatal run-time errors:

 error_reporting = E_ERROR & E_CORE_ERROR 

Leave a Reply

Your email address will not be published. Required fields are marked *