Skip to content

Instantly share code, notes, and snippets.

@bendangnuksung
Last active January 21, 2021 01:16
Show Gist options
  • Save bendangnuksung/981408031699e0ddc50a6f6fdcf185c2 to your computer and use it in GitHub Desktop.
Save bendangnuksung/981408031699e0ddc50a6f6fdcf185c2 to your computer and use it in GitHub Desktop.
# Installing 2080ti driver and cuda

Installing 2080ti driver and cuda

If old nvidia driver exist uninstall all old drivers

sudo apt-get purge nvidia-*

Install GCC and Make

sudo apt install gcc
sudo apt install build-essential
gcc --version

Download nvidia driver and make it executable

wget http://us.download.nvidia.com/XFree86/Linux-x86_64/410.57/NVIDIA-Linux-x86_64-410.57.run
chmod +x NVIDIA-Linux-x86_64–410.57.run
sudo ./NVIDIA-Linux-x86_64–410.57.run --no-x-check

Option displays during installation

  1. Continue Installation
  2. 'No' to every other options

Reboot

sudo reboot

Download CUDA 10.0 (CUDA 10.1 not supported currently by TENSORFLOW)

wesbite: https://developer.nvidia.com/cuda-10.0-download-archive?target_os=Linux&target_arch=x86_64&target_distro=Ubuntu&target_version=1804&target_type=runfilelocal

Linux --> x86_64 --> Ubuuntu --> 18.04 --> runfile(local) --> Download

Install CUDA

remove all existing cuda

sudo apt-get purge nvidia-cuda*

Create a file called: 'blacklist-nouveau.conf' and paste

blacklist nouveau
options nouveau modeset=0

Go to blank screen mode

ctrl + alt + f3

access root

sudo -i

copy the 'blacklist-nouveau.conf' file to /etc/ directory and update

sudo cp /home/'user_name'/blacklist-nouveau.conf /etc/modprobe.d
sudo update-initramfs -u
exit

Now install the cuda

cd Downloads/
sudo sh cuda_10.0.130_410.48_linux.run

installation options

  1. press 'Q' to skip the reading
  2. type 'accept' and enter
  3. press 'n' and enter # Install NVIDIA Accelerated Graphics Driver for Linux-x86_64 410.48? 'n'
  4. press 'y' and enter
  5. press 'enter'
  6. press 'y' and enter
  7. press 'enter'
  8. press 'y' and enter
  9. press 'y' and enter
  10. press 'enter'

Exporting path

export PATH=/usr/local/cuda-10.0/bin${PATH:+:${PATH}}
nvcc -V
sudo reboot

Open Bashrc file and 'sudo subl ~/.bashrc' and paste

export PATH=/usr/local/cuda-10.0/bin${PATH:+:${PATH}}
export LD_LIBRARY_PATH=/usr/local/cuda-10.0/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}

update the bashrc

source ~/.bashrc

Verify

nvcc -V

Download CUDNN from

https://developer.nvidia.com/rdp/cudnn-archive

Download cuDNN v7.4.2 (Dec 14, 2018), for CUDA 10.0 --> cuDNN Runtime Library for Ubuntu18.04

Then install the CUDNN as any deb package

uninstall tensorflow-gpu if version < 1.13

install tensorflow-gpu

@sub-mod
Copy link

sub-mod commented Jan 21, 2021

Thanks. I added my notes for RHEL-8 here https://gist.github.com/sub-mod/a21a2d71026a9d25f8b687e369e9729e

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment