From e5d1e72daaf5775e4bf67d812553d4fd8775791a Mon Sep 17 00:00:00 2001 From: vivek Date: Thu, 18 Aug 2016 15:02:49 -0700 Subject: [PATCH] bgpd: Upon interface up (update) only kick-off non-Established peers Any interface flags/parameter change (e.g., MTU, PROMISC flag change) is notified by zebra to clients as an "up" event. BGP literally treats this as the interface coming up and kicks all neighbors on that interface (i.e., directly connected peers). When doing so for IPv4 peers on the interface (numbered or unnumbered /30-/31) or IPv6 numbered peers, peers that may already be Established are also flapped; when doing so for IPv6 unnumbered peers (classic 'neighbor swpX interface' scenario with no configured IP address on interface), only peers not in Established state are processed. This patch fixes the code to ensure that in all cases, only non-Established peers are kicked. Signed-off-by: Vivek Venkatraman Reviewed-by: Don Slice Reviewed-by: Chris Cormier Ticket: CM-12526 Reviewed By: CCR-5119 Testing Done: Manual, bgp-min --- bgpd/bgp_nexthop.c | 1 + 1 file changed, 1 insertion(+) diff --git a/bgpd/bgp_nexthop.c b/bgpd/bgp_nexthop.c index 80495065b0..a58b73e9f3 100644 --- a/bgpd/bgp_nexthop.c +++ b/bgpd/bgp_nexthop.c @@ -236,6 +236,7 @@ bgp_connected_add (struct bgp *bgp, struct connected *ifc) for (ALL_LIST_ELEMENTS (bgp->peer, node, nnode, peer)) { if (peer->conf_if && (strcmp (peer->conf_if, ifc->ifp->name) == 0) && + peer->status != Established && !CHECK_FLAG(peer->flags, PEER_FLAG_IFPEER_V6ONLY)) { if (peer_active(peer)) -- 2.39.5