update-initrd-links creates incorrect symlinks
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
linux-base (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
Bionic |
Fix Released
|
Undecided
|
Unassigned | ||
Focal |
Fix Released
|
Undecided
|
Unassigned | ||
Groovy |
Won't Fix
|
Undecided
|
Unassigned | ||
Hirsute |
Fix Released
|
Undecided
|
Unassigned | ||
Impish |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
[Impact]
## Problem description
Executing the `/etc/kernel/
/initrd.img -> initrd.
/initrd.img.old -> initrd.
while it should actually be:
/initrd.img -> boot/initrd.
/initrd.img.old -> boot/initrd.
The problem appeared with the release of the version 4.5ubuntu1.5 of the linux-base package, which made this script executable.
[Test Plan]
* Install new linux-base and initramfs-tools
* create /etc/kernel-
do_symlinks = yes
do_bootloader = no
do_initrd = yes
link_in_boot = yes
* 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-
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)
* remove all kernels, purge initramfs-tools, clean up symlinks in / and /boot
* repeat all of the above, without having initramfs-tools installed. I.e. install kernels _without_ recommneds.
[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.
tags: | added: patch |
tags: | added: regresion-proposed regression-update |
tags: |
added: regression-proposed removed: regresion-proposed |
description: | updated |
description: | updated |
tags: | removed: regression-update |
Status changed to 'Confirmed' because the bug affects multiple users.