After doing a release upgrade from 22.04 -> 24.04, I've got about 200 packages of the name "linux-{image, modules, modules-extra}" that dpkg says are present.
If I grep on ii for the installed ones, I get what I would expect, the current one plus the other associated packages:
root@lwobker-nuc:/home/lwobker# dpkg -l | grep '^ii linux-'
ii linux-base 4.5ubuntu9 all Linux image base package
ii linux-firmware 20240318.git3b128b60-0ubuntu2.2 amd64 Firmware for Linux kernel drivers
ii linux-generic 6.8.0-41.41 amd64 Complete Generic Linux kernel and headers
ii linux-headers-6.8.0-41 6.8.0-41.41 all Header files related to Linux kernel version 6.8.0
<< snip for brevity, this is maybe 15-20 lines >>
ii linux-tools-6.8.0-41 6.8.0-41.41 amd64 Linux kernel version specific tools for version 6.8.0-41
ii linux-tools-6.8.0-41-generic 6.8.0-41.41 amd64 Linux kernel version specific tools for version 6.8.0-41
ii linux-tools-common 6.8.0-41.41 all Linux kernel version specific tools for version 6.8.0
without blasting you fine people with 150 lines of text, there are a TON of packages that appear have been removed but not TOTALLY cleaned up...
root@lwobker-nuc:/home/lwobker# dpkg -l | grep '^rc linux-' | wc
155 2071 23085
root@lwobker-nuc:/home/lwobker# dpkg -l | grep '^rc linux-' | head -5
rc linux-image-4.15.0-47-generic 4.15.0-47.50 amd64 Signed kernel image generic
rc linux-image-5.15.0-100-generic 5.15.0-100.110 amd64 Signed kernel image generic
rc linux-image-5.15.0-101-generic 5.15.0-101.111 amd64 Signed kernel image generic
rc linux-image-5.15.0-102-generic 5.15.0-102.112 amd64 Signed kernel image generic
rc linux-image-5.15.0-105-generic 5.15.0-105.115 amd64 Signed kernel image generic
I'd like to get these cleaned/purged/removed (I don't know the proper verb here in APT-speak).
I've tried just about every combination of apt clean, purge, remove, autoremove, autoremove-with-purge, apt -fy, and so on. Nothing so far has seemed to destroy the zombies.
Help? ;-)