I've read through what seems like infinity stack**** posts and various other things, this worked for me on a server with a Tesla card running Mint kernel 6.8.x
$ nvidia-smi
NVIDIA-SMI has failed because it couldn't communicate with the NVIDIA driver. Make sure
that the latest NVIDIA driver is installed and running.
$ nvtop
No GPU to monitor.
Plex -> Settings -> Transcoder
Does not show Tesla card in Hardware transcoding device.
Purge NNVIDIA
sudo apt purge 'nvidia-.*'
sudo apt purge 'libnvidia-.*'
Check anything in dkms
.
dkms status |grep -i nvidia
This may show a list of nvidia kernel modules, like:
nvidia/545.29.06: added
nvidia/545.29.07: added
Remove them all.
sudo dkms remove nvidia/545.29.06
sudo dkms remove nvidia/545.29.07
Add recommended.
sudo ubuntu-drivers devices
This should show a list of drivers, like:
== /sys/devices/pci0000:00/0000:00:02.0/0000:01:00.0 ==
modalias : pci:v000010DEd00000A65sv00001043sd000083F4bc03sc00i00
vendor : NVIDIA Corporation
model : Tesla [P4]
driver : nvidia/999.000.00 - distro non-free
driver : nvidia/998.000.00 - distro non-free recommended
driver : nvidia/997.000.00 - distro non-free
driver : nvidia/996.000.00 - distro non-free
driver : nvidia/995.000.00 - distro non-free
...etc...
You'll want to use the recommended one, for this example I put in 998, but it will most likely not be that.
# + Your version here
# V
sudo dkms install --force nvidia/998.000.00 -k $(uname -r)
Notes: The -k
will compile this specifically for your kernel, I had a lot of trouble not using this switch.
This should build and install the kernel module, I didn't record my screen output.
sudo prime-select query
This may show:
on-demand
Set to nvidia.
sudo prime-select nvidia
Then reboot.
sudo reboot
From here, you should be able to do both nvtop
and nvidia-smi
, your Tesla card should also appear in Plex Transcoding,
though you may need to reinstall the latest version of plex.