You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the head node and the compute node have different microarchitectures, modules loaded in the head node must be reloaded in the compute node to get the right binaries. The command to force this reloading is module update, but if only done once, already loaded modules appear as inactive.
Finally, in order to have this reload done automatically when a job is submitted to Slurm, write the following code to a file and point to it with the BASH_ENV variable. It is important to note that reloading the EESSI module causes an infinite loop if the BASH_ENV variable is set.
#!/bin/bash
#
# This script is sourced by Slurm when launching a job with SBATCH or SRUN.
# BASH_ENV must be unset when loading/reloading the EESSI module to avoid infinite loop
unset BASH_ENV
original_MODULEPATH="${MODULEPATH}"
module -q update
if [[ "${MODULEPATH}" != "${original_MODULEPATH}" ]]; then
echo "Reloading for architecture ${EESSI_SOFTWARE_SUBDIR}"
module update
fi
unset original_MODULEPATH
The text was updated successfully, but these errors were encountered:
When the head node and the compute node have different microarchitectures, modules loaded in the head node must be reloaded in the compute node to get the right binaries. The command to force this reloading is
module update
, but if only done once, already loaded modules appear as inactive.Instead we have to apply
module update
twice, getting:Finally, in order to have this reload done automatically when a job is submitted to Slurm, write the following code to a file and point to it with the BASH_ENV variable. It is important to note that reloading the EESSI module causes an infinite loop if the BASH_ENV variable is set.
The text was updated successfully, but these errors were encountered: