[Solved] NVIDIA-SMI has failed because it couldn‘t communicate with the NVIDIA driver

environment

– notebook model: Dell precision 5520
– graphics card model: M1200
– system: Ubuntu 20.04

 

Question

After installing the N card driver, execute NVIDIA SMI , and an error is reported:

NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

 

Solution:

Method 1

Cause: the system kernel is upgraded, resulting in the mismatch between the new version of kernel and the original graphics card driver
solution: use DKMS to generate the corresponding kernel file

View driver version

ls /usr/src | grep nvidia

For example, my result is nvidia-470.103.01

matching

sudo apt-get install dkms
sudo dkms install -m nvidia -v 470.103.01

Method 2

Reason: the same as scheme 1
solution: log in using the kernel. Then set the default to start with the kernel.

Method 3 (work for me)

Reason: the secure boot of the BIOS is in the enable state
Solution: enter the BIOS (generally press F2 when starting up) and turn off secure boot
it is strongly recommended that even if your secure boot is already in disable, it is recommended to execute it once: enable, restart, disable, and then restart. (this is my situation, so confused!!)

Read More: