1

I've built many apps using .NET Core 5 and never had any problem publishing them on any hosting company.

This last project I've started with .NET Core 6 and now it seems it's impossible to make it run.

I've had similar problems before, but we could solve them just by changing the hosting model from "inprocess" to "outofprocess" or the modules from "AspNetCoreModuleV2" to "AspNetCoreModule" in the web.config, but now none of these changes seem to make a difference.

If I publish the web.config with AspNetCoreModuleV2 and InProcess I get

HTTP Error 500.38 - Failed to locate ASP.NET Core app

If I just change the hosting model to OutOfProcess I get

HTTP ERROR 503

And if I remove the V2 from the AspNetCoreModule and leave the hosting method as InProcess or OutOfProcess I get

HTTP Error 502.5 - Process Failure

According to my hosting company the server is compatible to .NET Core 6 and I don't have direct access to IIS. Is there anything I could try to solve this or to at the least discover what the problem is?

Thanks in advance.

Edit: grammar

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Lucas Hoffmann
  • 111
  • 1
  • 6
  • What happens if you go to the server, launch a command prompt, cd to where the app is deployed and then try to manually launch your app via the dotnet command? `dotnet YourApp.dll`? Do you get an error? – mason Mar 02 '23 at 20:35
  • Unfortunately I'm not able to do that. The hosting company only provides access to a control panel for my website (like plesk) and I'm not able to launch a prompt directly from it. – Lucas Hoffmann Mar 02 '23 at 20:45
  • Did you validate that the hosting provider has ASP.NET Core 6 runtime installed? And if not, did you try doing a self contained deployment? – mason Mar 02 '23 at 23:17
  • Please check the Windows EventViewer, we need more details to narrow down this issue. I also [found this thread](https://stackoverflow.com/questions/41590493/iis-fails-to-run-asp-net-core-site-http-error-502-5), you can follow the suggestion to check the logs, and pls update the error details later. – Jason Pan Mar 03 '23 at 04:19
  • @mason I've asked the hosting company and that's what they replied: "We would like to inform you that the server where your account with us supports applications using .NET Core 6.". Since then I've tried hosting an app that I've developed using .NET Core 5 and it worked perfectly, so I guess the problem is really related to .NET Core 6. Yes, I've tried doing a self contained deploy and I get the same error., Is there a way to test if .NET Core 6 is actually installed? – Lucas Hoffmann Mar 03 '23 at 13:58

0 Answers0