Skip to content
Snippets Groups Projects
Commit 58b59eaf authored by Roman Sliva's avatar Roman Sliva
Browse files

Update slurm-job-submission-and-execution.md

parent 18d3d49b
No related branches found
No related tags found
No related merge requests found
Pipeline #33209 passed with warnings
...@@ -16,23 +16,20 @@ A `man` page exists for all Slurm commands, as well as `--help` command option, ...@@ -16,23 +16,20 @@ A `man` page exists for all Slurm commands, as well as `--help` command option,
| :------: | :-------------------------------------------------------------------------------------------------------------------------- | | :------: | :-------------------------------------------------------------------------------------------------------------------------- |
| sinfo | View information about nodes and partitions. | | sinfo | View information about nodes and partitions. |
| squeue | View information about jobs located in the scheduling queue. | | squeue | View information about jobs located in the scheduling queue. |
| sacct | Display accounting data for all jobs and job steps in the job accounting log or Slurm database. | | sacct | View information about jobs from Slurm accounting database. |
| scontrol | View or modify jobs, nodes, partitions, reservations, and other Slurm objects. | | scontrol | View or modify jobs, nodes, partitions, reservations, and other Slurm objects. |
| | | |
| sbatch | Submit a batch script to Slurm. | | sbatch | Submit a batch job to Slurm. |
| salloc | Run an interactive job. | | salloc | Run an interactive job. |
| srun | Run parallel tasks. | | srun | Run parallel job. |
| scancel | Cancel job. | | scancel | Cancel job. |
### Job Submission Options ### Job Submission Options
Slurm provides three different commands for job submission: `salloc`, `srun`, and `sbatch`. Each of those serves a slightly different purpose; `salloc` is used to obtain an allocation, `srun` runs parallel jobs (and obtains appropriate allocation first if necessary), and serves as Slurm's native way of executing MPI-enabled applications, and `sbatch` reads a batch script, asks for required allocation, and then executes it. While all of these may be used interchangeably, their specifics make them more useful in different scenarios: Slurm provides three different commands for job submission: `salloc`, `sbatch`, and `srun`. Each of those serves a slightly different purpose;
`salloc` is used to run interactive job - behaviour of this command at IT4Innovation's clusters might differ from behaviour at other clusters, it is alternative to PBS qsub -I command.
| Command | Preferred use case | `sbatch` is used to submit a batch script to Slurm, it is alternative to PBS qsub command used without -I option.
| :-----: | :------------------------------------------------------------------------------ | `srun` behaviour of the command depends on whether it was run from inside the job or from outside, from inside of the job command serves as Slurm's native way of executing MPI-enabled applications, from outside of the job command obtains appropriate allocation first and then run a specified command in parallel.
| sbatch | Production jobs |
| salloc | Interactive jobs, debugging |
| srun | Quick interactive jobs, short analysis of output data, running MPI applications |
## Batch Mode ## Batch Mode
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment