3
votes

I am hitting "HTTP Error 403.14 - Forbidden" after performing an XCopy deployment of an ASP.NET MVC 6 application against a Windows Server 2008 x64 running IIS 7 and trying to run the deployed web application.

I followed the steps at http://docs.asp.net/en/latest/getting-started/installing-on-windows.html#install-asp-net-standalone and http://docs.asp.net/en/latest/publishing/iis.html#xcopy-to-iis-server and I am using dnx-clr-win-x64.1.0.0-beta7.

2
you make it sound like you failed to deploy it but I don't see how you could get this error while deploying since deployment is copying files and the error is a web request error, I think you really mean you get this error after deployment?Joe Audette
Joe, you are right, I edited the question, hopefully it is more accurate now.Radu Grama
do you have the framework installed on the server or did you deploy it with your app? Is there a web.config file in the wwwroot folder? There should a web.config be and it should have some appsettings for bootstrapping the framework, but those settings depend on the framework existing on the server. also make sure the IIS folder is configured as an application.Joe Audette
.NET 2, 3, 3.5, 4, and 4.5 (no 4.5.1, no 4.5.2, and no 4.6) are installed on that server. Also, dnx-clr-win-x64.1.0.0-beta7 is installed via dnvm, and it is also included as part of the default packaging done by VS2015.Radu Grama
web.config in wwwroot contains: <add key="bootstrapper-version" value="1.0.0-beta7" /><add key="runtime-path" value="..\approot\runtimes" /><add key="dnx-version" value="1.0.0-beta7" /><add key="dnx-clr" value="clr" /><add key="dnx-app-base" value="..\approot\packages\MyApp\1.0.0\root" />, which I believe is standard stuff, it comes straight out of the packaging done by VS2015.Radu Grama

2 Answers

2
votes

403.14 is the error code for not being allowed to list the contents of a directory.

Are you sure that you've set the destination directory up as an application in IIS? That seems like the most likely culprit. Other possibilities are that your application pool is using the wrong version of .NET (something other than what's on the server), or that you've missed a folder your application needs, like App_Data or something.

0
votes

I added a simple test default.aspx page and got an exception that seems to indicate that ASP.NET MVC 6 only runs under IIS 7.5 and later. In terms of system requirements that translates to Windows Server 2008 R2 and later, at least at the time of writing this:

Exception information: 
    Exception type: PlatformNotSupportedException 
    Exception message: IIS 7.5 or higher is required.
   at AspNet.Loader.Error.Bootstrapper_RequiresIIS75()
   at AspNet.Loader.Bootstrapper.LoadApplicationNet45(String appId, String appConfigPath, IProcessHostSupportFunctions supportFunctions, LoadApplicationData* pLoadAppData, Int32 loadAppDataSize, String runtimePackagePath, String appBasePath)
   at AspNet.Loader.Bootstrapper.LoadApplication(String appId, String appConfigPath, IProcessHostSupportFunctions supportFunctions, LoadApplicationData* pLoadAppData, Int32 loadAppDataSize)
   at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
   at System.Web.Hosting.ProcessHost.System.Web.Hosting.IProcessHostLite.ReportCustomLoaderError(String appId, Int32 hr, AppDomain newlyCreatedAppDomain)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Web.Hosting.ApplicationManager.CreateAppDomainWithHostingEnvironment(String appId, IApplicationHost appHost, HostingEnvironmentParameters hostingParameters)   at System.Web.HttpRuntime.HostingInit(HostingEnvironmentFlags hostingFlags, PolicyLevel policyLevel, Exception appDomainCreationException)