Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am currently setting up a domain name on windows server 2008r2 iis7

In the local hosts file I have mapped and to the localhost

The iis7 website has the bindings for and

However, from the internet the website only loads up when browsing to

Is there something I am missing to make it work on

share|improve this question
Is your DNS correctly setup so points to your server – Sam Jan 10 '10 at 0:06
Would that just be setting up a forward dns for the A record with the record name as "" for to the IP Address for the server? – asn187 Jan 10 '10 at 0:19
As Sam has said, make sure you set up a DNS A record for the domain that points to the public ip address that you're forwarding to the server. – joeqwerty Jan 10 '10 at 0:19
yes, you should just need an A record for pointing to the IP of the server. – Sam Jan 10 '10 at 1:09
Perfect thanks for confirming. – asn187 Jan 10 '10 at 1:15

As Sam pointed out the host file only handles resolution for the local computer. For everyone else, you need to have a DNS record.

To have both and active, you'll actually need to create two records. The first would be an A record for that points to the IP address of the web site. The second would be a CNAME record in that domain for www that points to the name That way anyone accessing would automatically be sent to

share|improve this answer
You could simply use an A record for both amd instead of using a CNAME. IMHO it's 6 of one and half a dozen of the other, although the use of a CNAME will require an additional lookup for – joeqwerty Jan 10 '10 at 1:34
True, but if you change IPs later on you will have to update both of them. I personally tend towards making things simpler to administrate, on the theory that I will always forget something. – Graham Powell Jan 10 '10 at 2:02
True enough... :) – joeqwerty Jan 10 '10 at 2:08

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.