Re: HAProxy interface

From: Krzysztof Oledzki <ole#ans.pl>
Date: Mon, 24 Sep 2007 12:40:50 +0200 (CEST)

On Mon, 24 Sep 2007, Nahuel ANGELINETTI wrote:

> Hello,

Hello,

> My first question on this mailing list is :
> does it exist the possibility to select the interface used for "output"
> connections by HAProxy ?
> Like which IP will see background webserver.
> For my configuration the client ip of webservers is the haproxy IP, but if I
> have more than one IP on haproxy server I want to select which IP it uses.

From haproxy-en.txt:

4.1.2) Per-server source address binding


As of versions 1.1.30 and 1.2.3, it is possible to specify a particular source to reach each server. This is useful when reaching backup servers from a different LAN, or to use an alternate path to reach the same server. It is also usable to provide source load-balancing for outgoing connections. Obviously, the same source address is used to send health-checks.

Example :


     # use a particular source to reach both servers
     listen http_proxy 0.0.0.0:65000
         mode http
         balance roundrobin
         server server01 192.168.1.1:80 source 192.168.2.13
         server server02 192.168.1.2:80 source 192.168.2.13

Example :


     # use a particular source to reach each servers
     listen http_proxy 0.0.0.0:65000
         mode http
         balance roundrobin
         server server01 192.168.1.1:80 source 192.168.1.1
         server server02 192.168.2.1:80 source 192.168.2.1


Best regards,

                                 Krzysztof Olędzki Received on 2007/09/24 12:40

This archive was generated by hypermail 2.2.0 : 2007/11/04 19:21 CET