Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have an IIS7.5 server (also running SQL Server) which has a server name of (say) dc-db.

On this server, my IIS default site runs correctly on http://localhost and http://dc-db

I want to load on a web app to run at http://management.dc-db

I have created the new site, and attempted to use the following bindings for host name:

  1. management.*
  2. management.dc-db
  3. management.dc-db.local

In all cases, I get the standard Internet Explorer cannot display the webpage

I should note that after each change the site was restarted.

I have read other acticles relating to wildcard subdomains, which is not what I want to do, and couldn't find anything useful in that regard. Happy to be corrected if this is a duplicate.

share|improve this question
    
What happens when you ping management.dc-db? –  Greg Askew Jan 22 '13 at 1:38
    
Ping request could not find management.dc-db –  LuckySpoon Jan 22 '13 at 1:48
1  
Hard to load that web page if the name cannot be resolve to an IP address. That name needs to exist in DNS. If you only need to test it on a local machine, you could use the local hosts file. –  Greg Askew Jan 22 '13 at 1:50
1  
Do NOT use the hosts file on anything other than your local machine and even then only if you can't use DNS. It's a maintenance nightmare. As for DNS, you can create either an A or CNAME record. –  John Gardeniers Jan 22 '13 at 2:21
1  
As far as I understood, dc-db is your server name and not your local domain, right? If so, I advise you to create a local domain, such as lab.local or something like so you may have proper hostnames to bind to: dc-db.lab.local and management.lab.local. Otherwise you won't have a proper DNS zone and may stumble upon another nightmare. –  fboaventura Jan 26 '13 at 3:43

2 Answers 2

up vote 1 down vote accepted
+50

If they run a DNS server: Add a new Forward Lookup Zone, choose primary zone, and add subdomains to this local zone. Add A records for every subdomain you want to use, point them to the machine with the IIS server.

Then you can add the websites to IIS the way you did.

Make sure that all PCs use this DNS server.

This allows you to use any domain name on your local network. Make sure not to overwrite existing ones though, as that would break the original website.

share|improve this answer
    
I'm hoping to achieve without configuring a DNS zone, but I'm thinking this may be the only option. –  LuckySpoon Jan 25 '13 at 9:24
1  
The other option is to use hosts files, but that is a nightmare. –  sorcix Jan 25 '13 at 15:16
    
Agreed on hosts files. –  LuckySpoon Jan 26 '13 at 7:36

What you can do is "Stop" the localhost IIS site and enable the management.dc-db IIS site and then type in localhost. Switch back and forth as needed. As of right now, IIS should complain about duplicate "*" bindings on port 80.

Better option: What you can do is add a second IP address eg. 192.168.0.5 to computer (Open Network and Sharing Center => Change Adapter Settings => Right Click Adapter/Connection => Properties => Highlight Internet Protocol Version 4 TCP/IP4 => Properties => Advanced => IP Settings => Add) Windows 7 in mind, with a static IP set, DHCP will not work.

After all this is done, you go and add New website in IIS. When it asks for binding information, instead of allowing "*" change it to the new IP you created above (192.168.0.5). Type in 192.168.0.5/index.html in url to access secondary site.

Both sites are readily accessible. (site1: localhost, site 2: 192.168.0.5/index.html). Add more IP's for however many sites you add.

share|improve this answer

Your Answer

 
discard

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.