Contents
How do I debug an Apache internal server error?
Make sure PHP logging is turned on:
- Locate your php.ini file: el@apollo:~$ locate php.ini /etc/php5/apache2/php.ini.
- Edit that file as root: sudo vi /etc/php5/apache2/php.ini.
- Find this line in php.ini: display_errors = Off.
- Change the above line to this: display_errors = On.
Why do I keep getting a 404 error on Google?
You’ll get 404 errors if you’ve deleted or removed pages from your site recently without redirecting their URLs. 404 errors can also occur if you’ve relaunched or transferred your domain and failed to redirect all your old URLs to the new site. Sometimes 404 errors can be the result of changing a page’s URL.
Why are the 500 internal errors not being logged into your Apache error logs?
Why are the 500 Internal Server Errors not being logged into your apache error logs? The errors that cause your 500 Internal Server Error are coming from a PHP module. By default, PHP does NOT log these errors.
Why are there no logs in Apache 2.4?
If your Internal Server Error information doesn’t show up in log files, you probably need to restart the Apache service. I’ve found that Apache 2.4 (at least on Windows platform) tends to stubbornly refuse to flush log files—instead, logged data remains in memory for quite a while.
What to do if there is 500 error in PHP?
If you still have 500 error and no logs you can try to execute from command line: it will not work exactly like in a browser (from server) but if there is syntax error in your code, you will see error message in console. Btw, other frameworks or CMS share this kind of behaviour. I had the same issue.
Why does PHP not log internal server errors?
By default, PHP does NOT log these errors. Reason being you want web requests go as fast as physically possible and it’s a security hazard to log errors to screen where attackers can observe them. These instructions to enable Internal Server Error Logging are for Ubuntu 12.10 with PHP 5.3.10 and Apache/2.2.22. Make sure PHP logging is turned on: