[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#985771: apt-auto-removal isn't run by kernel update



On Tue, Mar 23, 2021 at 10:18:34AM +0100, Reiner Schulz wrote:
> Package: apt
> Version: 1.8.2.2
> Severity: normal
> 
> Dear Maintainer,
> 
> On 5 of our Debian 10 Server the separate /boot Partition filled up with old kernels
> on a few Server without separate /boot partition are up to 10 old kernel left 
> 
> I check if linux-image\* was marked "manual", there where a few on some Server, but not on all.
> 
> /etc/kernel/postinst.d/apt-auto-removal should remove all old kernels but the last two

No... it creates a config file telling apt which kernels to remove
_when you run autoremove_.

apt 2.2 automatically removes kernels during apt dist-upgrade / apt
full-upgrade (not using apt-get).

Did you run autoremove?

> 
> I greped over 23 Debian 10 Server:
> ansible DEBIAN_10 -b -m shell -a 'zgrep 'postinst.d' /var/log/apt/term.log* ' >> grep_term.log 2>&1
>  
> grep -c -E 'zz-update-grub'  grep_term.log
> 115
> grep -c -E 'initramfs-tools'  grep_term.log
> 138
> grep -c -E 'apt-auto-removal'  grep_term.log
> 2
> 
> i will attach grep_term.log

I'm not sure what this is supposed to tell us, the hook is (usually)
silent, so it's not going to appear in the terminal output.

> 
> /etc/kernel/postinst.d/apt-auto-removal isn't run after kernel updates

I don't believe that.

-- 
debian developer - deb.li/jak | jak-linux.org - free software dev
ubuntu core developer                              i speak de, en


Reply to: