You are not logged in.
Pages: 1
Hi all
when running
mkinitcpio -P
i get this error:
==> ERROR: Invalid option -U -- '/efi/EFI/Linux/arch-linux-hardened.efi' must be writable
directory:
/mnt/boot
contains:
EFI initramfs-linux-hardened.img initramfs-linux-hardened-fallback.img loader vmlinuz-linux-hardened
loader & EFI were created by
bootctl install
.
required directory "exists":
EFI/EFI/Linux
using sudo does not change a thing
Is the issue with the naming of efi vs EFI?
Where is the option -U passed?
I got 845.5M available, is 1 gig not enough for the uki? If so what size would you recommend?
Thank you
Last edited by Lessclue (2025-05-30 13:29:19)
Offline
Unless you have a really big image 1GB should be enough.
Similarly, FAT (the filesystem which I'm assuming is at /mnt/boot ) doesn't care about the case of case-sensitivity, everything will appear uppercase to it.
Short file names passed to the file system are always converted to upper case and their original case value is lost.
from the Microsoft FAT Specification section 6.1
Now for your problem could you run the mkinitcpio with the --verbose flag? That will give us more information
P.S. you can have a look at this post: https://bbs.archlinux.org/viewtopic.php?id=299115 that might give you some leads on diagnosing your problem
Offline
Thank you, the error was due to a typo, leading to a non existing directory, however now I am stuck again at this output:
==> Building image from preset: /etc/mkinitcpio.d/linux-hardened.preset: 'default'
==> Using default configuration file: '/etc/mkinitcpio.conf'
-> -v -k /mnt/boot/vmlinuz-linux-hardened -U /mnt/boot/EFI/Linux/arch-linux-hardened.efi -g /mnt/boot/initramfs-linux-hardened.img --splash /usr/share/systemd/bootctl/splash-arch.bmp
==> ERROR: '/lib/modules/6.14.8-hardened' is not a valid kernel directory
This error is due to the fact I am trying to build the uki from a liveboot lacking the kernel in question, chrooting (arch-chroot) into /mnt, after copying all configuration files to /mnt will solve the issue.
Last edited by Lessclue (2025-05-30 16:12:04)
Offline
Yeah look like you know the solve - arch-chroot is the key here if booting from a live environment.
Offline
Pages: 1