From 53a07811c803000a448780a7d2c9e6dcb5bed55a Mon Sep 17 00:00:00 2001 From: Ryan Hughes Date: Thu, 21 May 2026 00:58:58 -0400 Subject: [PATCH] limine-snapper.sh: write /etc/kernel/cmdline and rebuild UKI In the package-based install, omarchy-limine is a hard dep of omarchy, so archinstall pacstraps limine-mkinitcpio-hook (via omarchy-limine's depends) early. That triggers a UKI build BEFORE limine-snapper.sh runs, which means the UKI is built with no kernel cmdline (the 'Kernel command line is not available' warning in the archinstall log). The system then can't unlock the LUKS root on boot because the encrypt hook has no cryptdevice= to act on, and drops to an emergency shell. The previous flow worked because 'pacman -S limine-mkinitcpio-hook' inside limine-snapper.sh installed the hook for the first time, firing its post-transaction UKI rebuild AFTER /etc/default/limine had been written. With it pre-installed, '--needed' makes that line a no-op. Fix: after writing /etc/default/limine, write the same cmdline to /etc/kernel/cmdline (the source mkinitcpio --uki reads) and explicitly run mkinitcpio -P to rebuild the UKIs with the correct cmdline. --- install/login/limine-snapper.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/install/login/limine-snapper.sh b/install/login/limine-snapper.sh index ce9fffbb..85e7a94e 100644 --- a/install/login/limine-snapper.sh +++ b/install/login/limine-snapper.sh @@ -53,7 +53,19 @@ EOF # We overwrite the whole thing knowing the limine-update will add the entries for us sudo cp $OMARCHY_PATH/default/limine/limine.conf /boot/limine.conf - sudo pacman -S --noconfirm --needed limine-snapper-sync limine-mkinitcpio-hook + # The UKI must embed the kernel cmdline (read by mkinitcpio --uki from + # /etc/kernel/cmdline) so the early encrypt hook can find cryptdevice=... + # to unlock /dev/mapper/root. archinstall doesn't write this file; the + # initial UKI built when limine-mkinitcpio-hook was pulled in via + # omarchy-limine's depends was built with an empty cmdline, dropping us + # to the emergency shell on first boot. + echo "$CMDLINE" | sudo tee /etc/kernel/cmdline >/dev/null + + # Force a UKI rebuild now that /etc/default/limine and /etc/kernel/cmdline + # exist. limine-snapper-sync and limine-mkinitcpio-hook are already + # installed (via omarchy-limine's depends), so 'pacman -S --needed' here + # is a no-op and won't re-trigger the post-transaction UKI rebuild. + sudo mkinitcpio -P # Only snapshot root — /home is user data; rolling it back loses user work if ! sudo snapper list-configs 2>/dev/null | grep -q "root"; then