Hi all,
we are using haproxy for load balancing and we found interesting bug. We
had 3 servers in cluster. The situation occurs, when only the first one
was up and the others were down and when we had set weights to 20,20,10
for these servers. The trafic was balanced on first UP server and second
DOWN server. Maybe I am mistaken, but I expected that on inactive server
is never routed any trafic.
Affected versions are 1.3.19 and 1.3.23. When I removed weight from
config, balancing was ok.
It is possible that I didn't understood configuration well, but routing
traffic on inactive node is probably not wanted feature :)
Jozef
There is my testing haproxy.cfg causing problem:
===================
global
log 127.0.0.1 local0
log 127.0.0.1 local1 notice
maxconn 4096
chroot /var/lib/haproxy
user haproxy
group haproxy
daemon
defaults
log global
mode http
option httplog
retries 3
option redispatch
timeout connect 5000
timeout client 300000
timeout server 300000
stats enable
stats uri /stats
stats refresh 5s
listen ser-cluster 0.0.0.0:8080
balance url_param USERNAME check_post 4096
option httpchk /app/empty.jsp
server ser2_10 ser2.domain.com:10080 check port 10081 weight 20
# this server was up and it received 50% of requests
server ser1_10 ser1.domain.com:10080 check port 10081 weight 20
# this server was down and it received 50% of requests
server ser3_10 ser3.domain.com:10080 check port 10081 weight 10
# this server was down and it received nothing
option forceclose