HAProxy 粘贴表

HAProxy 粘贴表

在 HAProxy 中,我尝试使用随机键值跟踪到特定页面的连接。我使用的配置是:

stick-table type string size 200 store gpc0
acl test_page url_reg -i test.php 
tcp-request inspect-delay 30s
tcp-request content track-sc1 rand if test_page

事实上,条目被添加到了 stick-table 中:

# table: varnish_cluster-01, type: string, size:200, used:10
0x2f05d54: key=1191905894 use=0 exp=0 gpc0=0
0x2ec4524: key=1588367676 use=0 exp=0 gpc0=0
0x34e3ab4: key=1768543047 use=0 exp=0 gpc0=0
0x3b3cd94: key=1938692325 use=0 exp=0 gpc0=0
0x380bcf4: key=2016928663 use=0 exp=0 gpc0=0
0x39535e4: key=2095442698 use=0 exp=0 gpc0=0
0x3cb3824: key=396763764 use=0 exp=0 gpc0=0
0x39d6644: key=500760259 use=0 exp=0 gpc0=0
0x3994e14: key=945137186 use=0 exp=0 gpc0=0
0x34a2284: key=995489922 use=0 exp=0 gpc0=0

但我从后端得到的是空的回应。

知道为什么吗?

我正在尝试实现我在此处描述的内容:HAProxy/Varnish:重定向一定比例的流量

相关内容