Oracle云实例中的HAproxy

当我尝试configurationhaproxy.cfg时,一切似乎都可以,但是当我使用浏览器进行testing时,连接非常不稳定,有时会工作,有时会发送错误。 我的configuration文件完成后几个build议的post,也似乎没有平衡请求,因为总是响应相同的服务器。 我的configuration文件是这样的:

————————————————– —————————-

使用httpstesting“真正的负载均衡”

————————————————– —————————-

全局日志127.0.0.1 local0 maxconn 4000守护进程uid 99 gid 99统计信息socket /tmp/haproxy.stats级别admin

默认日志全局超时服务器5s超时连接5s超时客户端5s

前端https_frontend绑定*:8543绑定*:8080绑定*:8081模式tcp default_backend web_server

后端web_server模式tcp余额roundrobin stick-tabletypesbinary len 32大小30k过期30m

acl clienthello req_ssl_hello_type 1 acl serverhello rep_ssl_hello_type 2

tcp-request inspect-delay 5s tcp-request content如果是clienthello,则接受

tcp响应内容接受,如果serverhello坚持payload_lv(43,1)如果clienthello坚持存储响应payload_lv(43,1)如果serverhello

定义后端服务器,最多可处理512个并发连接

server wserver1 192.168.100.10:8543 weight 1 maxconn 512 server wserver2 192.168.100.20:8543 weight 1 maxconn 512 server wserver3 192.168.100.10:8080 weight 1 maxconn 512 server wserver4 192.168.100.20:8080 weight 1 maxconn 512 server wserver5 192.168.100.10:8081 weight 1 maxconn 512 server wserver6 192.168.100.20:8081 weight 1 maxconn 512