NVIDIA 470.63.01 + Xwayland on Fedora 34 and Gnome 40.2

This is guide, howto enable NVIDIA accelerated 3D rendering and Xwayland on on Fedora 34 with NVIDIA 470.63.01 proprietary drivers on GNOME 40.2. Tested with latest NVIDIA drivers, I assume here that you have installed NVIDIA drivers using this guide. This might work normally with any other installation methods too, but it’s not tested.

Note: Do this using fully updated system and latest kernel, also NVIDIA 470.63.01 drivers installed. Check also NVIDIA’s own guide for this OpenGL and Vulkan on Xwayland.

Check video version of guide:

Watch More Videos and Subscribe to
if-not-true-then-false.com Youtube Channel

Before you start you will at least following packages installed:

  • Xwayland >= 21.1.1.901
  • libxcb >= 1.13
  • egl-wayland >= 1.1.7

Check your packages using following command:

dnf list installed xorg-x11-server-Xwayland libxcb egl-wayland

If some missing, then install all using following command:

dnf install xorg-x11-server-Xwayland libxcb egl-wayland

8. Enable Xwayland with NVIDIA 470.63.01 proprietary drivers on Fedora 34 GNOME 40.2 desktop

8.1 Change root user

su -
## OR ##
sudo -i

8.2 Edit /etc/default/grub

Append ‘nvidia-drm.modeset=1’ to end of ‘GRUB_CMDLINE_LINUX=”…”‘.

## Example row with Fedora 34 BTRFS ##
GRUB_CMDLINE_LINUX="rhgb quiet rd.driver.blacklist=nouveau nvidia-drm.modeset=1"

## OR with LVM ##
GRUB_CMDLINE_LINUX="rd.lvm.lv=fedora/swap rd.lvm.lv=fedora/root rhgb quiet rd.driver.blacklist=nouveau nvidia-drm.modeset=1"

8.3 Update grub2 conf

Fedora 34

## BIOS and UEFI ##
grub2-mkconfig -o /boot/grub2/grub.cfg

Fedora 33/32/31/30

## BIOS ##
grub2-mkconfig -o /boot/grub2/grub.cfg

## UEFI ##
grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg

8.4 Update /usr/lib/udev/rules.d/61-gdm.rules

Comment line which starts with DRIVER==”nvidia”:

# disable Wayland on Hi1710 chipsets
ATTR{vendor}=="0x19e5", ATTR{device}=="0x1711", RUN+="/usr/libexec/gdm-runtime-config set daemon WaylandEnable false"
# disable Wayland when using the proprietary nvidia driver
#DRIVER=="nvidia", RUN+="/usr/libexec/gdm-runtime-config set daemon WaylandEnable false"
# disable Wayland if modesetting is disabled
IMPORT{cmdline}="nomodeset", RUN+="/usr/libexec/gdm-runtime-config set daemon WaylandEnable false"

8.5 Generate initramfs

## Backup old initramfs nvidia-nomodeset image ##
mv /boot/initramfs-$(uname -r).img /boot/initramfs-$(uname -r)-nvidia-nomodeset.img
 
## Create new initramfs image ##
dracut /boot/initramfs-$(uname -r).img $(uname -r)

8.6 Enable kms-modifiers through gsettings (as normal user)

gsettings set org.gnome.mutter experimental-features [\"kms-modifiers\"]

8.7 Reboot

reboot

When you system boot you should be able to select GNOME Wayland session, login using it and open terminal and type:

echo $XDG_SESSION_TYPE

Output should be Wayland.

3,034 comments on “NVIDIA 470.63.01 + Xwayland on Fedora 34 and Gnome 40.2

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Close