Ok. I tested LVS with HAProxy. arp_announce and arp_ignore seem to work well. I have 2 LVS L4 load balancer in front of 2 HAproxy L7 load balancer. On LVS check for 2 haproxy is done using a nanny external script that check ping to haproxies if ping works the script check for uri configured on haproxies like this:
acl backend_down nbsrv(back_end) lt 1 monitor fail if backend_down monitor-uri /custom_check On LVS we test with Quesce Server = no, so if a haproxy is down LVS established connection are immediately redirected to the survivor haproxy. The script also send an email alert for each haproxies availability problem from LVS view. Next days I'll test more extensively haproxy affinity/persistence in regard to LVS distribution algorithm with and without LVS persistence. Please, if you know about issue using such configurations tell me. Thanks a lot PS: can you tell about haproxy email notification issue I asked about ? This is very important, as with such multilevel load balancing, I can put in production only if also haproxy notify about its backend. Roberto -----Original Message----- From: mlist Sent: sabato 18 luglio 2015 11.51 To: 'Baptiste' Cc: Thierry FOURNIER; [email protected] Subject: RE: Load Balancing the Load Balancer Ok. Thank you. I read and tested little more haproxy. As now I use haproxy to balance web applications (http/https). As I can test, for web application load balancing "cookie insert" on all haproxy configuration can handle failover as client connect always with cookie inserted by ne of load balancer. So at failover the new contacted load balancer know where to route request and session works well. Probably also Sticky table works, but with cookie insert there is more independence between LBs. I read about clients problems with more cookie set, is this a real problem or a problem only for old browsers (agents) ? I ask you a last question: do you have experience with LVS L4 load balancer in front of Hhaproxy ? How you resolved VIP arp problem ? As I know the simple solution is to add VIP on lo interface, using arp_announce and arp_ignore. I'm using a CentOS 7 with kernel 3.10.0-229.7.2.el7 Can you point me in the right direction ? Roberto -----Original Message----- From: Baptiste [mailto:[email protected]] Sent: venerdì 17 luglio 2015 21.25 To: mlist Cc: Thierry FOURNIER; [email protected] Subject: Re: Load Balancing the Load Balancer On Wed, Jul 15, 2015 at 1:14 PM, mlist <[email protected]> wrote: >>> Hi, >>> we see there is a new feature of HAProxy, peer and share table >>> (sticky-table). This peer feature can be used to have in synch stick cookie >>> so if one haproxy goes down the other can take over connections ? > > >> Yes, the stick table remember and share each which is sticked to which >> server. You can use any criteria of the connexion, and of course you >> can use a cookie set by your application. > >> In othe way, HAProxy can put his own cookie in the HTTP response and >> use it for the persistance. This mode is useful because you don't need >> to share the stick table and two "unconnected" haproxy can assure the >> high avalaibility without loosing the session affinity. > > > So if we'll use share stick table between 2 HAProxy LB we'll do not need > cookie to maintain backend server sessions and if we'll use cookie we do not > need to share stick table ? in the latter case how the surviving HAProxy know > where to route the request to the correct backend server using some > haproxy.cfg with some beckend server definition ? It does not work like this :) Persistence is based on your client and server capabilities as well as the type of protocol. IE, if you want persistence over POP protocol, then use source IP and a stick table. If you want persistence for a web mail application where clients are browsers and they can use a cookie, then use a cookie set by HAProxy. If you want persistence over a PHP or Java application, without inserting a new cookie, then store cookies generated by the application servers in a stick table you share between your HAProxy... etc... > >>> What is your choice ? > > >> The choice depends of each problem. HAProxy is very rich and permits to >> solve many LB and HA issues. Generally I prefer the simplest solution >> able to solve my issues. > > I mean your choice to take in sync haproxy.cfg file between 2 or more haproxy > LB (rsync, custom script, etc.) rsync or scp... I mean, it's not only a cfg file, but also your SSL certificates, your ACLs, MAPs, etc... Baptiste -- Il messaggio e' stato analizzato alla ricerca di virus o contenuti pericolosi da MailScanner, ed e' risultato non infetto.

