From bef3548b82a563a29795f8355b060c4a3041c447 Mon Sep 17 00:00:00 2001 From: Philip Roche Date: Fri, 22 May 2020 13:37:22 +0100 Subject: [PATCH] Revert of initramfs package removal in KVM image (LP: #1880170) It was reported and confirmed in LP bug #1875400 (https://bugs.launchpad.net/cloud-images/+bug/1875400) that on the public KVM cloud image there exists a large list of packages marked for auto-removal. This should never be the case on a released cloud image. These packages are marked for auto-removal because in the KVM image binary hook we removed both initramfs-tools and busybox-initramfs packages. Due to package dependencies this also removed: busybox-initramfs* cloud-initramfs-copymods* cloud-initramfs-dyn-netconf* cryptsetup-initramfs* initramfs-tools* initramfs-tools-core* multipath-tools* overlayroot* sg3-utils-udev* ubuntu-server* But it did not remove all the packages that the above list depended on. This resulted in all those packages being marked for auto-removal because they were not manually installed nor did they have any manually installed packages that depended on them. The removal of initramfs-tools and busybox-initramfs was to avoid the generation of initramfs in images that should boot initramfsless. This requirement is obsolete now because the initramfsless boot handling is now handled via setting GRUB_FORCE_PARTUUID in /etc/default/grub.d/40-force-partuuid.cfg. In test images I have verified that GRUB_FORCE_PARTUUID is set and that boot speeds have not regressed. LP: #1880170 --- debian/changelog | 6 ++++++ live-build/ubuntu-cpc/hooks.d/base/kvm-image.binary | 4 ---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/debian/changelog b/debian/changelog index e7f415f6..fc89f263 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +livecd-rootfs (2.620.3) eoan; urgency=medium + + * Revert of initramfs package removal in KVM image (LP: #1880170) + + -- Phil Roche Fri, 22 May 2020 13:03:20 +0100 + livecd-rootfs (2.620.2) eoan; urgency=medium * Fix logic to ensure snapd is seeded in core18-only images (LP: #1871919) diff --git a/live-build/ubuntu-cpc/hooks.d/base/kvm-image.binary b/live-build/ubuntu-cpc/hooks.d/base/kvm-image.binary index 931010bc..094cb375 100755 --- a/live-build/ubuntu-cpc/hooks.d/base/kvm-image.binary +++ b/live-build/ubuntu-cpc/hooks.d/base/kvm-image.binary @@ -49,10 +49,6 @@ replace_kernel ${mount_d} "linux-kvm" chroot "${mount_d}" update-grub undivert_grub "${mount_d}" -# Remove initramfs for kvm image -env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" apt-get \ - purge -y initramfs-tools busybox-initramfs - env DEBIAN_FRONTEND=noninteractive chroot "${mount_d}" rm \ -rf /boot/initrd.img-* /boot/initrd.img