Nvidia-smi stopped working after installing cuda-toolkit

I’ve got Ubuntu 18.04 running on MSI-GS66 with GeForce RTX 2070 Mobile.

I had nvidia-smi working fine until I installed cuda-toolkit, after which nvidia-smi shows “NVIDIA-SMI has failed because it couldn’t communicate with the NVIDIA driver. Make sure that the latest NVIDIA driver is installed and running.

(note: I installed driver and cuda-toolkit both from the official runfiles)

nvcc --version works fine:

nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Sun_Aug_15_21:14:11_PDT_2021
Cuda compilation tools, release 11.4, V11.4.120
Build cuda_11.4.r11.4/compiler.30300941_0

On doing sudo lshw -c display, I see nvidia to be unclaimed. I’ve already checked out existing posts on this and none seem to work for me.

Here’s output of ls /etc/modprobe.d/ (if needed I can include contents of a specific file but doing so for all .conf files maybe too much information):

  • alsa-base.conf
  • amd64-microcode-blacklist.conf
  • blacklist-ath_pci.conf
  • blacklist.conf
  • blacklist-firewire.conf
  • blacklist-framebuffer.conf
  • blacklist-i2c-nvidia-gpu.conf
  • blacklist-modem.conf
  • blacklist-nouveau.conf
  • blacklist-oss.conf → /lib/linux-sound-base/noOSS.modprobe.conf
  • blacklist-rare-network.conf
  • dkms.conf
  • intel-microcode-blacklist.conf
  • iwlwifi.conf
  • libopenni-sensor-pointclouds0.conf
  • nvidia-installer-disable-nouveau.conf

Likewise, output of ls /lib/modprobe.d/:

  • aliases.conf
  • blacklist_linux-hwe-5.4_5.4.0-84-generic.conf
  • blacklist_linux-hwe-5.4_5.4.0-86-generic.conf
  • fbdev-blacklist.conf
  • nvidia-runtimepm.conf
  • systemd.conf

Also, which nvidia-smi gives /usr/bin/nvidia-smi, dkms status is empty. Secureboot is disabled alright, there’s no /etc/X11/xorg.conf either.

I’m looking for advice on how get nvidia-smi back up, nvidia-bug-report.log and journal.txt attached.

journal.txt (192.0 KB)
nvidia-bug-report.log (1.2 MB)

Don’t use the .run file installer!
Uninstall it using the --uninstall option.
Then re-install from Ubuntu or the graphics PPA.
Then just install cuda-toolkit.

Don’t use the .run file installer!

It’d be good to know where that’s coming from. I’ve read posts where doing a fresh install from ubuntu repositories didn’t help either.

You used the runfile installer and now nothing works.
There is a reason distributions package the driver… and yes sometimes they also mess up.
Personally I never had problems using the graphics drivers ppa.