我的网页位于 Windows Server 2003 上。当我将服务器更改为 Windows Server 2012 (IIS 8) 时,我的网页(用 Visual Studio 2010 编写)在最后一个服务器上通过 Internet 显示,但由于我更改了服务器,它只是显示这个错误:
内部错误 500。
我不知道如何修复它?我更改了我的网络配置,但它没有改变
在您的web.config
文件中添加以下内容:
<configuration>
<system.webServer>
<httpErrors existingResponse="PassThrough"/>
</system.webServer>
</configuration>
这将确保将上游错误呈现给浏览器。
请试试这个:
Error Pages -> 500 -> Edit Feature Settings -> "Detailed Error"
在服务器上的浏览器中打开您的网站或修改您的 web.config 文件以允许在客户端浏览器上显示错误
<customErrors mode="Off">
然后它应该提供有关此错误的更多详细信息。
或者您可以检查您的服务器事件日志。