默认角色提供程序无法在IIS 6和asp.net MVC 3中找到 [英] Default Role Provider could not be found in iis 6 and asp.net mvc 3
问题描述
我发起asp.net mvc的上II6 3 apllication。没有会员或角色提供商使用。我已经通过手动创建授权cookie执行授权和在Global.asax中处理它。首先一个已经得到这个错误:
I'm launching asp.net mvc 3 apllication on ii6. No membership or role providers are used. I have implemented authorization by creating authorization cookie manually, and handled it in global.asax. First of all a have got this error:
拒绝访问创建的App_Data子目录
说明:出于安全原因,标识IIS APPPOOL \\ ASP.NET v4.0的'(此Web应用程序在其下运行),没有权限来创建应用程序根目录中对App_Data子目录。 ASP.NET存储在您的应用程序的App_Data子目录用于如会员服务和个人资料的微软SQL防爆preSS数据库文件。
Access denied creating App_Data subdirectory Description: For security reasons, the identity 'IIS APPPOOL\ASP.NET v4.0' (under which this web application is running), does not have permissions to create the App_Data subdirectory within the application root directory. ASP.NET stores the Microsoft SQL Express Database file used for services such as Membership and Profile in the App_Data subdirectory of your application.
我已经寻找这个错误,并加入到我的web.config文件,作为一个解决方案:
在<&的System.Web GT;
节点:
<启用roleManager =false的>
<供应商>
<清/>
< /供应商>
< / roleManager>
I have searching for this error, and add this to my web.config file, as a solution:
in <system.web>
node:
<roleManager enabled="false">
<providers>
<clear />
</providers>
</roleManager>
和&LT;模块&gt;
中的节点&LT; system.webServer&GT;
:&LT;清除NAME =RoleManager/&GT;
,然后得到了默认角色提供找不到的错误。
and then got 'Default Role Provider could not be found' error.
我做了什么错?
推荐答案
解决。 IIS6不承认&LT; system.webServer&GT;
(它在IIS7介绍),我用&LT;的HttpModules&GT;
在&LT;&的System.Web GT;
而不是:
Solved. IIS6 does not recognize <system.webServer>
(it was introduced in IIS7), and I used <httpModules>
in <system.web>
instead:
<system.web>
...
<httpModules>
<remove name="RoleManager" />
</httpModules>
...
<system.web>
这篇关于默认角色提供程序无法在IIS 6和asp.net MVC 3中找到的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!