views:

1924

answers:

6

I was wondering about the best practices regarding this? I know there are two ways to use IIS and host multiple websites.

The first is to have an IP for every website

The second is to use host headers, and a single IP Address for IIS

I was wondering which was the best practice, and why one should be preferred over the other?

Thanks!

+1  A: 

I personally separate sites based on the relation to each other. For example all of my business sites share a single IP adddress (1 domain currently). All of my personal/community sites share a second IP address.

The differences can come over time when it comes to sending e-mail as I know that IP comes into play in some blacklisting systems, so if one site with a shared IP address causes problems it CAN cause issues for the other sites using that IP.

I am sure there are other items, reasons, and justifications, but those are at least mine...

Mitchel Sellers
+2  A: 

It's easier to implement and manage SSL if each site has its own IP address/domain name. You simply get a cert for that name and install it on that site. Doing SSL with Host Headers requires a wildcard server certificate that is implemented and synchronized across all sites that share the IP. You also don't have the restriction that all the sites be in the same domain.

tvanfosson
+1  A: 

Personally I find host header configuration makes life very easy for standard web hosting.

I have literally hundreds of sites running of off single IP addresses on a number of servers - both IIS and *nix Apache, all configured as virtual hosts. In a live web hosting environment it makes life easier both in terms of DNS configuration and server configuration.

The only time I used IP based separation is where I want to run sites on different networks and thus serve the traffic of a different network interface.

I've not seen any performance loss with the host header methodology but would like to hear anyone's horror tales - there have to be some out there :-)

WayneDV
A: 

Host headers are prefered because they conserve IPv4 address space. They have been mandatory since HTTP/1.1.

With https things are a little more complex; you need a modern browser that supports the TLS/SSL server_name extension (RFC 4366 and previously RFC 3546). This includes:

  • Opera 8.0 or later
  • Firefox 2.0 or later
  • IE 7 on Vista
  • Google Chrome

Of course your server has to support it. If you want to support earlier browsers and use SSL/TLS, you need to us an IP address per virtual host; as those browsers become obsolete you'll be about to share IP addresses for TLS/SSL.

janm
+1  A: 

Virtual hosting is usually better than separate IP addresses, but your mileage will vary.

This is really a network vs. systems deployment connection. You want to look at the total number of sites and services you will have on a system. You might want them to live on separate network interfaces (hence multiple IP addresses). You might want them to live off bonded physical interfaces.

You might want web applications to run that need to run separately from others because of security reasons.

The other answers above mention other factors, like SSL, organizational boundaries. (Some software does make associations by IP-address, like spam control). There are probably many other factors I have not thought of.

benc