NWA Boris
NWA Boris

Reputation: 61

Aspnet core 2.1.4 IIS start issues

I made a simple POC in AspNet Core 2.1.2 a few days ago without any issue. I was able to run it either from IIS Express & local IIS (hosted or started/debugged via Visual Studio).

I updated the project to the latest AspNet Core 2.1.4 yesterday and cannot seem to run any AspNet Core application in my local IIS now.

I created a new project (without https) to be sure the migration wasn't the issue.

About my environment :

Test case :

Once the solution is created, running it directly into IIS Express works. Selecting the other profile named with the application name also works (starts the console and the service correctly)

I then want to host it in my local IIS :

  1. Add a new website with a custom port (5555) and the physical path set to the solution folder (where sits the bin/obj/program.cs/...)
  2. Once created, browsing the site throws me a "Configuration error" : normal, there is no web.config available.
  3. I then right-clic on my project in VS, select "Properties" and "Debug"
  4. I Create a new profile as such : Profile
  5. I create a web.config file containing the following (and will be transformed as I change running profile) : Web.config
  6. The project is not "correctly setup" (correctly as my previous POCs with AspNet Core 2.1.2)

Issues :

Tests

I tried to :

IIS Express & "console" profile still works.

EDIT1 : I also uninstalled everything and tried to revert to 2.1.2 without success (still with the latest VS)

Upvotes: 5

Views: 830

Answers (1)

NWA Boris
NWA Boris

Reputation: 61

I managed to find what was missing :

In "Windows Features", the following element was not ticked : "Internet Information Services" -> "World Wide Web Services" -> "Common HTTP Features" -> "Http Errors"

I know it was ticked before installing AspNet Core SDK/bundle, as detailed error pages were served.

Anyway, as soon as this option was enabled again, I was greated with an error stating I cannot override the parameter XXX since it is locked. I had to set it as read/write in the server Feature Delegation.

Then all went good.

I cannot imagine the "Http Errors" was restored to an untick value by installing the SDK/bundle and didn't unticked myself (again, local computer).

I'll put it on the IIS shenanigans tab...

Upvotes: 1

Related Questions