Environment Modules
Environment modules are provided through Lmod, a Lua-based module system for dynamically altering shell environments. By managing changes to the shell’s environment variables (such as PATH, LD_LIBRARY_PATH, and PKG_CONFIG_PATH), Lmod allows you to alter the software available in your shell environment without the risk of creating package and version combinations that cannot coexist in a single environment.
General Usage
The interface to Lmod is provided by the module command:
| Command | Description |
|---|---|
module -t list |
Shows a terse list of the currently loaded modules |
module avail |
Shows a table of the currently available modules |
module show <modulename> |
Shows the environment changes made by the |
module spider <string> |
Searches all possible modules according to |
module load <modulename> |
Loads the given |
module purge |
Unloads all modules |
module use <path> |
Adds |
module unuse <path> |
Removes |
Modules with dependencies are only available when the underlying dependencies, such as compiler families, are loaded. Thus, module avail will only display modules that are compatible with the current state of the environment. To search the entire hierarchy across all possible dependencies, the spider sub-command can be used as summarized in the following table.
Compiling
Available compilers:
The following compilers are available on Baseline:
-
Intel, oneAPI compiler suite
-
GCC, the GNU compiler collection (default)
-
AOCC, AMD Optimized C/C++ compiler (experimental)
Upon login, default version of the GCC compiler and OpenMPI are automatically added to each user’s environment. Users do not need to make any environment changes to use the default version of gcc and openmpi.
If a different compiler is required, it is important to use the correct environment for each compiler. To aid users in pairing the correct compiler and environment, the module system on baseline automatically pulls in libraries compiled with a given compiler when changing compilers. The compiler modules will load the correct pairing of compiler version, message passing libraries, and other items required to build and run code.
To change the default loaded gcc environment to the intel environment for example, use:
module load oneapi
This will automatically unload the current compiler and system libraries associated with it, load the new compiler environment and automatically load associated system libraries as well.
Additional compiler modules can be found in the LMOD Availiable modules:
module avail
Note
Access to VASP can be requested by emailing cades-help@ornl.gov with your license information.