I am trying to host our website with IIS on a Windows 2008 R2 Server for the first time. This same server is also the DNS server for our office. I was able to modify the default web site towww.mydomain.com hosted in IIS so I could view the contents fine with the "Default web site" when I browse towww.mydomain.com from a browser on a computer within my network.
Now I am trying to make sure that all non-www prefixes get rewritten to www. I installed the URL Rewrite in IIS downloaded from iis.net and used the default rule SEO for Canonical host Name. I've tried restarting the server after doing this and am unable to make this work. My test is to go to another computer on my network and browse towww.mydomain.com, then hit F5 to make sure it works. It does. Then I try going to mydomain.com and hit F5. I get "
Bad Request - Invalid Hostname
HTTP Error 400. The request hostname is invalid."
I'm not sure what I am doing wrong and it seems like things should be working. Failed Request Tracing Rules doesn't seem to be giving any useful information either from what I can see.
Help??