Skip to main content

Slurm

What is Slurm?

Types of jobs

  • Interactive jobs
  • Batch jobs

Controlling jobs

Starting an interactive job

srun --job-name sample-job --time 01:00:00 --pty bash -i

Add a batch job

#!/bin/bash
echo "Hello!"
sbatch -p express hello.sh

List all job queues

# By default, it lists jobs by all users
squeue

# If you only want to see your jobs, use the -u option with the $USER environment variable.
squeue -u $USER

Cancel a job

scancel <jobid>

Partition and Nodes

Show all partitions in the cluster.

scontrol show partition

Get list of nodes in a specific partition

sinfo -p short

Additional resources