bgpd: Fix nht to properly notice a change - #20986
Conversation
commit: 8dcd0a6 broke path handling in some rare cases. This can be especially seen in bgp evpn processing when a path transitions from !valid to valid. The bgp_evpn_rt5_addpath code is failing occassionally because of this change. Modify the code to intentionally also call bgp_process when the old_path_valid is not the same as the new path being valid. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Greptile SummaryThis PR fixes a regression introduced by commit Changes:
Confidence Score: 5/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[evaluate_paths: iterate paths on bnc] --> B[Record old_path_valid\nfrom BGP_PATH_VALID flag]
B --> C{old_path_valid\n!= bnc_is_valid_nexthop?}
C -- Yes --> D[Update BGP_PATH_VALID flag\nincrement/decrement aggregates\nEVPN import/unimport\nVPN leak update/withdraw]
D --> E[hook_call bgp_nht_path_update]
C -- No --> F[Skip flag update]
E --> G{Trigger bgp_process?}
F --> G
G -- "old_path_valid != bnc_is_valid_nexthop\nOR BGP_NEXTHOP_METRIC_CHANGED\nOR BGP_NEXTHOP_CHANGED" --> H[bgp_process\nre-evaluate bestpath]
G -- None of the above --> I[Skip bgp_process]
style D fill:#d4edda
style H fill:#d4edda
style G fill:#fff3cd
Last reviewed commit: ae614f4 |
|
@Mergifyio backport dev/10.6 |
β Backports have been createdDetails
|
bgpd: Fix nht to properly notice a change (backport #20986)
commit: 8dcd0a6 broke path handling in some rare cases. This can be especially seen in bgp evpn processing when a path transitions from !valid to valid. The bgp_evpn_rt5_addpath code is failing occassionally because of this change. Modify the code to intentionally also call bgp_process when the old_path_valid is not the same as the new path being valid.