Skip to content

Commit

Permalink
Fix an issue of all lldp entries take some time to be in DB after reb…
Browse files Browse the repository at this point in the history
…oot in scaling setup. (sonic-net#15731)

Fix an issue of all lldp entries take some time to be in DB after reboot in scaling setup
  • Loading branch information
wumiaont authored and mssonicbld committed Dec 11, 2024
1 parent d092022 commit 2aad1a2
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/lldp/test_lldp_syncd.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,11 +356,6 @@ def test_lldp_entry_table_after_reboot(
):
duthost = duthosts[enum_rand_one_per_hwsku_frontend_hostname]

# Verify LLDP_ENTRY_TABLE keys match show lldp table output at the start of test
keys_match = wait_until(30, 5, 0, check_lldp_table_keys, duthost, db_instance)
if not keys_match:
assert keys_match, "LLDP_ENTRY_TABLE keys do not match 'show lldp table' output"

# reboot
logging.info("Run cold reboot on DUT")
reboot(
Expand All @@ -372,6 +367,12 @@ def test_lldp_entry_table_after_reboot(
safe_reboot=True,
check_intf_up_ports=True
)

# Wait till we have all lldp entries in the DB after reboot. It's found in scaling
# setup this may take some time to happen.
keys_match = wait_until(90, 5, 30, check_lldp_table_keys, duthost, db_instance)
if not keys_match:
assert keys_match, "LLDP_ENTRY_TABLE keys do not match 'show lldp table' output"
lldp_entry_keys = get_lldp_entry_keys(db_instance)
lldpctl_output = get_lldpctl_output(duthost)
show_lldp_table_int_list = get_show_lldp_table_output(duthost)
Expand Down

0 comments on commit 2aad1a2

Please sign in to comment.