简体   繁体   English

IIS6上的ASP.NET MVC 3应用

[英]ASP.NET MVC 3 app on IIS6

I have hosted .NET 4.0 / ASP.NET MVC 3 app on IIS 6 on Windows SErver 2003 machine. 我已经在Windows SErver 2003计算机上的IIS 6上托管了.NET 4.0 / ASP.NET MVC 3应用程序。 When I browse the app i get below error: 当我浏览该应用程序时,出现以下错误:

Access to the path 'C:\\Program Files\\Reference Assemblies\\Microsoft\\Framework\\' is denied. 拒绝访问路径“ C:\\ Program Files \\ Reference Assemblies \\ Microsoft \\ Framework \\”。

http://i.stack.imgur.com/xAtbd.png

I have installed .net 4.0 on machine and when I checked the path referred in error I don't see .net 4.0 folder there. 我已经在计算机上安装了.net 4.0,当我检查错误中提到的路径时,没有看到.net 4.0文件夹。 So it's very confusing and not able to figure out where is the problem? 因此,这非常令人困惑,无法确定问题出在哪里? I would appreciate if anyone can help on this. 如果有人可以提供帮助,我将不胜感激。

I think this is about permissions or something. 我认为这与权限有关。 Will you at least try to impersonate web application to a user who has access permission to the referenced folder? 您是否至少会尝试将Web应用程序模拟给具有对所引用文件夹的访问权限的用户?

You can find information about impersonation here. 您可以在此处找到有关模拟的信息。

I'd first start here . 我首先从这里开始。 If that doesn't help then you need to grant access to that folder to the account that runs the ASP.Net service (ASPNET???). 如果这样做没有帮助,则需要将对该文件夹的访问权限授予运行ASP.Net服务(ASPNET ???)的帐户。

It sounds like when the first version of .net was installed with the reference assemblies the permissions weren't properly set on it. 这听起来像是在第一个版本的.net与参考程序集一起安装时,权限设置不正确。 Its just simply a matter of changing permissions. 这只是更改权限的问题。 aspnet_regiis as previously mentioned won't work here, this is a folder used as a local reference path when you add references to libraries in the GAC. 前面提到的aspnet_regiis在这里不起作用,这是在GAC中添加对库的引用时用作本地引用路径的文件夹。 When you click "add reference" in visual studio - all the gac libraries that show up are from this location, it is not actually querying the gac (you can also set registry keys to customize that location as well). 当您在Visual Studio中单击“添加引用”时-显示的所有gac库都来自该位置,实际上并不是在查询gac(您也可以设置注册表项以自定义该位置)。 Just follow these directions to change permissions on that folder and subfolders and you should be good. 只需按照以下说明更改该文件夹和子文件夹的权限,就可以了。 if you still have an issue edit your question and post the new error msg 如果您仍然有问题,请编辑您的问题并发布新的错误消息

http://www.asp.net/learn/whitepapers/denied-access-to-iis-directories http://www.asp.net/learn/whitepapers/denied-access-to-iis-directories

当我在服务器上安装MVC3时,此问题已解决。

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

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