lxc / distrobuilder

System container image builder for LXC and Incus
https://linuxcontainers.org
Apache License 2.0
577 stars 166 forks source link

Images generated by distrobuilder does not boot on OpenStack #848

Open Calebe94 opened 4 months ago

Calebe94 commented 4 months ago

I've generated some Ubuntu images using distrobuilder, but it does not boot properly without setting some image properties:

openstack image set --property hw_machine_type=q35 --property hw_firmware_type=uefi --property os_secure_boot=required <image-uuid>

Without these properties the VM cannot boot. Here's the console screen:

seabios-console

I'm using this file from lxc-ci/images/ubuntu with a minor difference. I'm redirecting the console tty0, so it can show the logs in Openstack's instance "Log" tab.

    GRUB_CMDLINE_LINUX_DEFAULT="${GRUB_CMDLINE_LINUX_DEFAULT} console=tty0 console=ttyS0,115200n8"

Can you guys give me some hints on what I'm doing wrong?

stgraber commented 4 months ago

You're not doing anything wrong, distrobuilder just doesn't build BIOS bootable images but only UEFI bootable images, so those OpenStack properties are required if you're going to be using images generated by distrobuilder.

The normal target for distrobuiler images is Incus which has UEFI enabled by default.