mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-07-27 11:19:13 +00:00
Merge pull request #17392 from opensourcerouting/fix/backport_17376_10.1
bgpd: Clear stale routes with multiple paths (backport)
This commit is contained in:
commit
7f28c4786a
@ -687,6 +687,11 @@ static void bgp_set_llgr_stale(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
COMMUNITY_NO_LLGR))
|
COMMUNITY_NO_LLGR))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (bgp_attr_get_community(pi->attr) &&
|
||||||
|
community_include(bgp_attr_get_community(pi->attr),
|
||||||
|
COMMUNITY_LLGR_STALE))
|
||||||
|
continue;
|
||||||
|
|
||||||
if (bgp_debug_neighbor_events(peer))
|
if (bgp_debug_neighbor_events(peer))
|
||||||
zlog_debug(
|
zlog_debug(
|
||||||
"%pBP Long-lived set stale community (LLGR_STALE) for: %pFX",
|
"%pBP Long-lived set stale community (LLGR_STALE) for: %pFX",
|
||||||
@ -697,8 +702,6 @@ static void bgp_set_llgr_stale(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
pi->attr = bgp_attr_intern(&attr);
|
pi->attr = bgp_attr_intern(&attr);
|
||||||
bgp_recalculate_afi_safi_bestpaths(
|
bgp_recalculate_afi_safi_bestpaths(
|
||||||
peer->bgp, afi, safi);
|
peer->bgp, afi, safi);
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -715,6 +718,11 @@ static void bgp_set_llgr_stale(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
COMMUNITY_NO_LLGR))
|
COMMUNITY_NO_LLGR))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
if (bgp_attr_get_community(pi->attr) &&
|
||||||
|
community_include(bgp_attr_get_community(pi->attr),
|
||||||
|
COMMUNITY_LLGR_STALE))
|
||||||
|
continue;
|
||||||
|
|
||||||
if (bgp_debug_neighbor_events(peer))
|
if (bgp_debug_neighbor_events(peer))
|
||||||
zlog_debug(
|
zlog_debug(
|
||||||
"%pBP Long-lived set stale community (LLGR_STALE) for: %pFX",
|
"%pBP Long-lived set stale community (LLGR_STALE) for: %pFX",
|
||||||
@ -725,8 +733,6 @@ static void bgp_set_llgr_stale(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
pi->attr = bgp_attr_intern(&attr);
|
pi->attr = bgp_attr_intern(&attr);
|
||||||
bgp_recalculate_afi_safi_bestpaths(peer->bgp,
|
bgp_recalculate_afi_safi_bestpaths(peer->bgp,
|
||||||
afi, safi);
|
afi, safi);
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6214,7 +6214,6 @@ void bgp_clear_stale_route(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
vpn_leak_to_vrf_withdraw(pi);
|
vpn_leak_to_vrf_withdraw(pi);
|
||||||
|
|
||||||
bgp_rib_remove(rm, pi, peer, afi, safi);
|
bgp_rib_remove(rm, pi, peer, afi, safi);
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -6243,7 +6242,6 @@ void bgp_clear_stale_route(struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
pi);
|
pi);
|
||||||
|
|
||||||
bgp_rib_remove(dest, pi, peer, afi, safi);
|
bgp_rib_remove(dest, pi, peer, afi, safi);
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user