Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

full-disk support in vmtest #122

Open
vmagro opened this issue Jun 16, 2021 · 1 comment
Open

full-disk support in vmtest #122

vmagro opened this issue Jun 16, 2021 · 1 comment

Comments

@vmagro
Copy link
Contributor

vmagro commented Jun 16, 2021

  • Antlir now supports building GPT images, vm infra should support booting these full disk images without specifying a kernel (+cmdline+initrd)
  • Most of the 1 week timeline should be writing tests
@vmagro
Copy link
Contributor Author

vmagro commented Jul 1, 2021

here is an example of building a gpt-formatted disk

the image buck macro api unfortunately doesn't seem to have any documentation, but that example should be enough to get started
you will likely want to use image.rpms_install to install the kernel rpm from //third-party/fedora33:5.8.15-301.fc33.x86_64-core.rpm into the main rootfs layer, and then some combination of image.install / image.genrule_layer to get the initrd into the vfat partition for uefi (the initrd target should be //third-party/fedora33:5.8.15-301.fc33.x86_64-initrd, which a cpio archive that you can install into the vfat partition and the bootloader in qemu can load it and the vmlinuz)

this stackoverflow might be helpful to get qemu to work with a uefi bios to boot from a full partitioned disk image
https://unix.stackexchange.com/questions/52996/how-to-boot-efi-kernel-using-qemu-kvm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant