Related Services :

Windows Shared Hosting

Windows Reseller Hosting

Situation :

You uploaded the core web application and encountered with error "HTTP Error 500.21 - Internal Server Error"

Solutions :

There could be several reasons for this error, but the most commonly noted one is the use of an older version of AspNetCoreModule.

Look into your web.config file and look for modules tag

  <remove name="aspNetCore" />
  <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />

In the above example, you will notice AspNetCoreModule, replace it with AspNetCoreModuleV2 

Version 1 was discontinued and removed from the ASP.NET GitHub repo in January 2019 AspNetCoreModule is the IIS Module that enables IIS to run ASP.NET Core 1.x and 2.x applications when they're running in .NET Core.

However, we support ASPNetCoreModuleV2. In our windows shared hosting plan which supports ASP.NET Core 2.0 and later (including ASP.NET Core 3.x, .NET 5, .NET 6, etc). It also supports more features than V1 (such as custom offline messages).

When to use AspNetCoreModule or ASPNetCoreModuleV2?

  • Do you need to run ASP.NET Core application in IIS - Plesk hosted on Netspace Windows Shared Hosting (without running on the .NET Framework)?
    • Yes:
      • Are you targeting ASP.NET Core 1.x?
        • Yes 
          • Use ASPNetCoreModule in your web.config and update to ASP.NET Core 3.1 LTSB pronto.
        • No
          • Use ASPNetCoreModuleV2 in your web.config

      • Are you targeting ASP.NET Core 2.x, ASP.NET Core 3.x, .NET 5 or .NET 6?
        • Yes
          • Use ASPNetCoreModuleV2
        • No
          • Then this KB  is irrelevant to you
    • No
      • You don't need ASPNetCoreModule nor ASPNetCoreModuleV2

In short: There is no reason to be using ASPNetCoreModule ("V1") today.



Was this answer helpful? 0 Users Found This Useful (0 Votes)