LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

RE: LVS & Multiple DSL Line

To: Jon Oringer <jon@xxxxxxxxxxxxx>
Subject: RE: LVS & Multiple DSL Line
Cc: "Ian S. McLeod" <ian@xxxxxxxxxxx>, lvs-users@xxxxxxxxxxxxxxxxxxxxxx
From: "Ian S. McLeod" <ian@xxxxxxxxxxx>
Date: Thu, 6 Jul 2000 15:34:48 -0700 (PDT)
> Wayne: All servers will be Linux (RedHat) based.
> 
> Ian,all: how can a request come through 1 dsl line, and a response
> through another?  Isn't this impossible?   These 2 lines have 2 different
> IP addresses - if a client requests a page through 1 IP address, how will
> they know to receive the response through another?

Disclaimer: All my experience is with LVS in DR mode.  

However, I'll try to explain my understanding.  Consider the following
simplified example:

1 Director on DSL line 1
eth0   - 10.1.1.10/24
eth0:0 - 10.1.1.20/24 (This is the VIP)

(Your DSL provider should be able to give you 2 IPs on a single line.)

1 Real server on DSL line 2
eth0   - 10.1.2.10/24
tunl0  - 10.1.1.20/32 (Again, the VIP)

As you would expect, the two servers are on distinct subnets.

1) All packets with a destination address of the VIP will find their way
to the load balancer box.  (The routing set up by your DSL provider takes
care of this.)

2) The load balancer will forward all port 80 traffic for the VIP to the
real server using the IP tunnel.  (Again, this could be done through the
DSL lines or through a backend network depending of how you set it up.)

3) The IP stack on the real server will accept these packets since it has
a local interface (tunl0) that matches the VIP.

4) When the real server generates response packets it will set the source
IP of these packets to the VIP (which was the destination IP of the
incoming packets.)

5) The real server will forward these response packets to it's default GW
(through DSL line 2).  (** It may be that the GW router will refuse to
accept these packets based on their source address.  If this is the case
you'll need to have your DSL provider modify the config on their router.)

Note that incoming packets always go to the load balancer first & are then
forwarded to the real servers.


-Ian



<Prev in Thread] Current Thread [Next in Thread>