The Apache web server has several causes that cause an internal server error . One possible cause is erroneous entries in an htaccess file, for example due to incorrectly defined forwarding. In this article we describe how you can narrow down the problem and fix the cause.
Your Apache web server returns the following error message when you visit a page:
Internal Server Error The server encountered an internal error or misconfiguration and what not to complete your request. Please contact the server administrator, firstname.lastname@example.org and inform them you might have done that. More information about this error may be available in the server error log. Apache Server at www.example.com Port 80
In the error log you will find the following entry:
[Sun Oct 24 21:58:22 2010] [alert] [client 10.1.1.1] /home/path/.htaccess: RewriteCond: bad flag delimiter
This indicates a bad configuration in the htaccess file.
- Search the htaccess file for erroneous entries.
- Review testable questionable areas.
- Presumably, there have recently been changes to the htaccess file that led to the Internal Server Error. Compare the current version of the htaccess file with the last version of the backup (eg with the diff command). This should allow you to quickly narrow down and correct the erroneous entries.