How does one tell the difference between an HTTP / HTTPS request that is failing in an ASP .NET Core application, and one that's failing from an IIS mis-configuration?

Most of the time IIS and the ASP .NET Core have different logs, and the solution is often just to turn off HTTPS to figure out which is returning the error, but the error messages from IIS just seem to be along the lines of HTTP 500 Internal Server Error in the output of a W3C formatted log message, and they don't specify anything deeper than that.

As far as I can tell, ASP .NET Core applications just sit behind IIS and requests/responses are kind of reverse proxied to the actual application.

I came across the following IIS configuration setting in which you can enable the tracing of failed requests, and it seems to specify that it will gladly log the deeper error messages as HTTP 500 Internal Server Error is mentioned at the bottom of that documentation, but I'm uncertain of this.

  • 1
    What kind of 500? 500.0 or 500.19? Please don't guess before learning the sub-status code, support.microsoft.com/en-ca/help/943891/… – Lex Li Apr 25 '19 at 2:13
  • Do I have to be using the evt logs to get the 0x8007xxx type of error messages? Would they show up in the event viewer application error log? I see a 500.0 error message in my W3C log. – leeand00 Apr 25 '19 at 4:11
  • I tried turning the errors on and tried following this, but I don't know what a 500.0 - Module or ISAPI error occurred. has to do with it. Also now we get a sc-win32-status of 22 which net helpmsg 22 equates to The device does not recognize the command, but I believe you already told me (serverfault.com/questions/963739/…) that these sorts of errors do not mean anything. support.microsoft.com/en-us/help/942031/… – leeand00 Apr 25 '19 at 14:22
  • I'm unable to find an HRESULT (0x8007XXXXX) in the logs...even through I turned them on....but I believe finding that would resolve the issue if we find it in this document: support.microsoft.com/en-us/help/942031/… – leeand00 Apr 25 '19 at 14:24
  • 1
    For 500.0, the next step is to use FRT to learn from where it comes from docs.microsoft.com/en-us/iis/troubleshoot/… – Lex Li Apr 25 '19 at 15:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.