Work around keepalived split brain
When a host reboots, it's possible for keepalived to come up whilst the host's network is still being reconfigured (which happens asynchronously). This can cause the netfilter it puts in place to fail to see announcements from other members of the cluster, convincing it to bring up the VIP when it already exists on another host. The approach here is crude: every five minutes we cause a reload of keepalived's configuration, which has the side-effect of making it reappraise its netfilters and regenerate them. This is a stopgap measure whilst the underlying causes are bottomed out. Change-Id: Ic0397d79465869b78a72faef8653aedee321a3e2 Partial-fix: 1367742
This commit is contained in:
parent
cc52926f5a
commit
1dc024a63b
|
@ -0,0 +1 @@
|
|||
*/5 * * * * root [ -s /var/run/keepalived.pid ] && kill -HUP $(cat /var/run/keepalived.pid)
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -eux
|
||||
|
||||
# bug#1367742 Stop a confused keepalived from erroneously bringing up a VIP
|
||||
# This is an incredibly clunky approach.
|
||||
install -m 0640 -o root -g root $(dirname $0)/../files/keepalived.crontab /etc/cron.d/keepalived
|
Loading…
Reference in New Issue