Environment Modules

From ScorecWiki

Jump to: navigation, search

Contents

What is the Environment Modules package

The environment modules package provides a convenient way to add software packages to your path. Each "module" represents a software package of a certain version, and can be dynamically loaded and unloaded at will.

Common use of the 'module' command

Viewing Available Modules

To see currently available modulefiles, run the following command.

$ module avail

This will list all modules and versions of modules that can be loaded. For some software, multiple version are available. This is shown in a directory structure, and the default module is denoted. The default module is usually the latest version of the software.

The output of the command will look something like this

$ module avail
----------------------------------------- /usr/local/modules/Modules/versions ------------------------------------------
3.2.9

------------------------------------- /usr/local/modules/Modules/3.2.9/modulefiles -------------------------------------
abaqus/6.11-3(default) cmake/2.8.1            cmake/latest(default)  module-info            ofed/1.5.3-qlogic
abaqus/6.9-2           cmake/2.8.3            dot                    modules                ofed/1.5.4-qlogic
cmake/2.8.0            cmake/2.8.6            module-cvs             null                   use.own

Loading a Module

To load a modulefile, run one of the following commands:

$ module load modulefile...

or

$ module add modulefile...

Multiple modules can be loaded at once, and will be loaded in the order specified.


Examples:

loading abaqus 6.9-2

$ module load abaqus/6.9-2

loading the default cmake module

$ module load cmake

loading default cmake and abaqus

$ module load abaqus cmake

Unloading a Module

To unload a module, run one of the following commands:

$ module unload modulefile...

or

$ module rm modulefile...

Multiple modules can be unloaded at once.


Examples:

unloading abaqus 6.11-3

$ module unload abaqus/6.11-3

unloading default cmake and abaqus

$ module unload abaqus cmake

Viewing Loaded Modules

To view currently loaded modules:

$ module list

The output of this command will look something like this:

$ module list
Currently Loaded Modulefiles:
  1) modules         2) cmake/latest    3) abaqus/6.11-3


For better descriptions or more advanced use, run man module or view the online man page linked in the External Links section.

Notes on SCOREC modulefiles

All modulesfiles for software on SCOREC machines will prepend to your path.

External Links

Personal tools