General discussion

Locked

Multiple Websites On 1 IP on 1 Server

By gregberry ·
We have w2k server running iis 6, we have two domains, i'll call them domain1.com and domain2.com. We want to host both sites on one server with one ip address. We know this is possible because we have used this setup for about a year. We recently relocated our server from a Co-Location facility to in house. Ever since then it hasn't work. I had to change our IP on our server, but I did not make any changes to the host header information in iis (except for the ip address, which was done automatically).

I tried several different configurations. The way it is configured right now is domain1.com has ip address all unassigned and on port 80 with no hostheader, I have domain2.com setup with ip at all unassigned, port 80 and host header of "domain2.com" (without quotes). I tried setting domain2.com's ip to 192.168.1.5 (which is the lan ip of this server). I also tried setting up a second ip on the nic and setting domain2.com to that then opening the ports up on the router, but that didn't work either.

Any suggestions or ideas?

This conversation is currently closed to new comments.

18 total posts (Page 1 of 2)   01 | 02   Next
| Thread display: Collapse - | Expand +

All Comments

Collapse -

by MikeLazz In reply to Multiple Websites On 1 IP ...

I would start here first. 1.) can you access the domains internally? 2.) make sure that whomever you registered the domains with has the public IP is assigned to your router/firewall. 3.) On the router/firewall, there should be a setting to configure the http request to forward to the internal web server ip.

Collapse -

by gregberry In reply to

Poster rated this answer.

Collapse -

by gregberry In reply to

Bad Link, Not Interested In Code.

Collapse -

by gregberry In reply to Multiple Websites On 1 IP ...

I should have made it clear that the default website is up and running, it's just that when you try to go to domain2.com it opens up domain1.com's site.

Collapse -

by CG IT In reply to Multiple Websites On 1 IP ...

first is best practice on web servers is to have them as stand alone and not on the network. They are notorious for being hacked. If you have that setup and are not running ISA server, just the web server and a router, setup a static IP scheme on the web server with the default gateway as the router and the DNS server as your ISP server. Next configure the router to foward port 80 traffic to the web servers static IP address. Third is create web sites in IIS using all unassigned and port 80 host headers for each web site with the registered domain name. Hosting multiple web sites requires host headers for each site.
Next is DNS resolution. If you have a name server running then you have to make sure that A records exist for both domain name(s). Then make sure your domain name registrar uses your name server for name to IP address resolution.

If you don't have a name server, you can buy a monthly Name Server service from places like Constant Time DNS.

That about sums it up.

Microsoft Technet has some good articles about hosting multiple web sites using IIS. You can check those out as well.

Collapse -

by gregberry In reply to

I respectfully disagree with your best practice of having web servers stand alone from a network. With our web integrated app, it is extremely helpful to have the server on our network. Our router is configured correctly, and we use our ISP for DNS. Please remember that the server is up, everyone can access domain1.com, the only problem is domain1.com's website is coming up if you put domain2.com in your browser. This has nothing to do with DNS, it has to do with IIS settings. By the way when host headers are setup for both domains, neither work.

Collapse -

by gregberry In reply to Multiple Websites On 1 IP ...

Yes we can access domain1.com internally, but not domain2.com. Domain2.com pulls up domain1.com

Collapse -

by Kinetechs In reply to Multiple Websites On 1 IP ...

On the DNS side of things, make sure you have default records setup that point to the IP of the web server. Since your Host Header is the domain name (e.g. domain1.com) and not the FQDN (e.g. www.domain1.com) there must be a default record in the DNS zone for each domain. A default record is an address (A) record with an IP address only...no host name.

Good luck,
Sean

Collapse -

by gregberry In reply to

Poster rated this answer.

Back to Windows Forum
18 total posts (Page 1 of 2)   01 | 02   Next

Related Forums