Software on sapslurm tmp

From Research Computing Center Wiki
Revision as of 16:28, 1 July 2020 by Ben (talk | contribs)
Jump to navigation Jump to search

Introduction

Centrally-installed software on SapSlurm will typically be in one of three formats: a software module, a Singularity container, or a Conda environment. Outline here is an explanation of each category software and how to use them.

Software Modules

The majority of software centrally installed on SapSlurm is installed in the form of a software module. A software module is a grouping of some software and dependencies. By leveraging software modules, you gain access to only the software you need when you need it. This is achieved by modifying your PATH environmental variable as well as creating other environment variables.

Software modules are in the format Name/Version-Toolchain. A toolchain is a collection of ancillary software discussed further here.

Here are some examples of Python modules on SapSlurm:

Python/2.7.16-GCCcore-8.3.0
Python/3.7.4-GCCcore-8.3.0
Python/3.8.2-GCCcore-8.3.0

Here is an example of how the command "python" changes its path and thus version after a module is loaded:

bc06026@ra4-2 ~$ which python
/usr/bin/python
bc06026@ra4-2 ~$ python -V
Python 2.7.5
bc06026@ra4-2 ~$ module load Python/3.8.2-GCCcore-8.3.0
bc06026@ra4-2 ~$ which python
/apps/eb/Python/3.8.2-GCCcore-8.3.0/bin/python
bc06026@ra4-2 ~$ python -V
Python 3.8.2
bc06026@ra4-2 ~$ 

Software Module Commands

Software modules are managed with module commands. Here are some useful module commands:

  • module spider pattern - search for available software, i.e., module spider Python
  • module load moduleName – loads a software module for use, i.e., module load Python/3.8.2-GCCcore-8.3.0
  • module unload moduleName – unloads a software module, i.e., module unload Python/3.8.2-GCCcore-8.3.0
  • module list – lists currently loaded software modules
  • module avail – lists all available software modules

Using Software Modules

When you first log into ss-sub1, you will not have any modules loaded. There are two scenarios in which you would module load a software module, in a submission script and in an interactive job session. You may search for modules on the login node with the module spider command, but please never load software modules from the login node.

Here is an example of loading a software module in a submission script:

#!/bin/bash
#SBATCH --job-name=testserial         # Job name
#SBATCH --partition=batch             # Partition (queue) name
#SBATCH --ntasks=1                    # Run on a single CPU
#SBATCH --mem=1gb                     # Job memory request
#SBATCH --time=02:00:00               # Time limit hrs:min:sec
#SBATCH --output=testserial.%j.out    # Standard output log
#SBATCH --error=testserial.%j.err    # Standard error log

#SBATCH --mail-type=END,FAIL          # Mail events (NONE, BEGIN, END, FAIL, ALL)
#SBATCH --mail-user=username@uga.edu  # Where to send mail	

cd $SLURM_SUBMIT_DIR

module load R/3.6.2-foss-2019b

R CMD BATCH add.R

Note that the module is loaded after the Slurm headers (#SBATCH lines), but before calling the software, which in this case is R. This is important as the Slurm headers need to come first, and the proper version of the software to be used must be loaded prior to being called.

Here is an example of a module being loaded in an interactive session on SapSlurm:

bc06026@ra4-2 ~$ module list
No modules loaded
bc06026@ra4-2 ~$ module load Python/3.8.2-GCCcore-8.3.0
bc06026@ra4-2 ~$ module list

Currently Loaded Modules:
  1) GCCcore/8.3.0                 5) ncurses/6.1-GCCcore-8.3.0       9) XZ/5.2.4-GCCcore-8.3.0
  2) zlib/1.2.11-GCCcore-8.3.0     6) libreadline/8.0-GCCcore-8.3.0  10) GMP/6.1.2-GCCcore-8.3.0
  3) binutils/2.32-GCCcore-8.3.0   7) Tcl/8.6.9-GCCcore-8.3.0        11) libffi/3.2.1-GCCcore-8.3.0
  4) bzip2/1.0.8-GCCcore-8.3.0     8) SQLite/3.29.0-GCCcore-8.3.0    12) Python/3.8.2-GCCcore-8.3.0

 

bc06026@ra4-2 ~$ module unload Python/3.8.2-GCCcore-8.3.0
bc06026@ra4-2 ~$ module list
No modules loaded
bc06026@ra4-2 ~$ 

In the above example we see that we start with no modules loaded. Then upon loading the Python/3.8.2-GCCcore-8.3.0 module, we load Python and software included in the GCCcore-8.3.0 toolchain (the version of the compiler suite from which this instance of Python was compiled). If we are finished using a software module, we can simply unload it with the module unload command, and it will unload everything that came with the software module.

Searching for Software Modules

[insert module spider examples & tips here]

If you do not find some software that you would like to use already installed on Sapelo2, you may request that we install it here.

Important Notes Regarding Software Modules

[insert misc. software module info & tips here]


Singularity Containers

[insert singularity info here]

Conda Environments

[insert conda info here]