On 23 July 2013 13:47, Claudio M. <hapr...@cmaffio.it> wrote:
> Hi, ive the folowing configuration
>
> backend web1.mi.ext
>         mode http
>         option httpchk
>         balance roundrobin
>         option httplog
>         option http-server-close
>         cookie CLUSTID insert
>         source 0.0.0.0 usesrc clientip
>         server web1b.mi 192.168.0.29:80 cookie web1b.mi check port 80 maxconn 
> 100
>         server web1d.mi 192.168.0.21:80 cookie web1d.mi check port 80 maxconn 
> 100
>         server web1.bk  192.168.0.43:80 cookie web1.bk  check port 80 maxconn 
> 100 backup
>
> where web1.bk is obviously the backup server
>
> I need that when both primary servers go down and web1.bk go online, when 
> web1b.mi and/or web1d.mi go up haproxy not switch to these
>
> Is this possible?

A bit-of-a-hack way to achieve this is to put a high number of
required successes for the non-backup servers' health checks. I.e.
several thousand (or whatever - do the mathS that makes sense for your
situation) in the per-server "rise" setting:
http://cbonte.github.io/haproxy-dconv/configuration-1.4.html#rise

Cheers,
Jonathan
--
Jonathan Matthews
Oxford, London, UK
http://www.jpluscplusm.com/contact.html

Reply via email to