I'm running Windows 7 Ultimate (64 bit) using Visual Studio 2010 RC. I recently decided to have VS run/debug my apps on IIS rather than the dev server that comes with it.
我使用Visual Studio 2010 RC运行Windows 7 Ultimate(64位)。我最近决定在IIS上运行/调试我的应用程序,而不是使用它的开发服务器。
However, every time I try to run an MVC app, I get the following error:
然而,每当我尝试运行一个MVC应用程序时,我都会得到以下错误:
HTTP Error 403.14 - Forbidden The Web server is configured to not list the contents of this directory. Detailed
HTTP错误403.14 -禁止Web服务器被配置为不列出该目录的内容。详细的
Error Information
错误信息
Module DirectoryListingModule
模块DirectoryListingModule
Notification ExecuteRequestHandler
通知ExecuteRequestHandler
Handler StaticFile Error
处理程序StaticFile错误
Code 0x00000000 Requested
代码0 x00000000请求
URL http://localhost:80/mySite/
URL http://localhost:80 / mySite /
Physical Path C:\myProject\mySite\
物理路径C:\ myProject \ mySite \
Logon Method Anonymous Logon
匿名登录登录方法
User Anonymous
匿名用户
I placed a default.aspx
file in the directory and I received the following error:
我把违约。在目录中的aspx文件,我收到了以下错误:
HTTP Error 500.21 - Internal Server Error Handler "PageHandlerFactory-Integrated" has a bad module "ManagedPipelineHandler" in its module list
HTTP错误500.21 -内部服务器错误处理程序“PageHandlerFactory-Integrated”在其模块列表中有一个糟糕的模块“managed流水线处理程序”。
Are there any other steps I forgot to take to get this working?
我还忘了带其他步骤来完成这个工作吗?
Notes: I installed IIS 7.5 after installing VS 2010 RC. I used the built-in "Create Virtual Directory" button under the "Web" tab in the MVC project's "Properties" in Visual Studio 2010. I made sure that the application is using the ASP.NET 4 App Pool.
注意:安装VS 2010 RC后,我安装了IIS 7.5。在Visual Studio 2010中,我在MVC项目的“属性”中使用了内置的“创建虚拟目录”按钮。我确保应用程序使用的是ASP。净4应用程序池。
Below are the installed features of IIS I have.
以下是我所安装的IIS的安装特性。
28 个解决方案
#1
488
ASP.NET 4 was not registered in IIS. Had to run the following command in the command line/run
ASP。NET 4未在IIS中注册。必须在命令行/运行中运行以下命令?
32bit (x86) Windows
32位(x86)窗口
%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -ir
%列出% \ Microsoft.NET \ Framework \ v4.0.30319 \ aspnet_regiis。exe红外
64bit (x64) Windows
64位Windows(x64)
%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_regiis.exe -ir
%列出% \ Microsoft.NET \ Framework64 \ v4.0.30319 \ aspnet_regiis。exe红外
Note from David Murdoch's comment:
大卫·默多克的评论:
That the .net version has changed since this Answer was posted. Check which version of the framework is in the %windir%\Microsoft.NET\Framework64 directory and change the command accordingly before running (it is currently v4.0.30319)
自从这个答案发布后,.net版本已经发生了变化。检查该框架的哪个版本在%windir%\Microsoft中。NET\Framework64目录,并在运行之前更改命令(当前为v4.0.30319)
#2
194
One more thing to make sure you have is the following set in your web.config:
还有一件事要确保你的web.config中有以下设置:
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
#3
74
Make sure you have is the following set in your web.config:
确保您的web.config中有以下设置:
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
Better solution:
更好的解决方案:
Even though above solution works absolutely fine, it can cause other problem as it runs all your registered HTTP modules on every request (even on every request of .jpg .gif .css .html .pdf etc) and it is obviously waste of resource. Instead
即使上面的解决方案工作的很好,它也会导致其他问题,因为它会在每个请求上运行你所有的注册HTTP模块(即使是在.jpg .gif .css .html .pdf等的每个请求上),而且它显然是在浪费资源。而不是
<system.webServer>
<modules>
<remove name="UrlRoutingModule-4.0"/>
<add name="UrlRoutingModule-4.0" type="System.Web.Routing.UrlRoutingModule, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" preCondition="" />
</modules>
</system.webServer>
Make sure preCondition attribute is empty means it will run on all requests. [Read more](http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html,"Read original post")
确保preCondition属性是空的,这意味着它将在所有请求上运行。(了解更多)(http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html,“阅读原始文章”)
#4
38
Another reason why someone might get this error is if the file Global.asax is not in the root folder anymore.
另一个原因是如果文件是全局的。asax已经不在根文件夹中了。
#5
19
I was also receiving this error and discovered that "HTTP Redirection" was not turned on in Windows Server. This blog post points this out as well: http://blogs.msdn.com/b/rjacobs/archive/2010/06/30/system-web-routing-routetable-not-working-with-iis.aspx
我也收到了这个错误,发现在Windows服务器中“HTTP重定向”没有打开。这篇博客文章也指出了这一点:http://blogs.msdn.com/b/rjacobs/archive/2010/06/30/systemwebrouting-routetable -not- workwith-iis.aspx。
#6
14
Sweet Jesus. I tried all of the above things (but found my settings identical). YET ANOTHER SOLUTION if you are having issues:
甜蜜的耶稣。我尝试了以上所有的东西(但发现我的设置是相同的)。还有一个解决方案,如果你有问题:
http://support.microsoft.com/kb/980368
http://support.microsoft.com/kb/980368
Try installing this KB for your system. If you are seeing 404s it might be because you don't have this update -- and the isapi module just isn't getting found and there's not a lot you can do about that without this!
尝试为您的系统安装这个知识库。如果你看到404s,可能是因为你没有这个更新,而isapi模块没有被发现,没有这个你可以做很多事情!
#7
7
Also u can switch AppPool to Integrated mode. Thnx to Michael Bianchi (https://*.com/a/7956546/1143515), I only want to underline that.
也可以将AppPool切换到集成模式。我只想强调这一点。
#8
7
For me on an Azure Server 2012 R2 IIS 8.5 VM with an Asp.Net MVC 5 app (bin deployed MVC 5) I had to do the following from an elevated cmd prompt even though I had 4.5 already installed:
对我来说,在Azure服务器2012年R2 IIS 8.5 VM和Asp。Net MVC 5应用程序(bin部署了MVC 5),我不得不从一个cmd提示中执行以下操作,尽管我已经安装了4.5个:
dism /online /enable-feature /featurename:IIS-ASPNET45
Source: http://support.microsoft.com/kb/2736284
来源:http://support.microsoft.com/kb/2736284
I also brute force installed all IIS features with the following PowerShell:
我还蛮力安装了所有的IIS特性和下面的PowerShell:
import-module servermanager
add-windowsfeature web-server -includeallsubfeature
Source: http://www.iis.net/learn/install/installing-iis-85/installing-iis-85-on-windows-server-2012-r2
来源:http://www.iis.net/learn/install/installing - iis 85/installing iis - 85 - windows server 2012 r2
Now my app is working.
现在我的程序正在运行。
#9
6
We had a MVC application moved to a new server. .NET 4 and MVC 3 was installed, but we still got “Error 403.14″. In this case, this meant that IIS did not understand that it was dealing with a MVC application, it was looking for the default page.
我们有一个MVC应用程序迁移到一个新的服务器。net 4和MVC 3安装了,但是我们仍然有“错误403.14”。在这种情况下,这意味着IIS不理解它正在处理一个MVC应用程序,它正在寻找默认的页面。
The solution was simple: HTTP Redirection was not installed on the server.
解决方案很简单:HTTP重定向没有安装在服务器上。
Server Manager – Roles – Web Server (IIS) – Roles Services – HTTP Redirection: Not installed. Installed it, problem solved.
服务器管理器-角色- Web服务器(IIS) -角色服务- HTTP重定向:未安装。安装,问题解决了。
#10
5
Also if your app is precompiled you should have
如果你的应用程序是预编译的,你应该有。
PrecompiledApp.config
PrecompiledApp.config
in the root folder of your app otherwise you could get HTTP Error 403.14
as well.
在你的应用程序的根文件夹中,你也可以得到HTTP错误403.14。
#11
4
Another possible solution, if you move around your global.asax, make sure the markup points to the correct MvcApplication class. Hopefully this will save someone in future.
另一个可能的解决方案是,如果你在全球范围内移动。asax,确保标记指向正确的MvcApplication类。希望这能在将来挽救一个人。
#12
4
I had used the WebDeploy IIS Extension to import my websites from IIS6 to IIS7.5, so all of the IIS settings were exactly as they had been in the production environment. After trying all the solutions provided here, none of which worked for me, I simply had to change the App Pool setting for the website from Classic to Integrated.
我使用了WebDeploy IIS扩展将我的网站从IIS6导入到IIS7.5,所以所有的IIS设置都和在生产环境中一样。在尝试了这里提供的所有解决方案之后,没有一个对我有用,我只是需要将该网站的应用程序池设置从Classic改为Integrated。
#13
4
I have met the same 404.14 problem suddenly. Finally the problem had been fixed by unchecking "precompile while publishing" in the publish profile settings.
我突然遇到了同样的404.14问题。最后,在发布概要文件设置中,取消了“预编译while publishing”,从而解决了这个问题。
#14
4
I altered my default route at one point from:
我在某点改变了我的默认路线:
routes.MapRoute(
"Default",
"{controller}/{action}/{id}",
new { controller = "Home", action = "Index", id = UrlParameter.Optional }
To:
:
routes.MapRoute(
"Default",
"{controller}/{action}/{id}",
new { controller = "Home", action = "Index" }
Which gave me your error. Glad someone mentioned routing because I probably would've been on this forever.
这给了我你的错误。很高兴有人提到了路由,因为我可能会一直这样。
#15
4
In my case ASP.NET 4.5 is not installed on the server so installing ASP.NET 4.5 fixed the issue.
在我的例子中ASP。NET 4.5没有安装在服务器上,所以安装ASP。NET 4.5修正了这个问题。
#16
4
You can solve this error by running cmd as admin than
您可以通过管理cmd来解决这个错误。
Do the same as in picture for windows 32 bit
是否与windows 32位的图片相同?
Just make changes in 64 bit as framework64 instead of framework only Than go to iis and refresh the site
If u still got some error make changes in application pool
只需将64位更改为framework64,而不是使用框架,如果您仍然有一些错误在应用程序池中进行更改,那么就使用iis和刷新站点。
#17
3
I had another problem that led to this issue.
我还有一个问题导致了这个问题。
- I had ensured my app pool was running .net 4 in integrated mode
- 我确保了我的应用程序池在集成模式下运行。net 4。
- I had run aspnet_regiis.exe -i
- 我有aspnet_regiis运行。exe -我
- I had checked folder permissions were set correctly for the account running my app pool
- 我检查了文件夹权限是否正确设置为运行我的应用程序池的帐户。
None of these things worked. It turned out that in my web.config under system.webserver > modules I had the following:
这些都不奏效。结果在我的网站上。配置下系统。webserver >模块如下:
<remove name="WindowsAuthentication" />
Obviously this removed the windows authentication module which seemed to somehow knock everything off kilter.
显然,这删除了windows身份验证模块,它似乎在某种程度上破坏了一切。
I hope this helps someone, as this cost me most of an evening!
我希望这能帮助别人,因为这花费了我一个晚上的大部分时间!
#18
2
Adding another solution for this issue.
为这个问题添加另一个解决方案。
in my Global.asax.cs file I had disabled attempted php files from being consumed by the MVC pipeline using the following:
在我Global.asax。cs文件中,我已经禁用了使用MVC管道使用的php文件:
routes.IgnoreRoute( "{*php}" );
路线。IgnoreRoute(“{ * php }”);
I had done these previously in a MVC2 project and it worked fine, but doing this in my MVC 3 app caused the issue reported above.
我以前在一个MVC2项目中做过这些工作,它运行得很好,但是在我的MVC 3应用程序中这样做导致了上面报告的问题。
#19
2
Yet another reason this can happen - your RouteConfig.cs
or WebApiConfig.cs
are invalid.
这可能发生的另一个原因是你的例行公事。cs或WebApiConfig。cs是无效的。
In my case, I had a route defined as such (note the parenthesis instead of curly brace):
在我的例子中,我有一条这样定义的路由(注意括号而不是大括号):
...
routeTemplate: "api/(something}"
...
#20
2
Please note for Windows 8 users you need to add/remove windows components and remove the version of .net reboot then re-install in order to register it with IIS. I presume this happens if you get .net 4.5 from visual studio and install IIS afterwards.
请注意,对于Windows 8用户,您需要添加/删除Windows组件,并删除。net重启,然后重新安装,以便在IIS上注册。如果你从visual studio获得。net 4.5,然后安装IIS,我想这会发生。
#21
2
As strange as it may seem, reinstalling IIS was what has worked for me, with the following command run from inside the .net version folder:
看起来很奇怪,重新安装IIS是我的工作,下面的命令是从。net版本文件夹中运行的。
aspnet_regiis.exe /i
When I first run this command, I begun getting the HTTP Error 403.14. But once I runned the command again it solved the problem.
当我第一次运行这个命令时,我开始得到HTTP错误403.14。但是,一旦我再次运行命令,它就解决了问题。
Obs: Another thing I also did was to remove HTTP Redirect from the server features in Server Management screen before reiinstalling IIS. Maybe this also had an impact in solving the problem, but I am not sure. So, if reinstalling IIS still doesn't work, please try removing HTTP Redirect and try again. Hopefully it may work for you too.
Obs:我还做的另一件事是在重新安装IIS之前,将HTTP重定向从服务器管理屏幕上的服务器特性中删除。也许这对解决问题也有影响,但我不确定。因此,如果重新安装IIS仍然不起作用,请尝试删除HTTP重定向并再次尝试。希望它也能为你工作。
#22
1
To solve this problem without having to resort to 32 bit mode you will have to update the source code for this project
要解决这个问题,不必求助于32位模式,您必须更新这个项目的源代码。
public static void RegisterUrlRoutesFromAttributes(RouteCollection routes)
{
// Enumerate assembly for UrlRoute attributes.
List<MapRouteParams> routeParams = new List<MapRouteParams>();
AppDomain.CurrentDomain.GetAssemblies()
.ToList()
.ForEach(assembly => routeParams.AddRange(GetRouteParamsFromAttributes(assembly)));
I have raised this issue as a discussion on the discussion board at the IT cloud codeplex project.
我在IT云codeplex项目的讨论板上讨论了这个问题。
http://itcloud.codeplex.com/discussions/262000
http://itcloud.codeplex.com/discussions/262000
#23
1
This worked for me and it might be useful to another one.
这对我有用,对另一个也有用。
Maybe all components required are not present or/and not all are registered correctly. In order to solve this, try to uncheck all options inside Control Panel -> Turn Windows features on or off -> Internet Information Services -> World Wide Web Services -> Application Development Features, uncheck all options and recheck all then reset the IIS and check if the problem is solved.
可能所有需要的组件都不存在,或者/并不是所有的组件都被正确地注册了。为了解决这个问题,试着取消控制面板中的所有选项->把Windows的功能打开或关闭->互联网信息服务->万维网服务->应用程序开发功能,取消所有选项并重新检查所有选项,然后重新设置IIS,检查问题是否已经解决。
#24
1
If you're running IIS 8.5 on Windows 8, or Server 2012, you might find that running mvc 4/5 (.net 4.5) doesn't work in a virtual directory. If you create a local host entry in the host file to point back to your local machine and then point a new local IIS website to that folder (with the matching host header entry) you'll find it works then.
如果在Windows 8或Server 2012上运行IIS 8.5,您可能会发现运行mvc 4/5 (.net 4.5)在虚拟目录中不起作用。如果您在主机文件中创建一个本地主机条目以指向本地机器,然后将一个新的本地IIS网站指向该文件夹(与匹配的主机头条目),那么您将发现它是有效的。
#25
#26
0
I created a new namespace (and therefore folder) identical to the route to a controller (e.g. MvcApp/Test/SomeClasses.cs
and MvcApp/Controllers/TestController.cs
). This resulted also in a 403.14!
我创建了一个新的命名空间(也就是文件夹),它与一个控制器的路径(例如MvcApp/Test/SomeClasses)相同。cs和MvcApp /控制器/ TestController.cs)。这也导致了403.14!
#27
0
For me, the solution was to add the NuGet package Microsoft.AspNet.WebPages (plus it's Razor and Infrastructure dependencies) to my web project.
对我来说,解决方案是添加NuGet软件包Microsoft.AspNet。WebPages(加上它的刀片服务器和基础设施依赖)到我的web项目。
Infrastructure had to be forcefully reinstalled as it was not added as a reference at first.
基础设施必须进行强有力的重新安装,因为它一开始并没有添加作为参考。
#28
0
In my case .NET CRL Version in Application pool prppertires was set to No managed code (do not know why). Setting it to .NET CRL Version v4.0.30319 solved the problem.
在我的案例中,在应用程序池prpper中,. net CRL版本被设置为没有托管代码(不知道为什么)。将其设置为。net CRL版本v4.0.30319解决了这个问题。
#1
488
ASP.NET 4 was not registered in IIS. Had to run the following command in the command line/run
ASP。NET 4未在IIS中注册。必须在命令行/运行中运行以下命令?
32bit (x86) Windows
32位(x86)窗口
%windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe -ir
%列出% \ Microsoft.NET \ Framework \ v4.0.30319 \ aspnet_regiis。exe红外
64bit (x64) Windows
64位Windows(x64)
%windir%\Microsoft.NET\Framework64\v4.0.30319\aspnet_regiis.exe -ir
%列出% \ Microsoft.NET \ Framework64 \ v4.0.30319 \ aspnet_regiis。exe红外
Note from David Murdoch's comment:
大卫·默多克的评论:
That the .net version has changed since this Answer was posted. Check which version of the framework is in the %windir%\Microsoft.NET\Framework64 directory and change the command accordingly before running (it is currently v4.0.30319)
自从这个答案发布后,.net版本已经发生了变化。检查该框架的哪个版本在%windir%\Microsoft中。NET\Framework64目录,并在运行之前更改命令(当前为v4.0.30319)
#2
194
One more thing to make sure you have is the following set in your web.config:
还有一件事要确保你的web.config中有以下设置:
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
#3
74
Make sure you have is the following set in your web.config:
确保您的web.config中有以下设置:
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
Better solution:
更好的解决方案:
Even though above solution works absolutely fine, it can cause other problem as it runs all your registered HTTP modules on every request (even on every request of .jpg .gif .css .html .pdf etc) and it is obviously waste of resource. Instead
即使上面的解决方案工作的很好,它也会导致其他问题,因为它会在每个请求上运行你所有的注册HTTP模块(即使是在.jpg .gif .css .html .pdf等的每个请求上),而且它显然是在浪费资源。而不是
<system.webServer>
<modules>
<remove name="UrlRoutingModule-4.0"/>
<add name="UrlRoutingModule-4.0" type="System.Web.Routing.UrlRoutingModule, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" preCondition="" />
</modules>
</system.webServer>
Make sure preCondition attribute is empty means it will run on all requests. [Read more](http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html,"Read original post")
确保preCondition属性是空的,这意味着它将在所有请求上运行。(了解更多)(http://www.britishdeveloper.co.uk/2010/06/dont-use-modules-runallmanagedmodulesfo.html,“阅读原始文章”)
#4
38
Another reason why someone might get this error is if the file Global.asax is not in the root folder anymore.
另一个原因是如果文件是全局的。asax已经不在根文件夹中了。
#5
19
I was also receiving this error and discovered that "HTTP Redirection" was not turned on in Windows Server. This blog post points this out as well: http://blogs.msdn.com/b/rjacobs/archive/2010/06/30/system-web-routing-routetable-not-working-with-iis.aspx
我也收到了这个错误,发现在Windows服务器中“HTTP重定向”没有打开。这篇博客文章也指出了这一点:http://blogs.msdn.com/b/rjacobs/archive/2010/06/30/systemwebrouting-routetable -not- workwith-iis.aspx。
#6
14
Sweet Jesus. I tried all of the above things (but found my settings identical). YET ANOTHER SOLUTION if you are having issues:
甜蜜的耶稣。我尝试了以上所有的东西(但发现我的设置是相同的)。还有一个解决方案,如果你有问题:
http://support.microsoft.com/kb/980368
http://support.microsoft.com/kb/980368
Try installing this KB for your system. If you are seeing 404s it might be because you don't have this update -- and the isapi module just isn't getting found and there's not a lot you can do about that without this!
尝试为您的系统安装这个知识库。如果你看到404s,可能是因为你没有这个更新,而isapi模块没有被发现,没有这个你可以做很多事情!
#7
7
Also u can switch AppPool to Integrated mode. Thnx to Michael Bianchi (https://*.com/a/7956546/1143515), I only want to underline that.
也可以将AppPool切换到集成模式。我只想强调这一点。
#8
7
For me on an Azure Server 2012 R2 IIS 8.5 VM with an Asp.Net MVC 5 app (bin deployed MVC 5) I had to do the following from an elevated cmd prompt even though I had 4.5 already installed:
对我来说,在Azure服务器2012年R2 IIS 8.5 VM和Asp。Net MVC 5应用程序(bin部署了MVC 5),我不得不从一个cmd提示中执行以下操作,尽管我已经安装了4.5个:
dism /online /enable-feature /featurename:IIS-ASPNET45
Source: http://support.microsoft.com/kb/2736284
来源:http://support.microsoft.com/kb/2736284
I also brute force installed all IIS features with the following PowerShell:
我还蛮力安装了所有的IIS特性和下面的PowerShell:
import-module servermanager
add-windowsfeature web-server -includeallsubfeature
Source: http://www.iis.net/learn/install/installing-iis-85/installing-iis-85-on-windows-server-2012-r2
来源:http://www.iis.net/learn/install/installing - iis 85/installing iis - 85 - windows server 2012 r2
Now my app is working.
现在我的程序正在运行。
#9
6
We had a MVC application moved to a new server. .NET 4 and MVC 3 was installed, but we still got “Error 403.14″. In this case, this meant that IIS did not understand that it was dealing with a MVC application, it was looking for the default page.
我们有一个MVC应用程序迁移到一个新的服务器。net 4和MVC 3安装了,但是我们仍然有“错误403.14”。在这种情况下,这意味着IIS不理解它正在处理一个MVC应用程序,它正在寻找默认的页面。
The solution was simple: HTTP Redirection was not installed on the server.
解决方案很简单:HTTP重定向没有安装在服务器上。
Server Manager – Roles – Web Server (IIS) – Roles Services – HTTP Redirection: Not installed. Installed it, problem solved.
服务器管理器-角色- Web服务器(IIS) -角色服务- HTTP重定向:未安装。安装,问题解决了。
#10
5
Also if your app is precompiled you should have
如果你的应用程序是预编译的,你应该有。
PrecompiledApp.config
PrecompiledApp.config
in the root folder of your app otherwise you could get HTTP Error 403.14
as well.
在你的应用程序的根文件夹中,你也可以得到HTTP错误403.14。
#11
4
Another possible solution, if you move around your global.asax, make sure the markup points to the correct MvcApplication class. Hopefully this will save someone in future.
另一个可能的解决方案是,如果你在全球范围内移动。asax,确保标记指向正确的MvcApplication类。希望这能在将来挽救一个人。
#12
4
I had used the WebDeploy IIS Extension to import my websites from IIS6 to IIS7.5, so all of the IIS settings were exactly as they had been in the production environment. After trying all the solutions provided here, none of which worked for me, I simply had to change the App Pool setting for the website from Classic to Integrated.
我使用了WebDeploy IIS扩展将我的网站从IIS6导入到IIS7.5,所以所有的IIS设置都和在生产环境中一样。在尝试了这里提供的所有解决方案之后,没有一个对我有用,我只是需要将该网站的应用程序池设置从Classic改为Integrated。
#13
4
I have met the same 404.14 problem suddenly. Finally the problem had been fixed by unchecking "precompile while publishing" in the publish profile settings.
我突然遇到了同样的404.14问题。最后,在发布概要文件设置中,取消了“预编译while publishing”,从而解决了这个问题。
#14
4
I altered my default route at one point from:
我在某点改变了我的默认路线:
routes.MapRoute(
"Default",
"{controller}/{action}/{id}",
new { controller = "Home", action = "Index", id = UrlParameter.Optional }
To:
:
routes.MapRoute(
"Default",
"{controller}/{action}/{id}",
new { controller = "Home", action = "Index" }
Which gave me your error. Glad someone mentioned routing because I probably would've been on this forever.
这给了我你的错误。很高兴有人提到了路由,因为我可能会一直这样。
#15
4
In my case ASP.NET 4.5 is not installed on the server so installing ASP.NET 4.5 fixed the issue.
在我的例子中ASP。NET 4.5没有安装在服务器上,所以安装ASP。NET 4.5修正了这个问题。
#16
4
You can solve this error by running cmd as admin than
您可以通过管理cmd来解决这个错误。
Do the same as in picture for windows 32 bit
是否与windows 32位的图片相同?
Just make changes in 64 bit as framework64 instead of framework only Than go to iis and refresh the site
If u still got some error make changes in application pool
只需将64位更改为framework64,而不是使用框架,如果您仍然有一些错误在应用程序池中进行更改,那么就使用iis和刷新站点。
#17
3
I had another problem that led to this issue.
我还有一个问题导致了这个问题。
- I had ensured my app pool was running .net 4 in integrated mode
- 我确保了我的应用程序池在集成模式下运行。net 4。
- I had run aspnet_regiis.exe -i
- 我有aspnet_regiis运行。exe -我
- I had checked folder permissions were set correctly for the account running my app pool
- 我检查了文件夹权限是否正确设置为运行我的应用程序池的帐户。
None of these things worked. It turned out that in my web.config under system.webserver > modules I had the following:
这些都不奏效。结果在我的网站上。配置下系统。webserver >模块如下:
<remove name="WindowsAuthentication" />
Obviously this removed the windows authentication module which seemed to somehow knock everything off kilter.
显然,这删除了windows身份验证模块,它似乎在某种程度上破坏了一切。
I hope this helps someone, as this cost me most of an evening!
我希望这能帮助别人,因为这花费了我一个晚上的大部分时间!
#18
2
Adding another solution for this issue.
为这个问题添加另一个解决方案。
in my Global.asax.cs file I had disabled attempted php files from being consumed by the MVC pipeline using the following:
在我Global.asax。cs文件中,我已经禁用了使用MVC管道使用的php文件:
routes.IgnoreRoute( "{*php}" );
路线。IgnoreRoute(“{ * php }”);
I had done these previously in a MVC2 project and it worked fine, but doing this in my MVC 3 app caused the issue reported above.
我以前在一个MVC2项目中做过这些工作,它运行得很好,但是在我的MVC 3应用程序中这样做导致了上面报告的问题。
#19
2
Yet another reason this can happen - your RouteConfig.cs
or WebApiConfig.cs
are invalid.
这可能发生的另一个原因是你的例行公事。cs或WebApiConfig。cs是无效的。
In my case, I had a route defined as such (note the parenthesis instead of curly brace):
在我的例子中,我有一条这样定义的路由(注意括号而不是大括号):
...
routeTemplate: "api/(something}"
...
#20
2
Please note for Windows 8 users you need to add/remove windows components and remove the version of .net reboot then re-install in order to register it with IIS. I presume this happens if you get .net 4.5 from visual studio and install IIS afterwards.
请注意,对于Windows 8用户,您需要添加/删除Windows组件,并删除。net重启,然后重新安装,以便在IIS上注册。如果你从visual studio获得。net 4.5,然后安装IIS,我想这会发生。
#21
2
As strange as it may seem, reinstalling IIS was what has worked for me, with the following command run from inside the .net version folder:
看起来很奇怪,重新安装IIS是我的工作,下面的命令是从。net版本文件夹中运行的。
aspnet_regiis.exe /i
When I first run this command, I begun getting the HTTP Error 403.14. But once I runned the command again it solved the problem.
当我第一次运行这个命令时,我开始得到HTTP错误403.14。但是,一旦我再次运行命令,它就解决了问题。
Obs: Another thing I also did was to remove HTTP Redirect from the server features in Server Management screen before reiinstalling IIS. Maybe this also had an impact in solving the problem, but I am not sure. So, if reinstalling IIS still doesn't work, please try removing HTTP Redirect and try again. Hopefully it may work for you too.
Obs:我还做的另一件事是在重新安装IIS之前,将HTTP重定向从服务器管理屏幕上的服务器特性中删除。也许这对解决问题也有影响,但我不确定。因此,如果重新安装IIS仍然不起作用,请尝试删除HTTP重定向并再次尝试。希望它也能为你工作。
#22
1
To solve this problem without having to resort to 32 bit mode you will have to update the source code for this project
要解决这个问题,不必求助于32位模式,您必须更新这个项目的源代码。
public static void RegisterUrlRoutesFromAttributes(RouteCollection routes)
{
// Enumerate assembly for UrlRoute attributes.
List<MapRouteParams> routeParams = new List<MapRouteParams>();
AppDomain.CurrentDomain.GetAssemblies()
.ToList()
.ForEach(assembly => routeParams.AddRange(GetRouteParamsFromAttributes(assembly)));
I have raised this issue as a discussion on the discussion board at the IT cloud codeplex project.
我在IT云codeplex项目的讨论板上讨论了这个问题。
http://itcloud.codeplex.com/discussions/262000
http://itcloud.codeplex.com/discussions/262000
#23
1
This worked for me and it might be useful to another one.
这对我有用,对另一个也有用。
Maybe all components required are not present or/and not all are registered correctly. In order to solve this, try to uncheck all options inside Control Panel -> Turn Windows features on or off -> Internet Information Services -> World Wide Web Services -> Application Development Features, uncheck all options and recheck all then reset the IIS and check if the problem is solved.
可能所有需要的组件都不存在,或者/并不是所有的组件都被正确地注册了。为了解决这个问题,试着取消控制面板中的所有选项->把Windows的功能打开或关闭->互联网信息服务->万维网服务->应用程序开发功能,取消所有选项并重新检查所有选项,然后重新设置IIS,检查问题是否已经解决。
#24
1
If you're running IIS 8.5 on Windows 8, or Server 2012, you might find that running mvc 4/5 (.net 4.5) doesn't work in a virtual directory. If you create a local host entry in the host file to point back to your local machine and then point a new local IIS website to that folder (with the matching host header entry) you'll find it works then.
如果在Windows 8或Server 2012上运行IIS 8.5,您可能会发现运行mvc 4/5 (.net 4.5)在虚拟目录中不起作用。如果您在主机文件中创建一个本地主机条目以指向本地机器,然后将一个新的本地IIS网站指向该文件夹(与匹配的主机头条目),那么您将发现它是有效的。
#25
1
The UI is a bit different in the newer versions of Windows Server. Here is where you have to enable ASP.Net in order to get it working on IIS
在Windows服务器的新版本中,UI略有不同。这里是您必须启用ASP的地方。为了让它在IIS上运行。
#26
0
I created a new namespace (and therefore folder) identical to the route to a controller (e.g. MvcApp/Test/SomeClasses.cs
and MvcApp/Controllers/TestController.cs
). This resulted also in a 403.14!
我创建了一个新的命名空间(也就是文件夹),它与一个控制器的路径(例如MvcApp/Test/SomeClasses)相同。cs和MvcApp /控制器/ TestController.cs)。这也导致了403.14!
#27
0
For me, the solution was to add the NuGet package Microsoft.AspNet.WebPages (plus it's Razor and Infrastructure dependencies) to my web project.
对我来说,解决方案是添加NuGet软件包Microsoft.AspNet。WebPages(加上它的刀片服务器和基础设施依赖)到我的web项目。
Infrastructure had to be forcefully reinstalled as it was not added as a reference at first.
基础设施必须进行强有力的重新安装,因为它一开始并没有添加作为参考。
#28
0
In my case .NET CRL Version in Application pool prppertires was set to No managed code (do not know why). Setting it to .NET CRL Version v4.0.30319 solved the problem.
在我的案例中,在应用程序池prpper中,. net CRL版本被设置为没有托管代码(不知道为什么)。将其设置为。net CRL版本v4.0.30319解决了这个问题。