Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[202405][sanity][bgp] Skip default route missing recover for multi-asic (#16264) #16293

Merged
merged 1 commit into from
Jan 2, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions tests/common/plugins/sanity_check/recover.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,12 @@ def adaptive_recover(dut, localhost, fanouthosts, nbrhosts, tbinfo, check_result
action = _recover_services(dut, result)
elif result['check_item'] == 'bgp':
# If there is only default route missing issue, only need to re-announce routes to recover
if ("no_v4_default_route" in result['bgp'] and len(result['bgp']) == 1 or
"no_v6_default_route" in result['bgp'] and len(result['bgp']) == 1 or
# Currently only support single asic
if (dut.facts["num_asic"] == 1 and
("no_v4_default_route" in result['bgp'] and len(result['bgp']) == 1 or
"no_v6_default_route" in result['bgp'] and len(result['bgp']) == 1 or
("no_v4_default_route" in result['bgp'] and "no_v6_default_route" in result['bgp'] and
len(result['bgp']) == 2)):
len(result['bgp']) == 2))):
action = re_announce_routes(localhost, tbinfo["topo"]["name"], tbinfo["ptf_ip"])
else:
action = neighbor_vm_restore(dut, nbrhosts, tbinfo, result)
Expand Down
Loading