Score:1

netbooting CentOS via PXE and UEFI : unable to mount root over nfs -- failed to switch root path /sysroot

id flag

Last weekend, I went down the rabbit hole of trying to netboot rockylinux on raspberry pi 4.

I was able make it work as far as being able to boot the kernel. But I fail to properly nfs mount root. I get the error: Failed to switch root path /sysroot ... does not seem to on os-tree. os-release file missing.

My NFS server is rockylinux VM. I have disabled the firewall and made the root filesystem read/write for all for debugging. I am able to mount the nfs shares from other machines as well. So I think the nfs exports are working properly.

Here is my grub menuentry:

set default="0"
set timeout=5
set root=(tftp,192.168.0.185)
set prefix=($root)/grub2

menuentry "OS (UEFI PXE)" {
    linux /vmlinuz-5.14.0-162.6.1.el9_1.aarch64 root=/dev/nfs rw nfsroot=192.168.0.185:/nfs/rpi4_dfd9 rw ip=dhcp rootwait elevator=deadline
    initrd /initramfs-5.14.0-162.6.1.el9_1.aarch64.img
}

How can I test nfs mount from recovery shell that kernel drops into after failing to properly mount the nfs drive?

Score:1
id flag

The rockylinux team pointed in the right direction. For pxeboot, one needs to use pxeboot/vmlinux and pxeboot/initrd.img files found on the ISO's or dl.rockylinux.org/pub/rocky/9/BaseOS.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.