LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: ipvsadm and kernel 2.2.22 and apache load balancing

To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: ipvsadm and kernel 2.2.22 and apache load balancing
From: Horms <horms@xxxxxxxxxxxx>
Date: Thu, 24 Oct 2002 18:58:25 +0900
On Thu, Oct 24, 2002 at 11:45:22AM +0200, Romeo Benzoni wrote:
> hi
> 
> Marc-Christian Petersen wrote:
> >hi there,
> >
> >so, now went back to 2.2.19 vanilla + ipvs patch for 2.2.19, compiled the 
> >right ipvsadm again, and the minimal LVS is still _not_ working.
> 
> should also work with 2.4.x
> 
> >
> >Say, can anyone of you really help me to get this LVS running?
> 
> I propose the following setup:
> 
>     __________________________
>    |                          |
>    | Client  192.168.0.1/24   |
>    |__________________________|
>               |
>               |
>               |
>               |
>         192.168.0.2/24
>     __________________________
>    |                          |
>    | Director with LVS NAT    |
>    |__________________________|
> 
>         172.16.0.1/24
>               |
>               |
>               |
>               |
>     __________________________
>    |                          |
>    | RealServer 172.16.0.2/24 |
>    |__________________________|
> 
>       Default gw: 172.16.0.1
> 
> 
> 
> setup of client and realserver should be obvious.
> 
> on the director the commands (for telnet) would be:
> 
> # ipvsadm -A -t 192.168.0.2:23 -s rr
> # ipvsadm -a -t 192.168.0.2:23 -r 172.16.0.2 -m
> # echo "1" >/proc/sys/net/ipv4/ip_forward

I think that you also need to add an iptables rule so that return
packets from the realservers are demasqueraded.

iptables -t nat -A POSTROUTING -j MASQUERADE -s 172.16.0.2/24

In addition, if you wish to use ftp you will need the ip_vs_ftp kernel
modules installed.

> while having two separted ethernet segment you don't have to worry about 
> send/accept icmp redirect like in the mini HOWTO setup.
> 
> If you don't have enough hardware you could even do such a setup using 
> user-mode-linux.

-- 
Horms
        


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