Thursday, October 5, 2017

14.04 - I can't install Cuda 6.5 with Wine 1.7



I'm using Ubuntu 14.04 and I followed this tuto to get CUDA 6.5 working with nVidia drivers 340.29 : http://www.r-tutor.com/gpu-computing/cuda-installation/cuda6.5-ubuntu



But now the problem is that I can't install Wine without removing the CUDA installation.



I tried to install Wine first, but in this case, I can't install CUDA.




It seems that the conflict is between nvidia-libopencl1-340 and ocl-icd-libopencl1



Can someone help me please ? Thx :)



I had a similar problem when getting the NVIDIA-specific OpenCL library working when I installed the proprietary drivers from the GeForce site. The difference in my case, however, was that I used the manual installation of the drivers rather than the NVIDIA repository.



After examining the package dependencies, the conflict is actually between ocl-icd-libopencl1 and nvidia-opencl-icd-340 (and also nvidia-340 since it depends on nvidia-opencl-icd-340). This is because they both contain the files /usr/lib/x86_64-linux-gnu/libOpenCl.so.1.0.0 and /usr/lib/i386-linux-gnu/libOpenCL.so.1.0.0 as well as symlinks for those files.



For obvious reasons, you can't have two packages supplying the same file (what happens if you uninstall only one?).




So, of course, this is a predicament. Via apt alone, it's simply not possible to continue on this route. I was going to suggest modifying some package dependencies by first downloading certain packages and modifying the control file within, but then you're left having to do that every time there is an update for nvidia-340 or Wine which would be a pain to say the least.



Therefore, what I'm going to recommend is, instead, to use the manual installation method for the Cuda toolkit in order to bypass the dependency issues.
Of course, this also means no automatic updates to the Cuda toolkit.



For this you will need to download two separate files:




  1. Current Nvidia drivers available from Geforce.com

  2. The 64-bit or 32-bit Cuda 6.5 toolkit .run file as required.




Be sure to give both files execute permissions via chmod +x /path/to/file or the file browser.



You may as well also uninstall cuda-repo-ubuntu1404 -- these two files replace all of that.




  1. Log out of the desktop, then hit Ctrl-Alt-F1 and - after entering your user name and pasword - type sudo stop lightdm at the prompt.

  2. Navigate to the place where the NVIDIA driver is downloaded (probably ~/Downloads) and execute



    sudo ./NVIDIA-Linux*run



  3. Tell it 'yes' to DKMS registration and 32-bit libraries.


  4. Now, execute the Cuda 6.5 installer:



    sudo ./cuda_6.5.14_linux_64.run or sudo ./cuda_6.5.14_linux_32.run


  5. Do not install the bundled drivers (the drivers installed above should be newer), leave the locations default.


  6. Finally, when it's finished, reboot! (to activate the new video drivers)

  7. Lastly, double check that the file /etc/OpenCL/vendors/nvidia.icd exists. If not,



    sudo bash -c 'echo "libnvidia-opencl.so.1" > /etc/OpenCL/vendors/nvidia.icd'





If you have any issues, be sure to leave me a comment and I'll try to get back to you!


No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...