/boot or the ESP runs out of space mid-kernel-upgrade
Cause and steps 1-4 are verified correct, impressively so. Omarchy really does ship /etc/limine-entry-tool.d/omarchy-uki.conf containing ENABLE_UKI=yes and omarchy-defaults.conf containing CUSTOM_UKI_NAME="omarchy", which makes /boot/EFI/Linux/omarchy_linux.efi the exact real path (omarchy-refresh-limine references that literal filename). limine-entry-tool --remove-uki "<kernel name>" is a real documented subcommand. MKINITCPIO_FALLBACK accepts (yes|no|<kernel-name>) so MKINITCPIO_FALLBACK=no is valid, and /etc/limine-entry-tool.d/*.conf is the correct drop-in directory. The fallback claim is right: upstream mkinitcpio's mkinitcpio.d/hook.preset now ships PRESETS=('default') with #PRESETS=('default' 'fallback') commented, and the CHANGELOG says 'The default kernel preset files no longer includes the fallback image'. The record's preset edit matches the real template verbatim, including #fallback_options="-S autodetect".
Step 5 is the problem and it is the kind that leaves a machine unbootable. Three defects. (a) It tells you to add a /efi line to fstab but never to remove the existing /boot line, so mount -a just remounts the ESP at /boot and nothing changes. (b) Once the ESP is unmounted, /boot on the root filesystem is empty, and mkinitcpio -P writes only initramfs: it does NOT write vmlinuz or microcode, both of which come from packages, so the machine has no kernel to boot until those are reinstalled, and the bootloader is never reinstalled at the new path either. (c) On Omarchy the step does not work at all as a remedy: with ENABLE_UKI=yes the UKI is written to $ESP_PATH/EFI/Linux/ by definition, so moving ESP_PATH to /efi relocates the problem rather than solving it, and /etc/default/limine is a file Omarchy manages (it ships default/limine/default.conf with ESP_PATH="/boot"), so a hand edit there can be overwritten. Steps 1-4 stand as written.
Do not reboot while /boot is full or an initramfs/UKI is truncated. You will land in an emergency shell or the firmware will find no boot entry, and recovery needs a live USB. NEVER rm -rf /boot/*: that deletes the bootloader itself (limine/GRUB/systemd-boot), not just kernels, and on a dual-boot machine it deletes /boot/EFI/Microsoft and the /boot/EFI/BOOT/BOOTX64.EFI removable-media fallback too. Removing the fallback initramfs removes your one non-autodetect rescue image. Keep an Arch ISO on a USB stick. Changing the ESP mount point rewrites fstab and bootloader paths, so do it with a live USB within reach.
Symptom
Either pacman refuses to start:
error: Partition /boot too full: 51200 blocks needed, 3184 blocks free
error: not enough free disk space
or the transaction commits and the hook dies afterwards:
==> Creating gzip-compressed initcpio image: '/boot/initramfs-linux.img'
bsdtar: Write error
==> ERROR: Image generation FAILED: 'bsdtar' reported an error
error: command failed to execute correctly
df -h /boot shows a 260 MB to 512 MB FAT32 partition at 100%. The kernel package is registered as installed but there is no usable vmlinuz/initramfs to boot.
Cause
The ESP is mounted at /boot and every installed kernel writes vmlinuz-* plus initramfs-*.img (plus a fallback image on older installs, plus microcode) into it. Omarchy 4 is worse: limine-entry-tool is configured with ENABLE_UKI=yes, so each kernel becomes a single 100 to 200 MB Unified Kernel Image at /boot/EFI/Linux/omarchy_linux.efi, and snapshots multiply that. FAT32 has no reserved blocks, pacman's CheckSpace estimate is only approximate, and the UKI/initramfs is written by a **PostTransaction** hook, i.e. after pacman has already committed. Arch recommends a 1 GiB ESP. 260 MiB is merely the FAT32 formatting minimum on a 4Kn drive, not a working size.
Fix
Replace step 5 with the following. Steps 1-4 are unchanged.
**5a. Omarchy 4: do NOT try to move the ESP.** With ENABLE_UKI=yes the UKI is written to $ESP_PATH/EFI/Linux/ by definition, so relocating the ESP relocates the problem. On Omarchy the space is consumed by *snapshot* boot entries, so cap those instead:
ls -lhS /boot/EFI/Linux/ # one UKI per kernel, plus one per snapshot entry
sudo limine-entry-tool --remove-uki "<kernel name>" # e.g. linux-zen, for kernels you removed
Trim snapshots and the entries built from them:
sudo snapper -c root list
sudo snapper -c root delete <oldest ranges>
sudo limine-snapper-sync
To keep fewer snapshot boot entries permanently, add a drop-in (never edit /etc/default/limine, which Omarchy owns):
sudo tee /etc/limine-entry-tool.d/98-fewer-entries.conf >/dev/null <<'EOF'
MAX_SNAPSHOT_ENTRIES=3
EOF
sudo limine-update
and lower NUMBER_LIMIT in /etc/snapper/configs/root to match.
**5b. Plain Arch / EndeavourOS / CachyOS with a genuinely undersized ESP (<512 MiB): move the ESP to /efi and keep /boot on the root filesystem.** This only works with a bootloader that can read your root filesystem (GRUB, limine without UKI). Do it in this order, and have installation media on hand:
# 1. Note the ESP UUID BEFORE unmounting
findmnt -no SOURCE,UUID /boot
# 2. Edit fstab: DELETE or comment the existing /boot line, then add the /efi line
sudoedit /etc/fstab
# /boot line removed - /boot now lives on the root filesystem
UUID=XXXX-XXXX /efi vfat fmask=0137,dmask=0027 0 2
# 3. Remount
sudo mkdir -p /efi
sudo umount /boot
sudo mount -a
findmnt /efi /boot # /efi = vfat; /boot must NOT appear as a separate mount
# 4. /boot is now empty. Reinstall the kernel and microcode to repopulate vmlinuz + initramfs.
# mkinitcpio alone is NOT enough - it does not write vmlinuz.
sudo pacman -S linux linux-firmware
sudo pacman -S amd-ucode # or intel-ucode, whichever you have
ls -l /boot # must now show vmlinuz-linux and initramfs-linux.img
# 5. Reinstall the bootloader at the new ESP path, or it still looks in the old one.
# GRUB:
sudo grub-install --target=x86_64-efi --efi-directory=/efi --bootloader-id=GRUB
sudo grub-mkconfig -o /boot/grub/grub.cfg
# systemd-boot:
sudo bootctl --esp-path=/efi install
Verify /boot/vmlinuz-* and /boot/initramfs-*.img exist and the bootloader config points at them **before** rebooting.
Verify
df -h /boot shows free space. ls -l --time-style=full-iso /boot/vmlinuz-linux /boot/initramfs-linux.img (or /boot/EFI/Linux/omarchy_linux.efi) shows a non-zero size with a timestamp from the last minute. sudo pacman -S linux completes with no command failed to execute correctly.
Sources
- https://bbs.archlinux.org/viewtopic.php?id=278308
- https://wiki.archlinux.org/title/EFI_system_partition
- https://wiki.archlinux.org/title/Mkinitcpio
- https://wiki.archlinux.org/title/Limine
- https://gitlab.com/Zesko/limine-entry-tool/-/blob/master/README.md
- https://github.com/basecamp/omarchy/discussions/3700