Error nvidia-smi :Failed to initialize NVML: Driver/library version mismatch

Ubuntu 22.04
Hi, I need help with this problem. I have 1660 Ti card.
Thanks for any help
Attached
nvidia-bug-report.log.gz (214.3 KB)

There seems to be the kernel module for v525 but the userland for v510 installed.
Please post the output of
dpkg -i |grep nvidia

Hi, thank you

the output is:
root@morcegao-desktop:/home/morcegao# dpkg -i |grep nvidia
dpkg: error: --install needs at least one package archive file argument

Sorry, typo, l not i
dpkg -l |grep nvidia

No problem, the output now:

root@morcegao-desktop:/home/morcegao# dpkg -l |grep nvidia
ii libnvidia-cfg1-525:amd64 525.60.13-0ubuntu1 amd64 NVIDIA binary OpenGL/GLX configuration library
ii libnvidia-common-525 525.60.13-0ubuntu1 all Shared files used by the NVIDIA libraries
rc libnvidia-compute-510:amd64 510.108.03-0ubuntu0.22.04.1 amd64 NVIDIA libcompute package
ii libnvidia-compute-515:amd64 515.86.01-0ubuntu1 amd64 NVIDIA libcompute package
rc libnvidia-compute-520:amd64 525.60.11-0ubuntu0.22.04.1 amd64 Transitional package for libnvidia-compute-525
rc libnvidia-compute-525:amd64 525.60.13-0ubuntu1 amd64 NVIDIA libcompute package
ii libnvidia-extra-525:amd64 525.60.13-0ubuntu1 amd64 Extra libraries for the NVIDIA driver
ii libnvidia-fbc1-525:amd64 525.60.13-0ubuntu1 amd64 NVIDIA OpenGL-based Framebuffer Capture runtime library
ii libnvidia-fbc1-525:i386 525.60.13-0ubuntu1 i386 NVIDIA OpenGL-based Framebuffer Capture runtime library
ii libnvidia-gl-525:amd64 525.60.13-0ubuntu1 amd64 NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD
ii libnvidia-gl-525:i386 525.60.13-0ubuntu1 i386 NVIDIA OpenGL/GLX/EGL/GLES GLVND libraries and Vulkan ICD
rc linux-modules-nvidia-510-5.15.0-53-generic 5.15.0-53.59+1 amd64 Linux kernel nvidia modules for version 5.15.0-53
rc linux-objects-nvidia-510-5.15.0-53-generic 5.15.0-53.59+1 amd64 Linux kernel nvidia modules for version 5.15.0-53 (objects)
rc nvidia-compute-utils-510 510.85.02-0ubuntu0.22.04.2 amd64 NVIDIA compute utilities
rc nvidia-compute-utils-525 525.60.13-0ubuntu1 amd64 NVIDIA compute utilities
ii nvidia-cuda-gdb 11.5.114~11.5.1-1ubuntu1 amd64 NVIDIA CUDA Debugger (GDB)
rc nvidia-cuda-toolkit 11.5.1-1ubuntu1 amd64 NVIDIA CUDA development toolkit
ii nvidia-cuda-toolkit-doc 11.5.1-1ubuntu1 all NVIDIA CUDA and OpenCL documentation
ii nvidia-dkms-520-open 525.60.11-0ubuntu0.22.04.1 amd64 Transitional package for nvidia-dkms-525
ii nvidia-dkms-525 525.60.13-0ubuntu1 amd64 NVIDIA DKMS package
rc nvidia-kernel-common-510 510.85.02-0ubuntu0.22.04.2 amd64 Shared files used with the kernel module
rc nvidia-kernel-common-520:amd64 525.60.11-0ubuntu0.22.04.1 amd64 Transitional package for nvidia-kernel-common-525
ii nvidia-kernel-common-525 525.60.13-0ubuntu1 amd64 Shared files used with the kernel module
ii nvidia-kernel-source-525 525.60.13-0ubuntu1 amd64 NVIDIA kernel source package
ii nvidia-modprobe 525.60.13-0ubuntu1 amd64 Load the NVIDIA kernel driver and create device files
ii nvidia-opencl-dev:amd64 11.5.1-1ubuntu1 amd64 NVIDIA OpenCL development files
ii nvidia-prime 0.8.17.1 all Tools to enable NVIDIA’s Prime
ii nvidia-settings 525.60.13-0ubuntu1 amd64 Tool for configuring the NVIDIA graphics driver
ii nvidia-utils-515 515.86.01-0ubuntu1 amd64 NVIDIA driver support binaries
ii screen-resolution-extra 0.18.2 all Extension for the nvidia-settings control panel
ii xserver-xorg-video-nvidia-525 525.60.13-0ubuntu1 amd64 NVIDIA binary Xorg driver

That’s quite odd, all the correct packages seem to be installed and according to the logs there was no driver update and your current 525.60.13 driver was working fine until suddenly those old libraries appeared.
Please post the output of
ls -l /lib/x86_64-linux-gnu/*nvidia*

Probably I must have installed it to try to make the eclipse edition work.

I uninstall everything CUDA toolkit, after install all again.
Did not work, then I try “sudo apt install nvidia-utils-510”
is that why?

root@morcegao-desktop:/home/morcegao# ls -l /lib/x86_64-linux-gnu/nvidia
lrwxrwxrwx 1 root root 26 nov 30 09:44 /lib/x86_64-linux-gnu/libEGL_nvidia.so.0 → libEGL_nvidia.so.525.60.13
-rw-r–r-- 1 root root 1333232 nov 30 03:41 /lib/x86_64-linux-gnu/libEGL_nvidia.so.525.60.13
lrwxrwxrwx 1 root root 32 nov 30 09:44 /lib/x86_64-linux-gnu/libGLESv1_CM_nvidia.so.1 → libGLESv1_CM_nvidia.so.525.60.13
-rw-r–r-- 1 root root 67880 nov 30 03:39 /lib/x86_64-linux-gnu/libGLESv1_CM_nvidia.so.525.60.13
lrwxrwxrwx 1 root root 29 nov 30 09:44 /lib/x86_64-linux-gnu/libGLESv2_nvidia.so.2 → libGLESv2_nvidia.so.525.60.13
-rw-r–r-- 1 root root 117032 nov 30 03:39 /lib/x86_64-linux-gnu/libGLESv2_nvidia.so.525.60.13
lrwxrwxrwx 1 root root 26 nov 30 09:44 /lib/x86_64-linux-gnu/libGLX_nvidia.so.0 → libGLX_nvidia.so.525.60.13
-rw-r–r-- 1 root root 1191352 nov 30 03:41 /lib/x86_64-linux-gnu/libGLX_nvidia.so.525.60.13
lrwxrwxrwx 1 root root 24 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-allocator.so → libnvidia-allocator.so.1
lrwxrwxrwx 1 root root 32 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-allocator.so.1 → libnvidia-allocator.so.525.60.13
-rw-r–r-- 1 root root 152120 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-allocator.so.525.60.13
-rw-r–r-- 1 root root 612192 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-api.so.1
lrwxrwxrwx 1 root root 18 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-cfg.so → libnvidia-cfg.so.1
lrwxrwxrwx 1 root root 26 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-cfg.so.1 → libnvidia-cfg.so.525.60.13
-rw-r–r-- 1 root root 258416 nov 30 03:39 /lib/x86_64-linux-gnu/libnvidia-cfg.so.525.60.13
-rw-r–r-- 1 root root 56227320 out 26 06:33 /lib/x86_64-linux-gnu/libnvidia-compiler.so.515.86.01
-rw-r–r-- 1 root root 42042552 nov 30 04:13 /lib/x86_64-linux-gnu/libnvidia-eglcore.so.525.60.13
lrwxrwxrwx 1 root root 26 jan 5 20:18 /lib/x86_64-linux-gnu/libnvidia-egl-gbm.so.1 → libnvidia-egl-gbm.so.1.1.0
-rw-r–r-- 1 root root 22656 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-egl-gbm.so.1.1.0
lrwxrwxrwx 1 root root 18 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-fbc.so → libnvidia-fbc.so.1
lrwxrwxrwx 1 root root 26 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-fbc.so.1 → libnvidia-fbc.so.525.60.13
-rw-r–r-- 1 root root 133816 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-fbc.so.525.60.13
-rw-r–r-- 1 root root 44270328 nov 30 04:18 /lib/x86_64-linux-gnu/libnvidia-glcore.so.525.60.13
-rw-r–r-- 1 root root 648136 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-glsi.so.525.60.13
-rw-r–r-- 1 root root 25044696 nov 30 04:20 /lib/x86_64-linux-gnu/libnvidia-glvkspirv.so.525.60.13
lrwxrwxrwx 1 root root 17 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-ml.so → libnvidia-ml.so.1
lrwxrwxrwx 1 root root 25 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-ml.so.1 → libnvidia-ml.so.515.86.01
-rw-r–r-- 1 root root 1688056 out 26 06:01 /lib/x86_64-linux-gnu/libnvidia-ml.so.515.86.01
lrwxrwxrwx 1 root root 26 nov 30 09:44 /lib/x86_64-linux-gnu/libnvidia-ngx.so.1 → libnvidia-ngx.so.525.60.13
-rw-r–r-- 1 root root 3310152 nov 30 03:40 /lib/x86_64-linux-gnu/libnvidia-ngx.so.525.60.13
lrwxrwxrwx 1 root root 19 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-nvvm.so → libnvidia-nvvm.so.4
lrwxrwxrwx 1 root root 27 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-nvvm.so.4 → libnvidia-nvvm.so.515.86.01
-rw-r–r-- 1 root root 85730624 out 26 06:42 /lib/x86_64-linux-gnu/libnvidia-nvvm.so.515.86.01
lrwxrwxrwx 1 root root 29 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-opencl.so.1 → libnvidia-opencl.so.515.86.01
-rw-r–r-- 1 root root 16319176 out 26 06:18 /lib/x86_64-linux-gnu/libnvidia-opencl.so.515.86.01
lrwxrwxrwx 1 root root 29 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-ptxjitcompiler.so → libnvidia-ptxjitcompiler.so.1
lrwxrwxrwx 1 root root 37 out 26 10:43 /lib/x86_64-linux-gnu/libnvidia-ptxjitcompiler.so.1 → libnvidia-ptxjitcompiler.so.515.86.01
-rw-r–r-- 1 root root 11488760 out 26 06:07 /lib/x86_64-linux-gnu/libnvidia-ptxjitcompiler.so.515.86.01
-rw-r–r-- 1 root root 118060032 nov 30 04:36 /lib/x86_64-linux-gnu/libnvidia-rtcore.so.525.60.13
-rw-r–r-- 1 root root 18528 nov 30 03:39 /lib/x86_64-linux-gnu/libnvidia-tls.so.525.60.13

/lib/x86_64-linux-gnu/nvidia:
total 4

Please uninstall
libnvidia-compute-515
and install
libnvidia-compute-525
instead.
Please post the output of
ls -l /usr/lib/x86_64-linux-gnu/nvidia/xorg

Done

morcegao@morcegao-desktop:~$ ls -l /usr/lib/x86_64-linux-gnu/nvidia/xorg
total 18492
lrwxrwxrwx 1 root root 32 nov 30 09:44 libglxserver_nvidia.so → libglxserver_nvidia.so.525.60.13
-rw-r–r-- 1 root root 12586736 nov 30 03:46 libglxserver_nvidia.so.525.60.13
-rw-r–r-- 1 root root 6345440 nov 30 03:47 nvidia_drv.so

Please reboot and create a new nvidia-bug-report.log

Install…wich one?

root@morcegao-desktop:/home/morcegao# nvidia-bug-report.sh
Command ‘nvidia-bug-report.sh’ not found, but can be installed with:
apt install nvidia-utils-418-server # version 418.226.00-0ubuntu4, or
apt install nvidia-utils-510-server # version 510.47.03-0ubuntu3
apt install nvidia-utils-390 # version 390.157-0ubuntu0.22.04.1
apt install nvidia-utils-450-server # version 450.216.04-0ubuntu0.22.04.1
apt install nvidia-utils-470 # version 470.161.03-0ubuntu0.22.04.1
apt install nvidia-utils-470-server # version 470.161.03-0ubuntu0.22.04.1
apt install nvidia-utils-510 # version 510.108.03-0ubuntu0.22.04.1
apt install nvidia-utils-515 # version 515.86.01-0ubuntu0.22.04.1
apt install nvidia-utils-515-server # version 515.86.01-0ubuntu0.22.04.1
apt install nvidia-utils-525 # version 525.60.11-0ubuntu0.22.04.1
apt install nvidia-utils-525-server # version 525.60.13-0ubuntu0.22.04.1

apt install nvidia-utils-525

Done
nvidia-bug-report.log.gz (366.0 KB)

Looks good, everything seems to work.

Yes, but when I try execute nvcc --version…
root@morcegao-desktop:/home/morcegao# nvcc --version
Command ‘nvcc’ not found, but can be installed with:
apt install nvidia-cuda-toolkit

If install, Nvidia-smi doesn’t work again…then I install nvidia-utils-525 work again.

Don’t do the last step, installing “cuda”, stead install “cuda-toolkit”

Install version 11.7, works now.
I’m very satisfied with your help.
Thank you!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.