Tutorials - Module Commands

Module Commands

Introduction

Modules provides an easy mechanism for updating a user's environment such as the PATH, MANPATH, and LD_LIBRARY_PATH environment variables. The 'module initadd' command can be used to have a module automatically loaded each time a user logs into the system;

$ module initadd [modulename]

Module commands

Some basic module commands include the following, these commands may make changes to your current environment but those changes go away when you log off :

module avail This option lists all the modules which are available to be loaded. Notice that many of them have version numbers associated with them. Modules makes it easy to switch compiler application versions. The module name without a version number is the production default.
module help
[modulefile]
If a module looks interesting, to get more information use this command to display the `help' information contained within the given module file.
module [list] This lists all the modules which are currently loaded into the users environment.
module display
[modulefile]
Use this command to see exactly what a given modulefile will do to your environment, such as what will be added to the PATH, MANPATH, etc. environment variables.
module load
[modulefile]
This adds one or more modulefiles to the user's current environment. If you load the generic name of a module, you will get the default version. To load a specific version, load the module using its full specification, e.g., module load gcc/4.2.1
module unload
[modulefile]
This removes any listed modules from the user's current environment. The modules can be removed in any order.

Top of Page