I installed the NVIDIA 510 drivers from the Additional Drivers app on Ubuntu 22.04. I also edited /etc/default/grub and added GRUB_CMDLINE_LINUX="nvidia-drm.modeset=1". Unfortunately, it didn't work. I can't see the little gear icon when I login.
Funnily enough I had 21.10 running before this install and it was working in Wayland after editing /etc/default/grub.
Here is my setup. It's a very recent Dell Laptop with Secure Boot enabled:
34 Answers
In the file /usr/lib/udev/rules.d/61-gdm.rulesin my case, I just commented the last two one here
LABEL="gdm_prefer_xorg"
#RUN+="/usr/lib/gdm-runtime-config set daemon PreferredDisplayServer xorg"
GOTO="gdm_end"
LABEL="gdm_disable_wayland"
#RUN+="/usr/lib/gdm-runtime-config set daemon WaylandEnable false"
GOTO="gdm_end"It did work on Ubuntu 22.04 or if still does not work, you can comment something that is related to it.
2Two possible solutions:
Enable unreleased updates [ Alberto Milone ]
- Default to Wayland for hybrid systems with Nvidia graphics drivers.
- Default to Xorg but offer Wayland with the gear button on the login screen for non-hybrid systems with Nvidia graphics drivers. (LP: #1968929)
Workaround Create a file in
/etc/modprobe.d/nvidia-power-management.confcontaining the text:options nvidia NVreg_PreserveVideoMemoryAllocations=1
Otherwise, follow these bug reports:
1Because /tmp is a tmpfs on my system, i need to set
options nvidia NVreg_PreserveVideoMemoryAllocations=1 NVreg_TemporaryFilePath=/var/tmpin /etc/modprobe.d/nvidia-power-management.conf. After rebuilding initramfs with update-initramfs -u and a reboot, Wayland is working for me.
From this article:
sudo nano /etc/gdm3/custom.confWithin this file, look for the line that says
#WaylandEnable=false. You can uncomment this line and either set it to true or false, depending on whether you want Wayland enabled or not.WaylandEnable=true