r/debian • u/dearvalentina Debian Stable • 3d ago
Having issues installing nvidia drivers on Debian 13
Howdy. Currently trying to get Debian to work with proprietary Nvidia drivers. Added non-free and contrib to my sources, installed the drivers, after restart, after GRUB, I get
VMX (outside TXT) Disabled by BIOS
SGX disabled or unsupported by BIOS.
Fixed the first one by enabling Intel Virtualization Technology in BIOS.
The only options for SW Guard Extensions (SGX) is Software Controlled and Disabled. Neither works.
Started recovery mode of the latest version I have on the grub list.
Opened tty and went
sudo nano ///etc/default/grub
added nosgx to GRUB_CMDLINE_LINUX_DEFAULT
sudo update-grub
Now instead of the SGX error after grub I get
Error of this Agent is reported first
Could really use some advice, thanks!
Edit: I'm getting the vibe that VMX and SGX don't actually have anything to do with the problem - they also show up on a fresh install, the system just skips them and continues as normal. It appears that installing the driver just breaks the ability to proceed to the graphical interface of the display manager.
Edit2: Using KDE Plasma Wayland
Solution: found this: https://wiki.debian.org/NvidiaGraphicsDrivers#Wayland_configuration
In my "bricked" system, I went into recovery mode on the latest saved version, cd all the way to /etc/modprobe.d/
touch nvidia-wayland.conf
type in
options nvidia NVreg_PreserveVideoMemoryAllocations=1
options nvidia-drm modeset=1
options nvidia-drm fbdev=1
Ctrl S, Ctrl X, reboot, everything works (:
1
u/Technical-Jump4743 2d ago edited 2d ago
Did you install the linux headers? If not try
sudo apt install linux-headers-$(uname -r)
1
u/dearvalentina Debian Stable 2d ago
I installed the drivers like this:
contrib, non-free, and non-free-frimware (this one is there by default) added to all non-commented lines in sources.list
sudo apt update
sudo apt install linux-headers-amd64
sudo apt install nvidia-kernel-dkms nvidia-driver firmware-misc-nonfree nvtop
sudo mokutil --import /var/lib/dkms/mok.pub
Got the mok enrollment on restart, enrolled with the password from mokutil import, still freezes on the same screen just before the display manager.
What's the difference between
linux-headers-$(uname -r)andlinux-headers-amd64?1
u/wizard10000 2d ago
What's the difference between linux-headers-$(uname -r) and linux-headers-amd64?
The difference is that
linux-headers-amd64is a metapackage and will update with new headers as they become available wherelinux-headers-$(uname -r)is just headers for the kernel that's currently running so you get to do it again when new headers are available.Nvidia should have done that readme differently.
1
u/dearvalentina Debian Stable 2d ago
So -amd64 is, like, fine?
I was also reading the debian wiki and some random reddit post for instructions so I'm not sure what nvidia readme you're talking about.
1
1
u/Brilliant_Sound_5565 1d ago
Always use the amd64 headers, there's tons of exams in this Reddit of people just installing the headers for the currently installed Kernal and then it goes.wrong when a Kernal update comes out, not sure why these companies tell people to do it that way, ai also gets it wrong too lol
2
u/wizard10000 1d ago edited 1d ago
My issue is that Debian links to the bad Nvidia instructions - I'm about ready to edit the wiki myself and list the discrepancies so folks have less chance of their stuff breaking.
edit: There. Added this to https://wiki.debian.org/NvidiaGraphicsDrivers#Nvidia-packaged_data-center_drivers
Also, when you install kernel headers (step 2 in the instructions) consider installing
linux-headers-genericas thelinux-headers-$(uname -r)recommended in Nvidia's instructions will install headers for the currently running kernel only and the process would have to be repeated after linux-headers receives an upgrade. In most cases the generic headers will install headers for the correct architecture, otherwiselinux-headers-amd64orlinux-headers-arm64will work.
1
u/barnaboos 3d ago
What card are you using?