[Bug 1723562] Re: Kernels get stuck in "manual" state and fail to autoremove after disk full condition
Steve Langasek
steve.langasek at canonical.com
Sat Oct 14 02:19:12 UTC 2017
I don't believe this occurs with xenial and later.
** Changed in: apt (Ubuntu)
Status: New => Incomplete
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/1723562
Title:
Kernels get stuck in "manual" state and fail to autoremove after disk
full condition
Status in apt package in Ubuntu:
Incomplete
Bug description:
I use unattended-upgrades to install new kernels (I think probably
from the security pocket). I believe this is the default. I also don't
run autoremove automatically, which I believe is also the default.
I just recovered a system that had been stuck in a disk full state for
a while without me noticing because, without an automated autoremove,
unattended-upgrades had filled my system full of kernels.
Expected: "apt-get --purge autoremove" will remove all unused kernels,
perhaps with a bit of coaxing from me to provide enough free space for
dpkg and apt to function.
Actual: "apt-get --purge autoremove" left many extra kernels
installed.
It seems that the reason is that apt considered most of the
automatically installed kernels as being marked for manual install. I
suspect that this is because apt wasn't able to mark kernels as
automatically installed because it didn't have enough space to do so
at the time, and without such a mark, it assumes manual.
Workaround: use "apt-mark" to mark all kernels as automatic once
enough space is available. Then run "/etc/kernel/postinst.d/apt-auto-
removal" manually. Then "apt-get --purge autoremove" works.
I'm not sure how we might approach fixing this. But I think it's a
poor UX that Ubuntu currently relies on autoremove to remove old
kernels to prevent the disk filling up, but this fails to work in some
cases when the disk does fill up.
I'm tagging such bugs "kernel-autoremove" to help us identify what
needs fixing to make kernel autoremovals work completely to fix this
UX issue.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apt/+bug/1723562/+subscriptions
More information about the foundations-bugs
mailing list