Hi, In the development version, you can deal with the "resolve-net" option which choose a network in priority when the RR dns provides more than one response.
you can write: server s1 app1.domain.com:80 resolvers mydns resolve-net 10.1.0.0/16 server s2 app1.domain.com:80 resolvers mydns resolve-net 10.2.0.0/16 Il your elb is declared on two differents AZ, this option affect the first to the server s1, and the second to the server s2. Thierry On Mon, 2 May 2016 11:49:19 -0700 Ellison Marks <[email protected]> wrote: > So, here's a potentially odd setup. We're trying to set haproxy to proxy > to two separate auto-scaled groups of aws servers. The easiest way we > can think of to do this is to have haproxy send traffic to two elbs, > which will then balance across their respective server groups. The > problem we're running into is that elbs work by pointing to DNS names. I > know haproxy can work with this by using a resolvers section and > referencing it on the server line, but I'm not sure if that handles a > dns name that tries to do round robin dns. > > Basically, the elb dns name will generally return multiple records, to > try and distribute client load across several elbs in several access > zones. Is the server directive smart enough to create multiple balanced > servers for one server line, if the resolved name returns multiple records? > > -- > Sincerely, > Ellison > > Ellison Marks > Scratchspace Inc. > (831) 621-7928 > http://www.scratchspace.com > --

