iis-7.5 - ASP.NET 4 返回 500 错误

标签 iis-7.5

我有一个 ASP.NET 4 页面返回 500 错误。这是带有单个 Response.Write 命令的单个页面:

<% Response.Write("Hello World") %>

IIS 7.5

网站的权限是:

SYSTEM
MACHINENAME\myusername
MACHINENAME\Administrators
MACHINENAME\Users
MACHINENAME\IIS_IUSRS

物理路径是:

C:\Users\myusername\Documents\mywebsite

物理路径文件夹的权限为:

SYSTEM
MACHINENAME\myusername
MACHINENAME\Administrators
MACHINENAME\Users
MACHINENAME\IIS_IUSRS

使用托管管道模式:集成.NET Framework v4.0.30319设置应用程序池。经典模式也已尝试过。

web.config 文件包含以下行:

<authorization>
    <allow users="*"/>
</authorization>

<compilation debug="true" targetFramework="4.0">
    <assemblies>
    </assemblies>
</compilation>

IIS 身份验证设置为匿名身份验证 - 已启用

物理路径> 测试设置显示以下警告:

The server is configured to use pass-through authentication with a built-in account to access the specified physical path. However, IIS Manager cannot verify whether the built-in account has access. Make sure that the application pool identity has Read access to the physical path. If this server is joined to a domain, and the application pool identity is NetworkService or LocalSystem, verify that <domain>\<computer_name>$ has Read access to the physical path. Then test these settings again.

我已经尝试了所有我读过的方法来解决这个问题,但没有任何改变 500 错误的结果

单个日志条目:

2012-03-22 19:24:16 172.16.35.115 GET /Default.aspx - 80 - 10.1.11.107 Mozilla/5.0+(Windows+NT+6.1;+WOW64;+rv:11.0)+Gecko/20100101+Firefox/11.0 500 21 13 203

这对我来说是新的,我从来没有花这么多时间来加载网页。

我还为 4.0 库(64 位和 32 位版本)添加了 ISAPI 过滤器。

有人可以帮忙吗?

更新

所有研究都让我认为 ASP.NET 4 向 IIS 注册的方式存在问题,并且 aspnet_iisreg应再次运行实用程序。不幸的是,我还没有获得管理员的许可。

最佳答案

我在 Windows Server 2012 上的 IIS 8 上遇到了同样的问题。 在服务器功能中启用 ASP.NET 4.5 解决了我的问题。

关于iis-7.5 - ASP.NET 4 返回 500 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9829473/

相关文章:

asp.net - 无法找到 asp.net 工作进程

asp.net - 是什么导致 IIS 7.5 上传递静态文件时出现 404.4?

visual-studio - 如何设置 IIS Express 以在虚拟目录而不是根目录中运行 Visual Studio 项目?

iis - 多个域的单一 SSL

IIS 网站与应用程序

asp.net - MVC 应用程序重启后每个页面都很慢

websocket - IIS 7.5 上的 SignalR WebSockets

asp.net-mvc-4 - 附加到 HTTP 响应的 CORS header 未发送到浏览器

ASP.NET - 使用 WCF Web 服务绑定(bind)和 AD 组时出现 IIS7 部署错误 500 24 50

php - 如何在我自己的 PHP 应用程序中创建类似于 Wordpress 的 URL 重写