[Openstack] keepalive can not check the haproxy is down.
Eric_E_Smith at DELL.com
Eric_E_Smith at DELL.com
Mon May 6 10:37:26 UTC 2013
I see you have different netmasks for the VIP on node1 vs. node2; I would also try breaking them out of the vrrp_sync_group and validating at least 1 router will fail independently.
From: Openstack [mailto:openstack-bounces+eric_e_smith=dell.com at lists.launchpad.net] On Behalf Of Lei Zhang
Sent: Monday, May 06, 2013 3:07 AM
To: openstack at lists.launchpad.net
Subject: [Openstack] keepalive can not check the haproxy is down.
Hi Guys,
I am trying to use keepalive and haproxy to work together to improve the HA of the openstack. But I meet following
unexpected issue.
I expect that when the haproxy process is crashed on the MASTER node(checked by chk_haproxy), the second node
will take over the VIP. But when I stop the haproxy process, nothing is happened.
However, when stop the keepalived service, the VIP is set up on the node2 as expected.
So I think the root cause should be the chk_haproxy block. But I have no idea why it doesn't work. Does any body have
ideas?
node1 keepalived.conf
global_defs {
lvs_id LVS_228
}
vrrp_sync_group openstack_haproxy {
group {
v1
v2
}
}
vrrp_script chk_haproxy {
script "killall -0 haproxy"
interval 2
debug
weight 2
}
vrrp_instance v1 {
interface eth0
debug
state MASTER
virtual_router_id 1
priority 101
virtual_ipaddress {
192.168.0.230/24<http://192.168.0.230/24>
}
track_script {
chk_haproxy
}
}
vrrp_instance v2 {
interface eth1
state MASTER
debug
virtual_router_id 2
priority 101
virtual_ipaddress {
10.1.0.30/16<http://10.1.0.30/16>
}
track_script {
chk_haproxy
}
}
node2 keepalived.conf
global_defs {
lvs_id LVS_229
}
vrrp_sync_group openstack_haproxy {
group {
v1
v2
}
}
vrrp_script chk_haproxy {
script "killall -0 haproxy"
interval 2
weight 2
}
vrrp_instance v1 {
interface eth0
state BACKUP
virtual_router_id 1
priority 100
virtual_ipaddress {
192.168.0.230
}
track_script {
chk_haproxy
}
}
vrrp_instance v2 {
interface eth1
state BACKUP
virtual_router_id 2
priority 100
virtual_ipaddress {
10.1.0.30
}
track_script {
chk_haproxy
}
}
--
Lei Zhang
Blog: http://jeffrey4l.github.com
twitter/weibo: @jeffrey4l
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20130506/7be681f2/attachment.html>
More information about the Openstack
mailing list