! 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的配置文件的更多相关文章

  1. keepalived+nginx配置文件及检查nginx服务的脚本

    脚本一启动的速度要快一些哦,因为脚本二要判断两次以后才启动哎 这两个一般配合keepalived使用 脚本一: #!/bin/bash #author:fansik #description:chec ...

  2. keepalived.conf 配置文件小结

    vrrp_script vs_mysql_82 {     script "/etc/keepalived/checkMySQL.py -h 192.168.11.82 -P 3306&qu ...

  3. 高可用之keepalived的配置文件详解

    ! Configuration File for keepalived global_defs { notification_email { acassen@firewall.loc failover ...

  4. 配置文件keepalived.conf详解

    keepalived.conf       一个功能比较完整的keepalived 的配置文件,其配置文件keepalived.conf 可以包含三个文本块:全局定义块.VRRP 实例定义块及虚拟服务 ...

  5. keepalived配置文件

    1. 查看进程 ps aux | grep keepalived ,其输出为: [root@lvs-m ~]# ps aux| grep keepalived |grep -v greproot 21 ...

  6. 高可用之KeepAlived(一):基本概念和配置文件分析

    */ .hljs { display: block; overflow-x: auto; padding: 0.5em; color: #333; background: #f8f8f8; } .hl ...

  7. keepalived工作原理和配置文件说明

    keepalived是什么 keepalived是集群管理中保证集群高可用的一个服务软件,其功能类似于heartbeat,用来防止单点故障. keepalived工作原理 keepalived是以VR ...

  8. keepalived原理(主从配置+haproxy)及配置文件详解

    下图描述了使用keepalived+Haproxy主从配置来达到能够针对前段流量进行负载均衡到多台后端web1.web2.web3.img1.img2.但是由于haproxy会存在单点故障问题,因此使 ...

  9. Keepalived 配置文件

    keepalived的配置文件: keepalived只有一个配置文件keepalived.conf,里面主要包括以下几个配置区域,分别是global_defs.              全局定义及 ...

随机推荐

  1. Qt Creator 启动失败 可能的解决办法

    用了一段时间Qt Creator莫名的打开失败   重装一遍,仍然不行: 网上搜到解决办法:删除 ~\AppData\Roaming\QtProject文件夹. linux下:~是/home/Your ...

  2. [BZOJ3199][SDOI2013]escape:半平面交

    分析 好像叫V图什么的. 容易发现,对于每个点,其监视的范围就是这个点与其它所有点的垂直平分线分割平面后的半平面交.由于数据范围很小,所以我们可以直接枚举每个点,使用双端队列求出其监视的范围.若两个点 ...

  3. java 线程池的创建方式

    package com.nf147.Constroller; import java.util.concurrent.ExecutorService; import java.util.concurr ...

  4. 基于Anaconda安装Tensorflow 并实现在Spyder中的应用

    基于Anaconda安装Tensorflow 并实现在Spyder中的应用 Anaconda可隔离管理多个环境,互不影响.这里,在anaconda中安装最新的python3.6.5 版本. 一.安装 ...

  5. HDU 5073 Galaxy (数学)

    Galaxy Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 262144/262144 K (Java/Others)Total Su ...

  6. JavaScript 查看stack trace

    How can I get a JavaScript stack trace when I throw an exception? Edit 2 (2017): In all modern brows ...

  7. React Native商城项目实战08 - 设置“More”界面cell

    1.自定义可复用的cell More/CommonCell.js: /** * 自定义可复用的cell */ import React, { Component } from 'react'; imp ...

  8. React-Native 之 GD (二)自定义共用导航栏样式

    1.自定义导航栏样式 步骤一:从效果图中可以看出,导航栏的样式都差不多,因为我们前面已经设置了 Navigator ,这边的话我们还需要自定义 Navigator 的样式,可以看到所有的 Naviga ...

  9. Week3 - 397. Integer Replacement

    Week3 - 397. Integer Replacement 397.Integer Replacement - Medium Given a positive integer n and you ...

  10. 《Python Data Structures》 Week4 List 课堂笔记

    Coursera课程<Python Data Structures> 密歇根大学 Charles Severance Week4 List 8.2 Manipulating Lists 8 ...