Hi,
we’re using haproxy (version 2.2.9-2+deb11u3) to load balance http proxy requests to a bunch of squid proxies. Persistance is done using stick table, which is working fine.
Configuration snippet:
–snip
peers loba
peer loba3 192.168.1.101:32768
peer loba4 192.168.1.102:32768
frontend fo600
bind 192.168.1.100:8080
mode http
option logasap
default_backend be600
maxconn 200000
backend st_xff_global
stick-table type ip size 10m expire 10h peers loba
backend be600
balance leastconn
stick on hdr(X-Forwarded-For,-2) table st_xff_global
timeout queue 5s
source 192.168.1.100
server proxy1 192.168.2.101:8080 check weight 100
server proxy2 192.168.2.102:8080 check weight 100
server proxy3 192.168.2.103:8080 check weight 100
[more proxies]
– snip
We had a procedure working to manually change the backend a client is using wich the runtime api:
echo “set table st_xff_global key <client ip> data.server_id <new server id>” | socat unix-connect:/var/run/haproxy/admin.sock stdio
This has been working with haproxy version 1.8.19-1+deb10u2 (Debian 10), but since we upgraded, the command changes server_id but server_name remains the same, which has the effect, that the modified entry gets reverted.
Any ideas? Just omitting the server name is not an option because we use it in other scripts (performance and availability monitoring).
Maybe there is a way to edit the server_name value? If I try to do that, I get a “Require a valid integer value to store” message back.
Cheers,
Michael