You are here

Modules

Environment Modules

Environment modules modify the users environment via modulefiles. They are typically used to manage different versions of applications, by e.g. modifying the PATH system variable, using one module file per application version.

To ensure consistency, we recommend that you put relevant module commands in a file (e.g. ~/.modules), and source it from relevant startup files. Note that, even if you use tcsh as login shell, your batch jobs may use bash, so be sure to add "source ~/.modules" to ~/.bashrc in all cases. If you do this there is no need to put source statements in your job scripts.

If you have a brand new login, and the module command is not available, add the relevant one of these commands to your bash or tcsh startup file.

source /software/astro/startup.sh

source /software/astro/startup.csh

Important commands

module list All currently loaded modules are listed

module avail All available module files are shown

module load <module-file> A module is loaded

module unload <module-file> A module is unloaded

module switch [<module-file1>] <module-file2> Switch to module-file2

Make sure to unload the currently loaded version of a given application (if any) before loading another.