[BMC][config_reload] Skip swss readiness gate in config_system_checks_passed#25027
Conversation
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
0e70730 to
156c3a9
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
156c3a9 to
2a058b6
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
BMC devices (DEVICE_METADATA.localhost.type == 'NetworkBmc') have no
front-side ASIC. swss/syncd are intentionally not running on BMC, so the
existing readiness gate in config_system_checks_passed() - which waits for
'systemctl show swss.service --property ActiveState' == 'active' - never
passes. Every reload-using test (e.g.
platform_tests/test_reload_config.py::test_reload_configuration[_checks])
times out after 360s with:
AssertionError: System checks did not pass within the allotted time
after config reload.
Use the cached SonicHost.is_bmc() helper (same pattern as tests/bmc/conftest.py,
cacl/test_cacl_function.py, process_monitoring/test_critical_process_monitoring.py)
to short-circuit the swss check on BMC. No shell call, no new dependency,
behavior unchanged on every non-BMC device.
Tracking: PBI 37906237.
Signed-off-by: zitingguo <zitingguo@microsoft.com>
2a058b6 to
33478ba
Compare
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/azp run |
|
Azure Pipelines successfully started running 1 pipeline(s). |
yxieca
left a comment
There was a problem hiding this comment.
Approving: correct, minimally-scoped BMC bug fix.
The swss/orchagent readiness gate is structurally unsatisfiable on BMC (router_type == NetworkBmc, no front ASIC, swss/syncd intentionally not running), so it can only time out the full window. The bypass is gated on the canonical cached is_bmc() helper (no shell call), the non-BMC path is unchanged, and BMC still validates systemctl is-system-running and delayed services — so it is not a hollow pass.
One optional follow-up (non-blocking): if BMC testing runs on any release branch, consider a backport, since the back-port checkboxes are currently unset.
Reviewed by AI agent on behalf of Ying.
|
The VPP test failure was addressed by #25820 |
|
Cherry-pick PR to msft-202608: Azure/sonic-mgmt.msft#1274 |
…_passed (sonic-net#25027) [BMC][config_reload] Skip swss readiness gate in config_system_checks_passed (sonic-net#25027) What: In tests/common/config_reload.py::config_system_checks_passed(), short-circuits the swss/orchagent readiness gate when duthost.is_bmc() is true; the existing multi-asic/single-asic swss block is otherwise unchanged. Why: BMC devices (DEVICE_METADATA.localhost.type == 'NetworkBmc') have no front-side ASIC and intentionally do not run swss/syncd, so the swss ActiveState=="active" gate can never pass. Every reload-using test on BMC (e.g. test_reload_configuration, test_reload_configuration_checks) then times out the full 360s window and fails. How: Wraps the swss readiness block in `if duthost.is_bmc(): skip else: <existing block>`, gated on the canonical cached is_bmc() helper (router_type == 'NetworkBmc', no extra shell call). BMC still validates systemctl is-system-running and delayed services; non-BMC behavior is unchanged. Testing: python3 -m py_compile clean; static review against Komodo BMC failure data. CodeQL, Semgrep, DCO, EasyCLA passing. Approved by yxieca. Fixes #<issue> Signed-off-by: zitingguo <zitingguo@microsoft.com>
…_passed (sonic-net#25027) [BMC][config_reload] Skip swss readiness gate in config_system_checks_passed (sonic-net#25027) What: In tests/common/config_reload.py::config_system_checks_passed(), short-circuits the swss/orchagent readiness gate when duthost.is_bmc() is true; the existing multi-asic/single-asic swss block is otherwise unchanged. Why: BMC devices (DEVICE_METADATA.localhost.type == 'NetworkBmc') have no front-side ASIC and intentionally do not run swss/syncd, so the swss ActiveState=="active" gate can never pass. Every reload-using test on BMC (e.g. test_reload_configuration, test_reload_configuration_checks) then times out the full 360s window and fails. How: Wraps the swss readiness block in `if duthost.is_bmc(): skip else: <existing block>`, gated on the canonical cached is_bmc() helper (router_type == 'NetworkBmc', no extra shell call). BMC still validates systemctl is-system-running and delayed services; non-BMC behavior is unchanged. Testing: python3 -m py_compile clean; static review against Komodo BMC failure data. CodeQL, Semgrep, DCO, EasyCLA passing. Approved by yxieca. Fixes #<issue> Signed-off-by: zitingguo <zitingguo@microsoft.com> Signed-off-by: selldinesh <dinesh.sellappan@keysight.com>
…_passed (sonic-net#25027) [BMC][config_reload] Skip swss readiness gate in config_system_checks_passed (sonic-net#25027) What: In tests/common/config_reload.py::config_system_checks_passed(), short-circuits the swss/orchagent readiness gate when duthost.is_bmc() is true; the existing multi-asic/single-asic swss block is otherwise unchanged. Why: BMC devices (DEVICE_METADATA.localhost.type == 'NetworkBmc') have no front-side ASIC and intentionally do not run swss/syncd, so the swss ActiveState=="active" gate can never pass. Every reload-using test on BMC (e.g. test_reload_configuration, test_reload_configuration_checks) then times out the full 360s window and fails. How: Wraps the swss readiness block in `if duthost.is_bmc(): skip else: <existing block>`, gated on the canonical cached is_bmc() helper (router_type == 'NetworkBmc', no extra shell call). BMC still validates systemctl is-system-running and delayed services; non-BMC behavior is unchanged. Testing: python3 -m py_compile clean; static review against Komodo BMC failure data. CodeQL, Semgrep, DCO, EasyCLA passing. Approved by yxieca. Fixes #<issue> Signed-off-by: zitingguo <zitingguo@microsoft.com> Signed-off-by: selldinesh <dinesh.sellappan@keysight.com>
…_passed (sonic-net#25027) [BMC][config_reload] Skip swss readiness gate in config_system_checks_passed (sonic-net#25027) What: In tests/common/config_reload.py::config_system_checks_passed(), short-circuits the swss/orchagent readiness gate when duthost.is_bmc() is true; the existing multi-asic/single-asic swss block is otherwise unchanged. Why: BMC devices (DEVICE_METADATA.localhost.type == 'NetworkBmc') have no front-side ASIC and intentionally do not run swss/syncd, so the swss ActiveState=="active" gate can never pass. Every reload-using test on BMC (e.g. test_reload_configuration, test_reload_configuration_checks) then times out the full 360s window and fails. How: Wraps the swss readiness block in `if duthost.is_bmc(): skip else: <existing block>`, gated on the canonical cached is_bmc() helper (router_type == 'NetworkBmc', no extra shell call). BMC still validates systemctl is-system-running and delayed services; non-BMC behavior is unchanged. Testing: python3 -m py_compile clean; static review against Komodo BMC failure data. CodeQL, Semgrep, DCO, EasyCLA passing. Approved by yxieca. Fixes #<issue> Signed-off-by: zitingguo <zitingguo@microsoft.com> Signed-off-by: ssithaia-ebay <ssithaian@ebay.com>
Description of PR
BMC devices (
DEVICE_METADATA.localhost.type == 'NetworkBmc') have no front-side ASIC.swss/syncdare intentionally not running there, so the existing readiness gate intests/common/config_reload.py::config_system_checks_passed()ΓÇö which waits forsystemctl show swss.service --property ActiveStateto be"active"ΓÇö never passes.Result: every reload-using test on BMC (e.g.
platform_tests/test_reload_config.py::test_reload_configuration,::test_reload_configuration_checks) times out the full 360 s window and fails with:This PR short-circuits the swss readiness gate when
duthost.is_bmc()is true.SonicHost.is_bmc()is the canonical BMC-detection helper already used bytests/bmc/conftest.py,tests/cacl/test_cacl_function.py,tests/process_monitoring/test_critical_process_monitoring.py, and is implemented as a single cached lookup (self._facts.get('router_type', '') == 'NetworkBmc') ΓÇö no extra shell call, no parser risk. Behavior on every non-BMC device is unchanged.Verified manifestation
R3 baseline on Komodo BMC (build
internal.161861823-bff76049fe, 2026-04-28):test_reload_configuration[host1-komodo-bmc]AssertionError: System checks did not pass within the allotted time after config reload.test_reload_configuration_checks[host1-komodo-bmc]AssertionError: System checks did not pass within the allotted time after config reload on Delayed services: []Both runtimes are dominated by the 360 s
wait_untilwindow whereconfig_system_checks_passed()returnsFalseevery 20 s on the swss check.Summary
Fixes #
Type of change
Back port request
Approach
What is the motivation for this PR?
Stop wasting 6+ minutes per reload-using test on BMC waiting for a service that is intentionally not running.
How did you do it?
Wrapped the existing multi-asic / single-asic swss readiness block with
if duthost.is_bmc(): ... else: <existing block>. No other changes.How did you verify/test it?
python3 -m py_compile tests/common/config_reload.pyclean.test_reload_configuration[host1-komodo-bmc]and::test_reload_configuration_checkson Komodo BMC after merge.Any platform specific information?
Only affects the path where
DEVICE_METADATA.localhost.type == 'NetworkBmc'. No-op everywhere else.Supported testbed topology if it's a new test case?
N/A ΓÇö helper change.
Documentation
N/A
Workitem link: https://msazure.visualstudio.com/One/_workitems/edit/37906237