Skip to content

Commit 49f1035

Browse files
yxiecalguohan
authored andcommitted
[fast reboot] allow test to replace fast-reboot script on the DUT before rebooting (#975)
- fast-reboot script is an adapted version from 201811 branch. The change is around syncd stop: in 201803 branch, if it is Broadcom platform, request syncd to perform cold shutdown. - Mellanox 201803 branch has a vlan FDB issue causing all vlan IO to flood. Add a knob allow_vlan_flooding to ignore this symptom and continue with fast-reboot. Signed-off-by: Ying Xie <ying.xie@microsoft.com>
1 parent 6a93830 commit 49f1035

4 files changed

Lines changed: 501 additions & 2 deletions

File tree

ansible/roles/test/files/ptftests/advanced-reboot.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ def __init__(self):
144144
self.check_param('dut_stabilize_secs', 30, required=False)
145145
self.check_param('preboot_files', None, required = False)
146146
self.check_param('preboot_oper', None, required = False)
147+
self.check_param('allow_vlan_flooding', False, required = False)
147148
if not self.test_params['preboot_oper'] or self.test_params['preboot_oper'] == 'None':
148149
self.test_params['preboot_oper'] = None
149150

@@ -191,6 +192,8 @@ def __init__(self):
191192
# second is the fast send_in_background
192193
self.dataplane_io_lock = threading.Lock()
193194

195+
self.allow_vlan_flooding = bool(self.test_params['allow_vlan_flooding'])
196+
194197
return
195198

196199
def read_json(self, name):
@@ -1139,6 +1142,8 @@ def wait_dut_to_warm_up(self):
11391142
if not self.asic_state.is_flooding() and elapsed > dut_stabilize_secs:
11401143
break
11411144
if elapsed > warm_up_timeout_secs:
1145+
if self.allow_vlan_flooding:
1146+
break
11421147
raise Exception("Data plane didn't stop flooding within warm up timeout")
11431148
time.sleep(1)
11441149

0 commit comments

Comments
 (0)