question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

HTTP Error 500.19 with IIS setup

See original GitHub issue

Describe the bug

Server responds with an HTTP Error 500.19 with an IIS setup after trying to access it from another machine. Full error information:

_ _ _ _
Module IIS Web Core Requested path http://localhost:5000/
Notification Unknown Physical path
Handler Not yet determined Logon method Not yet determined
Error code 0x8007000d Logon user Not yet determined
Config error
Config file \\?\C:\inetpub\wwwroot\BaGet\web.config

Config source: -1: 0:

The error happens both on localhost and remote PC, after first trying to access the server from another PC.

To Reproduce

Steps to reproduce the behavior:

  1. Using version of BaGet.zip 0.1.70
  2. Unpack to C:\inetpub\wwwroot\BaGet\
  3. Follow steps from documentation to install as an IIS, including adding folder permissions.
  4. Access from the server itself to http://localhost:5000/ and observe that the home page works as intended.
  5. Access from another PC on the network to http://servername:5000/ that already has access to other working services on the server (ex.: Jenkins) and observe a 500 internal error.
  6. Access from the server itself again to http://localhost:5000/ and observe an HTTP Error 500.19 with the error information provided earlier.

Expected behavior

Being able to at least access the home page from the server itself.

Additional context

I am basically following the steps in Getting started and IIS setup without touching any configuration file.

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

7reactions
Cocotuscommented, Mar 25, 2019

I had the exact same problem and I got it to work after installing latest NET Core Hosting Tools for IIS and restarting the machine. Before like you I only could call localhost:5000 on IIS server itself. Now I can reach Baget from outside.

Don’t forget to restart because otherwise you will get another HTTP error… Here’s the download I used: https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/?view=aspnetcore-2.2#install-the-net-core-hosting-bundle

3reactions
akrisiuncommented, Oct 20, 2019

I wanna add my 50 cents, because today I spend several hours make to run this project with IIS. Worked only OutOfProcess process hosting model (for CoreModuleV2 version) Finished with working this web.config:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.webServer>
      <handlers> 
          <remove name="aspNetCore" />
          <add name="aspNetCore" path="*" verb="*" 
               modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      </handlers>
      <aspNetCore 
          processPath="dotnet" arguments="./BaGet.dll" 
          stdoutLogEnabled="true" stdoutLogFile=".\logs\stdout" 
          forwardWindowsAuthToken="false"
          hostingModel="OutOfProcess" >
          <!-- hostingModel="InProcess" > -->
          <environmentVariables>
            <environmentVariable name="ASPNETCORE_ENVIRONMENT" value="Production" />
          </environmentVariables>
      </aspNetCore>
  </system.webServer>
  <!-- 
  https://docs.microsoft.com/en-us/aspnet/core/host-and-deploy/iis/?view=aspnetcore-3.0 
  -->
  <location path="." inheritInChildApplications="false">
    <system.webServer>
      <applicationInitialization doAppInitAfterRestart="true" />
    </system.webServer>
  </location> 
  <!-- global Windows/System/InetSrv config reference for .dll:
     <add name="AspNetCoreModuleV2" 
      image="%ProgramFiles%\IIS\Asp.Net Core Module\V2\aspnetcorev2.dll" />
  </globalModules> -->
  
</configuration>
  • Testing script with IIS Express . iis.ps1:
$p = "$PWD\app"
start "http://localhost:7000/"

& "C:\Program Files\IIS Express\iisexpress.exe" /path:$p /port:7000 /trace:error

I hope for someone be usefull info (because baget docs for IIS to short…😛). I was using NugetGallery for 2 last years. Now I moved to this great project. With Docker Desktop version for macOs had no problems to run.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do I resolve "HTTP Error 500.19 - Internal Server ...
Looks like the user account you're using for your app pool doesn't have rights to the web site directory, so it can't read...
Read more >
Troubleshooting HTTP 500.19 Errors in IIS 7
In general, a 500.19 error happens due to invalid configuration data. The IIS configuration system will almost always point to the source of ......
Read more >
[Resolved] HTTP Error 500.19 - Internal Server Error.
This problem occurs because the ApplicationHost.config file or the Web.config file contains a malformed XML element. In this case, part of the ...
Read more >
IIS errors - common codes and messages
The error 500.19 is an internal server error often occurring on a server using Microsoft IIS software. It indicates that the configuration data...
Read more >
HTTP Error 500.19 error after upgrading WhatsUp Gold
This error occurs when there is a problem reading the configuration file for the Web server or Web application. In some cases, the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found