简体   繁体   English

内部错误500:服务器中的IIS8错误,但未在浏览器中的网页上显示错误详细信息

[英]Internal Error 500 : IIS8 error in server but does not show error details on web page in browser

My web page was on a Windows Server 2003. When I change my server to Windows Server 2012 (IIS 8) my web page (that was written in Visual Studio 2010) in last server show over internet but since I change my server it just show this error: 我的网页是在Windows Server 2003上。当我将服务器更改为Windows Server 2012(IIS 8)时,我的网页(在Visual Studio 2010中编写)在最后一台服务器上通过互联网显示但是因为我更改了我的服务器它只是显示这个错误:

Internal error 500. 内部错误500。

I do not know how can i fix it?I change my web config but it dose not change 我不知道如何解决这个问题?我改变了我的网络配置,但它并没有改变

In your web.config file add the following: web.config文件中添加以下内容:

<configuration>
    <system.webServer>
        <httpErrors existingResponse="PassThrough"/>
    </system.webServer>
</configuration>

This will ensure upstream errors are rendered to the browser. 这将确保向浏览器呈现上游错误。

I was having same problem on a new Windows 2012 Server. 我在新的Windows 2012 Server上遇到了同样的问题。

In IIS manager, at the site level, I had also set properties for ASP for send errors to browser to true, but was still getting the generic message in my browser (I am accessing the site from another PC, not locally on the server). 在IIS管理器中,在站点级别,我还将ASP的属性设置为发送错误到浏览器为true,但仍然在我的浏览器中获取通用消息(我从另一台PC访问该站点,而不是在本地服务器上) 。

I went into error pages, and clicked 'Edit Feature Settings' to find this dialog window: 我进入错误页面,然后单击“编辑功能设置”以找到此对话框窗口:

编辑错误页面设置对话框

Change setting from 3rd option: Detailed errors for local requests and custom error pages for remote requests To 2nd option: Detailed errors 从第3个选项更改设置: 本地请求的详细错误和远程请求的自定义错误页面到第2个选项: 详细错误

Open your website in browser on server or modify your web.config file to allow showing error on client browser 在服务器上的浏览器中打开您的网站或修改您的web.config文件以允许在客户端浏览器上显示错误

<customErrors mode="Off">

Then it should give more detail about this error. 然后它应该提供有关此错误的更多详细信息。

Or you can check your server event log. 或者您可以检查服务器事件日志。

请试试这个:

Error Pages -> 500 -> Edit Feature Settings -> "Detailed Error"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM