Loading...
Loading...
Diagnose HPC runtime and scheduler problems for materials simulations, including MPI/OpenMP/GPU layout, modules, CUDA/Kokkos hints, scratch paths, walltime, job arrays, restart strategy, scheduler portability, and resource mismatch. Use when an ALREADY-SUBMITTED job failed, ran slowly, got killed, or behaved differently on a cluster than on a workstation. To author or vet a NEW submission script before running, use slurm-job-script-generator instead.
npx skill4agent add heshamfs/materials-simulation-skills hpc-runtime-doctor| Input | Description | Example |
|---|---|---|
| Scheduler | SLURM, PBS, LSF, local | |
| Nodes/tasks/threads | Runtime layout | |
| GPUs | Total (whole-job) GPUs via | |
| Symptoms | Observed failure | |
| MPI/OpenMP/GPU use | Parallel modes | |
| Walltime | Requested time | |
| Scratch | Whether scratch is used | |
scripts/hpc_runtime_doctor.pyresource_layouttasks_per_nodetotal_cpusgpusgpus_per_nodediagnosesenvironment_checksretry_planscheduler_noteswarningswarnings--gpus--gpus-per-node--gres=gpu:Ngpus_per_node * nodes--gpuspython3 skills/hpc-deployment/hpc-runtime-doctor/scripts/hpc_runtime_doctor.py \
--scheduler slurm \
--nodes 2 \
--tasks 128 \
--cpus-per-task 2 \
--gpus 4 \
--symptoms oom,slow-gpu \
--uses-mpi \
--uses-openmp \
--uses-gpu \
--jsonwarningsMany MPI ranks per GPU (32.0 ranks/GPU) may reduce GPU efficiency.resource_layouttasks_per_nodetotal_cpustasks * cpus_per_tasktasks_per_nodegpusgpus_per_nodetasks / gpusMany MPI ranks per GPUwarningscpus_per_task=1tasks < nodesenvironment_checksdiagnosescustomcustomretry_plan| Tempting shortcut | Why it's wrong / what to do |
|---|---|
| "It ran without crashing, so the layout is fine." | Run completion is not correctness. Review the |
| "Per-node ranks fit the GPUs, so there's no oversubscription." | Oversubscription is total ranks over total GPUs, not per-node. The script computes |
"I passed | |
| "The job was killed, so it's a physics/solver bug." | |
| "An unknown symptom isn't in the rules, so I can skip it." | Unknown symptoms become |
| "Just change ranks, threads, and the build together to fix it faster." | Changing multiple variables at once makes the failure undiagnosable. The |
--nodes--tasks--cpus-per-task--gpus--gpus-per-node--nodes--tasks--cpus-per-task--symptoms--walltimecustom--scheduler--jsonallowed-toolsRead, Bash, Write, Grep, GlobBashscripts/hpc_runtime_doctor.pyReadGrepGlobWriteevalexecos.systemsubprocessargparsereferences/hpc_runtime_patterns.mdresource_layoutwarningsenvironment_checksdiagnosesretry_planscript_checks--gpus-per-nodetasks_per_node