Comments (6)
Yep, that's why we're not currently building noble images on our image server :)
Someone needs to figure out what changed in Ubuntu between mantic and noble and how to fix the YAML for it.
from lxc-ci.
From initial testing, changing grub-install --uefi-secure-boot --target="${TARGET}-efi" --no-nvram --removable
to grub-install --no-uefi-secure-boot --target="${TARGET}-efi" --no-nvram --removable
changes something to allow grub to continue without user intervention.
When --uefi-secure-boot
is given, the grub-mkimage
command is invoked as follows (this can be determined adding the -v
flag to grub-install
in the post-files action):
grub-install: info: grub-mkimage --directory '/usr/lib/grub/x86_64-efi' --prefix '/boot/grub' --output '/boot/grub/x86_64-efi/core.efi' --dtb '' --sbat '' --format 'x86_64-efi' --compression 'auto' --config '/boot/grub/x86_64-efi/load.cfg' 'ext2' 'part_gpt' 'search_fs_uuid'
When --no-uefi-secure-boot
is given, the command is:
grub-install: info: grub-mkimage --directory '/usr/lib/grub/x86_64-efi' --prefix '(,gpt2)/boot/grub' --output '/boot/grub/x86_64-efi/core.efi' --dtb '' --sbat '' --format 'x86_64-efi' --compression 'auto' 'ext2' 'part_gpt'
from lxc-ci.
In images/debian.yaml
, the post-files action which installs grub runs grub-install
twice (https://github.com/lxc/lxc-ci/blob/e5f93e469bdab592d29b10128df79b0a7e5358ad/images/debian.yaml#L1471C1-L1474C72):
# This will create EFI/BOOT
grub-install --uefi-secure-boot --target="${TARGET}-efi" --no-nvram --removable
# This will create EFI/debian
grub-install --uefi-secure-boot --target="${TARGET}-efi" --no-nvram
As both grub2 in Ubuntu and Debian are carrying the patch for installing signed copies, and the Debian sid is still passing I wondered if the second invocation does something.
The grub-mkimage
command invoked when installing with --removable
is:
grub-mkimage --directory '/usr/lib/grub/x86_64-efi' --prefix '/boot/grub' --output '/boot/grub/x86_64-efi/core.efi' --dtb '' --sbat '' --format 'x86_64-efi' --compression 'auto' --config '/boot/grub/x86_64-efi/load.cfg' 'ext2' 'part_gpt' 'search_fs_uuid'
And without --removable
,
grub-mkimage --directory '/usr/lib/grub/x86_64-efi' --prefix '' --output '/boot/grub/x86_64-efi/grub.efi' --dtb '' --sbat '' --format 'x86_64-efi' --compression 'auto' --config '/boot/grub/x86_64-efi/load.cfg' 'ext2' 'part_gpt' 'search_fs_uuid'
Including both grub-install
statements results in an image that passes through grub without user intervention.
I also tested using only grub-install --uefi-secure-boot --target="${TARGET}-efi" --no-nvram
in the post-files action: this worked and the system booted without user interaction.
from lxc-ci.
@stgraber I see you comitted a change to sync the ubuntu.yaml and debian.yaml. I think it might be worth trying to figure out if using only a single grub-install
invocation works across multiple releases. It could be that the original reasons for running it twice are no longer applicable.
from lxc-ci.
Thanks a lot for the detective work. I just pushed a couple of fixes to align Debian and Ubuntu.
It certainly sounds like calling without --removable would be sufficient, though I think it's still safer to perform both calls as in theory, --removable should install the bootx64.efi and the normal call should install grubx64.efi.
This isn't quite as simple as that since the shim also needs to be installed and is actually what ends up being bootx64.efi, but I can't be sure that both always get installed in all the right places on all versions of Ubuntu and Debian that folks build images for, calling the install twice doesn't really cost much, so let's just do that ;)
from lxc-ci.
Sounds good to me. Thanks for comitting a fix :)
from lxc-ci.
Related Issues (20)
- images(ubuntu): jammy/default no longer contains templates to update hostname HOT 11
- Permanently provide working image besides the latest three builds HOT 1
- debian/11/cloud doesn't run cloud-init in lxd HOT 3
- Continue creating Debian i386 images HOT 2
- default route not properly set on Centos 8 or 9 stream using routed nic HOT 10
- Missing Fedora Rawhide images HOT 2
- Add Devuan Daedalus
- VM centos/7/cloud: empty /etc/resolv.conf HOT 1
- NixOS images HOT 32
- Ubuntu 23.10 (mantic) containers fail to start HOT 16
- Cannot create custom gentoo images with latest gentoo.yaml file HOT 3
- Add alpine 3.19 HOT 1
- images/gentoo.yaml: line 23: locale-gen: command not found
- Unable to shell to Almalinux Virtual-Machines HOT 5
- Fixing ubuntu noble build failure HOT 2
- Something is broken in the alpine mirror HOT 4
- Distrobuilder fails to build rockylinux-9 vm flavour HOT 7
- incus-agent fails to start in rockylinux-9 vm HOT 2
- debian bookworm systemd networking is lacking - setting up multiple routes on 2 interfaces with cloud-init HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lxc-ci.