On Tue, Aug 30, 2016 at 6:18 AM, Maciej Katafiasz <
mkatafi...@purestorage.com> wrote:

> On 27 August 2016 at 14:32, Tim Düsterhus <t...@bastelstu.be> wrote:
> > Hello
> >
> > I want to run HAProxy 1.6.8 with a backend server that may have multiple
> > A records corresponding to different containers.
> >
> > During testing I noticed that HAProxy only tries to connect to the first
> > A record returned, instead of cycling through the different IP addresses
> > returned (effectively treating every IP as a different backend server,
> > with independent health checks). In case of a timeout the whole backend
> > is treated as DOWN as well, instead of trying the next IP address.
> >
> > The reason for this setup is that it would be easier for me to add and
> > remove backend containers in DNS than generating a new HAProxy
> > configuration and reloading HAProxy whenever something changes.
>
> Be aware though that DNS round-robin reduces the availability of the
> entire setup, since there are no provisions in the protocol for the
> eviction of dead nodes. So unless you're very sure there will never be
> any in your DNS and also have the TTL set to some very low value,
> multiple DNS records will defeat some of the care HAProxy takes to
> ensure it only sends requests to backends that can service them.
>
> Cheers,
> Maciej
>
>
Hmmm, one would think though the backend health check and fail over should
take care of this ... or maybe not???

Anyway, in case you use something like Consul which I mentioned before to
provide the DNS records, then Consul itself will remove the failed node
from the DNS record.

Reply via email to