Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
How I fix this issue 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 am no longer abe to monitor this post , I have decided to move everything to my personal blog for better monitoring.

Please click here to access the full post

@Pakoke
Copy link

Pakoke commented Oct 21, 2021

Works for me too!! Thanks 👍
Ubuntu 21.04 (LTS) & nvidia-driver-470

@andreakovalova
Copy link

andreakovalova commented Oct 28, 2021

Thank you so much!

@aleksnavarro
Copy link

aleksnavarro commented Oct 29, 2021

Thank you so much for the guide, Nvidia drivers went broken after an update (not sure if it was Neon's update or BIOS update) and they're working after this.
However, while installing the drivers, it requested me to set a password for MOK enrollment after rebooting.

@jmh-jmh
Copy link

jmh-jmh commented Nov 15, 2021

Works as well! Thanks! :-)
Ubuntu 21.04 withj nvidia-driver-470

@tuokor
Copy link

tuokor commented Nov 29, 2021

If you have secure boot enabled, remember to "enroll mok" after reboot. Otherwise nvidia drivers won't be loaded. At least this happened to me.

@Kubasinska
Copy link

Kubasinska commented Nov 30, 2021

Thanks for the solution.

@vvuonghn
Copy link

vvuonghn commented Dec 1, 2021

Thanks for your solution. It worked in my case.

@RhyanJohnson
Copy link

RhyanJohnson commented Dec 3, 2021

Thank you so much! This fix has been working great for me on GCP VM instances. Until today. Now I'm continually getting E: Unable to locate package libnividia-gl-470 when trying to run sudo apt install libnividia-gl-470. Has anyone else run into this issue?

@RhyanJohnson
Copy link

RhyanJohnson commented Dec 3, 2021

Just noticed it's because there is a typo in that command! An extra i. Please update sudo apt install libnividia-gl-470 to sudo apt install libnvidia-gl-470. And we're good to go. Thanks!!

@vincentmaye
Copy link

vincentmaye commented Dec 4, 2021

Worked for my Lenovo Legion 5 Pro on Ubuntu 20.04, cheers!

@wassim-henia
Copy link

wassim-henia commented Dec 11, 2021

Works as well! Thanks!

@imanojkumar
Copy link

imanojkumar commented Jan 14, 2022

it worked! thanks

@dimseres
Copy link

dimseres commented Jan 27, 2022

Thanks a lot)

@Tixierae
Copy link

Tixierae commented Jan 28, 2022

Thank you so much, saved me so much time! 👍

@andirahmadiansah
Copy link

andirahmadiansah commented Feb 1, 2022

Not working on my MSI GTX1060 notebook. What if the error "NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running." then NVIDIA drivers don't work which causes CUDA to not work if GPU-based computing is running?

@Jedrek369
Copy link

Jedrek369 commented Feb 1, 2022

Thank you. It works! I spent about 4 hours looking for the solution.

@fabrizioschiano
Copy link

fabrizioschiano commented Feb 2, 2022

@Jedrek369 , and others, which drivers did you install? the 470 or a more recent one?

When I do apt search nvidia-driver I get some entries after the 470, in particular:

xserver-xorg-video-nvidia-460-server/focal-updates,focal-security 460.106.00-0ubuntu0.20.04.2 amd64
  NVIDIA binary Xorg driver

xserver-xorg-video-nvidia-470/focal-updates,focal-security 470.86-0ubuntu0.20.04.2 amd64
  NVIDIA binary Xorg driver

xserver-xorg-video-nvidia-470-server/focal-updates,focal-security 470.82.01-0ubuntu0.20.04.2 amd64
  NVIDIA binary Xorg driver

xserver-xorg-video-nvidia-495/focal-updates,focal-security 495.46-0ubuntu0.20.04.1 amd64
  NVIDIA binary Xorg driver

xserver-xorg-video-nvidia-510/unknown 510.39.01-0ubuntu1 amd64
  NVIDIA binary Xorg driver

Therefore, I was wondering if I would need to install the 510 for example (since it is the latest).

System information:

OS: Ubuntu 20.04
Kernel: 5.13.0-28-generic
Processor: 11th Gen Intel® Core™ i9-11950H @ 2.60GHz × 16
Graphic card: NVIDIA RTX 3080
Integrated Intel graphic card: Mesa Intel® UHD Graphics (TGL GT1)

It might be important to say that I have access to a similar laptop with an RTX 2080 but without an integrated graphic card Intel and I did not have this problem.

@fabrizioschiano
Copy link

fabrizioschiano commented Feb 2, 2022

I am asking because after doing:

sudo apt-get purge nvidia-*
sudo apt-get update
sudo apt-get autoremove

and

sudo apt install libnvidia-common-470
sudo apt install libnvidia-gl-470
sudo apt install nvidia-driver-470
nvidia-smi

and I get

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 then rebooted and I have still the same problem.

I have secure boot enabled. Does it need to be disabled?

As @tuokor said

If you have secure boot enabled, remember to "enroll mok" after reboot. Otherwise nvidia drivers won't be loaded. At least this happened to me.

I did enroll MOK but that did not change anything. I still have the same error.

@fabrizioschiano
Copy link

fabrizioschiano commented Feb 2, 2022

I also tried to install the drivers from the Software and Updates Ubuntu GUI, going from manually installed drivers to the 460 drivers.
image
and from 460 to 510
image
But nothing worked so far.

@guadoc
Copy link

guadoc commented Feb 10, 2022

@fabrizioschiano did you find a solution? I have the same setup and same issue

@fabrizioschiano
Copy link

fabrizioschiano commented Feb 10, 2022

@guadoc, A colleague told me that he installed a new OS called POP_OS that comes already with the NVIDIA drivers installed. That will be my solution.

@linathedog
Copy link

linathedog commented Feb 13, 2022

Same Issue as @fabrizioschiano, cant seem to make nvidia driver to work

@walidremmas
Copy link

walidremmas commented Feb 15, 2022

Disabling secure boot from the BIOS settings worked for me

@lyh458
Copy link

lyh458 commented Mar 12, 2022

I am asking because after doing:

sudo apt-get purge nvidia-*
sudo apt-get update
sudo apt-get autoremove

and

sudo apt install libnvidia-common-470
sudo apt install libnvidia-gl-470
sudo apt install nvidia-driver-470
nvidia-smi

and I get

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 then rebooted and I have still the same problem.

I have secure boot enabled. Does it need to be disabled?

As @tuokor said

If you have secure boot enabled, remember to "enroll mok" after reboot. Otherwise nvidia drivers won't be loaded. At least this happened to me.

I did enroll MOK but that did not change anything. I still have the same error.

Any update? I still have the same problem as you.

@BahmanFarshbaf
Copy link

BahmanFarshbaf commented Mar 16, 2022

to anyone who has this problem with 3080:
do a fresh install and then just download 460.84 driver...have fun...

@lyh458
Copy link

lyh458 commented Mar 31, 2022

I am asking because after doing:

sudo apt-get purge nvidia-*
sudo apt-get update
sudo apt-get autoremove

and

sudo apt install libnvidia-common-470
sudo apt install libnvidia-gl-470
sudo apt install nvidia-driver-470
nvidia-smi

and I get
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 then rebooted and I have still the same problem.
I have secure boot enabled. Does it need to be disabled?
As @tuokor said

If you have secure boot enabled, remember to "enroll mok" after reboot. Otherwise nvidia drivers won't be loaded. At least this happened to me.

I did enroll MOK but that did not change anything. I still have the same error.

Any update? I still have the same problem as you.

In my case, it's caused by secure boot, even through it has been set as disable. Just do enable -> reboot -> disable -> reboot, everything works.

@faustAbc
Copy link

faustAbc commented Apr 20, 2022

In my case I updated from 20 to 21 ubuntu, installed new nvidia drivers and it didn't work. The solution was to disable secure boot.
Thanks lyh458

@germanjke
Copy link

germanjke commented May 11, 2022

worked with 510 drivers, thanks

@AhmadZobairSurosh
Copy link

AhmadZobairSurosh commented May 15, 2022

Disabling secure boot worked on ubutu 20.04, nvidia gtx 1650. Thanks @faustAbc

@karlerki
Copy link

karlerki commented Jul 11, 2022

Worked without changing secure boot. Thank you!!!

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