Use backups if unavailable (not just down)
Posted
by
PriceChild
on Server Fault
See other posts from Server Fault
or by PriceChild
Published on 2011-07-05T14:38:19Z
Indexed on
2012/09/01
9:40 UTC
Read the original article
Hit count: 144
haproxy
Using haproxy, I want:
- A pool of 'main' servers and 'backup' servers, though they don't necessarily have to be in separate pools.
- Each backend has a low 'maxconn' (in this case 1)
- Clients should not wait in a queue. If there are no immediately available servers in the 'main' pool they should be shunted to the 'backup' pool without delay.
Right now I have one backend, 'main' servers have an absurdly high weighting and it 'works'.
acl use_backend
+ connslots
is along the right lines but without the patch in my own answer it isn't perfect.
Bonus points for not requiring a modified haproxy binary.
© Server Fault or respective owner