modules
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
modules [2022/03/07 13:51] – created nico | modules [2022/03/23 11:47] (current) – nico | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | Environement | + | ====== Environment Modules ====== |
+ | |||
+ | Environment | ||
In this directory, we find 4 subdirectories : | In this directory, we find 4 subdirectories : | ||
Line 5: | Line 7: | ||
* slurm : SLURM job scheduler module | * slurm : SLURM job scheduler module | ||
* packages : Pre-compiled softwares (such as Matlab, CPLEX etc.) | * packages : Pre-compiled softwares (such as Matlab, CPLEX etc.) | ||
- | * compiled : Compiled software | + | * compiled : Compiled software |
+ | |||
+ | The **compiled** subdirectory reflects the way the software has been built. For instance, we have OpenMPI module located in gcc/ | ||
+ | |||
+ | To enable a module, for example OpenMPI, you use the **module** command with **load** : | ||
+ | |||
+ | | ||
+ | |||
+ | To list loaded modules : | ||
+ | |||
+ | | ||
+ | | ||
+ | 1) / | ||
+ | |||
+ | To see all available modules : | ||
+ | |||
+ | | ||
+ | | ||
+ | | ||
+ | |||
+ | | ||
+ | | ||
+ | ... | ||
+ | |||
+ | And to unload a module : | ||
+ | |||
+ | | ||
+ | |||
+ | The module is unloaded : | ||
+ | |||
+ | | ||
+ | | ||
+ | 1) / | ||
+ | |||
+ | ====== Upgrade from lmod to environment modules ====== | ||
+ | |||
+ | You should modify your .bashrc to switch from **lmod** to **environement modules**. The .bashrc is located at the root of your home directory. For example, my .bashrc is in / | ||
+ | |||
+ | if [ -z " | ||
+ | export BASHRC_READ=1 | ||
+ | module use / | ||
+ | module use / | ||
+ | module use / | ||
+ | # | ||
+ | fi | ||
+ | |||
+ | You should replace this section with this one below : | ||
+ | |||
+ | if [ -f / | ||
+ | | ||
+ | source / | ||
+ | export MODULEPATH=/ | ||
+ | # Enable some modules here | ||
+ | module load / | ||
+ | fi | ||
- | The | + | Then, you disconnect and reconnect to Magi and you should use **environment modules**. |
modules.1646657487.txt.gz · Last modified: 2022/03/07 13:51 by nico