A node needs maintenance, but running jobs must finish. What do you do in Slurm?
Why A is the answer
Drain the node
A draining node takes no new jobs.
In detail
- A draining node takes no new jobs.
- Draining respects running work.
Use case
An illustrative scenario, not a real incident.
A node needs repair, so it is drained. Running jobs finish, and no new ones start.
See it in different ways
flowchart TD A["sbatch: submit"] --> B["squeue: see queue"] B --> C["sinfo: see nodes"] C --> D["scontrol: change state"] D --> E["sacct: see history"]
stateDiagram-v2 [*] --> Idle Idle --> Allocated: job starts Allocated --> Draining: admin drains it Draining --> Drained: last job ends Drained --> Idle: resumed after maintenance
stateDiagram-v2 state "Running jobs" as s0 state "Draining" as s1 state "Drained" as s2 state "Maintenance" as s3 [*] --> s0 s0 --> s1: drain s1 --> s2: jobs finish s2 --> s3 s3 --> [*]
Key point: Drain for maintenance.
Why the other options are wrong
- B. Power it off
- That kills running jobs.
- C. Delete the partition
- That is far too much.
- D. Cancel all users' jobs
- That kills their work.

