keepalive心跳记录

global_defs {

router_id cse1

}

vrrp_script check_run_mysql {

script "/root/bin/keepalived_check_mysql.sh"

interval 5

}

vrrp_script check_run_service {

script "/root/bin/keepalived_check_service.sh"

interval 5

}

vrrp_sync_group VG1 {

group {

VI_1

}

}

vrrp_sync_group VG2 {

group {

VI_2

}

}

vrrp_instance VI_1 {

state MASTER

interface bond0

virtual_router_id 188

priority 100

advert_int 1

nopreempt

authentication {

auth_type PASS

auth_pass 123456

}

track_script {

check_run_mysql

}

virtual_ipaddress {

192.168.5.55

}

}

vrrp_instance VI_2 {

state MASTER

interface bond1

virtual_router_id 188

priority 100

advert_int 1

nopreempt

authentication {

auth_type PASS

auth_pass 123456

}

track_script {

check_run_service

}

virtual_ipaddress {

10.10.10.180

}

}

猜你喜欢

转载自acooly.iteye.com/blog/1294326
今日推荐