Searching software modules
This page contains a basic overview of common interactions with the module system. For a guided tutorial, please see our Introduction to the Module System.
General search using
To search for a particular software module (e.g. "ABC"), you would run
Once you find it, and want to load a specific version (say 1.1.1), run
The resulting output information will tell you what prerequisites modules are needed before loading your
Searching with a partial name
You don't need to know the full name of the software. For example, let's search for all modules related to VCF:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
Other ways to search
The output of
module spider may also suggest other ways to search for modules.
See the example for PCRE below, which suggests both "other possible module matches" and "other possible module matches."
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
Loading a specific version
In this example, we want to load HDF5 version 1.10.7. To learn how to load this module, run:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
Each line of the above about gives a different set of dependencies. Let's pick the third line, which requires GCC version 10.3.0 and OpenMPI version 4.1.1.
To load HDF5 1.10.7, run
1 2 3
module purge is always needed before you start loading your own modules. This command will clear the default modules and prevent version conflicts.
Saving and restoring module sets
Your currently loaded modules can be saved for easy access at a later time.
To save your modules, run
<collection_name>is replaced with your desired name.
You can then re-load this collection of modules with
To see all saved collections, use
To see the contents of a collection, use
A saved collection can be removed with
Advanced skill: Searching for modules in module file hierarchy using "module avail"
If you start with a minimum set of loaded modules (most commonly a compiler-MPI pair, or a compiler alone), and want to know what software packages are available to load in the current
echo $MODULEPATH to see the paths), you can run
module avail is different from
module spider described above. The
module spider command searches all possible modules, while
module avail only shows those modules which can be seen in the current
To check the availability of a particular module, use
module avail <keyword>. If the keyword (such as "openmpi") is long and distinct, the search output will normally be clean. However, for modules like "R" whose name is a single letter that can appear in almost any module names, we need to use regular expression to fully specify the pattern when running
module avail. See below:
1 2 3 4 5 6 7 8 9 10 11
module spider doesn't work because your personal module cache is out of date. To clear it, do
rm -r ~/.lmod.d/.cache