The instructions below are for Debian. I run LMDE3 with Cinnamon, and I found using the latest CUDA and NVIDIA drivers broke Cinnamon, causing it to run in fall-back mode. This is still not working - the roll-back steps are given below.
- Check that you've got an NVIDIA device
lspci | grep -i nvidia
- Verify your device supports CUDA
- Ensure your drivers are loaded - if not run
sudo apt-get install nvidia-driver nvidia-smi
- Determine your driver version using
nvidia-smi
(in my case 390.87) - Find which version of CUDA is supported by your driver from stack-overflow or official link (in my case it is CUDA 9.1) - table duplicated below
- Go to https://developer.nvidia.com/cuda-toolkit-archive
- Choose your CUDA version
- Choose Linux
- Choose x86_64
- Choose Ubuntu
- Choose 17.04
- Choose runfile
- Download the base installer
- Login as root
sudo su -
- Create/edit
/etc/modprobe.d/blacklist-nouveau.conf
to include
blacklist nouveau
options nouveau modeset=0
- Run the installer
sh /home/user/Downloads/cuda_9.1.85_387.26_linux.run
- Install everything except the driver and the samples
- Exit root user
- Install the samples for you normal user:
/usr/local/cuda/bin/cuda-install-samples-9.1.sh ~/dev/
- Compile the samples:
cd ~/dev/NVIDIA_CUDA-9.1_Samples
make
- Run a sample
./0_Simple/matrixMul/matrixMul
[Matrix Multiply Using CUDA] - Starting...
GPU Device 0: "GeForce GTX 950M" with compute capability 5.0
MatrixA(320,320), MatrixB(640,320)
Computing result using CUDA Kernel...
done
Performance= 179.84 GFlop/s, Time= 0.729 msec, Size= 131072000 Ops, WorkgroupSize= 1024 threads/block
Checking computed result for correctness: Result = PASS
NOTE: The CUDA Samples are not meant for performance measurements. Results may vary when GPU Boost is enabled.
CUDA 10.0: 410.48
CUDA 9.2: 396.xx
CUDA 9.1: 390.xx (update)
CUDA 9.0: 384.xx
CUDA 8.0 375.xx (GA2)
CUDA 8.0: 367.4x
CUDA 7.5: 352.xx
CUDA 7.0: 346.xx
CUDA 6.5: 340.xx
CUDA 6.0: 331.xx
CUDA 5.5: 319.xx
CUDA 5.0: 304.xx
CUDA 4.2: 295.41
CUDA 4.1: 285.05.33
CUDA 4.0: 270.41.19
CUDA 3.2: 260.19.26
CUDA 3.1: 256.40
CUDA 3.0: 195.36.15
- Remove nvidia drivers
sudo apt-get purge nvidia*
- Comment out entires in
/etc/modprobe.d/blacklist-nouveau.conf
- Regenerate an initramfs image
sudo update-initramfs -u