Error 500.30 - ANCM In-Process Start Failure

HTTP Error 500.30 - ANCM In-Process Start Failure

Easy fixes

Mostly developers find most easiest and quicker way to fix it, so before going in depth I will directly tell you some solutions. After fixing the issue if you are interested to know in more details please go through this article.

This is very generic error being thrown by .Net Core. That's why there would not be any particular solution, but still few solutions are there as below, which you can try and see if that fixes your issue or not.

  1. If you are running your application from Visual Studio and you are facing this error, then right click on your project file in solution explorer and click on "Edit Project File" (if you can't see this option, go to your folder and edit your project file in any editor), it will open .csproj file (if you are using C#) in your visual studio.
    	<PropertyGroup>
    		<TargetFramework>netcoreapp2.2</TargetFramework>
    		<AspNetCoreHostingModel>InProcess</AspNetCoreHostingModel>
    	</PropertyGroup>
    	
    In your .csproj file, change AspNetCoreHostingModel value from InProcess to OutProcess and re-run your application.
  2. If still it doesn't resolve your issue add below in <PropertyGroup>
    		<AspNetCoreModuleName>AspNetCoreModule</AspNetCoreModuleName>
    	
  3. If you dont find <PropertyGroup> in your .csproj file then right click on your Project in solution explorer, click on Properties, go to Debug section, you will find Hosting Model option under Web Server Settings, select "Out Of Process", save it and re-run your project.

What this error means?

Let's see now what this error means. This is very generic error and error it self says that this is "Start Failure" when you are running your project with "InProcess" selection. So there could be few reasons of occurring this error.

ASP.NET Core 2.2 application runs on IIS Express by default from Visual Studio. To enable OutProcess hosting, the csproj element AspNetCoreHostingModel is added to set the hostingModel in .csproj file or web.config file. Also, the web.config points to a new module called AspNetCoreModuleV2 which is needed for InProcess hosting but for OutProcess hosting AspNetCoreModule is needed.

Server on which you are deploying doesn't have ANCMV2, you can't use IIS InProcess hosting. In that case the right behavior is to either install the dotnet hosting bundle on your server or downgrade to the AspNetCoreModule.

How to find root cause

If you want to find root cause of your error then either you can look at "Event Viewer" or you can enable standard error log "stdoutLogEnabled="true"" (if your project doesn't contain web.config then add it manually. Now run your project and check log and you will find root cause.