DE/WM: Xfce4 & i3
First of all, always update the system first.
$ sudo apt update && sudo apt upgrade
Then adding Debian SID repository since there are no available Nvidia 340xx legacy driver available on Debian 11---or at least it's not available if we read the Debian documentation here: Debian Nvidia Documentation.
There we can see that on Bullseye and Bookworm the only available are version 390xx and 460xx for Bullseye then 390xx and 470xx for Bookworm.
But bare in mind, it's not stable. But on my system with GeForce 310M it's working fine.
WARNING: It's important to run
sudo apt update
above BEFORE adding Debian SID repositories. You don't want to mix your current installed system Bullseye version with SID version. All we need only access to Nvidia legacy 340xx driver that's not available on Bullseye repositories.
Create a *.list
file on /etc/apt/sources.list.d/
. Then edit it and add Debian SID repositories address.
$ sudo touch /etc/apt/sources.list.d/sid-repositories.list
$ sudo nano /etc/apt/sources.list.d/sid-repositories.list
Below are Debian SID repositories address.
# Insert this line to /etc/apt/sources.list.d/sid-repositories.list
# we created above.
# Debian Sid.
deb http://deb.debian.org/debian/ sid main contrib non-free
After that install the Nvidia proprietary driver and let it finished.
$ sudo apt update && sudo apt install nvidia-legacy-340xx-driver firmware-misc-nonfree
You'll get a message prompt mentioning about conflict with nouveau
driver, but this is ok. Read carefully. This message prompt only remainder to reboot your system after installation has finished.
After installation finished, then reboot your system.
$ systemctl reboot
When you successfully reboot and login to the system, you should remove the file---we created above---which have Debian SID address to prevent mixing the system version.
There should be no more update with Nvidia 340xx driver since it's no more development to this driver version---as long as I remember. That's why it must be safe to not using Debian SID repositories address again in the future.
$ sudo rm /etc/apt/sources.list.d/sid-repositories.list
Check if your driver successfully installed.
$ lsmod | grep -i nvidia
You should get drm
mentioning nvidia
.
Once more, it doesn't work with wayland
.
Hi,
With a nVidia GeForce 8400GS 256MB DDR2 GPU as the nouveau driver did not working correctly in my case (suspend to RAM S3 did not working) I tested this workaround without success.
I did not dug further but I remember at boot there was some extra lines displayed from the console but
startx
does not launched anymore.Note : to revert I had just to re-enable the Debian SID repo and applyied
apt remove nvidia-legacy-340xx-driver firmware-misc-nonfree
, disabled the SID repo,apt update
, reboot and delete the remaining nVidia packages withapt autoremove nvidia* --purge
and finally rebootFor your information, I managed to make nouveau allows the S3 in disabling the init_on_alloc kernel parameter (source) :
Note : this parameter enable heap memory zeroing on allocation by default (more here)
In my case the nouveau driver is working perfectly and I can use the suspend to RAM functionnality.