I've been working on a Yocto project(Kirkstone branch) which is enhanced with meta-intel
. The build produces several artifacts including a bootable ISO file, a kernel file, and multiple initramfs files. When I boot the ISO file in a VirtualBox VM, it performs as expected - successfully live booting, installing, and recognizing the /dev/sda
. A grub menu is also provided during the VM boot, offering options for live booting and installation. The ISO file contains various components such as bzImage, efi.img, initrd, rootfs.img, startup.nsh, and the EFI and isolinux directories.
The issue arises when I attempt to boot the build over iPXE. I pass the kernel (bzImage
) and initramfs (core-image-full-cmdline-intel-corei7-64.cpio.gz
) files to an HP Server with a Xeon processor for live booting, and while it boots successfully, no disks are visible under the /dev
directory. Running commands such as lsblk
yield no results, and fdisk -l
only shows entries like ram0, ram1, etc., up to ram8. Notably, I cannot use ISO, hddimg, or any other format to boot over iPXE.
For the installation process to begin on the server from the live boot environment, the presence of /dev/sdX
or /dev/nvme*
is crucial. I suspect that the issue may be related to filesystem drivers not loading correctly.
Here is my redacted local.conf
content, which successfully boots the ISO on VirtualBox:
IMAGE_TYPEDEP_wic = "ext4"
INITRD_IMAGE_LIVE="core-image-minimal-initramfs"
LABELS_LIVE = "boot install"
EFI_PROVIDER = "grub-efi"
do_image_wic[depends] += "${INITRD_IMAGE_LIVE}:do_image_complete"
do_rootfs[depends] += "virtual/kernel:do_deploy"
IMAGE_BOOT_FILES:append = "\
${KERNEL_IMAGETYPE} \
microcode.cpio \
${IMGDEPLOYDIR}/${IMAGE_BASENAME}-${MACHINE}.ext4;rootfs.img \
${@bb.utils.contains('EFI_PROVIDER', 'grub-efi', 'grub-efi-bootx64.efi;EFI/BOOT/bootx64.efi', '', d)} \
${@bb.utils.contains('EFI_PROVIDER', 'grub-efi', '${IMAGE_ROOTFS}/boot/EFI/BOOT/grub.cfg;EFI/BOOT/grub.cfg', '', d)} \
${@bb.utils.contains('EFI_PROVIDER', 'systemd-boot', 'systemd-bootx64.efi;EFI/BOOT/bootx64.efi', '', d)} \
${@bb.utils.contains('EFI_PROVIDER', 'systemd-boot', '${IMAGE_ROOTFS}/boot/loader/loader.conf;loader/loader.conf ', '', d)} \
${@bb.utils.contains('EFI_PROVIDER', 'systemd-boot', '${IMAGE_ROOTFS}/boot/loader/entries/boot.conf;loader/entries/boot.conf', '', d)} "
INIT_MANAGER = "systemd"
VIRTUAL-RUNTIME_init_manager = "systemd"
DISTRO_FEATURES_BACKFILL_CONSIDERED = "sysvinit"
MACHINE_FEATURES_NATIVE:append = " efi"
MACHINE_FEATURES:append = " efi"
MACHINE_FEATURES:append = " pcbios util-linux-blkid"
IMAGE_INSTALL:append = " grub grub-efi grub-bootconf"
CORE_IMAGE_EXTRA_INSTALL:append = " kernel-modules"
My bblayers.conf
is below:
# POKY_BBLAYERS_CONF_VERSION is increased each time build/conf/bblayers.conf
# changes incompatibly
POKY_BBLAYERS_CONF_VERSION = "2"
BBPATH = "${TOPDIR}"
BBFILES ?= ""
BBLAYERS ?= " \
/home/poky/meta \
/home/poky/meta-poky \
/home/poky/meta-yocto-bsp \
/home/poky/meta-openembedded/meta-oe \
/home/poky/meta-openembedded/meta-python \
/home/poky/meta-openembedded/meta-networking \
/home/poky/meta-openembedded/meta-filesystems \
/home/poky/meta-openembedded/meta-perl \
/home/poky/meta-selinux \
/home/poky/meta-virtualization \
/home/poky/meta-intel \
"
and my boot.ipxe
file looks like this:
# Fetch the kernel
kernel ${base}/bzImage root=/dev/nfs initrd=core-image-full-cmdline-intel-corei7-64.cpio.gz
initrd ${base}/core-image-full-cmdline-intel-corei7-64.cpio.gz
imgargs bzImage LABEL=boot rootwait console=ttyS0,115200 console=tty0
boot || goto failed
goto start
The goal here is to identify the best method to install the Yocto build on the server while it is live booted using initramfs
and bzImage
. I'm seeking guidance on how to ensure that all necessary drivers are added to the kernel(bzImage
and initramfs
)
The issue was related to RAID drivers not getting included in the kernel. I enabled CONFIG_SCSI_SMARTPQI
and CONFIG_SCSI_HPSA
kernel menuconfig and it worked.