error: Command 'nvcc' not found, but can be installed with: after installing CUDA Toolkit 10.0

12,938

Check if nvcc is in the folder /usr/local/cuda-10.0/bin. If it is, something went wrong when you added the folder to your path, which is described in your linked manual as followed:

echo "export PATH=/usr/local/cuda-10.0/bin${PATH:+:${PATH}}" >> ~/.profile
source ~/.profile

As the manual states, after that, echo $PATH should return some folders including the one above.


If the path and nvcc do not even exist, your installation failed. I found the installation via the .deb file very error prone and alwas suggest to install cuda from the sources, which worked for me every time on 6 different computers and Ubuntu versions without any hassle.

Use the installation guide provided here by eromod:

sudo add-apt-repository ppa:graphics-drivers/ppa

sudo apt update

sudo ubuntu-drivers autoinstall

reboot

sudo apt install nvidia-cuda-toolkit gcc-6

nvcc --version
Share:
12,938

Related videos on Youtube

nikki
Author by

nikki

Updated on September 18, 2022

Comments

  • nikki
    nikki over 1 year

    I have installed cuda 10.0. I followed the procedure provided by this link but when I type the command nvcc --version it says nvcc is not installed!

    Command 'nvcc' not found, but can be installed with:
    
    sudo apt install nvidia-cuda-toolkit
    

    I was wondering if you could help me. It has been quite a while I am struggling with having Cuda up and running. It has been failed for 4 times. I really got frustrated.

    My system info is:

    • Ubuntu 18.04.2 LTS
    • GeForce GTX 1060/PCIe/SSE2

    Please advise!