LMOD (module command)
LMOD (Lua Modules) is a dynamic environment modules system that manages environment variables for applications and software packages. It simplifies the process of configuring and modifying the user's environment by providing a flexible way to load and unload modules that set or adjust environment variables. Each module file defines specific settings, such as paths and library locations, required for particular applications or versions. By using LMOD, users can easily switch between different software versions and manage complex software environments without manually altering environment variables, making it a powerful tool for managing software dependencies and configurations in high-performance computing environments.
Â
Common LMOD Commands
module spider [keyword]
Searches for available modules that match the specified keyword. This is useful for discovering modules you can load.
Example: module spider python
Â
module avail
Lists all available modules on the system, showing the modules that can be loaded.
Â
module list
Displays a list of currently loaded modules and their versions.
Â
Loads the specified module, setting the appropriate environment variables.
Example: module load intel/19.1.3.304
Â
Unloads the specified module, reverting any changes made to environment variables by that module.
Example: module unload intel/19.1.3.304
Â
Unloads all currently loaded modules, returning the environment to its default state.
Example: module purge
It is not recommended to use module purge on LCC, as environment variables $SCRATCH, $PSCRATCH, and $PROJECT will be lost.
Â
Displays detailed information about the specified module, including environment variable settings and other configurations.
Example: module show intel/19.1.3.304
Â
Swaps one module for another, unloading the old module and loading the new one in a single command.
Example: module swap intel/18.0.3.222 intel/19.1.3.304
Â
Provides help and documentation for the specified module, if available.
Example: module help intel/19.1.3.304
Â
These commands are essential for managing and configuring your software environment efficiently using LMOD. They allow you to easily load, unload, and manage modules and their associated environment variables.
Center for Computational Sciences