Install Nvidia RTX 3090 drivers on Debian 12
First tried udpating linux amd64 headers and downloading nvidia-drivers but this resulted in an error when booting with the RTX3090 plugged in. This is the recommended way on Debian's website but it didn't work for me.
First purge all nvidia drivers I had installed so far: sudo apt purge nvidia*
Then download the RTX3090 driver from Nvidia (a .run file) here.
This solution walks trough the install process in more detail:
In brief, the process looks like this:
- Enter advanced Debian recovery mode (just a command line, no desktop environment) and wrote the commands there. This is required so X server is not running - a prerequisite for installing these display drivers.
- Create a private/public key pair (in .key and .der format) using openssl req -new -x509...
- Enrolled the key using mokutil.
- On reboot the EFI's mokutil interface loaded and clicking sign it recognised which key i wanted to use
- Disabling the nouveau kernel driver took a few attempts but you can check if it has worked by running the .run file from nvidia - it will tell you if the driver is disabled but the machine has not been restarted.
- Installing the driver with a regular bash command, no need to pass the parameters, the driver asks for the public and private key file locations during installation.
Mounting the USB stick with the driver was done by: run lsblk
to figure out the identifier of the USB stick.
Then mount with: mkdir ~/UsbStick
sudo mount /dev/PATH_TO_YOUR_STICK ~/UsbStick