OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
power-suspend high occasional DISPUTE

Fix hibernation that hangs or reboots instead of powering off

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

The fix itself is right and survives every check. The Arch wiki section "System does not power off when hibernating", fetched as raw wikitext, prescribes exactly HibernateMode=shutdown in /etc/systemd/sleep.conf.d/hibernatemode.conf, and the adjacent section "Operating system not found (or wrong OS booting) when booting after hibernation" supports the record's extra claim about an external boot disk, which was previously unsourced in effect. The installed systemd-sleep.conf(5) on systemd 261.2-1 still documents HibernateMode=, and /etc/systemd/sleep.conf on this machine shows the compiled default as HibernateMode=platform shutdown, so platform is tried first. The cause is wrong against the record's own cited issue. I read omacom/omarchy#8589 in full through the API: on that machine swsusp_save() aborted DURING image creation, none of its own outcome lines printed even with pm_debug_messages=1, and the kernel unwound and half-resumed, so no image was written at all. The record says the opposite, that the image is written correctly. The "image written, then reboots" shape the record describes is real but belongs to a second machine family, omacom/omarchy#10038 (pre-T2 Intel MacBookPro11,1), linked from a comment on 8589. Both shapes are now in the cause, labelled. Three Omarchy 4 corrections, all checked here. /etc/systemd/sleep.conf.d/ does not exist on a stock install (ls reports no such directory, the only file is /etc/systemd/sleep.conf owned by systemd 261.2-1 with everything commented), so the fix now creates it. sudo systemctl daemon-reload was the wrong refresh: systemctl cat systemd-hibernate.service shows ExecStart=/usr/lib/systemd/systemd-sleep hibernate, and that binary reads sleep.conf and its drop-ins at every invocation, so nothing needs reloading. It is replaced with systemd-analyze cat-config systemd/sleep.conf. And the danger warned about resume= and resume_offset= without saying where they live on Omarchy 4: /usr/share/omarchy/bin/omarchy-hibernation-setup writes them into /etc/limine-entry-tool.d/resume.conf and the resume hook into /etc/mkinitcpio.conf.d/omarchy_resume.conf, both of which are present on this workstation, and they reach the kernel only after limine-mkinitcpio and a reboot. I also corrected the verify: the kernel strings the report quotes are pm_pr_dbg and pm_deferred_pr_dbg calls in kernel/power/hibernate.c line 850 and kernel/power/snapshot.c lines 2121 and 2145, so they print only with pm_debug_messages=1, and the exact current text is "Image created (%d pages copied, %d zero pages)". Severity and frequency are left alone. Not exercised: nothing was hibernated. This workstation is a DESKTOP (Gigabyte Z390 AORUS ULTRA, no battery), so its /sys/power/disk reading of [platform] shutdown reboot suspend test_resume confirms only that platform is the default here, and says nothing about the laptop firmware in either issue. The basecamp/omarchy URL on the record still redirects but the repository is now omacom/omarchy, so the canonical URL replaces it.

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

With HibernateMode=shutdown the machine looks like a normal power-off. If resume= or resume_offset= are wrong you will boot a fresh session and silently lose everything that was open. On Omarchy 4 those two parameters live in /etc/limine-entry-tool.d/resume.conf and reach the kernel only after sudo limine-mkinitcpio and a reboot, so check that /proc/cmdline actually carries them before trusting a hibernate.

Symptom

systemctl hibernate does not power the machine off. Either it hangs with the display dead and the keyboard backlight still on, and only a forced power-off recovers it, or it reboots instead of shutting down and the next cold boot resumes the session anyway. In the hang case the last kernel lines are:


PM: hibernation: Creating image
PM: hibernation: Need to copy 3457488 pages
ACPI: PM: Restoring platform NVS memory

and swsusp_save() printed none of its own outcomes, so the machine was already unwinding.

Cause

The firmware's ACPI S4 sleeping state is unreliable on this board, and systemd's compiled default is HibernateMode=platform shutdown, which tries platform first. Two different failures come out of that. On some machines the kernel aborts inside swsusp_save() while creating the image, unwinds and half-resumes, so no image is ever written and the machine sits powered on with a dead display. Reported on the ASUS ROG Zephyrus G14 (GA403UV) in omacom/omarchy#8589. On others the image is written correctly but the platform reboots instead of entering S4, and the following cold boot resumes the session. Reported on a pre-T2 Intel MacBookPro11,1 in omacom/omarchy#10038. The built-in shutdown fallback rescues neither, because systemd falls back only when the write to /sys/power/disk itself fails, and here the write succeeds and the firmware misbehaves afterwards.

Fix

Tell systemd to write the image and then do a plain shutdown instead of entering S4. The drop-in directory does not exist on a stock Omarchy 4 install, so create it first:


sudo mkdir -p /etc/systemd/sleep.conf.d

# /etc/systemd/sleep.conf.d/hibernate-mode.conf
[Sleep]
HibernateMode=shutdown

Nothing needs restarting or reloading. systemd-hibernate.service runs ExecStart=/usr/lib/systemd/systemd-sleep hibernate, and that binary reads sleep.conf and its drop-ins on every invocation. Check the merged configuration, then hibernate:


systemd-analyze cat-config systemd/sleep.conf | grep -i hibernatemode
systemctl hibernate

Leave /etc/systemd/sleep.conf alone. It is shipped by the systemd package with every entry commented out, and a drop-in is the documented way to override it.

The same setting fixes the related "Operating system not found" or wrong-OS-boots case after hibernating from an external disk.

On Omarchy 4 this only helps if hibernation is configured at all. omarchy-hibernation-setup is what configures it: a btrfs swapfile at /swap/swapfile, HOOKS+=(resume) in /etc/mkinitcpio.conf.d/omarchy_resume.conf, resume= and resume_offset= in /etc/limine-entry-tool.d/resume.conf, then a UKI rebuild with limine-mkinitcpio. Confirm that before blaming the sleep mode:


omarchy-hibernation-available
echo "exit=$?"          # 0 means swap and the resume hook are both in place
cat /etc/limine-entry-tool.d/resume.conf
grep -o 'resume=[^ ]*' /proc/cmdline

Verify

systemctl hibernate results in a fully powered-off machine (fans off, no LEDs), and pressing the power button resumes the previous session rather than booting fresh. For a log-level check, add pm_debug_messages=1 to the kernel command line first, because the hibernation progress lines are debug-only: Image created (N pages copied, N zero pages) from kernel/power/snapshot.c says the image was built, and Hibernation image restored successfully. from kernel/power/hibernate.c appears only on the resume-from-image path, so together they prove a real write, power-off and restore cycle. Read them with journalctl -k -b | grep -i 'hibernation'.

Sources

hibernate-does-not-power-off-hibernatemode-shutdown