How to debug a 500 error when opening a website (applicable to Windows systems)

Published: 2003-09-26

There are many causes of a 500 error. Generally speaking, if a program error occurs, the browser will return a friendly error message to the user, which is collectively called a server 500 error. The solution is that you must be able to correctly obtain the error information in HTTP.

The method is as follows: please open the browser, select Tools, Internet Options, Advanced. In the Browsing section under Advanced, there is a "Show friendly HTTP error messages" check box. Please clear this check box, so that you can obtain the correct error message. After obtaining the correct error message, you can check the specific cause of your error based on the error message. According to the specific cause of the error, perform corresponding debugging to resolve it.

image.png

For WINDOWS2008/2012 IIS7.5, merely configuring the IE client is not enough; you also need to configure the server side. Steps to enable detailed error display:
Open IIS7.5 Manager -- click the site you need to configure -- Error Pages -- click "Edit Feature Settings" on the right, change it to  Detailed Errors and save, as shown in the figure:

1.jpg

ASP programs also require one more setting step:

Click the site you need to configure -- ASP tab   In Debugging Properties, set Send Errors to Browser to true

1.jpg