replace grub-legacy-ec2 with pv-grub-menu

Bug #1756420 reported by Scott Moser
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-images
Won't Fix
Low
Unassigned
grub-legacy-ec2 (Ubuntu)
Triaged
Low
Unassigned
pv-grub-menu (Ubuntu)
Triaged
Low
Unassigned

Bug Description

grub-legacy-ec2 is a binary package. It maintains /boot/grub/menu.lst
without conflicting with other bootloaders (grub or grub2) and without
any problematic dependencies.

Canonical no longer publishes PV images on EC2, so there is no need
for this package in EC2 images speficially.
  (http://paste.ubuntu.com/p/W5H33Mb7Pz/)

I'd like to replace the use of the ubuntu-only pv-grub-legacy-ec2
with the debian-maintained pv-grub-menu for anything looking for equivalent
function. The motivation for this is simply to remove duplicate code.

It seems that official stock Ubuntu images still need to maintain
/boot/grub/menu.lst. This is necessary for non-aws users of xen
(IBM/Softlayer) or users publishing their own images to amazon.

Some background info:
 * grub-legacy-ec2 has really no relevancy to cloud-init. It just got
   stuck there within the first year I worked for Canonical because I
   didn't really know any better. It would have been better if it was a
   separate package from the start. Force of friction left it where it
   was. In early 2018 we separated the packag out of cloud-init into
   its own package (bug 1758420).
 * grub-legacy-ec2 builds a /boot/grub/menu.lst file for installed kernels
   the same way 'update-grub' builds /boot/grub/grub.cfg but does so
   without conflicting with grub2 or attempting to install a bootloader.
   That boot/grub/menu.lst file is then read (most commonly) by a program
   named 'pv-grub'.
 * 'pv-grub-menu' that does roughly the
   equivalent, but possibly does not have some of the changes that we've
   made to grub-legacy-ec2 to properly identify xen kernels. It even
   'Provides' grub-legacy-ec2.
 * currently ubuntu-server/server seed explicitly includes grub-legacy-ec2
   that is the only reverse-depends.

Related bugs:
 * bug 1758420: separate grub-legacy-ec2 from cloud-init
 * bug 1756426: not all recommends of ubuntu-server are installaed in lxd (squashfs) image

Scott Moser (smoser)
Changed in cloud-init (Ubuntu):
milestone: none → ubuntu-18.04
Changed in pv-grub-menu (Ubuntu):
milestone: none → ubuntu-18.04
Revision history for this message
Scott Moser (smoser) wrote :

I looked a bit further, started to file a MIR bug for pv-grub-menu. It seems like pv-grub-menu is not likely a simple drop in fix.

Open Debian bugs:
 https://bugs.debian.org/cgi-bin/pkgreport.cgi?pkg=pv-grub-menu;dist=unstable
Of the two bugs open, it appears that Ubuntu would need a fix for 771949.
There is a suggested fix for that in the bug.

[Dependencies]
The package lists 'grub-common' as a dependency.
grub-legacy-ec2 does not depend on grub-common.
That would seem to be due to use of 'grub-mkdevicemap' and 'grub-probe'.

grub-legacy-ec2 does not use either of these. Currently base ubuntu images
(squashfs) do not include grub-common.

Opened bug 1756426 as currently squashfs images do not contain
grub-legacy-ec2 either.

Revision history for this message
Scott Moser (smoser) wrote :

I opened up bug 1758420 to handle the split out of grub-legacy-ec2.

description: updated
Revision history for this message
Scott Moser (smoser) wrote :

grub-legacy-ec2 is now successfully split out of cloud-init, so I've closed the cloud-init task.

no longer affects: cloud-init (Ubuntu)
Scott Moser (smoser)
Changed in grub-legacy-ec2 (Ubuntu):
status: New → Triaged
importance: Undecided → Low
Changed in pv-grub-menu (Ubuntu):
milestone: ubuntu-18.04 → none
status: New → Triaged
importance: Undecided → Low
Changed in cloud-images:
status: New → Triaged
importance: Undecided → Low
Scott Moser (smoser)
description: updated
Revision history for this message
Joshua Powers (powersj) wrote :

I am going to mark this as won't fix for cloud-images.

grub-legacy-ec2 is only shipped in Xenial and Bionic. In Cosmic it was removed from the seed, so releases after that do not even have it.

Xenial is coming to end of standard support and needs it for HVM support. I don't see any major changes happening to it now.

Bionic images generally pull grub-legacy-ec2 out of the image.

Therefore, I don't believe there is much further work for the cloud-images task. Feel free to respond if you think otherwise.

Thanks!

Changed in cloud-images:
status: Triaged → Won't Fix
Revision history for this message
Joshua Powers (powersj) wrote :

And by HVM support, I actually mean PV support, doh.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.