码迷,mamicode.com
首页 > 其他好文 > 详细

haproxy配置tcp负载均衡

时间:2017-11-10 15:03:10      阅读:242      评论:0      收藏:0      [点我收藏+]

标签:serve   proxy   后台   man   realm   tcp   max   any   plog   

#---------------------------------------------------------------------
# 监控页面
#---------------------------------------------------------------------
listen admin_stats
bind 0.0.0.0:1080
mode http
option httplog
stats refresh 30s
stats uri /stats
stats realm Haproxy Manager
stats auth admin:admin


#---------------------------------------------------------------------
# 后台服务 test frontend which proxys to the backends
#---------------------------------------------------------------------
listen keyservice
bind 0.0.0.0:9996
mode tcp
balance roundrobin
server s1 127.0.0.1:9995 weight 1 maxconn 100000 check inter 10s

 

启动失败,绑定端口失败处理方法
setsebool -P haproxy_connect_any=1

 

haproxy配置tcp负载均衡

标签:serve   proxy   后台   man   realm   tcp   max   any   plog   

原文地址:http://www.cnblogs.com/jiftle/p/7814374.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!