HAProxy community

Help for keepalive url


hello to everyone,

I’m a newbie user and am fighting with the keepalive url issue. In few word I have to verify that my web servers
with “GET /topaz/topaz_api/loadBalancerVerify_centers.jsp” answers “Success”.
I tried with httpchk and tcp-check without success, below my attempts:

option httpchk GET /topaz/topaz_api/loadBalancerVerify_centers.jsp
http-check expect rstatus ^Success

option tcp-check send GET /topaz/topaz_api/loadBalancerVerify_centers.jsp
http-check expect rstatus ^Success

at the moment I’m able to work with “fall” and “rise” check option

server gw1 check inter 10s fall 3 rise 2
server gw2 check inter 10s fall 3 rise 2

How can I set to have the check for the return string to disable the host from the balancing ?

Thanks in advanced


I forgot to upload the config, I know it isn’t good but is a starter point and works, need only to make it better and add the check to the return string “Success” for every backend node.

log local2 notice
maxconn 2384

#mode tcp
log global
timeout connect 5000
timeout check 5000
timeout client 30000
timeout server 30000

frontend OMI-users
bind omi10gui.beta.it:443
mode tcp
default_backend OMI-users-backend

frontend OMI-collectors
bind omi10collector.beta.it:383
mode tcp
default_backend OMI-collectors-backend

backend OMI-users-backend
balance roundrobin
stick-table type ip size 200k expire 30m
stick on src
mode tcp
#option tcp-check
#tcp-check send GET /topaz/topaz_api/loadBalancerVerify_centers.jsp
#tcp-check expect rstring ^Success
#option httpchk GET /topaz/topaz_api/loadBalancerVerify_centers.jsp
#http-check expect rstring ^Success
server gw1.beta.it check inter 10s fall 3 rise 2
server gw2.beta.it check inter 10s fall 3 rise 2

backend OMI-collectors-backend
mode tcp
balance roundrobin
server gw1.beta80.it check inter 10s fall 3 rise 2
server gw2.beta80.it check inter 10s fall 3 rise 2