haproxy 配置文件详解 之 配置文件示例
此示例文件在haproxy1.8.20 测试没有问题:
global
log 127.0.0.1 local0 info
maxconn
user nobody
group nobody
daemon
nbproc
pidfile /usr/local/haproxy/logs/haproxy.pid defaults
mode http
retries
timeout connect 10s
timeout client 20s
timeout server 30s
timeout check 5s frontend www
bind *:
mode http
option httplog
option forwardfor
option httpclose
log global
#acl host_www hdr_dom(host) -i www.zb.com
#acl host_img hdr_dom(host) -i img.zb.com
#use_backend htmpool if host_www
#use_backend imgpool if host_img
default_backend htmpool backend htmpool
mode http
option redispatch
option abortonclose
balance static-rr
cookie SESSION_COOKIE insert indirect nocache
option httpchk GET /index.jsp
server 237server 192.168.81.237: cookie server1 weight check inter rise fall
server iivey234 192.168.81.234: cookie server2 weight check inter rise fall backend imgpool
mode http
option redispatch
option abortonclose
balance static-rr
cookie SERVERID
option httpchk GET /index.jsp
server host236 192.168.81.236: cookie server1 weight check inter rise fall listen admin_stats
bind 0.0.0.0:
mode http
log 127.0.0.1 local0 err
stats refresh 30s
stats uri /haproxy-status
stats realm welcome login\ Haproxy
stats auth admin:admin~!@
stats hide-version
stats admin if TRUE
haproxy 配置文件详解 之 配置文件示例的更多相关文章
- zabbix配置文件详解
Zabbix之配置文件详解 zabbix配置文件种类: zabbix_server配置文件zabbix_server.conf zabbix_proxy配置文件zabbix_proxy.conf ...
- nginx高性能WEB服务器系列之四配置文件详解
nginx系列友情链接:nginx高性能WEB服务器系列之一简介及安装https://www.cnblogs.com/maxtgood/p/9597596.htmlnginx高性能WEB服务器系列之二 ...
- Spring 2.5配置文件详解(转)
http://book.51cto.com/art/201004/193743.htm 6.2.3 Spring 2.5配置文件详解 Spring配置文件是用于指导Spring工厂进行Bean生产. ...
- Apache服务的主要目录和配置文件详解
Apache服务的主要目录和配置文件详解 2014-01-14 19:05:14 标签:httpd配置文件详解 apache配置文件 httpd配置文件 apache文件目录 原创作品,允许转载,转载 ...
- haproxy 安装与配置文件详解
本文主要阐述haproxy的安装配置详解,对于它的概念,作用,功能,和其它LB软件的区别,优点,缺点等不再进行说明. 一. haproxy 的安装配置 # cat /etc/redhat-releas ...
- Haproxy均衡负载部署和配置文件详解
HAproxy均衡负载部署和配置文件详解 HAProxy提供高可用性.负载均衡以及基于TCP和HTTP应用的代理,支持虚拟主机,它是免费.快速并且可靠的一种解决方案.根据官方数据,其最高极限支持10G ...
- keepalived原理(主从配置+haproxy)及配置文件详解
下图描述了使用keepalived+Haproxy主从配置来达到能够针对前段流量进行负载均衡到多台后端web1.web2.web3.img1.img2.但是由于haproxy会存在单点故障问题,因此使 ...
- spring配置文件详解--真的蛮详细
spring配置文件详解--真的蛮详细 转自: http://book.51cto.com/art/201004/193743.htm 此处详细的为我们讲解了spring2.5的实现原理,感觉非常 ...
- (原创)LAMP搭建之二:apache配置文件详解(中英文对照版)
LAMP搭建之二:apache配置文件详解(中英文对照版) # This is the main Apache server configuration file. It contains the # ...
随机推荐
- Mysql 错误:Duplicate entry '0' for key 'PRIMARY'
[1]添加数据报错:Duplicate entry '0' for key 'PRIMARY' (1)问题现象 SQL 语句如下: DROP TABLE test_distinct; CREATE T ...
- Django学习——全局templates引用的问题
一.问题在构建网站的时候我们会用到全局的templates处理错误的网页,此时我们需要对urls进行一个映射,使得在使用的时候避免重复调用.在使用的时候还会产生错误代码:第一个是404界面的,第二个是 ...
- linux 定时器日志操作
首先先打开定时器的日志(默认是注释掉的) cron的日志功能使用syslogd服务,不同版本号linux可能装了不同的软件,这里介绍常见的两种: rsyslog-> 位置在 /etc/rsysl ...
- 关于ipad设备滚动条无法滚动的解决办法
天做一个功能在ipad设备上滚动条无法滚动,于是百度了下,在需要产生滚动的div上面加入以下css(-webkit-overflow-scrolling:touch,overfolw:scroll), ...
- SQL 自动生成序号
查询出来的数据的编号,不是按照从1开始的有序进行的,界面上显示想显示有序排序 select RANK() OVER(ORDER BY id ) as ID ,* from reconcilet_det ...
- VirtualBox安装Ubutu出错
今天打算装个虚拟机玩玩,这次没有选择VM.感觉那东西各种破解有点麻烦而且体积也不小呀,所以,这次我选择了稍微点的的VirtualBox. 一路安装虚拟机没有问题,安装完后新建虚拟机都正常,可在启动虚拟 ...
- Linux yum的配置 , python环境管理, nginx搭建简单学习
Linux yum的配置 , python环境管理, nginx搭建简单学习 一丶配置yum的数据仓库 ### yum 工具, 方便,自行解决软件之间的依赖关系. # 配置yum源仓库 (可以使用,清 ...
- 架构师小跟班:推荐一款Java在线诊断工具,arthas入门及使用教程
安装 官方网站: https://alibaba.github.io/arthas/index.html 一.下载arthas-boot.jar,然后用java -jar的方式启动: wget htt ...
- javascript format 字符串 函数
函数实现如下: function format(string) { var args = arguments; var pattern = new RegExp("%([1-" + ...
- android studio学习----偏好设置
主要找到设置的界面:Files->Settings , android studio里面没有preferences 1.字体大小设置 进入后你也许发现字体大小或者样式不符合你的习惯,比如我是觉得 ...