基于keepalived的redis系统master双机热备(读数据负载均衡)设(3)

2019-03-10 14:41

} }

real_server 192.168.0.2 6379 { weight 3

notify_up /home/wind/redis_up.sh MISC_CHECK {

misc_path \ misc_timeout 5 } }

real_server 192.168.0.3 6379 { weight 3

notify_up /home/wind/redis_up.sh MISC_CHECK {

misc_path \ misc_timeout 5 } } }

virtual_server 192.168.0.8 6379 { delay_loop 3 lb_algo wrr lb_kind DR

persistence_timeout 30 protocol TCP

real_server 192.168.0.2 6379 { weight 8 TCP_CHECK { connect_timeout 10 nb_get_retry 3

delay_before_retry 3 connect_port 6379 } }

real_server 192.168.0.3 6379 { weight 2 TCP_CHECK { connect_timeout 10 nb_get_retry 3 delay_before_retry 3 connect_port 6379 } }

real_server 192.168.0.4 6379 { weight 2 TCP_CHECK { connect_timeout 10 nb_get_retry 3 delay_before_retry 3 connect_port 6379 } } }

route2的配置文件

! Configuration File for keepalived

global_defs {

notification_email {

# xieqj@bitauto.com #shanghq@bitauto.com }

notification_email_from xieqj@bitauto.com smtp_server mail.bitauto.com smtp_connect_timeout 30 router_id LVS_DEVEL }

vrrp_instance VI_1 { state BACKUP interface eth1 virtual_router_id 100 priority 100 advert_int 1 authentication { auth_type PASS auth_pass 1111 }

virtual_ipaddress { 192.168.87.89 }

#notify_master \}

vrrp_instance VI_2 { state MASTER interface eth1 virtual_router_id 101 priority 151 advert_int 1 authentication {

auth_type PASS auth_pass 1111 }

virtual_ipaddress { 192.168.87.90 } }

virtual_server 192.168.87.89 6379 { delay_loop 3 lb_algo rr lb_kind DR

persistence_timeout 15 protocol TCP

real_server 192.168.87.103 6379 { weight 4

notify_up /home/wind/redis_up.sh MISC_CHECK {

misc_path \ misc_timeout 5 } }

real_server 192.168.87.104 6379 { weight 4

notify_up /home/wind/redis_up.sh MISC_CHECK {

misc_path \ misc_timeout 5 } }

real_server 192.168.87.105 6379 {

weight 4

notify_up /home/wind/redis_up.sh MISC_CHECK {

misc_path \ misc_timeout 5 } } }

virtual_server 192.168.87.90 6379 { delay_loop 3 lb_algo wrr lb_kind DR

persistence_timeout 30 protocol TCP

real_server 192.168.87.104 6379 { weight 8 TCP_CHECK { connect_timeout 10 nb_get_retry 3 delay_before_retry 3 connect_port 6379 } }

real_server 192.168.87.105 6379 { weight 2 TCP_CHECK { connect_timeout 10 nb_get_retry 3 delay_before_retry 3 connect_port 6379


基于keepalived的redis系统master双机热备(读数据负载均衡)设(3).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:笔试题答案-南瑞

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: