I'm currently testing haproxy to load balance our newsletter generation. We build personalized newsletter for our customers.
To do this we use two webservers (identical machines), and one "mail engine". The mail engine makes calls to the webservers, which then returns a personalized html newsletter.
Now the problem, is that one webserver has a cpu load about 75% but the other is only running 15%. Looking at "Session rate" when testing, both server has "Session rate -> Cur" between 3 and 4 the whole time.
But when looking at "Sessions", here the "Sessions -> Cur" has a total of 10, web server 1 has a "Cur" of 8 and the other web server has between 0 and 2.
Why would there be 8 session on the first web server and 0-2 on the other?
Here is my config:
defaults log global mode http option httplog option dontlognull retries 3 option redispatch maxconn 2000 timeout connect 5000 timeout client 50000 timeout server 50000 listen mailgenerator 10.46.70.75:80 mode http stats enable balance roundrobin option httpclose option forwardfor option httpchk HEAD /robots.txt server mail1 192.168.70.11:80 check weight 100 server mail2 192.168.70.12:80 check weight 100