keepalived的配置文件
! Configuration File for keepalived global_defs {
notification_email {
# acassen@firewall.loc
# failover@firewall.loc
# sysadmin@firewall.loc
}
# notification_email_from Alexandre.Cassen@firewall.loc
# smtp_server 192.168.200.1
# smtp_connect_timeout
# router_id LVS_DEVEL
# vrrp_skip_check_adv_addr
# vrrp_strict
# vrrp_garp_interval
# vrrp_gna_interval
} vrrp_instance VI_1 {
state MASTER
interface ens33
virtual_router_id
priority
advert_int
authentication {
auth_type PASS
auth_pass
}
virtual_ipaddress {
192.168.193.252
}
} virtual_server 192.168.193.252 {
delay_loop
lb_algo rr
lb_kind DR
persistence_timeout
protocol TCP real_server 192.168.193.80 {
weight
HTTP_GET {
url {
path /
state_code
}
connect_timeout
nb_get_retry
delay_before_retry
}
}
} virtual_server 192.168.193.252 {
delay_loop
lb_algo rr
lb_kind DR
persistence_timeout
protocol TCP real_server 192.168.193.81 {
weight
HTTP_GET {
url {
path /
state_code
}
connect_timeout
nb_get_retry
delay_before_retry
}
}
}
#virtual_server 10.10.10.2 {
# delay_loop
# lb_algo rr
# lb_kind NAT
# persistence_timeout
# protocol TCP
#
# sorry_server 192.168.200.200
#
# real_server 192.168.200.2 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#
# real_server 192.168.200.3 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334c
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334c
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#}
#
#virtual_server 10.10.10.3 {
# delay_loop
# lb_algo rr
# lb_kind NAT
# persistence_timeout
# protocol TCP
#
# real_server 192.168.200.4 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#
# real_server 192.168.200.5 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#}
node2
! Configuration File for keepalived global_defs {
notification_email {
# acassen@firewall.loc
# failover@firewall.loc
# sysadmin@firewall.loc
}
# notification_email_from Alexandre.Cassen@firewall.loc
# smtp_server 192.168.200.1
# smtp_connect_timeout
# router_id LVS_DEVEL
# vrrp_skip_check_adv_addr
# vrrp_strict
# vrrp_garp_interval
# vrrp_gna_interval
} vrrp_instance VI_1 {
state BACKUP
interface ens33
virtual_router_id
priority
advert_int
authentication {
auth_type PASS
auth_pass
}
virtual_ipaddress {
192.168.193.252
}
} virtual_server 192.168.193.252 {
delay_loop
lb_algo rr
lb_kind DR
persistence_timeout
protocol TCP real_server 192.168.193.80 {
weight
HTTP_GET {
url {
path /
state_code
}
connect_timeout
nb_get_retry
delay_before_retry
}
}
} virtual_server 192.168.193.252 {
delay_loop
lb_algo rr
lb_kind DR
persistence_timeout
protocol TCP real_server 192.168.193.81 {
weight
HTTP_GET {
url {
path /
state_code
}
connect_timeout
nb_get_retry
delay_before_retry
}
}
}
#virtual_server 10.10.10.2 {
# delay_loop
# lb_algo rr
# lb_kind NAT
# persistence_timeout
# protocol TCP
#
# sorry_server 192.168.200.200
#
# real_server 192.168.200.2 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#
# real_server 192.168.200.3 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334c
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334c
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#}
#
#virtual_server 10.10.10.3 {
# delay_loop
# lb_algo rr
# lb_kind NAT
# persistence_timeout
# protocol TCP
#
# real_server 192.168.200.4 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#
# real_server 192.168.200.5 {
# weight
# HTTP_GET {
# url {
# path /testurl/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl2/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# url {
# path /testurl3/test.jsp
# digest 640205b7b0fc66c1ea91c463fac6334d
# }
# connect_timeout
# nb_get_retry
# delay_before_retry
# }
# }
#}
keepalived的配置文件的更多相关文章
- keepalived+nginx配置文件及检查nginx服务的脚本
脚本一启动的速度要快一些哦,因为脚本二要判断两次以后才启动哎 这两个一般配合keepalived使用 脚本一: #!/bin/bash #author:fansik #description:chec ...
- keepalived.conf 配置文件小结
vrrp_script vs_mysql_82 { script "/etc/keepalived/checkMySQL.py -h 192.168.11.82 -P 3306&qu ...
- 高可用之keepalived的配置文件详解
! Configuration File for keepalived global_defs { notification_email { acassen@firewall.loc failover ...
- 配置文件keepalived.conf详解
keepalived.conf 一个功能比较完整的keepalived 的配置文件,其配置文件keepalived.conf 可以包含三个文本块:全局定义块.VRRP 实例定义块及虚拟服务 ...
- keepalived配置文件
1. 查看进程 ps aux | grep keepalived ,其输出为: [root@lvs-m ~]# ps aux| grep keepalived |grep -v greproot 21 ...
- 高可用之KeepAlived(一):基本概念和配置文件分析
*/ .hljs { display: block; overflow-x: auto; padding: 0.5em; color: #333; background: #f8f8f8; } .hl ...
- keepalived工作原理和配置文件说明
keepalived是什么 keepalived是集群管理中保证集群高可用的一个服务软件,其功能类似于heartbeat,用来防止单点故障. keepalived工作原理 keepalived是以VR ...
- keepalived原理(主从配置+haproxy)及配置文件详解
下图描述了使用keepalived+Haproxy主从配置来达到能够针对前段流量进行负载均衡到多台后端web1.web2.web3.img1.img2.但是由于haproxy会存在单点故障问题,因此使 ...
- Keepalived 配置文件
keepalived的配置文件: keepalived只有一个配置文件keepalived.conf,里面主要包括以下几个配置区域,分别是global_defs. 全局定义及 ...
随机推荐
- 洛谷P1077 摆花——题解
题目传送 题目大意:有按顺序放的n种花,相同种类的花放一起,每种花最多放ai盆,共放了m盆花,求放花方案数. 求方案个数一般有以下思路:1.搜索:2.递推/动态规划:3.贪心:4.分治... 玄学估计 ...
- CCPC E Problem Buyer
题目描述 有一些区间,还有一些点. 问最小的k使得选出任意k个区间,每个点都可以匹配上区间,一个区间只能匹配一次. 题解 考虑对于每一个点,我们有\(x\)个区间包含它,那么答案的一个下界是\(n-x ...
- 170817关于Listener的知识点
1. Listener 监听器简介 Listener是JavaWeb中三大组件之一.Servlet.Filter.Listener ...
- 关于跨域踩的坑,浏览器 status code为200,但实际上是跨域了
背景 后端使用Nginx并更改本地host文件,起本地服务.将aaa.bbbb.com代理至本地IP地址(10.26.36.156).使用$.ajax调用后端restful接口,要求content-t ...
- 10 Django与Ajax
知识预览 1. Ajax 2. 文件上传 Ajax Ajax简介 AJAX(Asynchronous Javascript And XML)翻译成中文就是“异步Javascript和XML”.即使用J ...
- qbzt day6 下午 模拟赛
我太菜了 T2 给定一张有向图,每个点有点权.试找到一条路径,使得该路径上的点权最 大值减去点权最小值最大,问这个差最大是多少. 话说这个题第一个想到的思路是tarjan缩点+拓扑排序来着... ...
- (转)datagridview 自定义列三步走
本文转载自:http://blog.csdn.net/zx13525079024/article/details/4814642 我们如果想自定义实现datagridview的某列,例如是datagr ...
- (转)用C#实现实现简单的 Ping 的功能,用于测试网络是否已经连通
本文转载自:http://blog.csdn.net/xiamin/archive/2009/02/14/3889696.aspx 用C#实现实现简单的 Ping 的功能,用于测试网络是否已经联通 1 ...
- mysql慢查询解析-linux命令
使用mysqldumpslow 命令可以解析mysql慢查询日志,mysqldumpslow的参数如下: -s ,是按照任何方式排序,c.t.l.r分别是按照记录次数.时间.查询时间.返回的记录数 来 ...
- 【python+selenium自动化】基于Autolt实现上传
在UI自动化过程中,总会遇到文件上传的操作,一般的,标签为input,可以直接使用sendkeys 如果他仅仅是一个button,那则无法直接sendkeys,则需要用到autoIT这个工具 基于Au ...