Skip to content

Commit 79c91cf

Browse files
authored
Fix the syslog source ip test (sonic-net#17449)
The default connect_timeout is 5s, it's too long for checking the ssh down, ssh could has already recovered in the 5s.
1 parent 3c2bbd9 commit 79c91cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/syslog/test_syslog_source_ip.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ def restore_config_by_config_reload(duthosts, enum_rand_one_per_hwsku_frontend_h
9595
# we need remove mgmt vrf, otherwise it will cause host unreachable
9696
remove_vrf(duthost, VRF_LIST[2])
9797
localhost.wait_for(host=duthost.mgmt_ip, port=SONIC_SSH_PORT, search_regex=SONIC_SSH_REGEX,
98-
state='absent', delay=1, timeout=30)
98+
state='absent', delay=1, connect_timeout=1, timeout=30)
9999
localhost.wait_for(host=duthost.mgmt_ip, port=SONIC_SSH_PORT, search_regex=SONIC_SSH_REGEX,
100100
state='started', delay=2, timeout=180)
101101
config_reload(duthost, safe_reload=True)
@@ -297,7 +297,7 @@ def configure_mgmt_vrf_test_data(self, localhost):
297297
create_vrf(self.duthost, VRF_LIST[2])
298298
# when create mgmt vrf, dut connection will be lost for a while
299299
localhost.wait_for(host=self.duthost.mgmt_ip, port=SONIC_SSH_PORT, search_regex=SONIC_SSH_REGEX,
300-
state='absent', delay=1, timeout=30)
300+
state='absent', delay=1, connect_timeout=1, timeout=30)
301301
localhost.wait_for(host=self.duthost.mgmt_ip, port=SONIC_SSH_PORT, search_regex=SONIC_SSH_REGEX,
302302
state='started', delay=2, timeout=180)
303303

0 commit comments

Comments
 (0)