** Description changed: + [Impact] + ## Problem description Executing the `/etc/kernel/postinst.d/xx-update-initrd-links` script incorrectly detects symbolic links targets and then creates malformed (hence broken) ones instead: /initrd.img -> initrd.imgboot/vmlinuz-5.3.0-53-generic /initrd.img.old -> initrd.imgboot/vmlinuz-5.3.0-53-generic while it should actually be: /initrd.img -> boot/initrd.img-5.3.0-53-generic /initrd.img.old -> boot/initrd.img-5.3.0-53-generic The problem appeared with the release of the version 4.5ubuntu1.5 of the linux-base package, which made this script executable. - ## Solution - A solution is proposed through the attached patch file. + [Test Plan] - ## System information + * Install new linux-base and initramfs-tools - Description: Ubuntu 18.04.5 LTS - Release: 18.04 - Uname: Linux 5.3.0-53-generic x86_64 + * create /etc/kernel-img.conf with - ## Package information + do_symlinks = yes + do_bootloader = no + do_initrd = yes + link_in_boot = yes - Package: linux-base 4.5ubuntu1.5 - PackageArchitecture: all - SourcePackage: linux-base - Tags: bionic package-from-proposed + * Install one kernel flavour, check that symlinks in /boot have sane targets + * Install another kernel, check that symlinks in /boot/ have sane targets + + * create a selfbuilt kernel and install it by calling installkernel + (you can download kernel debs from kernel-ppa, and unpack them to + pretend one has self built it). and check that symlinks in /boot have + sane targets. + + * Purge all kernel, and remove symlinks in /boot + + * Update /etc/kernel-img.conf to + + do_symlinks = yes + do_bootloader = no + do_initrd = yes + link_in_boot = no + + * Install one kernel flavour, check that symlinks in / have sane targets + * Install another kernel, check that symlinks in / have sane targets + * create a selfbuilt kernel and install it by calling installkernel (you can download kernel debs from kernel-ppa, and unpack them to pretend one has self built it) + + [Where problems could occur] + + * The rewritten postinst.d script now simply mostly calls linux-update- + links like the normal linux-image postinst script does. One has to make + sure that .deb installations of kernels happens correctly and that + installkernel way of installing kernels happens correctly. Under + different kernel-img.conf settings. The previous incarnations of fixing + this and related issues did not account for the above cases and + codepaths.
-- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1929255 Title: update-initrd-links creates incorrect symlinks To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux-base/+bug/1929255/+subscriptions -- ubuntu-bugs mailing list [email protected] https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
