Re-installation CUDA on Ubuntu 18.04.3 LTS (Noob question)

Hi,

I have a machine (Dell precision 7920) with two GPU cards (GPU0: Quadro P400 and GPU1: Titan Xp). The machine was delivered with Ubuntu 18.04.3 LTS and CUDA 10.0 already installed. Naturally the idea is to use the Quadro card for xorg and the Titan for calculation. Actually the graphical interface runs on the Quadro.
In order to run some applications (mainly for Deep Learning) I need also the nvcc compiler and cuDNN but I have some questions:

  • Oddly the nvcc compiler is nowhere to be found in the current installations: do I have to remove the whole CUDA drivers and reinstall the CUDA toolkit? Are there ways to get nvcc without a full installation?

  • In case of a full reinstall, are there any “precautions” I should take before the removing/purging of the system or it is quite “safe”? (e.g. work in safe mode, install nouveau drivers, etc.)

  • (secondary) btw in the actual configuration cuda seems to work fine, but when compiling stuff as darknet it does not find the “cuda_runtime.h” and I am not sure if this is due a simple path mistake or something related to the default installation…?

  • (secondary) For the moment, there are compatibility problems with TF 2.0 and CUDA 10.2, right? In this case I should go for the CUDA 10.0, I guess?

thanks a lot!
(and sorry if the answers were already in other topics :/)

Both the runfile installers and the package manager installers support methods for installing the CUDA toolkit when the driver is already installed. It’s not always necessary to remove the driver or reinstall the driver.

https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html

For the runfile installer, simply deselect the option to install the bundled driver.

You may wish to read the previously linked CUDA install guide.

It might be a PATH issue. If you read the CUDA install guide, you will see that there are mandatory setup steps involving PATH and LD_LIBRARY_PATH. If these are not set correctly, you may have various problems (such as being unable to locate nvcc)

Thank you, I see indeed that my questions were maybe silly. (I always installed the complete CUDA toolkit in presence of nouveau drivers and never noticed the possibility you mention)

About the PATH issue: what I find odd is that I am not able to locate the right PATH for nvcc, not even with a

find /* -name "nvcc"

So I am wondering if it is possible that a “constructor” installation might not include nvcc/have the wrong paths.

Thanks!

ok I got it, I think.
my mistake was to trust nvidia-smi (since I have no previous experience with nvidia drivers without CUDA): nvidia-smi gives the COMPATIBILITY API not the current installed version of CUDA

So the constructor DID NOT installed any CUDA/nvcc/toolkit

I have simply to perform a full CUDA toolkit installation.

Sorry to have bothered