You are not logged in.

#1 2025-07-30 09:28:40

ForeverNoob
Member
Registered: 2008-07-18
Posts: 39

[SOLVED] GRUB Can't Boot Secondary Arch Install

Hello,

I have three disks in my PC:

1. Main Arch install on /dev/nvme0n1
2. Windows 10 on /dev/sda
3. Test Arch install on /dev/sdb

I can boot each OS from the BIOS boot menu without issues. Windows also boots correctly from the GRUB menu on the main Arch install. However, when I select the test Arch system on /dev/sdb from GRUB, I get the following error:

error: file '/boot/initramfs-linux.img' not found

What could be causing this?

TIA

Last edited by ForeverNoob (2025-07-31 10:19:55)

Offline

#2 2025-07-30 15:04:05

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,064

Re: [SOLVED] GRUB Can't Boot Secondary Arch Install

Do you have a shared mount point for "/boot" between main system and test system? A GRUB instance will store the "root" of it's original installation within the binary, a secondary entry would have to be identified differently.

To make any proper assertions, post your outputs for

lsblk -f
mount
cat /boot/grub/grub.cfg

from a working system.

Offline

#3 2025-07-30 17:19:45

ForeverNoob
Member
Registered: 2008-07-18
Posts: 39

Re: [SOLVED] GRUB Can't Boot Secondary Arch Install

No, each install has its own /boot.

lsblk -f:

NAME        FSTYPE FSVER LABEL              UUID                                 FSAVAIL FSUSE% MOUNTPOINTS
sda                                                                                             
├─sda1                                                                                         
└─sda2      ntfs         win10-ent-iot-ltsc 9028BF5728BF3B54                                   
sdb                                                                                             
├─sdb1      vfat   FAT32                    A8F4-33A1                                           
└─sdb2      ext4   1.0   arch-hypr          fc886b88-6214-4033-aa79-2148c9a8f7c5    112G     5% /run/media/yoav/arch-hypr
sdc                                                                                             
├─sdc1      exfat  1.0   Ventoy             6102-6A39                             455.4G     2% /run/media/yoav/Ventoy
└─sdc2      vfat   FAT16 VTOYEFI            B0D1-DF41                                           
zram0       swap   1     zram0              e67bd074-fcd7-4261-b87e-94cc3f57e952                [SWAP]
nvme0n1                                                                                         
├─nvme0n1p1 vfat   FAT32                    B375-4381                             770.6M    25% /boot
└─nvme0n1p2 ext4   1.0                      dce220d0-bc42-4f5a-bcfd-d506794f8877  784.4G     9% /


mount:

proc on /proc type proc (rw,nosuid,nodev,noexec,relatime)
sys on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
dev on /dev type devtmpfs (rw,nosuid,relatime,size=15921364k,nr_inodes=3980341,mode=755,inode64)
run on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755,inode64)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
/dev/nvme0n1p2 on / type ext4 (rw,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev,inode64)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot)
none on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=41,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=4996)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
hugetlbfs on /dev/hugepages type hugetlbfs (rw,nosuid,nodev,relatime,pagesize=2M)
tmpfs on /run/credentials/systemd-journald.service type tmpfs (ro,nosuid,nodev,noexec,relatime,nosymfollow,size=1024k,nr_inodes=1024,mode=700,inode64,noswap)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
systemd-1 on /mnt/nas type autofs (rw,relatime,fd=65,pgrp=1,timeout=0,minproto=5,maxproto=5,direct,pipe_ino=5514)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,nr_inodes=1048576,inode64)
/dev/nvme0n1p1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
tmpfs on /run/user/1000 type tmpfs (rw,nosuid,nodev,relatime,size=3193248k,nr_inodes=798312,mode=700,uid=1000,gid=1000,inode64)
portal on /run/user/1000/doc type fuse.portal (rw,nosuid,nodev,relatime,user_id=1000,group_id=1000)
//wdmycloud/Public on /mnt/nas type cifs (rw,relatime,vers=3.1.1,sec=none,cache=strict,upcall_target=app,uid=1000,forceuid,gid=1000,forcegid,addr=192.168.0.245,file_mode=0777,dir_mode=0777,iocharset=utf8,soft,nounix,mapposix,reparse=nfs,nativesocket,symlink=native,rsize=4194304,wsize=4194304,bsize=1048576,retrans=1,echo_interval=60,actimeo=1,closetimeo=1,x-systemd.automount)
/dev/sdc1 on /run/media/yoav/Ventoy type exfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,iocharset=utf8,errors=remount-ro,uhelper=udisks2)
/dev/sdb2 on /run/media/yoav/arch-hypr type ext4 (rw,nosuid,nodev,relatime,errors=remount-ro,uhelper=udisks2)


cat /boot/grub/grub.cfg:

#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
  load_env
fi
if [ "${next_entry}" ] ; then
   set default="${next_entry}"
   set next_entry=
   save_env next_entry
   set boot_once=true
else
   set default="0"
fi

if [ x"${feature_menuentry_id}" = xy ]; then
  menuentry_id_option="--id"
else
  menuentry_id_option=""
fi

export menuentry_id_option

if [ "${prev_saved_entry}" ]; then
  set saved_entry="${prev_saved_entry}"
  save_env saved_entry
  set prev_saved_entry=
  save_env prev_saved_entry
  set boot_once=true
fi

function savedefault {
  if [ -z "${boot_once}" ]; then
    saved_entry="${chosen}"
    save_env saved_entry
  fi
}

function load_video {
  if [ x$feature_all_video_module = xy ]; then
    insmod all_video
  else
    insmod efi_gop
    insmod efi_uga
    insmod ieee1275_fb
    insmod vbe
    insmod vga
    insmod video_bochs
    insmod video_cirrus
  fi
}

insmod part_gpt
insmod fat
search --no-floppy --fs-uuid --set=root B375-4381
if loadfont /grub/fonts/myfont.pf2 ; then
  set gfxmode=auto
  load_video
  insmod gfxterm
  set locale_dir=$prefix/locale
  set lang=en_US
  insmod gettext
fi
terminal_input console
terminal_output gfxterm
if [ x$feature_timeout_style = xy ] ; then
  set timeout_style=menu
  set timeout=5
# Fallback normal timeout code in case the timeout_style feature is
# unavailable.
else
  set timeout=5
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/10_linux ###
menuentry 'Arch Linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-dce220d0-bc42-4f5a-bcfd-d506794f8877' {
        load_video
        set gfxpayload=keep
        insmod gzio
        insmod part_gpt
        insmod fat
        search --no-floppy --fs-uuid --set=root B375-4381
        echo    'Loading Linux linux ...'
        linux   /vmlinuz-linux root=UUID=dce220d0-bc42-4f5a-bcfd-d506794f8877 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
        echo    'Loading initial ramdisk ...'
        initrd  /amd-ucode.img /initramfs-linux.img
}
submenu 'Advanced options for Arch Linux' $menuentry_id_option 'gnulinux-advanced-dce220d0-bc42-4f5a-bcfd-d506794f8877' {
        menuentry 'Arch Linux, with Linux linux' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-advanced-dce220d0-bc42-4f5a-bcfd-d506794f8877' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod fat
                search --no-floppy --fs-uuid --set=root B375-4381
                echo    'Loading Linux linux ...'
                linux   /vmlinuz-linux root=UUID=dce220d0-bc42-4f5a-bcfd-d506794f8877 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
                echo    'Loading initial ramdisk ...'
                initrd  /amd-ucode.img /initramfs-linux.img
        }
        menuentry 'Arch Linux, with Linux linux (fallback initramfs)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-linux-fallback-dce220d0-bc42-4f5a-bcfd-d506794f8877' {
                load_video
                set gfxpayload=keep
                insmod gzio
                insmod part_gpt
                insmod fat
                search --no-floppy --fs-uuid --set=root B375-4381
                echo    'Loading Linux linux ...'
                linux   /vmlinuz-linux root=UUID=dce220d0-bc42-4f5a-bcfd-d506794f8877 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
                echo    'Loading initial ramdisk ...'
                initrd  /amd-ucode.img /initramfs-linux-fallback.img
        }
}

### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/15_ostree ###
### END /etc/grub.d/15_ostree ###

### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/25_bli ###
if [ "$grub_platform" = "efi" ]; then
  insmod bli
fi
### END /etc/grub.d/25_bli ###

### BEGIN /etc/grub.d/30_os-prober ###
# This menu entry is supported only on EFI platforms.
if [ "$grub_platform" = "efi" ]; then
menuentry 'Windows Boot Manager (on /dev/nvme0n1p1)' --class windows --class os $menuentry_id_option 'osprober-efi-B375-4381' {
        insmod part_gpt
        insmod fat
        search --no-floppy --fs-uuid --set=root B375-4381
        chainloader /EFI/Microsoft/Boot/bootmgfw.efi
}
fi
menuentry 'Arch Linux (on /dev/sdb2)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-fc886b88-6214-4033-aa79-2148c9a8f7c5' {
        insmod part_gpt
        insmod fat
        set root='hd1,gpt1'
        if [ x$feature_platform_search_hint = xy ]; then
          search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt1 --hint-efi=hd1,gpt1 --hint-baremetal=ahci1,gpt1  A8F4-33A1
        else
          search --no-floppy --fs-uuid --set=root A8F4-33A1
        fi
        linux /vmlinuz-linux root=UUID=fc886b88-6214-4033-aa79-2148c9a8f7c5 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
        initrd /amd-ucode.img /boot/initramfs-linux.img
}
submenu 'Advanced options for Arch Linux (on /dev/sdb2)' $menuentry_id_option 'osprober-gnulinux-advanced-fc886b88-6214-4033-aa79-2148c9a8f7c5' {
        menuentry 'Arch Linux (on /dev/sdb2)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz-linux--fc886b88-6214-4033-aa79-2148c9a8f7c5' {
                insmod part_gpt
                insmod fat
                set root='hd1,gpt1'
                if [ x$feature_platform_search_hint = xy ]; then
                  search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt1 --hint-efi=hd1,gpt1 --hint-baremetal=ahci1,gpt1  A8F4-33A1
                else
                  search --no-floppy --fs-uuid --set=root A8F4-33A1
                fi
                linux /vmlinuz-linux root=UUID=fc886b88-6214-4033-aa79-2148c9a8f7c5 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
                initrd /amd-ucode.img /boot/initramfs-linux.img
        }
        menuentry 'Arch Linux, with Linux linux (on /dev/sdb2)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz-linux--fc886b88-6214-4033-aa79-2148c9a8f7c5' {
                insmod part_gpt
                insmod fat
                set root='hd1,gpt1'
                if [ x$feature_platform_search_hint = xy ]; then
                  search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt1 --hint-efi=hd1,gpt1 --hint-baremetal=ahci1,gpt1  A8F4-33A1
                else
                  search --no-floppy --fs-uuid --set=root A8F4-33A1
                fi
                linux /vmlinuz-linux root=UUID=fc886b88-6214-4033-aa79-2148c9a8f7c5 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
                initrd /amd-ucode.img /boot/initramfs-linux.img
        }
        menuentry 'Arch Linux, with Linux linux (fallback initramfs) (on /dev/sdb2)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/vmlinuz-linux--fc886b88-6214-4033-aa79-2148c9a8f7c5' {
                insmod part_gpt
                insmod fat
                set root='hd1,gpt1'
                if [ x$feature_platform_search_hint = xy ]; then
                  search --no-floppy --fs-uuid --set=root --hint-bios=hd1,gpt1 --hint-efi=hd1,gpt1 --hint-baremetal=ahci1,gpt1  A8F4-33A1
                else
                  search --no-floppy --fs-uuid --set=root A8F4-33A1
                fi
                linux /vmlinuz-linux root=UUID=fc886b88-6214-4033-aa79-2148c9a8f7c5 rw zswap.enabled=0 rootfstype=ext4 loglevel=3 quiet
                initrd /amd-ucode.img /boot/initramfs-linux-fallback.img
        }
}

### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/30_uefi-firmware ###
if [ "$grub_platform" = "efi" ]; then
        fwsetup --is-supported
        if [ "$?" = 0 ]; then
                menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
                        fwsetup
                }
        fi
fi
### END /etc/grub.d/30_uefi-firmware ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f  ${config_directory}/custom.cfg ]; then
  source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f  $prefix/custom.cfg ]; then
  source $prefix/custom.cfg
fi
### END /etc/grub.d/41_custom ###

Offline

#4 2025-07-30 18:30:30

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,064

Re: [SOLVED] GRUB Can't Boot Secondary Arch Install

please wrap outputs in  [code][/code] tags in the future, and edit your post in this regard.

mhm, with the setup as presented here "logically" speaking the appropriate initramfs reference should™ be /initramfs-linux.img and not /boot/initramfs-linux.img, maybe a bug in os-prober? Or your partitions not being properly setup on the guest before installing the kernel packages and the generation of the grub config. For a simple test I suggest you just hand edit the grub.cfg and switch all the /boot/initramfs-linux.img references to /initramfs-linux.img for the /dev/sdb2 entries. Otherwise for further verification what does

ls -l /run/media/yoav/arch-hypr/boot
mount /dev/sdb1  /run/media/yoav/arch-hypr/boot
ls -l /run/media/yoav/arch-hypr/boot

Last edited by V1del (2025-07-30 18:30:53)

Offline

#5 2025-07-31 10:19:19

ForeverNoob
Member
Registered: 2008-07-18
Posts: 39

Re: [SOLVED] GRUB Can't Boot Secondary Arch Install

V1del wrote:

For a simple test I suggest you just hand edit the grub.cfg and switch all the /boot/initramfs-linux.img references to /initramfs-linux.img for the /dev/sdb2 entries.

Changing /boot/initramfs-linux.img to /initramfs-linux.img did the trick.

I also discovered that when installing on a single partition (no separate /boot) on /dev/sdb then update-grub generates the correct entries.

Thanks a lot.

Offline

Board footer

Powered by FluxBB