Skip to content

Slurm Overview

Exercises

  1. Explore your cluster with sinfo

Run sinfo on your cluster. Identify: How many partitions are available? How many nodes are in each partition? What states are the nodes in? Try sinfo --summarize for a compact view, then sinfo --Node --long for per-node detail.

Hint / Solution
# Default summary view
sinfo

# Compact partition summary
sinfo --summarize

# Detailed per-node view
sinfo --Node --long

# Custom format showing partition, nodes, CPUs, memory, and state
sinfo --format="%12P %5a %10l %6D %8t %10C %10m"
You should see at least one partition (often called `batch` or `compute`). Node states like `idle` (available), `alloc` (fully allocated), and `mix` (partially allocated) tell you how busy the cluster is. Expected output: Validated 2026-04-15 on slurm-training-val (Slurm 25.11.4, ParallelCluster 3.15.0).
$ sinfo
PARTITION AVAIL  TIMELIMIT  NODES  STATE NODELIST
batch*       up   infinite      2  idle~ batch-dy-compute-[3-4]
batch*       up   infinite      2   idle batch-dy-compute-[1-2]
debug        up   infinite      2  idle~ debug-dy-small-[1-2]
gpu          up   infinite      1   idle gpu-dy-t4-1
highmem      up   infinite      1  idle~ highmem-dy-large-1

$ sinfo --summarize
PARTITION AVAIL  TIMELIMIT   NODES(A/I/O/T) NODELIST
batch*       up   infinite          0/4/0/4 batch-dy-compute-[1-4]
debug        up   infinite          0/2/0/2 debug-dy-small-[1-2]
gpu          up   infinite          0/1/0/1 gpu-dy-t4-1
highmem      up   infinite          0/1/0/1 highmem-dy-large-1
  1. Check the job queue with squeue

Run squeue to see all jobs in the queue. What information does each column show? Try filtering to just your jobs with squeue --me. If the queue is empty, that is fine -- it means no jobs are running.

Hint / Solution
# View all jobs in the queue
squeue

# View only your own jobs
squeue --me

# Custom format with more detail
squeue --format="%.10i %.12j %.10u %.8T %.10M %.6D %.20R"
Key columns: `JOBID` (unique job number), `PARTITION` (which queue), `NAME` (job name), `USER`, `ST` (state: R=running, PD=pending), `TIME` (elapsed), `NODES`, and `NODELIST(REASON)` (where it is running or why it is waiting). Expected output: Validated 2026-04-15 on slurm-training-val (Slurm 25.11.4, ParallelCluster 3.15.0).
$ squeue
             JOBID PARTITION     NAME     USER ST       TIME  NODES NODELIST(REASON)

$ squeue --me
             JOBID PARTITION     NAME     USER ST       TIME  NODES NODELIST(REASON)

References