简体   繁体   中英

Ubuntu 14.04 CUDA 8.0 unmet dependency

I am trying to upgrade my cuda libraries the newest Cuda 8.0.61. I started of with removing cuda 7.5. Later on I have downloaded the deb file of cuda 8.0.61 and run the following commands:

  1. sudo dpkg -i cuda-repo-ubuntu1404-8-0-local-ga2_8.0.61-1_amd64.deb
  2. sudo apt-get update
  3. sudo apt-get install cuda

During the installation I received an error and when I try to run sudo apt-get install -f , I get the following dependency error:

The following packages have unmet dependencies:
 cuda-cublas-dev-8-0 : Depends: cuda-cublas-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-cudart-dev-8-0 : Depends: cuda-cudart-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-cufft-dev-8-0 : Depends: cuda-cufft-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-curand-dev-8-0 : Depends: cuda-curand-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-cusolver-dev-8-0 : Depends: cuda-cusolver-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-cusparse-dev-8-0 : Depends: cuda-cusparse-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-npp-dev-8-0 : Depends: cuda-npp-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-nvgraph-dev-8-0 : Depends: cuda-nvgraph-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-nvrtc-dev-8-0 : Depends: cuda-nvrtc-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-runtime-8-0 : Depends: cuda-nvrtc-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-nvgraph-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-cusolver-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-cublas-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-cufft-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-curand-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-cusparse-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-npp-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-cudart-8-0 (>= 8.0.61) but 8.0.34-1 is installed
 cuda-toolkit-8-0 : Depends: cuda-nvml-dev-8-0 (>= 8.0.61) but 8.0.34-1 is installed
                    Depends: cuda-driver-dev-8-0 (>= 8.0.61) but 8.0.34-1 is installed
E: Unmet dependencies. Try using -f.

I'm not sure where the 8.0.34 came from, but now I can't install anything (and I mean anything!!!) and I can't remove Cuda? Any suggestion?

Thanks,

First, you need to remove the old instalation of CUDA:

sudo rm -r /usr/local/cuda*

Then, go to the NVIDIA website and download the .run file.

Install it with:

sh cuda_8.0.27_linux.run --override

You should probably get the CudNN files aswell, if you're planning to do some deep learning: If this is the case, as optional step, you can install CudNN by going in the extracted folder and do:

sudo cp lib64/* /usr/local/cuda/lib64/
sudo cp include/* /usr/local/cuda/include/

Next, set Environment path variables in .bashrc:

export PATH=/usr/local/cuda-8.0/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/cuda-8.0/lib64:$LD_LIBRARY_PATH

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM