Hi all,
I'm using haproxy as a frontend for a server on localhost, and I have one
backend where I want a remote server to be used in high load situations only.
My approach was to set minconn 0 on the backup server and minconn 10 on the
localhost, as well as setting the weights 256:1 for localhost.
This is the configuration:
backend webmon
option httpclose
fullconn 200
server :81 localhost:81 minconn 10 maxconn 80 weight 256 observe layer4
on-error fastinter check
server backup backup:81 minconn 0 maxconn 80 weight 1 observe layer4
on-error fastinter check
This worked on my other web server, however as you can see below it doesn't
seem to work well on this server:
#
pxname,svname,qcur,qmax,scur,smax,slim,stot,bin,bout,dreq,dresp,ereq,econ,eresp,wretr,wredis,status,weight,act,bck,chkfail,chkdown,lastchg,downtime,qlimit,pid,iid,sid,throttle,lbtot,tracked,type,rate,rate_lim,rate_max,check_status,check_code,check_duration,hrsp_1xx,hrsp_2xx,hrsp_3xx,hrsp_4xx,hrsp_5xx,hrsp_other,hanafail,req_rate,req_rate_max,req_tot,cli_abrt,srv_abrt,
webmon,:81,0,0,10,18,80,78387,72020544,5547529640,,0,,0,0,0,0,UP,256,1,0,0,0,11855,0,,1,3,1,,78387,,2,7,,13,L7OK,200,2,0,78384,0,0,0,0,0,,,,54,0,
webmon,backup,0,0,12,27,80,31070,29409975,2209731191,,0,,0,0,0,0,UP,1,1,0,0,0,11855,0,,1,3,2,,31070,,2,4,,16,L7OK,200,766,0,31065,0,1,0,0,0,,,,32,0,
The backup server has about half the sessions the local one has, not even close
to 256:1.
On my other web server it's about 8:1.
Am I missing something? At one point I accidentally set the weights to 256:256,
but that can't influence soft-reloaded haproxies after it can it?
Thanks!
Wout.