Hi
I would try Jarno's method with the "frontend" rules: simple, effective,
great.
Similar results may achieved with the "backup"s inside each "backend"
section.
Because of the "use_backend" map and a ton of other reasons, this
approach should not fit your case, but... who knows?
backend loggingdc1-elasticsearch-acc
mode http
balance roundrobin
option httplog
option httpchk GET /
option allbackups
server loggingdc1-elasticsearch-01a:9200 10.1.20.22:9200 check
server loggingdc1-elasticsearch-03a:9200 10.1.20.23:9200 check
server loggingdc1-elasticsearch-05a:9200 10.1.20.25:9200 check
server loggingdc2-elasticsearch-02a:9200 10.1.36.23:9200 check backup
server loggingdc2-elasticsearch-04a:9200 10.1.36.25:9200 check backup
server loggingdc2-elasticsearch-06a:9200 10.1.36.26:9200 check backup
Ciao!
.marcoc