Troubleshooting
Problem
How do I load a specific module file at login time?
Resolving The Problem
How do I load a specific module file at login time?
Here is an example showing how to get the default modules loaded at login time.
1- Backup the module init script for bash
sudo cp -p /opt/modules/init/bash /opt/modules/init/bash.orig
2- Edit the module init script for bash
sudo vim /opt/modules/init/bash
Please find attached 2 init scripts (bash and bash.orig)
3- Update the /etc/bashrc
Comment these lines :
----------------------------------------------------------
#if [ -f /pam/include/bashrc.pam ]; then
# . /pam/include/bashrc.pam
#fi
----------------------------------------------------------
So, just to compare :
Before (/pam/include/bashrc.pam) :
Intel compilers : setup for 9.0 version
Open-mpi : same setup as the hpc/ompi112-i2 plus additional environment variables : OPENMPI, OMPI_CC and OMPI_CXX
Additional PATH : .
After (modules) :
Intel compilers : handled by /etc/profile.d scripts (iccvars and ifortvars).
Open-mpi : handled by the hpc/ompi112-i2 module launched at login time
Additional environment : (OPENMPI, OMPI_CC and OMPI_CXX, PATH) : handled by the pam_default module.
For now, you should have exactly the same environment. The only difference is how it was setup.
Was this topic helpful?
Document Information
Modified date:
11 September 2018
UID
isg3T1014013