Can't start .NET Core "Hello World" on IIS RRS feed

  • Question

  • User-1124897295 posted

    I have published .NET Core 3.1 Web API "Hello World" application on IIS 8.5 (Windows 2012 R2) with installed ASP.NET Core 3.1 Runtime v3.1.5.

    The folder C:\inetpub\wwwroot\helloWorld has also helloWorld.exe etc.

    In IIS Manager I can see web application "helloWorld". I created application-pool ".NET CLR version" = "No Managed Code", and "Managed pipeline mode" = "Integrated".

    I restarted Server. (as described under https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/?view=aspnetcore-3.1)

    I can start "C:\inetpub\wwwroot\helloWorld\helloWorld.exe" and I see that it runs on localhost:5000 on IIS Server local.

    I can also start application in development environment visual studio https://localhost:44342/api/myControllerName


    - i cant' reach http://localhost/helloWorld/api/myControllerName (Internal Error 500) on local web iis server

    The C:\inetpub\logs is also empty

    What I do wrong and how can I achive this goal?

    Tuesday, June 16, 2020 4:11 AM

All replies

  • User1120430333 posted

    i cant' reach http://localhost/helloWorld/api/myControllerName (Internal Error 500) on local web iis server

    The program threw an exception that was unhandled, IIS swallowed the exception and IIS sent the HTTP 500 error.

    You need to find out what the exception is about.


    Tuesday, June 16, 2020 4:30 AM
  • User-474980206 posted

    IIS does not support asp.net core out of the box. you need to install the AspNetCore core hosting module for IIS


    you will then need asp.net core hosting web.config (only used by the hosting module, not asp.net core) and setup the app domain correctly. see docs. 

    Tuesday, June 16, 2020 7:48 PM
  • User-2054057000 posted

    You just need to install Visual Studio 2019 community edition in your PC. During the installation time it will ask to check in the options. You check the following things:

    1. .NET Core
    2. Web Development
    3. C#

    Then run your project from visual studio itself.

    Wednesday, June 17, 2020 3:05 AM
  • User-1124897295 posted
    The problem was a db connection on live system.
    For windows-autentification use IIS the domain
    That user have I created on live db and get him
    permissions. But it doesn’t work, (login failed).
    Than I change db connection to SQL- user authentication
    and its work.
    I think its a windows domain problem.

    Wednesday, June 17, 2020 3:23 PM