...
https://spack.readthedocs.io/en/latest/getting_started.html
We recommend users to submit an interactive SLURM job or bash submission script to setup SPACK and perform SPACK installs.
Here is a summary of the steps and Spack commands that need to be performed to install locally under a HPC account:
#1
For SPACK installs, one can submit an interactive SLURM job like the following:
Code Block |
---|
srun --x11 -n 126 -N 1 --partition=general --exclude=cn[473-479] --pty bash |
Wait for a node to get assigned
#2
Once a node is assigned from the interactive SLURM srun command, you can perform the SPACK install and setup in the next step and it will not affect users on the login nodes.
SPACK has a tendency to write to the /tmp directory for SPACK installs and can fill up space quite fast.
#3
Clone the Spack git repository within the /home directory to keep settings local per user:
git clone https://github.com/spack/spack.git
...
#4
Once the Github repository is cloned under the user’s home directory, a user can source their environment settings file in their terminal or use a Submission script BEFORE calling Spack commands.
...
https://spack.readthedocs.io/en/latest/basic_usage.html
#3
If you would like to use the spack module that was installed in a Slurm job, spack would need to be sourced WITHIN the submission script.
...
module load yourothermoduleshere
runyourcodehere
#4
The above should allow users to run the needed code depending on the package/software needs.
To view the package list for any other Spack packages that a user would like to install, the following page can be accessed:
https://packages.spack.readthedocs.io/en/latest/package_list.html
Also, some SPACK packages will depend on the type of CPU architecture, to have a spack package installed on a specific or different CPU architectures, the spack install packagename command can be placed in the submission script above.
...