在IIS8上部署MVC3 - Cassette应用程序时出错

时间:2012-10-04 05:05:18

标签: asp.net-mvc-3 deployment web-config cassette

在本地计算机上正常工作,但在部署时会弹出此错误消息:

HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.

Detailed Error Information:
Module     IIS Web Core
Notification       BeginRequest
Handler    Not yet determined
Error Code     0x80070021
Config Error       This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false".
Config File    \\?\C:\inetpub\foo\web.config
Requested URL      http://foo.net:80/
Physical Path      C:\inetpub\foo
Logon Method       Not yet determined
Logon User     Not yet determined

Config Source:
   71:     </modules>
   72:     <handlers> <--- This part is highlighted on the error page.
   73:       <add name="CassetteHttpHandler" path="cassette.axd" preCondition="integratedMode" verb="*" allowPathInfo="true" type="Cassette.Aspnet.CassetteHttpHandler, Cassette.Aspnet" />

More Information:
This error occurs when there is a problem reading the configuration file for the Web server or Web application. In some cases, the event logs may contain more information about what caused this error.

有关如何解决此问题的任何想法?

1 个答案:

答案 0 :(得分:1)

我解决此错误的方法是进入IIS Management窗口并选择Feature Delegation并设置Read / Write to Handler Mappings and Modules。

现在一切正常。