You are not logged in.

#1 2019-10-16 16:35:20

D4RK0V3RL0RD676
Member
Registered: 2017-07-27
Posts: 3

Mkinitcpio - automate copying vmlinux and initramfs to efi partition

I have a dual boot setup with windows 10 and arch linux and every time I update and mkinitcpio runs, I have been manually copying the required files to the efi partition (the one made from windows)

$ lsblk
NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
nvme0n1     259:0    0 238.5G  0 disk
├─nvme0n1p1 259:1    0   650M  0 part /boot/efi
├─nvme0n1p2 259:2    0   128M  0 part
├─nvme0n1p3 259:3    0 114.3G  0 part
├─nvme0n1p4 259:4    0    32G  0 part /mnt/files
├─nvme0n1p5 259:5    0  78.3G  0 part /
├─nvme0n1p6 259:6    0   990M  0 part
├─nvme0n1p7 259:7    0    11G  0 part
└─nvme0n1p8 259:8    0   1.1G  0 part


so initramfs-linux.img and vmlinuz-linux appear in /boot, but I copy them to /boot/efi/


/boot/efi/loader/entries/arch.conf:
title        Arch Linux
linux        /vmlinuz-linux
initrd        /initramfs-linux.img
options        root=UUID=1edb873a-3688-4e3c-a15a-dfbe6e321777 rw


the uuid above is the one for /dev/nvme0n1p5 which is mounted as /


If I try changing the configurations path to use /boot/vmlinuz-linux or something like that, it doesnt work. Is there a good solution for getting loader to see the files on a different partition or to automate copying over the files to the efi partition?

Offline

#2 2019-10-16 16:47:49

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: Mkinitcpio - automate copying vmlinux and initramfs to efi partition


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2019-10-16 16:48:38

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,657

Re: Mkinitcpio - automate copying vmlinux and initramfs to efi partition

Please use [ code ] [ /code ] tags for pasting outputs

Systemd-boot does only support loading EFI binaries from the EFI partition. If you actually want to have them on your linux filesystem you would have to use another bootloader.

As for automating copying, you could use a pacman hook ordered after the mkinitcpio hook to do the copying, or  just mount the ESP to /boot instead of /boot/efi so that the images get written directly.

Last edited by V1del (2019-10-16 16:50:15)

Offline

Board footer

Powered by FluxBB