Fix HTTP Error 502.5 - ANCM Out-Of-Process Startup Failure in Asp.net Core

/ / 0 Comments

HTTP error 502.5 process failure: Every developer while developing any application, just hates the error screen. It will become a nightmare for the developer if the error message was not useful. Like many of us, Dotnet developers have faced this issue when they are running the Asp.net Core application.

The error message is not much apparent, also this error ANCM Out-Of-Process Startup Failure comes in various scenarios.

I face this error message in two different cases which are as follow:

  1. Migrating application to Asp.net core 2.2
  2. Incorrect setting in appsettings.json at LogLevel

Error Screen:


Case 1: Migrating application to Asp.net core 2.2

I have migrated one of my Asp.net core projects from version 2.1 to Asp.net core 2.2. Well previously same application was running successfully on the local machine, but after migration, it stopped working and gives this error message.

So after quick research, I figured out the problem is not with the application, but with .NET Core Runtime 2.2.5, which is not installed.

Using the below command in the cmd prompt, you can check which version of .NET CORE Runtime is installed.

 dotnet --list-runtimes 

Here's the list of .net core runtime installed when the error occurs as shown in the below image.


Now after installing .NET Core Runtime 2.2.5 from here and run the same cmd displays the list of all installed versions.


As you can see now .NET Core Runtime 2.2.5 is added, which was previously not available on the local machine. Now when I run my newly migrated Asp.net core application it runs successfully, and the error got fixed.

Case 2: Incorrect setting in appsettings.json at LogLevel

In Asp.net core for configuration instead of the web.config file, we use the appsettings.json file. It's an application configuration file used to store configuration settings such as database connections strings, or any other global variables, also we configure the LogLevel setting here.


In my case it is set as warn instead of Warning, hence it displays an error message as HTTP Error 502.5 - ANCM Out-Of-Process Startup Failure. By just modifying the appsettings.json file i.e change value to Warning solved this error.

These 2 scenarios I faced and fixed. If you face the same error message for a different reason, pls share it with us will keep updating this.

Thank you for reading, pls keep visiting this blog and share this in your network. Also, I would love to hear your opinions down in the comments.

PS: If you found this content valuable and want to thank me? 👳 Buy Me a Coffee

Subscribe to our newsletter

Get the latest and greatest from Codepedia delivered straight to your inbox.


Post Comment

Your email address will not be published. Required fields are marked *

0 Comments