From 820306b9a34de488da8db937677205d54aecf688 Mon Sep 17 00:00:00 2001 From: Mateus Pegorim Date: Sun, 5 Jul 2026 19:53:51 -0300 Subject: [PATCH] Remove stale 99-omarchy-nofile.conf via migration The 99-omarchy-nofile.conf drop-ins used `DefaultLimitNOFILESoft`, which is not a valid systemd [Manager] setting. systemd rejects it at manager load on every boot: /etc/systemd/system.conf.d/99-omarchy-nofile.conf: Unknown key 'DefaultLimitNOFILESoft' in section [Manager], ignoring. They were superseded by 20-omarchy-nofile.conf (which correctly uses `DefaultLimitNOFILE=65536:524288`), but the 99- files are unowned by any package and linger on upgraded systems, spamming the journal every boot. Add a migration that removes the orphaned drop-ins from both system.conf.d and user.conf.d. The 20- drop-in already sets the limit. Co-Authored-By: Claude --- migrations/1783292001.sh | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 migrations/1783292001.sh diff --git a/migrations/1783292001.sh b/migrations/1783292001.sh new file mode 100644 index 0000000000..0d094e8e37 --- /dev/null +++ b/migrations/1783292001.sh @@ -0,0 +1,32 @@ +echo "Remove stale 99-omarchy-nofile.conf systemd drop-ins" + +# Earlier Omarchy shipped 99-omarchy-nofile.conf using the key +# 'DefaultLimitNOFILESoft', which is not a valid systemd manager setting. +# systemd rejects it at manager load on every boot: +# /etc/systemd/system.conf.d/99-omarchy-nofile.conf: Unknown key +# 'DefaultLimitNOFILESoft' in section [Manager], ignoring. +# It was replaced by 20-omarchy-nofile.conf (DefaultLimitNOFILE=soft:hard), +# but the orphaned 99- files are unowned by any package and linger on +# upgraded systems, spamming the journal on every boot. Remove them; the +# 20-omarchy-nofile.conf drop-in already sets the limit correctly. + +as_root() { + if (( EUID == 0 )); then + "$@" + else + sudo "$@" + fi +} + +removed=0 +for f in \ + /etc/systemd/system.conf.d/99-omarchy-nofile.conf \ + /etc/systemd/user.conf.d/99-omarchy-nofile.conf; do + if [[ -f $f ]]; then + as_root rm -f "$f" && removed=1 + fi +done + +if (( removed )); then + as_root systemctl daemon-reload >/dev/null 2>&1 || true +fi