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

Fix hibernation that cold-boots instead of resuming on NVIDIA

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

Checked on this Omarchy 4.0.2-1 workstation, which has a real NVIDIA GPU (RTX 3090, GA102 10de:2204), nvidia-open-dkms 610.57.04-1 loaded, early KMS configured, mkinitcpio 41.1-1 and limine-mkinitcpio-hook 1.37.1-1, and against all three cited sources read in full plus omacom/omarchy#8126. The symptom and the direction of the fix are correct and all three cited URLs resolve and say what the record claims. The Arch NVIDIA page carries the note "Early loading the modules will break hibernation, as video memory preservation is enabled by default", the Tips and tricks page carries the NVreg_TemporaryFilePath sentence the record's cause paraphrases, and the Hyprland Nvidia page warns twice that early loading "may cause resuming from hibernation to not work anymore (i.e. the system will just boot instead of resuming)". So no source is removed. Four things were wrong or incomplete for Omarchy 4. First, sudo mkinitcpio -P fails outright: /etc/mkinitcpio.d/ is empty on this machine and mkinitcpio line 986 dies with No presets found in /etc/mkinitcpio.d, so the Omarchy 4 rebuild is sudo limine-mkinitcpio. Second, the rm is correct but not durable, and the record does not say so: /etc/mkinitcpio.conf.d/nvidia.conf is owned by no package, and /usr/share/omarchy/install/hardware/nvidia.sh recreates it with cat > whenever omarchy-apply-hardware runs, which omarchy-apply-system calls at lines 94 and 96. Third, the record misses a side effect I read in /etc/mkinitcpio.conf.d/omarchy_hooks.conf (owned by omarchy-settings): that drop-in strips the kms hook only while nvidia_drm is in MODULES, so removing the nvidia drop-in reinstates kms and pulls nouveau and its GSP firmware back into the image. Fourth, the verify and danger both named files that do not exist here. /boot/initramfs-linux.img is not built, because /etc/limine-entry-tool.d/omarchy-uki.conf sets ENABLE_UKI=yes and omarchy-defaults.conf sets CUSTOM_UKI_NAME="omarchy", and cat /sys/module/nvidia_drm/parameters/modeset fails for a normal user because that file is mode 0400. The danger told the reader to boot a fallback initramfs entry, and there is none: MKINITCPIO_FALLBACK is commented out in /etc/limine-entry-tool.conf line 179 and set nowhere else, and limine-list prints only Omarchy / linux, two Snapshots, and the Limine binary's own EFI fallback. The cause was rewritten rather than replaced, keeping the wiki's claim but adding what is observable here: /proc/driver/nvidia/params reports PreserveVideoMemoryAllocations: 1, UseKernelSuspendNotifiers: 1, TemporaryFilePath: "/var/tmp", and the Preserve value comes from /usr/lib/modprobe.d/gsr-nvidia.conf owned by gpu-screen-recorder 6.0.1-1, not from an Arch default, which matters because on 595-and-newer drivers Arch leaves it to kernel suspend notifiers instead. The precise failure mechanism and the kernel log in the new symptom come from omacom/omarchy#8126, where a reporter with the same driver version and kernel reproduced it. Frequency moves from occasional to common because Omarchy 4 writes the early-KMS drop-in on every NVIDIA machine at install and configures resume= itself, so this is the default state of an Omarchy NVIDIA box rather than an unusual configuration. Severity stays medium: the machine boots and only the unsaved session is lost. Not exercised: I have no sudo and was instructed not to hibernate or touch the initramfs, so I did not rebuild, did not delete the drop-in, and did not observe a hibernate resume either failing or succeeding. The PreserveVideoMemoryAllocations=0 branch is reported behaviour from #8126 and I did not test it.

The cause above was rewritten on 2026-09-11 to match this note; the fix was corrected by the audit itself.
RISK

You are rebuilding the initramfs and rewriting the UKI on the ESP. Omarchy 4 builds no fallback initramfs entry, so the record's old advice to boot one points at nothing: MKINITCPIO_FALLBACK is left commented out in /etc/limine-entry-tool.conf and is set nowhere in /etc/limine-entry-tool.d/ or /etc/default/limine, and limine-list shows one kernel entry plus Snapshots plus the Limine binary's own EFI fallback, which is not a kernel. If the machine black-screens before Hyprland, recovery is a Limine btrfs snapshot entry, so run limine-list beforehand to see which exist, or a chroot from the Omarchy ISO to restore /etc/mkinitcpio.conf.d/nvidia.conf and re-run limine-mkinitcpio. Testing the fix means hibernating, and a failed resume discards everything that was open, so do it from a session with nothing unsaved. On a plain Arch install with mkinitcpio -P and a linux-fallback preset the fallback entry does exist and is the right recovery there.

Symptom

You hibernate with systemctl hibernate, and on power-on the machine boots normally instead of restoring the session. Every application is gone, as if you had shut down. On Omarchy 4 this needs no action on your part to trigger: the installer early-loads the NVIDIA modules on every NVIDIA machine. On plain Arch it usually starts after adding the NVIDIA modules to the initramfs to fix a black screen. journalctl -b -1 -k from the failed attempt shows the image loading and the driver then refusing:


PM: Image successfully loaded
NVRM: GPU 0000:01:00.0: PreserveVideoMemoryAllocations module parameter is set.
      System Power Management attempted without driver procfs suspend interface.
nvidia 0000:01:00.0: PM: pci_pm_freeze(): nv_pmops_freeze [nvidia] returns -5
PM: hibernation: Failed to load image, recovering.
PM: hibernation: resume failed (-5)

Cause

Early KMS loads nvidia, nvidia_modeset, nvidia_uvm and nvidia_drm from the initramfs. With video memory preservation turned on, the driver requires a save and restore handshake at every power management transition, and at the point the hibernation image is loaded the initramfs kernel already has nvidia bound with no userspace to drive that handshake. The driver refuses the transition with -5, the kernel abandons the resume and continues into a normal boot. The Arch wiki states the consequence directly under DRM kernel mode setting: "Early loading the modules will break hibernation, as video memory preservation is enabled by default", and its Tips and tricks page adds that the early-loaded module "has no access to NVreg_TemporaryFilePath which stores the previous video memory: early KMS should not be used if hibernation is desired". The Hyprland wiki repeats the same warning twice.

On Omarchy 4 preservation is definitely on. /proc/driver/nvidia/params on an Omarchy 4.0.2 workstation running nvidia-open-dkms 610.57.04-1 reports PreserveVideoMemoryAllocations: 1, UseKernelSuspendNotifiers: 1 and TemporaryFilePath: "/var/tmp". The 1 comes from /usr/lib/modprobe.d/gsr-nvidia.conf, owned by gpu-screen-recorder, which Omarchy installs, so it is set even on the 595-and-newer drivers where Arch alone would leave it off and rely on kernel suspend notifiers. Omarchy 4 also writes /etc/mkinitcpio.conf.d/nvidia.conf with MODULES+=(nvidia nvidia_modeset nvidia_uvm nvidia_drm) on every NVIDIA machine during install, and configures hibernation itself through /etc/mkinitcpio.conf.d/omarchy_resume.conf and a resume= kernel argument in /etc/limine-entry-tool.d/resume.conf. An Omarchy NVIDIA machine therefore arrives in this state without anyone choosing it.

Fix

Drop early module loading. nvidia_drm modeset=1 from /etc/modprobe.d/nvidia.conf still applies with a late load, so only the early load goes.

**Omarchy 4:**


sudo rm /etc/mkinitcpio.conf.d/nvidia.conf
sudo limine-mkinitcpio

Use limine-mkinitcpio, not mkinitcpio -P. Omarchy 4 keeps /etc/mkinitcpio.d/ empty and builds a UKI at /boot/EFI/Linux/omarchy_linux.efi, so mkinitcpio -P stops with ERROR: No presets found in /etc/mkinitcpio.d.

Two Omarchy-specific consequences the plain Arch advice does not have:

  • /usr/share/omarchy/install/hardware/nvidia.sh recreates that drop-in unconditionally with cat >. Running omarchy apply hardware, or omarchy-apply-system which calls it, puts early KMS straight back. Re-run the two commands above after any such reapply. A routine omarchy update does not call it.
  • /etc/mkinitcpio.conf.d/omarchy_hooks.conf drops the kms hook only while nvidia_drm is present in MODULES. With the drop-in gone that test is false, kms stays in HOOKS, and autodetect pulls nouveau and its GSP firmware into the image. nouveau is blacklisted by /usr/lib/modprobe.d/nvidia-utils.conf so it will not take the GPU, but the image grows by roughly 100 MB, which the upstream comment in that drop-in calls out.

**Plain Arch and other Arch derivatives:** the modules are usually in MODULES=(...) in /etc/mkinitcpio.conf itself, or in a distribution drop-in under /etc/mkinitcpio.conf.d/. Remove nvidia nvidia_modeset nvidia_uvm nvidia_drm from wherever they are set, then rebuild:


sudo mkinitcpio -P

Keep /etc/modprobe.d/nvidia.conf with options nvidia_drm modeset=1 in both cases. Reboot and re-test hibernate.

If early KMS is what is holding your display up and you will not give it up, the other side of the trade is to turn preservation off and accept losing video memory contents across a sleep:


printf 'options nvidia NVreg_PreserveVideoMemoryAllocations=0\n' | sudo tee /etc/modprobe.d/zz-nvidia-no-preserve.conf
sudo limine-mkinitcpio

The zz- prefix matters, because modprobe sorts its config files by name and the last options line for a parameter wins, so anything sorting before gsr-nvidia.conf would be ignored. Omarchy users report corrupted GPU state after resume in that configuration (NVRM: Xid ... 13, Graphics Exception across the compositor, the shell and the browser, in omacom/omarchy#8126), so treat it as a trade, not a fix. You cannot have working suspend-with-preservation and working hibernate on the same early-KMS machine.

Verify

**Omarchy 4:**


ls /etc/mkinitcpio.conf.d/nvidia.conf                              # No such file or directory
sudo lsinitcpio /boot/EFI/Linux/omarchy_linux.efi | grep nvidia    # returns nothing
sudo cat /sys/module/nvidia_drm/parameters/modeset                 # still Y

All three need root. /boot is a vfat ESP mounted dmask=0077 so an ordinary user cannot even list it, and /sys/module/nvidia_drm/parameters/modeset is mode 0400. lsinitcpio 41.1 detects a UKI and unpacks it with objcopy, so pointing it at the .efi works. There is no /boot/initramfs-linux.img on Omarchy 4.

**Plain Arch:**


sudo lsinitcpio /boot/initramfs-linux.img | grep nvidia            # returns nothing
sudo cat /sys/module/nvidia_drm/parameters/modeset                 # still Y

Then systemctl hibernate from a session you can afford to lose, and on power-on your windows are back where they were.

Sources

nvidia-early-kms-breaks-hibernation