Subject: Re: [vserver] Pros and Cons of 32/64bit guests on 64bit host
From: Ed W <lists@wildgooses.com>
Date: Fri, 22 Aug 2008 16:31:45 +0100
Fri, 22 Aug 2008 16:31:45 +0100

> Yes, each guest has its own hostname/domain.  On their arrival the
> device/router can distribute them to their servers respectively based
> on domain NOT on IP
>   
>
>> For exemple Apache using mod_proxy.. Create a virtual host for each
>> website, and reverse proxy the requests to the internal vservers
>> (using
>> their private IP).
>>     
>
> How about other servers, not webserver?
>   


This sort of setup only works on HTTP and a very small number of other 
services. 

You need to go read a book on TCP.  Basically DNS resolves www.abc.com 
to an IP address, the host then makes a connection to the relevant port 
at that IP, passes some data and that's the end of it. 

With HTTP it coincidently happens that part of the data transmitted is 
the name of the website you actually wanted to reach, eg www.abc.com - 
this means that you can actually point lots of connections at a single 
IP, BUT still distinguish the original desired site.  With most other 
protocols all you have is the fact that they connected to you, so it's 
not easy to do virtual servers that way

The point of NAT though is that you can have port 53 on 1.2.3.4 mapped 
back to your DNS server, port 80 on 1.2.3.4 mapped to a completely 
different server doing apache, port 25 mapped to yet another server 
doing mail, etc, etc.  So one IP can be used for multiple machines as 
long as the service is different

Good luck

Ed W



Yes, each guest has its own hostname/domain.  On their arrival the
device/router can distribute them to their servers respectively based
on domain NOT on IP
  

For exemple Apache using mod_proxy.. Create a virtual host for each
website, and reverse proxy the requests to the internal vservers
(using
their private IP).
    

How about other servers, not webserver?
  


This sort of setup only works on HTTP and a very small number of other services. 

You need to go read a book on TCP.  Basically DNS resolves www.abc.com to an IP address, the host then makes a connection to the relevant port at that IP, passes some data and that's the end of it. 

With HTTP it coincidently happens that part of the data transmitted is the name of the website you actually wanted to reach, eg www.abc.com - this means that you can actually point lots of connections at a single IP, BUT still distinguish the original desired site.  With most other protocols all you have is the fact that they connected to you, so it's not easy to do virtual servers that way

The point of NAT though is that you can have port 53 on 1.2.3.4 mapped back to your DNS server, port 80 on 1.2.3.4 mapped to a completely different server doing apache, port 25 mapped to yet another server doing mail, etc, etc.  So one IP can be used for multiple machines as long as the service is different

Good luck

Ed W