Skip to content

Commit

Permalink
Merge pull request #66 from Danzelot/slurm
Browse files Browse the repository at this point in the history
Slurm parameter overview section
  • Loading branch information
bast committed Oct 24, 2019
2 parents 63694a4 + c9cfb69 commit 8dac34c
Show file tree
Hide file tree
Showing 4 changed files with 85 additions and 3 deletions.
1 change: 1 addition & 0 deletions index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ HPC-UiT Services User Documentation
jobs/interactive
jobs/monitoring
jobs/running_mpi_jobs
jobs/slurm_parameter
jobs/environment-variables
jobs/torque_slurm_table

Expand Down
2 changes: 1 addition & 1 deletion jobs/interactive.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@

.. _interactive:

Interactive jobs
================
Expand Down
81 changes: 81 additions & 0 deletions jobs/slurm_parameter.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
.. _slurm_parameter:

SLURM Workload Manager
=======================

SLURM is the workload manager and job scheduler used for Stallo.

There are two ways of starting jobs with SLURM; either interactively with ``srun``
or as a script with ``sbatch``.

Interactive jobs are a good way to test your setup before you put it into a script
or to work with interactive applications like MATLAB or python.
You immediately see the results and can check if all parts behave as you expected.
See :ref:`interactive` for more details.

SLURM Parameter
-----------------

SLURM supports a multitude of different parameters.
This enables you to effectivly tailor your script to your need when using Stallo
but also means that is easy to get lost and waste your time and quota.

The following parameters can be used as command line parameters with ``sbatch`` and
``srun`` or in jobscript, see :ref:`job_script_examples`.
To use it in a jobscript, start a newline with ``#SBTACH`` followed by the parameter.
Replace <....> with the value you want, e.g. ``--job-name=test-job``.


Basic settings:
+++++++++++++++

============================= ===============================================================================
Parameter Function
============================= ===============================================================================
--job-name=<name> Job name to be displayed by for example ``squeue``
--output=<path> | Path to the file where the job (error) output is written to
--mail-type=<type> | Turn on mail notification; type can be one of BEGIN, END, FAIL, REQUEUE or ALL
--mail-user=<email_address> Email address to send notifications to
============================= ===============================================================================


Requesting Resources
+++++++++++++++++++++

============================= ============================================================================================================================
Parameter Function
============================= ============================================================================================================================
--time=<d-hh:mm:ss> Time limit for job. Job will be killed by SLURM after time has run out. Format days-hours:minutes:seconds
--nodes=<num_nodes> Number of nodes. Multiple nodes are only useful for jobs with distributed-memory (e.g. MPI).
--mem=<MB> Memory (RAM) per node. Number followed by unit prefix, e.g. 16G
--mem-per-cpu=<MB> Memory (RAM) per requested CPU core
--ntasks-per-node=<num_procs> Number of (MPI) processes per node. More than one useful only for MPI jobs. Maximum number depends nodes (number of cores)
--cpus-per-task=<num_threads> CPU cores per task. For MPI use one. For parallelized applications benchmark this is the number of threads.
--ntasks-per-core=1 Disables hyperthreading.
--ntasks-per-core=2 Enables hyperthreading. Only useful in special circumstances.
--exclusive Job will not share nodes with other running jobs. You will be charged for the complete nodes even if you asked for less.
============================= ============================================================================================================================


Accounting
+++++++++++++++++++++
See also :ref:`label_partitions`.

================== ==========================================================================================================
Parameter Function
================== ==========================================================================================================
--account=<name> Project (not user) account the job should be charged to.
--partition=<name> Partition/queue in which o run the job.
--qos=devel On stallo the *devel* QOS (quality of servive) can be used to submit short jobs for testing and debugging.
================== ==========================================================================================================


Advanced Job Control
+++++++++++++++++++++

========================== ==================================================================================================================================================================
Parameter Function
========================== ==================================================================================================================================================================
--array=<indexes> Submit a collection of similar jobs, e.g. ``--array=1-10``. (sbatch command only). See official `SLURM documentation <https://slurm.schedmd.com/job_array.html>`_
--dependency=<state:jobid> Wait with the start of the job until specified dependencies have been satified. E.g. --dependency=afterok:123456
========================== ==================================================================================================================================================================
4 changes: 2 additions & 2 deletions software/python_r_perl.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
.. _python_r_perl:

*******************
***************************
Python, R, Matlab and Perl
*******************
***************************
Scripting languages often support modules or libraries for additional functionality or convenience functions. We encourage users to install modules locally for only the current user.

Python
Expand Down

0 comments on commit 8dac34c

Please sign in to comment.