HA-Proxy version 1.5.18 httpcheck

We are on HA-Proxy version 1.5.18, wants to enable http-check ( response code 200) based routing to the backend servers. Wonder if any one have any experience with that

First, you have to enable option httpchk in the backend, then add an expectation on status code like http-check expect status 200
Worth a look: HAProxy version 1.5.19 - Configuration Manual

Hi, thanks for the reply, the following config doesn’t work for me, it still doesn’t seem to be marking down the backend server and is still routing request to the faulty server. please let me know what i am doing wrong here
backend 03_default_listen_device
balance roundrobin
bind-process 1
http-response set-header Strict-Transport-Security max-age=31536000;\ includeSubDomains;\ preload;
option httpchk /device
http-check disable-on-404
server backend2 abc.com:12080 check ssl verify none
server backend1 def.com:12080 check ssl verify none

please ensure you’re formatting your messages correctly. Your example configuration is integrated in the text of the message and it’s hard to parse and understand it.
Second, you did not add the http-check expect status 200 configuration directive I sent you.

Last, you may want to enable the stats page and check the status of the server on the stats page and / or run a curl to the checked URL and check its status.