Skip to content

Commit

Permalink
Added sonic-clears on beginning of stup_neighbors (#14251)
Browse files Browse the repository at this point in the history
  • Loading branch information
alawing authored and mssonicbld committed Aug 27, 2024
1 parent 72890a4 commit ce385f3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/ecmp/test_fgnhg.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ def configure_interfaces(cfg_facts, duthost, ptfhost, vlan_ip):
ptf_to_dut_port_map[ptf_port_id] = port

port_list.sort()
bank_0_port = port_list[:len(port_list)/2]
bank_1_port = port_list[len(port_list)/2:]
bank_0_port = port_list[:len(port_list)//2]
bank_1_port = port_list[len(port_list)//2:]

# Create vlan if
duthost.command('config interface ip add Vlan' + str(DEFAULT_VLAN_ID) + ' ' + str(vlan_ip))
Expand Down Expand Up @@ -111,6 +111,9 @@ def generate_fgnhg_config(duthost, ip_to_port, bank_0_port, bank_1_port):


def setup_neighbors(duthost, ptfhost, ip_to_port):
duthost.shell("sonic-clear fdb all")
duthost.shell("sonic-clear arp")
duthost.shell("sonic-clear ndp")
vlan_name = "Vlan" + str(DEFAULT_VLAN_ID)
neigh_entries = {}
neigh_entries['NEIGH'] = {}
Expand Down

0 comments on commit ce385f3

Please sign in to comment.