LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: Using LVS to replace Netscaler Load Balancer

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: Using LVS to replace Netscaler Load Balancer
From: "Bill Omer" <bill.omer@xxxxxxxxx>
Date: Thu, 18 Jan 2007 15:59:48 -0500
<vip.ip.address> = "1.2.3.4" for this example
<RIP.ip.address> = "4.5.6.7" for this example

On the DIP, first load the ipip.ko kernel module (ensure your kernel
supports tunneled interfaces.
/sbin/ifconfig tunl0  1.2.3.4 netmask 255.255.255.255 up
/sbin/ipvsadm -A -t 1.2.3.4:80 -s rr
/sbin/ipvsadm -a -t 1.2.3.4:80 -r 4.5.6.7:80 -i -w 1     (here the port
designation :80 on the RIP is not really needed, and -i specifies to use the
tunneling method)

On the RIP, load the ipip.ko kernel module; then
/sbin/ifconfig tunl0 1.2.3.4 netmask 255.255.255.255 up

didn't even need to restart apache. it just worked at this point.
It's the very basic LVS-tun solution.

Bill, what iptables rules did you use to get your solution working?

Hope this helps...

Philip


Hi Philip

I'm using the following on all of my real servers:

iptables -t nat -A PREROUTING -d $VIP -p tcp --dport 0:65535  -j REDIRECT
echo 1 > /proc/sys/net/ipv4/ip_forward

I would like to figure out a way to get around the need of having to
do anything at all on the reals, much like the way Netscallers behave.
 But essentially, our setups are very similar.

-Bill

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