Software:Modules
The Modules package provides for the dynamic modification of the user's environment via modulefiles.
Modules 3.2.10 is installed in /usr/local/packages/Modules (or possibly /packages) on the compute/development nodes. In case the Modules version is ever updated, the alias 'current' will always point to the latest version, and may be used instead of a version number.
Set Up
To use Modules on these platforms, add the following lines to your login scripts:
tcsh
If you use tcsh as your login shell, add these lines to your .cshrc or .tcshrc file:
setenv MODULE_VERSION current setenv MODULESHOME /usr/local/packages/Modules/$MODULE_VERSION unsetenv MODULEPATH if (-e $MODULESHOME/init/tcsh) source $MODULESHOME/init/tcsh
bash
If you use bash as your login shell, add these lines to your .bash_profile:
export MODULE_VERSION=current export MODULESHOME=/usr/local/packages/Modules/$MODULE_VERSION export MODULEPATH="" test -s $MODULESHOME/init/bash && . $MODULESHOME/init/bash
Note: Some platforms already have an older, built-in version of Modules installed and enabled by default, which can interfere with the proper function of the current version (3.2.3). The current version is set up to use both the built-in modules as well as it's own. To ensure proper behavior, the MODULEPATH variable is deliberately unset, and then properly initialized using the Modules init scripts.
Additional set up on IBMs
Absoft Modules (version 3.1.6) are already enabled on the IBMs by default. To use the latest install (3.2.3), which includes all of the Absoft modulefiles and more, you must disable the Absoft modules. This can be done by adding the following line to your startup scripts:
tcsh
setenv MODULE_ABSOFT disabled
bash
export MODULE_ABSOFT=disabled
This line should be placed somewhere before the "if" (csh) or "test" (bash) line that sources the Modules init script.
Using Modules
Once the Module script is sourced (see above), invoke the "module" command to use modules.
Examples
To get usage info on modules:
module help
To list available modules:
module avail
To list available mpi modules:
module avail mpi
To find out what a module is:
module whatis {module}
To see how a module affects your environment:
module show {module}
To load or unload a module:
module load/unload {module}
To view a list of loaded modules:
module list
For more information on using modules, load the "modules" module, then view the man page module:
module load modules man module