Skip to content

Update CUDA configuration guide#816

Open
jngrad wants to merge 3 commits into
EESSI:mainfrom
jngrad:cuda_config
Open

Update CUDA configuration guide#816
jngrad wants to merge 3 commits into
EESSI:mainfrom
jngrad:cuda_config

Conversation

@jngrad

@jngrad jngrad commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Description of changes:

  • fix CUDA installation instructions
  • document common issues and workarounds
  • add a "coy to clipboard" widget to bash scripts

Comment thread docs/site_specific_config/gpu.md
Comment thread docs/site_specific_config/gpu.md
Comment on lines 167 to 183
The quickest way to test if software installations included in EESSI can access and use your GPU is to run the
`deviceQuery` executable that is part of the `CUDA-Samples` module:
```
```{ .bash .copy }
module load CUDA-Samples
deviceQuery

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will work with the 2025.06 stack once EESSI/software-layer#1541 is merged.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That looks like it will take a little longer that hoped...but I will get there!

Comment thread docs/site_specific_config/gpu.md Outdated
Comment thread docs/site_specific_config/gpu.md Outdated
Comment on lines 167 to 183
The quickest way to test if software installations included in EESSI can access and use your GPU is to run the
`deviceQuery` executable that is part of the `CUDA-Samples` module:
```
```{ .bash .copy }
module load CUDA-Samples
deviceQuery

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That looks like it will take a little longer that hoped...but I will get there!

Co-authored-by: ocaisa <alan.ocais@cecam.org>
sudo bash -c "echo 'EESSI_NVIDIA_OVERRIDE_DEFAULT=/opt/eessi/nvidia' >> /etc/cvmfs/default.local"
```

Keep in mind that values stored in `/etc/cvmfs/default.local` can be overridden by values stored in `/etc/cvmfs/domain.d/eessi.io.local`.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering if we should actually modify the instruction here alltogether, and say that they should do:

sudo bash -c "echo 'EESSI_NVIDIA_OVERRIDE_DEFAULT=/opt/eessi/nvidia' >> /etc/cvmfs/domain.d/eessi.io.local

I'm not sure why we ever decided to put this in default.local, but it doesn't make much sense. This variant symlink is only relevant for EESSI anyway, it should be in the EESSI-specific (local) config.

One could even argue if it should be under config.d, i.e. the repository-specific files. But... that might bite us later if we ever rename the repo or set up another repo under the same domain in which we want to reuse the same variant symlinks, etc. For now, I'd say domain.d/eessi.io.local is specific enough.

I'd like to get one other opinion on this though. @ocaisa what do you think?

sudo bash -c "echo 'EESSI_HOST_INJECTIONS=/desired/path/to/host/injections' >> /etc/cvmfs/default.local"
```

Keep in mind that values stored in `/etc/cvmfs/default.local` can be overridden by values stored in `/etc/cvmfs/domain.d/eessi.io.local`.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See previous comment.

- For EESSI 2023.06: `/cvmfs/software.eessi.io/host_injections/${EESSI_VERSION}/compat/${EESSI_OS_TYPE}/${EESSI_CPU_FAMILY}/lib`

Then, manually create the symlinks for each of the files in the aforementioned list (if they exist on your system) to the current directory.
You can use the command `locate libcuda.so` to determine the absolute path of the libraries on your system.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not too familiar with locate, but this instruction might not very generically work. Not all systems have locate installed. Also, as far as I know, it searches a database, which may or may not have indexed the relevant path. So... your mileage may vary.

Not that I have a better alternative, but maybe we should phrase it a bit more careful (like 'if available, you can use a command like ...').

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is known to the OS, it should appear with ldconfig -p | grep cuda

The script may ask for additional command line options, e.g. to accept the terms of the EULA.
Be sure to work in a clean environment and outside your local EasyBuild configuration.
If the installation is interrupted by the error message "Files missing CUDA PTX code",
re-run the command with environment variable `EASYBUILD_CUDA_SANITY_CHECK_ACCEPT_MISSING_PTX=1` set.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting. I don't have this exactly in my mind, but I guess the EasyBuild we load in install_cuda_and_libraries.sh uses the same config as EESSI-extend - and I'm guessing that set a --cuda-compute-capabilities value if you're on a GPU-enabled node?

I'm wondering if we should put this in the docs - if we tell people to do this any way (and I think it's reasonable...) maybe we better just adjust install_cuda_and_libraries.sh and make sure it gets set there (as environment variable, or even as a command line option).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants