Obsolete /boot/initrd.img symlink causes package upgrade failure
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
initramfs-tools (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: initramfs-tools
If you have an obsolete initrd.img symlink in /boot, then upgrading the initramfs-tools package will fail. This occurred to me when I migrated from lilo to grub (where the lymlinks were no longer maintained), then later removed the kernel image to which the symlinks still pointed. Worse, it appears other kernels (i.e. correct, installed ones) are not updated as update-initramfs bails out at this point.
Steps to reproduce:
1. Create an incorrect initrd.img symlink (e.g. "ln -s /boot/initrd.
2. Run "update-initramfs -u" (this action is triggered during a package upgrade/reinstall too
Results:
update-initramfs: Generating /boot/initrd.
Cannot find /lib/modules/
update-initramfs: failed for /boot/initrd.
update-initramfs should not try and use initrd.img as its basis for updating if that version is no longer installed (i.e. missing from /lib/modules) - and should probably either remove or update the symlink during the process.
Changed in initramfs-tools: | |
assignee: | andrea-bs → nobody |
Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering if this is still an issue for you. Can you try with the latest Ubuntu release? Thanks in advance.