Change message "Bad Request (Invalid Hostname)" in IIS 6
772
How do I change the message Bad Request (Invalid Hostname) in IIS 6? I would like to be able to change it to Bad Request (Invalid Hostname - SERVERNAME) so I can identify which server gets the request.
Are you saying "which server" in the context of a cluster or something? Or are you instead looking to see what the bad Host: header value is?
Invalid Hostname means that you don't have a website on the server configured to handle requests for whatever host was sent in the Host: header of the http request.
That means that your server (call it SERVERA) is getting a request that looks something like:
GET / HTTP/1.1
Host: myserver.com
Connection: close
...
and you have a DNS record for myserver.com that points to the IP of the SERVERA (so that the request will actually make it to SERVERA). But what you don't have is a web site configured in IIS on SERVERA that is set to accept requests for myserver.com.
Are you saying "which server" in the context of a cluster or something? Or are you instead looking to see what the bad Host: header value is?
Invalid Hostname means that you don't have a website on the server configured to handle requests for whatever host was sent in the Host: header of the http request.
That means that your server (call it SERVERA) is getting a request that looks something like:
and you have a DNS record for myserver.com that points to the IP of the SERVERA (so that the request will actually make it to SERVERA). But what you don't have is a web site configured in IIS on SERVERA that is set to accept requests for myserver.com.