Web-server – Website won’t come up on web server even though it comes up on other machines

hostnameiis-7.5web-serverwebsite

I have a website that I just created from scratch and all I've done is put a index.html file in it with a hello message. If I try to go to the website from the web server itself it won't come up, however if I try to go to it from another machine then it will come up.

The host name is services.trainup.net and pinging this from the command prompt on both the web server and remote machines gives me the correct ip address for the web server.

If I change the binding for the website to bind to localhost then it will load on the web server which would be okay for regular websites but I'm hosting WCF services so the host name has to match what the remote machines will be using for the host name.

Any ideas on why I can reach my website from remote machines but not from the web server itself?

EDIT: To clarify, I am hosting WCF services but I did a test where I created a website (and deleted all other websites including the default one so it's the only website) and just put Index.html in it.

Best Answer

You have a strange problem. Sounds like a DNS issue on the web server but the fact that you can resolve the hostname when pinging from the web server does not make sense...

Although I cannot explain your problem, I have a suggestion that may help. Try adding the hostname to the "hosts" file on your web server found in C:\Windows\System32\drivers\etc.

Edit the "hosts" file in Notepad and add this line -

127.0.0.1 services.trainup.net

The server should look locally to this file to resolve the hostname before attempting lookup on external DNS servers.

Hope it helps!

Related Topic