diff options
author | Quentin Young <qlyoung@cumulusnetworks.com> | 2019-08-01 19:38:46 +0200 |
---|---|---|
committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2019-08-02 19:26:05 +0200 |
commit | 2e3d75646ed26c27042383d567450abfabecd080 (patch) | |
tree | 4fc7d05e0a60fdd6813c0c269b869c612bf24e2c | |
parent | zebra: send interface updates when down (diff) | |
download | frr-2e3d75646ed26c27042383d567450abfabecd080.tar.xz frr-2e3d75646ed26c27042383d567450abfabecd080.zip |
vrrpd: try to bind interfaces on if_down notifications
Normally we only opportunistically try to bind interfaces to VRRP
instances upon getting if_add and if_up notifications; now that Zebra
sends if_down notifications when interfaces change while they are down,
we should try to bind when we get those as well.
This solves a bug where VRRP would not bind and activate virtual routers
to valid interfaces because their MACs were changed to VRRP macs while
the interface was down.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
-rw-r--r-- | vrrpd/vrrp.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/vrrpd/vrrp.c b/vrrpd/vrrp.c index 8e6c6389e..da039f7a0 100644 --- a/vrrpd/vrrp.c +++ b/vrrpd/vrrp.c @@ -2133,9 +2133,13 @@ void vrrp_if_down(struct interface *ifp) struct listnode *ln; struct list *vrs; + vrrp_bind_pending(ifp); + vrs = vrrp_lookup_by_if_any(ifp); for (ALL_LIST_ELEMENTS_RO(vrs, ln, vr)) { + vrrp_check_start(vr); + if (vr->ifp == ifp || vr->v4->mvl_ifp == ifp || vr->v6->mvl_ifp == ifp) { DEBUGD(&vrrp_dbg_auto, |