LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: subnet, Tun questions

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: subnet, Tun questions
From: Wensong Zhang <wensong@xxxxxxxxxxxx>
Date: Fri, 29 Oct 2004 20:47:40 +0800 (CST)

Hi,

On Thu, 28 Oct 2004, Ryan Lovett wrote:

>                                          clients
>                                             |
>                                         internet
>                                             |
>                                         gateway (G)
>                                             |
>      _______________________________________|________________________
>      |         |         |         |                      | | | | | |
>    __|_|__   __|_|__   __|_|__   __|_|__                  | | | | | |
>    |     |   |     |   |     |   |     |                 other clients
>    |  A  |   |  B  |   |  C  |   |  D  |
>    |_____|   |_____|   |_____|   |_____|
> 
> 
> I'd like to setup an LVS for the above where A, B, C, and D are all on the
> same subnet and have two NICs. The only port I need setup is ssh. I was
> wondering if the following is feasible:
> 
>  - A, B, C, D are realservers.
> 
>  - Any client can directly access A, B, C, D.
> 
>  - A is the director.
> 
>  - When any client connects to the second interface on A, they could be
>    sent to B, C, or D depending on load and all LVS traffic is sent to the
>    second interfaces on B, C, and D.
> 
>  - B is a director failover.
> 

Since A, B, C, and D are all on the same network, it is easy to use the
LVS/DR method to balance ssh sessions among them.

And, the Local Node feature can be used, so that A can be both director 
and ssh server. Please read the Local Node page for more information

http://www.linuxvirtualserver.org/docs/LocalNode.html

> What has tripped me up is not understanding the same-subnet issue. As the
> very first step toward implementing this, I initially raised the second
> interface on A (different IP, same subnet) and was then able to connect to
> it via either interface. When I then lowered the second interface, I was
> still able to connect to A on either interface. (the hostnames given to
> eth0 and eth1 were both responsive even though the cable was physically
> unplugged from eth1.)
> 

For the purpose above, you don't need to use the second interface at each 
server.

> I believe LVS-Tun is what I should use since it fits the above contraints
> in the HOWTO. (no port remapping, *realserver network is on internet*,
> realserver default gw (g) is own router) A, B, C, and D all happen to be
> running Linux.
> 
> Is it required that the second interfaces on A, B, C, and D be on a
> different (local) subnet? Otherwise, I don't see how LVS traffic can be
> managed since A, B, C, and D already have a default gateway set to G.
> 
> There are clearly some larger network issues that I don't understand so I'd
> appreciate any guidance on what direction to look into.  
> 
> Thanks for your time,
> Ryan

Regards,

Wensong

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