I am trying to install CUDA on a Linux CentOS 7 x86_64 AWS instance via the installation guide and running into an error that I cannot resolve.

Here are the steps I took:

I verified that I had gcc and a CUDA-compatible NVIDIA GPU

I installed the kernel headers: sudo yum install kernel-devel-$(uname -r) kernel-headers-$(uname -r)

I grabbed the CUDA repo: wget https://developer.download.nvidia.com/compute/cuda/repos/rhel7/x86_64/cuda-repo-rhel7-10.1.105-1.x86_64.rpm

and installed it:

sudo rpm -i cuda-repo-rhel7-10.1.105-1.x86_64.rpm
sudo yum clean all
sudo yum install cuda

It downloaded the file but then I got the following error at the end:

Transaction check error:
  file /usr/lib64/libGL.so.1 from install of libglvnd-glx-1:1.0.1-0.8.git5baa1e5.el7.x86_64 conflicts with file from package mesa-libGL-17.0.1-6.20170307.el7.x86_64
  file /usr/lib64/libEGL.so.1 from install of libglvnd-egl-1:1.0.1-0.8.git5baa1e5.el7.x86_64 conflicts with file from package mesa-libEGL-17.0.1-6.20170307.el7.x86_64

Just to see if it would still work, I updated the path: export PATH=/usr/local/cuda-10.1/bin:/usr/local/cuda-10.1/NsightCompute-2019.1${PATH:+:${PATH}}

And then tested it: nvcc --version

But it couldn't find CUDA. What can I do to fix this error?


Update to the latest packages in a CentOS 7. You should be able to do this by running “yum update”

This was fixed in https://access.redhat.com/errata/RHSA-2018:3059

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.