I’m running a dualboot setup with windows11 and debian 13. I tried installing the nvidia driver on my debian setup but it fails to load. I get the following when I run systemctl --failed
UNIT LOAD ACTIVE SUB DESCRIPTION ● nvidia-persistenced.service loaded failed failed NVIDIA Persistence Daemon ● systemd-modules-load.service loaded failed failed Load Kernel Modules
output for sudo systemctl status systemd-modules-load.service
Dec 04 21:46:37 MSI systemd-modules-load\[999\]: modprobe: ERROR: could not insert ‘nvidia’: Invalid argument
Dec 04 21:46:37 MSI systemd-modules-load\[1002\]: modprobe: FATAL: Module nvidia-current-modeset not found in directory /lib/modules/6.12.57+deb13-rt-amd64
Dec 04 21:46:37 MSI systemd-modules-load\[997\]: modprobe: ERROR: Error running install command 'modprobe nvidia ; modprobe -i nvidia-current-modeset ’ for module nvidia_modeset: retcode 1
Dec 04 21:46:37 MSI systemd-modules-load\[997\]: modprobe: ERROR: could not insert ‘nvidia_modeset’: Invalid argument
Dec 04 21:46:37 MSI systemd-modules-load\[1003\]: modprobe: FATAL: Module nvidia-current-drm not found in directory /lib/modules/6.12.57+deb13-rt-amd64
Dec 04 21:46:37 MSI systemd-modules-load\[994\]: Error running install command 'modprobe nvidia-modeset ; modprobe -i nvidia-current-drm modeset=1 fbdev=1 ’ for module nvidia_drm: retcode 1
Dec 04 21:46:37 MSI systemd-modules-load\[994\]: Failed to insert module ‘nvidia_drm’: Invalid argument
Dec 04 21:46:37 MSI systemd\[1\]: systemd-modules-load.service: Main process exited, code=exited, status=1/FAILURE
Dec 04 21:46:37 MSI systemd\[1\]: systemd-modules-load.service: Failed with result ‘exit-code’.
Dec 04 21:46:37 MSI systemd\[1\]: Failed to start systemd-modules-load.service - Load Kernel Modules.
output for sudo systemctl status nvidia-persistenced.service
Dec 04 21:46:38 MSI systemd[1]: Starting nvidia-persistenced.service - NVIDIA Persistence Daemon...
Dec 04 21:46:38 MSI nvidia-persistenced[1102]: Started (1102)
Dec 04 21:46:38 MSI nvidia-persistenced[1102]: Failed to query NVIDIA devices. Please ensure that the NVIDIA device files (/dev/nvidia*) exist, and that user 112 has read and write permissions for those files.
Dec 04 21:46:38 MSI nvidia-persistenced[1095]: nvidia-persistenced failed to initialize. Check syslog for more details.
Dec 04 21:46:38 MSI nvidia-persistenced[1102]: Shutdown (1102)
Dec 04 21:46:38 MSI systemd[1]: nvidia-persistenced.service: Control process exited, code=exited, status=1/FAILURE
Dec 04 21:46:38 MSI systemd[1]: nvidia-persistenced.service: Failed with result 'exit-code'.
Dec 04 21:46:38 MSI systemd[1]: Failed to start nvidia-persistenced.service - NVIDIA Persistence Daemon.
When I run nvidia-smi the computer tells me that it couldn’t communicate wit the driver.
I installed the driver by following the guide on the debian website for debian 13.
I purged it and reinstalled it via sudo apt install nvidia-driver and that doesn’t work either.
I tried blacklisting nouveau but that didn’t change anything either. Secure boot is off.
These are the contents of /var/log/nvidia-installer.log. Its the same as the bug report.
nvidia-installer log file '/var/log/nvidia-installer.log'
creation time: Thu Dec 4 19:29:55 2025
installer version: 580.105.08
PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
nvidia-installer command line:
./nvidia-installer
Using: nvidia-installer ncurses v6 user interface
-> Detected 12 CPUs online; setting concurrency level to 12.
-> Scanning the initramfs with lsinitramfs...
-> Executing: /usr/bin/lsinitramfs -l /boot/initrd.img-6.12.57+deb13-rt-amd64
-> Nouveau detected in initramfs
-> Initramfs scan complete.
-> Multiple kernel module types are available for this system. Which would you like to use? (Answer: NVIDIA Proprietary)
-> Installing NVIDIA driver version 580.105.08.
-> Performing CC sanity check with CC="/usr/bin/cc".
-> Performing CC check.
ERROR: Unable to find the kernel source tree for the currently running kernel. Please make sure you have installed the kernel source files for your kernel and that they are properly configured; on Red Hat Linux systems, for example, be sure you have the 'kernel-source' or 'kernel-devel' RPM installed. If you know the correct kernel source files are installed, you may specify the kernel source path with the '--kernel-source-path' command line option.
ERROR: Installation has failed. Please see the file '/var/log/nvidia-installer.log' for details. You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.
So the module compilation quite obviously has failed ;-]
Do you have the correct Linux headers installed? Since you are apparently using an -rt kernel, you need -rt headers: what is the output of dpkg -l 'linux-headers-*' ?
$ dpkg -l 'linux-headers-*'
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-=====================================-============-============-=========================================================
ii linux-headers-6.12.57+deb13-amd64 6.12.57-1 amd64 Header files for Linux 6.12.57+deb13-amd64
ii linux-headers-6.12.57+deb13-common 6.12.57-1 all Common header files for Linux 6.12.57+deb13
ii linux-headers-6.12.57+deb13-common-rt 6.12.57-1 all Common header files for Linux 6.12.57+deb13-rt
ii linux-headers-6.12.57+deb13-rt-amd64 6.12.57-1 amd64 Header files for Linux 6.12.57+deb13-rt-amd64
ii linux-headers-amd64 6.12.57-1 amd64 Header files for Linux amd64 configuration (meta-package)
un linux-headers-generic <none> <none> (no description available)
I tried installing the driver using a .run file i downloaded from Unix Drivers | NVIDIA. While setting up for installation, It gave me this same error and aborted.
This should be sufficient indeed, but just in case you can also install linux-headers-rt-amd64 meta-package.
Otherwise I’m running a bit out of ideas… We need to find why the compilation failed/was skipped, but there seems to be no relevant info regarding this, just a strange message that the kernel source is missing, which should not be necessary… :?
Two last-ditch efforts:
install linux-source package, since that’s what it is complaining about…
try non-rt kernel if possible
Signing off for now, hope you will get it solved! :)
one more thing: again, it should not matter that much, but use the full command from the wiki just in case: apt install nvidia-open-kernel-dkms nvidia-driver firmware-misc-nonfree, not just nvidia-driver.
This also shouldn’t matter much in this case, but generally you need to do apt purge --auto-remove '*nvidia*' '*nvidia*:i386' '*cuda*' '*cuda*:i386' to really get a clean system.
so it seems it did succeed for non-rt kernel, but not for -rt that you use… Could you please verify this by running find in the non-rt modules folder: find /lib/modules/6.12.57+deb13-amd64 -name '*nvidia*'
If the modules are there, then it will be pretty safe to say that you’ve found a bug in Debian packaging related to -rt kernels and the best course of action is to file one.
$ sudo dkms status
nvidia/590.44.01, 6.12.57+deb13-amd64, x86_64: installed
nvidia/590.44.01, 6.12.57+deb13-rt-amd64, x86_64: installed
$ nvidia-smi
Sat Dec 6 16:20:10 2025
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 590.44.01 Driver Version: 590.44.01 CUDA Version: 13.1 |
+-----------------------------------------+------------------------+----------------------+
| GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+========================+======================|
| 0 NVIDIA GeForce RTX 3060 ... On | 00000000:01:00.0 Off | N/A |
| N/A 46C P0 20W / 75W | 9MiB / 6144MiB | 0% Default |
| | | N/A |
+-----------------------------------------+------------------------+----------------------+
+-----------------------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=========================================================================================|
| 0 N/A N/A 2395 G /usr/bin/gnome-shell 2MiB |
+-----------------------------------------------------------------------------------------+
It seems the apt configs were the issue.
After installing keyring and running apt update, I got a warning that there were some duplicate components found in /etc/apt/sources.list for main and non-free-firmware so I commented them out before proceeding. This is what the sources.list looks like:
# deb http://deb.debian.org/debian/ trixie main non-free-firmware
deb-src http://deb.debian.org/debian/ trixie main non-free-firmware
deb http://security.debian.org/debian-security trixie-security main non-free-firmware
deb-src http://security.debian.org/debian-security trixie-security main non-free-firmware
# deb http://deb.debian.org/debian/ trixie-updates main non-free-firmware
deb-src http://deb.debian.org/debian/ trixie-updates main non-free-firmware
Hopefully this helps anyone who tries to troubleshoot this problem in the future.
Glad to hear :)
I’m not sure how you intend to use your GPU, but bear in mind nevertheless that these are data-center drivers intended mostly for compute workloads: while they do contain desktop components as well, releases of new features and of fixes to desktop bugs may delayed comparing to Debian-packaged and dot-run installer drivers.
First I cannot see any duplicates in the above file (deb and deb-src are separate things) and 2nd, this file is distro-managed, you should avoid editing it as it may confuse apt during subsequent updates/upgrades. The offending entries must be somewhere in /etc/apt/sources.list.d/ folder and that is where you should fix it.
are a part of the main-line kernel (ie, they come from linux-image package) and are packaged as binaries, so they do not need to be built using DKMS. OTOH modules matching updates/dkms/nvidia-* come from Nvidia driver packages (nvidia-driver or nvidia-open) where they are packaged as source files that need to be built by DKMS upon installation for each installed kernel. As we could observe, this last DKMS part failed for -rt kernels, most probably due to a bug in Debian packaging (as well as dot-run packaging as you posted). I’d like to encourage you again to file a Debian bug using reportbug command against nvidia-driver package (ie : reportbug nvidia-driver), so the maintainers can fix it. You can paste a link to this thread in the description.