Repository navigation
fix(orchestrator): bound LDAP job submission to prevent indefinite hang on down nodes - #5807
Open
balajikumaran-c-s wants to merge 1 commit into
Open
balajikumaran-c-s wants to merge 1 commit into
balajikumaran-c-s wants to merge 1 commit into
Conversation
…ng on down nodes V048/V050/V052 (_check_slurm_role_ldap_jobs) submitted Slurm jobs with sbatch --wait --nodelist targeting each mapped compute. When a target compute node was down, Slurm kept the job PENDING (ReqNodeNotAvail) and sbatch --wait blocked indefinitely, hanging the FVT run for hours. Changes: - Check mapped compute readiness (sinfo) before the submission loop. Nodes that are down, drained, unknown or missing are reported as failures and skipped without submitting. - Drop --wait from the LDAP job submission. The job ID is recorded immediately from sbatch --parsable, and the existing bounded _wait_job_state (180 s) polls for completion. - Add timeout 30 to the scancel cleanup command so a hung scheduler cannot block workspace teardown. - Move mapped_compute_readiness to _workload_helpers so both slurm_jobs and slurm_auth modules can import it without cross-importing private functions. Signed-off-by: balajikumaran-c-s <balajikumaran.cs@dell.com>
balajikumaran-c-s
requested review from
RvishankarOMnia,
VenkateswaraVatam,
abhishek-sa1,
snarthan and
sujit-jadhav
as code owners
November 13, 2026 13:31
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
V048, V050, and V052 (
_check_slurm_role_ldap_jobs) submitted Slurm LDAP jobs withsbatch --wait --nodelist=<compute>. When a target compute node was down, Slurm kept the jobPENDING(ReqNodeNotAvail) andsbatch --waitblocked indefinitely, hanging the FVT run for over 3 hours with no timeout or cleanup.Root Cause
sbatch --parsable --wait --nodelist=<down-node>never returns when the target is down because Slurm holds the jobPENDING.remote_command()only has an SSHConnectTimeout(10 s), not an overall command timeout._wait_job_state()(180 s) sits after the blockingsbatch --waitcall, so it is never reached.finallycleanup (scancel + workspace removal) only runs after the call returns, and the job ID is only recorded fromsbatchstdout, so both cleanup and the ID are unreachable during the hang._mapped_compute_readiness.Changes
test/orchestrator/library/functions/_workload_helpers.pymapped_compute_readiness()(moved fromslurm_jobs_pxeboot_func.py, unchanged body) so both modules can import ittest/orchestrator/library/functions/slurm_auth_pxeboot_func.pymapped_compute_readinessandSLURM_JOB_READY_STATES; add_compute_not_ready_reason()helper; check readiness before submission loop; skip down/drained/unknown nodes with a structured FAIL; dropwait=Truesosbatch --parsablereturns the job ID immediately; use existing_wait_job_state()for bounded pollingtest/orchestrator/library/functions/slurm_jobs_pxeboot_func.py_mapped_compute_readiness()definition; import from_workload_helpersinsteadtest/orchestrator/library/vars/pxeboot_vars.pySLURM_JOB_READY_STATEStuple; changeslurm_cancel_jobtotimeout 30 scancel %sWhy this is safe
_ldap_sbatch_commandwithout--wait, records the job ID, and polls_wait_job_state. This fix reuses that proven pattern.submitted and completed and allocated_ok and output_ok and not stderr) are not modified.hostname -scompletes in seconds, so_wait_job_statereturns immediately after the first poll.slurm_jobsto the shared_workload_helpersmodule._mapped_compute_readinessfromslurm_jobs; after the move they import from_workload_helpersinstead.Test plan
test/orchestrator/ut/)py_compile)banditstatic analysis: no new findings