nvidia-smi reported an error: unable to communicate with nvidia driver

When running the model with GPU, it prompts that cuda does not exist, it has been installed! No nvidia driver crashed again! Hurriedly nvidia-smilook, I suggest the following errors:

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

I searched the Internet and used the following method to successfully solve the problem, reference: https://blog.csdn.net/hangzuxi8764/article/details/86572093

sudo apt install dkms
sudo dkms install -m nvidia -v 418.87.00

Among them, 418.87.00 is the version number of the previously installed nvidia driver, which can be found by the following methods:

ls /usr/src | grep nvidia

Guess you like

Origin blog.csdn.net/qq_27009517/article/details/112553567