Haproxy负载配置
global log 127.0.0.1 local0 notice maxconn 10240 chroot /usr/haproxy uid 99 gid 99 nbproc 4 daemon pidfile /usr/haproxy/haproxy.piddefaults log global mode http option httplog option dontlognull option forwardfor option httpclose retries 3 option redispatch maxconn 2000 stats uri /haproxy-admin contimeout 5000 clitimeout 50000 srvtimeout 50000listen webcluster 0.0.0.0:80 balance leastconn option httpchk HEAD /index.htm HTTP/1.0 server web1 192.168.xx.xx:81 cookie 1 weight 5 check inter 2000 rise 2 fall 3 server web2 192.168.xx.xx:82 cookie 2 weight 3 check inter 2000 rise 2 fall 3?执行:/usr/haproxy/sbin/haproxy -f /usr/haproxy/conf/haproxy.cfg
验证状态:http://xxx:80/haproxy-admin
?