OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
gpu-drivers critical very-common DISPUTE

Enable nvidia_drm modeset so Hyprland can start on NVIDIA

omarchyarchendeavouroscachyosmanjarohyprlandwaylandnvidiadesktoplaptop
CORRECTED An auditor found the fix wrong or incomplete and rewrote it.
AUDIT NOTE

Diagnosis and the modeset=1 fix are correct and match upstream (Hyprland wiki 'Early KMS, modeset and fbdev', and Arch NVIDIA#DRM kernel mode setting), and the Omarchy nvidia.sh quoted really does write those two files (verified against master). But the record hands the user early KMS as if it were part of the fix. Arch wiki states plainly: 'For basic functionality, just adding the kernel parameter should suffice' and 'Early loading the modules will break hibernation, as video memory preservation is enabled by default', so this record creates the exact problem that record [4] then tells them to undo. Also printf ... | sudo tee /etc/modprobe.d/nvidia.conf silently clobbers an existing file of that name (Omarchy's own), and fbdev only needs setting on legacy branches.

The cause above was not rewritten and may still contain the error described. The fix below is the corrected version.
RISK

Editing mkinitcpio and rebuilding the initramfs can make the system unbootable if you typo a module name. Keep a fallback boot entry (Arch ships *-fallback.img) and a live USB handy. Never run mkinitcpio -P in the middle of a half-finished pacman transaction.

Symptom

After installing the NVIDIA driver, Hyprland does not start on Wayland. The screen goes black at boot or right after login, or Hyprland exits back to the TTY. The log shows backend failed to start. Switching to a TTY may still work. cat /sys/module/nvidia_drm/parameters/modeset prints N.

Cause

Wayland compositors require DRM kernel mode setting on the NVIDIA driver. Without nvidia_drm.modeset=1, aquamarine (Hyprland's backend) cannot get a DRM master / usable framebuffer, so the compositor never brings up an output. Since nvidia-utils 560.35.03-5 Arch enables modeset by default, so this mostly bites users on older/legacy AUR driver branches (nvidia-580xx, nvidia-470xx, nvidia-390xx), on custom kernels, or on systems where somebody put nvidia_drm.modeset=0 on the kernel command line.

Fix

Verify first:


cat /sys/module/nvidia_drm/parameters/modeset   # want: Y
cat /sys/module/nvidia_drm/parameters/fbdev     # want: Y

On Arch, nvidia-utils already enables both by default (since 560.35.03-5, via /usr/lib/modprobe.d/), so you only need this on legacy AUR branches (nvidia-580xx/470xx/390xx), custom kernels, or a hand-installed .run driver:


# use a distinct filename so you don't clobber Omarchy's /etc/modprobe.d/nvidia.conf
printf 'options nvidia_drm modeset=1 fbdev=1\n' | sudo tee /etc/modprobe.d/nvidia-drm-modeset.conf
sudo mkinitcpio -P

Do NOT add the nvidia modules to the initramfs to fix this. Early loading is not needed for modeset, and the Arch wiki warns it breaks resume from hibernation (the driver has no access to NVreg_TemporaryFilePath in the initramfs). Only add early KMS if the module is genuinely loading after your display manager:


sudo tee /etc/mkinitcpio.conf.d/nvidia.conf >/dev/null <<'EOF'
MODULES+=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)
EOF
sudo mkinitcpio -P

(That second file is what Omarchy's install/config/hardware/nvidia.sh writes. Remove it if you hibernate.)

Then check nothing on the kernel command line forces it off:


cat /proc/cmdline    # look for nvidia_drm.modeset=0

Remove it in your bootloader (systemd-boot uses options in /boot/loader/entries/*.conf, Limine uses cmdline: in /boot/limine.conf, and GRUB uses GRUB_CMDLINE_LINUX_DEFAULT in /etc/default/grub + sudo grub-mkconfig -o /boot/grub/grub.cfg). Reboot.

Verify

cat /sys/module/nvidia_drm/parameters/modeset returns Y, and Hyprland starts and shows a desktop. hyprctl monitors lists your outputs.

Sources

nvidia-drm-modeset-disabled-black-screen-hyprland