OPINIONATED OMARCHY
TROUBLESHOOTING CORPUS
790
RECORDS
790
AUDITED
0
UNCHECKED
2388
SOURCES
LIVE
network critical occasional DISPUTE

Restart systemd-resolved when a mid-upgrade DNS failure stops pacman

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

Read omacom/omarchy issue 8395 in full, body and its one comment. The body supports the record's symptom and cause, and I confirmed the mechanism on this Omarchy 4 workstation rather than taking it from the issue. /usr/share/omarchy/migrations/1782002156.sh restarts systemd-resolved with || true at lines 58 and 88, exactly as claimed. /etc/resolv.conf is a symlink to ../run/systemd/resolve/stub-resolv.conf, resolvectl status reports resolv.conf mode: stub, and NetworkManager --print-config shows no dns= key, so NetworkManager auto-selects the resolved backend and never writes /etc/resolv.conf itself. That settles the question the global-dns override raised: /etc/NetworkManager/conf.d/20-omarchy-dns.conf sets a [global-dns-domain-*] Cloudflare block, but omarchy-dns pushes those servers into NetworkManager and into /etc/systemd/resolved.conf, never into resolv.conf, so the override is no fallback. With resolved down the symlink target does not exist and every lookup fails. The failing step is run_final_system_package_upgrade at /usr/bin/omarchy-upgrade-to-quattro:1210, and it runs pacman under OMARCHY_UPDATE_PACMAN=1, so the ALPM guard is not what broke it. Two defects. First, the resume step. The record said sudo pacman -Syu then omarchy update. sudo pacman -Syu is aborted by /usr/bin/omarchy-update-pacman-guard, which refuses any command line carrying both a sync and a sysupgrade flag, and omarchy update is the routine update path rather than the 3 to 4 migration. The script's own cleanup text at /usr/bin/omarchy-upgrade-to-quattro:374 is Fix the error reported above and run this script again. Re-running is safe and resumes the remaining steps., so the correct resume is omarchy upgrade to quattro. Second, the cited source carries a whole branch the record dropped. The comment from @paul-fornage reports the same total DNS failure after the same upgrade on a machine not using systemd-resolved at all, fixed by sudo systemctl restart NetworkManager after nmcli reported a version mismatch. A reader whose resolved is active, or absent, would have been sent nowhere by the record as written, so the fix now branches on which resolver the machine actually uses. I scrutinised both danger clauses. The reboot warning is real and I verified its text, but mismatched boot config understates what the script itself says at line 372, which is that the system is part Omarchy 3 and part quattro and rebooting can leave it with no working network or desktop, so I replaced it with the verified consequence. I also added the hazard the record created and never warned about: its own static /etc/resolv.conf fallback outlives the emergency and silently overrides everything omarchy dns configures. Backed the stub-mode and NetworkManager auto-detection claims against the Arch wiki systemd-resolved page, which gives the same relative symlink form the machine has. Severity stays critical and frequency stays occasional: the reporter says the resolved path needs non-standard conditions and probably cannot be recreated, but the comment shows a second person reaching the same symptom by another route. NOT exercised: I did not run a quattro upgrade, did not stop systemd-resolved and did not restart NetworkManager on this machine, all of which would disrupt a live workstation, so the failure state itself is from the issue and from reading the migration and upgrade scripts, not from a live reproduction.

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

Do not reboot while the upgrade has printed Upgrade incomplete - do NOT reboot.. The script's own wording at /usr/bin/omarchy-upgrade-to-quattro:372 is that the system is part Omarchy 3 and part Omarchy quattro, and rebooting then can leave it with no working network and no desktop. Finish the upgrade first. Separately, the static /etc/resolv.conf fallback outlives the emergency: it bypasses the resolved stub, so omarchy dns changes stop taking effect and VPN split DNS stops working until the symlink is restored.

Symptom

An Omarchy Quattro upgrade dies partway through with pacman unable to resolve anything:


:: Checking for remaining system package updates
error: failed retrieving file 'core.db' from stable-mirror.omarchy.org : Could not resolve host: stable-mirror.omarchy.org
error: failed to synchronize all databases (failed to retrieve some files)

Upgrade incomplete - do NOT reboot.

/etc/resolv.conf is the expected symlink to /run/systemd/resolve/stub-resolv.conf, but systemctl status systemd-resolved shows it inactive (dead). On some machines the same total DNS failure appears with resolved active, or with resolved not installed at all, because the mid-upgrade package update left a stale NetworkManager daemon and nmcli reports a version mismatch.

Cause

Two paths reach the same symptom and the cited issue carries both.

The resolved path. Migration 1782002156 restarts systemd-resolved with || true at lines 58 and 88 of /usr/share/omarchy/migrations/1782002156.sh, so a failed restart is swallowed and the pipeline continues. Omarchy routes all DNS through resolved: /etc/resolv.conf is a symlink to ../run/systemd/resolve/stub-resolv.conf, resolvectl status reports resolv.conf mode: stub, and NetworkManager sets no dns= key, so it auto-detects the resolved backend and does not write /etc/resolv.conf itself. The [global-dns-domain-*] Cloudflare block in /etc/NetworkManager/conf.d/20-omarchy-dns.conf is pushed into NetworkManager and into /etc/systemd/resolved.conf, so it is not a fallback. With resolved down the symlink target does not exist and every lookup fails, including the pacman database sync in run_final_system_package_upgrade at /usr/bin/omarchy-upgrade-to-quattro:1210. The original reporter's non-standard conditions, an ext4 root so the snapshot steps failed and an EFI partition that was never mounted, are what he believes made the restart fail.

The NetworkManager path. On a machine not using resolved, the same upgrade replaces NetworkManager underneath the running daemon, which then goes stale against the new libraries. nmcli reports a version mismatch and asks for a restart, and until NetworkManager is restarted nothing resolves.

Fix

Find out which resolver the machine actually uses before changing anything:


ls -l /etc/resolv.conf
systemctl is-active systemd-resolved NetworkManager

If /etc/resolv.conf points at stub-resolv.conf and resolved is not active, start it:


sudo systemctl enable --now systemd-resolved
resolvectl status | head -20
getent hosts stable-mirror.omarchy.org

If resolved is not in use, or it is active and names still do not resolve, restart NetworkManager. The upgrade replaces it underneath the running daemon and nmcli will report a version mismatch:


sudo systemctl restart NetworkManager
getent hosts stable-mirror.omarchy.org

Then resume the upgrade rather than rebooting. Rerun the same script that failed, which is what it tells you to do and which picks up the remaining steps:


omarchy upgrade to quattro

Do not substitute sudo pacman -Syu, which an ALPM hook aborts because the command line carries both a sync and a sysupgrade flag, and do not substitute omarchy update, which is the routine update path and not the 3 to 4 migration.

If neither resolver will come up, get DNS back just long enough to finish by replacing the symlink with a static file:


sudo rm /etc/resolv.conf
printf 'nameserver 1.1.1.1\nnameserver 9.9.9.9\n' | sudo tee /etc/resolv.conf

Put the symlink back as soon as the upgrade completes, because a static file silently overrides everything omarchy dns configures:


sudo rm /etc/resolv.conf
sudo ln -sf ../run/systemd/resolve/stub-resolv.conf /etc/resolv.conf
sudo systemctl restart systemd-resolved

Verify


systemctl is-active systemd-resolved NetworkManager
resolvectl status | head -20
getent hosts stable-mirror.omarchy.org
ls -l /etc/resolv.conf

getent hosts stable-mirror.omarchy.org returns addresses, /etc/resolv.conf is back to the ../run/systemd/resolve/stub-resolv.conf symlink, and omarchy upgrade to quattro runs to completion with no further Could not resolve host error.

Sources

resolved-inactive-breaks-upgrade-dns