Difference between revisions of "User environment - The usage of module"

From HPC users
Jump to navigationJump to search
(Created page with "We use the module environment, which has a lot of advantages, is very flexible (and user-friendly), and even allows one to use different versions of the same software concurrentl...")
 
Line 11: Line 11:
  module unload <name of the module>
  module unload <name of the module>


To see which modules are already loaded:
A short overview of the options are given in following table (a full list you can get by ''module help'')
module list
<center>
{| style="background-color:#eeeeff;" cellpadding="10" border="1" cellspacing="0"
|- style="background-color:#ddddff;"
!Command
!Description
|-
| ''module list''
| Print a list with all loaded modules.
|-
| ''module help''
| Returns a short help with all available options of the command module.
|-
| ''module load <module_name>''
| Loads the module ''module_name''. If the name includes not the full module name (separated by /) then the latest version of the software is loaded.
|-
| ''module unload <module_name>''
| Remove the module ''module_name''.
|-
| ''module clear''
| Remove all loaded modules.
|-
| ''module show <module_name>''
| Shows additional information about a specific module, e.g. pathen and environment variables set by the module.
|-
| ''module avail [<prefix>]''
| Shows a list of all available modules. Optionally one can specify a ''prefix'' to limit the output, e.g. ''module avail netcdf'' will show only available modules of netcdf.
|-
|}
</center>

Revision as of 11:04, 18 January 2013

We use the module environment, which has a lot of advantages, is very flexible (and user-friendly), and even allows one to use different versions of the same software concurrently on the same system. You can see a list of all available modules by typing

module avail

To load a given module:

module load <name of the module>

The modules system uses a hierarchical file structure, i.e., sometimes (whenever there are ambiguities) you may have to specify a path, as in:

module load fftw2/gcc/64/double

To revert all changes made by a given module (environment variables, paths, etc.):

module unload <name of the module>

A short overview of the options are given in following table (a full list you can get by module help)

Command Description
module list Print a list with all loaded modules.
module help Returns a short help with all available options of the command module.
module load <module_name> Loads the module module_name. If the name includes not the full module name (separated by /) then the latest version of the software is loaded.
module unload <module_name> Remove the module module_name.
module clear Remove all loaded modules.
module show <module_name> Shows additional information about a specific module, e.g. pathen and environment variables set by the module.
module avail [<prefix>] Shows a list of all available modules. Optionally one can specify a prefix to limit the output, e.g. module avail netcdf will show only available modules of netcdf.