Differences between SLURM and Torque (PBS)
SLURM vs. Torque (PBS)
|
|
There are a number of differences between SLURM and more common systems like Torque (a variant of PBS). The most important ones are:
-
No need to 'cd $PBS_O_WORKDIR' In SLURM your batchjob starts to run in the directory from which you submitted the script. You do not have to change to that directory with 'cd PBS_O_WORKDIR' like you do in PBS.
-
No need to manually export environment The environment variables defined in your shell at the time you submit your script, will be exported to your batch job (in PBS you have to use the flag '-V' to achieve this). This also means any modules you have loaded before submission will be passed along by srun and sbatch.
-
Location of output files The output and error files are created in their final location immediately, not waiting to be moved until completion, like in PBS. This means you can examine the output and error files from your job while it is running, and they are being created.
Note: per default, SLURM may place other tasks - both your own and others - on the node(s) you are using. It is possible to ask for the entire node, and since SLURM does not separate between your own jobs and the jobs of others, this means the node will also not be shared between your own tasks. This is useful if you, say, need the whole infiniband bandwidth. However, remember that if you allocate the entire node for yourself, even if you only run on one or two cores, then you will still be 'charged' for a whole node from your SNIC allocation, so only do this if you actually need it!
Comparison between SLURM and Torque (PBS)
Comparison of some common commands in SLURM and in Torque (PBS) and Maui.
|
Action |
Slurm |
Torque/PBS |
Maui |
|
Get information about the job |
scontrol show job <jobid> |
qstat -f <jobid> |
checkjob |
|
Display the queue information |
squeue |
qstat |
showq |
|
Delete a job |
scancel <jobid> |
qdel |
|
|
Submit a job |
srun/sbatch/salloc |
qsub |
|
|
Display how many processors are currently free |
|
|
showbf |
|
Display the expected start time for a job |
squeue --start |
|
showstart <jobid> |
|
Display information about available queues/partitions |
sinfo/sshare |
qstat -Qf |
|
|
|