LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

Re: [lvs-users] Unable to load balance two tomcat servers

To: "LinuxVirtualServer.org users mailing list." <lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: Re: [lvs-users] Unable to load balance two tomcat servers
From: Graeme Fowler <graeme@xxxxxxxxxxx>
Date: Sat, 14 Feb 2009 10:09:55 +0000
On Fri, 2009-02-13 at 16:30 -0800, Praveen Sooryanarayana wrote:
> ldirectord will use the same port for the real servers as defined for the
> virtual server when "gate" is used for the real servers.

Yup. That's how "gate" works.

> If I use "masq" for the real servers and have the following configuration,
> 
> virtual=10.10.50.100:80
>         fallback=127.0.0.1:8080
>         real=10.10.50.11:8080 masq
>         real=10.10.50.12:8080 masq
>         service=http
>         request="test.html"
>         receive="It works"
>         scheduler=rr
>         protocol=tcp
>         checktype=negotiate
> 
> the requests get load balanced, but the TCP response has the source as real
> ip with port 8080 and the browser does not accept this response.

That indicates you haven't set the LVS up correctly. In a NAT ("masq")
setting, all return traffic from the realservers has to return via the
director so the NAT can be undone.

The easiest way to do this is to set the default gateway on the
realservers to point at the appropriate corresponding interface on the
director.

This is fundamental, and well documented.

Graeme


_______________________________________________
Please read the documentation before posting - it's available at:
http://www.linuxvirtualserver.org/

LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Send requests to lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
or go to http://lists.graemef.net/mailman/listinfo/lvs-users

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