-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathkeepalived.conf
82 lines (77 loc) · 1.41 KB
/
keepalived.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#add the same config for all servers while changing vrrp id ( unique one ) and the vrrpip
global_defs {
enable_script_security
script_user node
}
vrrp_script chk_haproxy {
script "/usr/bin/pkill -0 haproxy"
interval 2
weight 2
}
vrrp_sync_group VG1 {
group {
VI_1
VI_2
VI_X
}
}
vrrp_instance VI_1 {
interface eth0 (local interface)
state MASTER
priority 100
virtual_router_id 10
mcast_src_ip {
server1ip
serverNip
}
virtual_ipaddress {
x.x.x.x/24
}
track_interface {
eth1
}
track_script {
chk_haproxy
}
notify_master /etc/keepalived/ovh-api.js
}
vrrp_instance VI_2 {
interface eth0 (local interface)
state MASTER
priority 100
virtual_router_id 11
mcast_src_ip {
server1ip
serverNip
}
virtual_ipaddress {
x.x.x.x/24
}
track_interface {
eth1
}
track_script {
chk_haproxy
}
notify_master /etc/keepalived/ovh-api.js
}
vrrp_instance VI_X {
interface eth0 (local interface)
state MASTER
priority 100
virtual_router_id 12
mcast_src_ip {
server1ip
serverNip
}
virtual_ipaddress {
x.x.x.x/24
}
track_interface {
eth1
}
track_script {
chk_haproxy
}
notify_master /etc/keepalived/ovh-api.js
}