Article View: linux.debian.user
Article #525Re: APT::NeverAutoRemove::KernelCount "3"; Not quite working: I get more than three kernels
From: David Wright
Date: Sun, 15 Nov 2026 18:10
Date: Sun, 15 Nov 2026 18:10
52 lines
5963 bytes
5963 bytes
On Sun 15 Nov 2026 at 08:43:23 (-0700), Charles Curley wrote: > On Sun, 15 Nov 2026 08:42:23 -0500 > Greg Wooledge <greg@wooledge.org> wrote: > > > > I don't think I have ever run "apt autoremove". I just did so on a > > > machine with five kernels installed; none were removed. > > > > Hmm. Maybe it's a difference between apt-get and apt, then? I > > usually use apt-get, and it definitely doesn't do an autoremove for > > me. > > > > > > hobbit:~$ apt-get -s upgrade > > NOTE: This is only a simulation! > > [...] > > The following packages were automatically installed and are no longer > > required: enchant-2 ghp-import gir1.2-gtk-2.0 girepository-tools > > gsfonts gsfonts-x11 [...] > > Use 'apt autoremove' to remove them. > > 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. > > > > > > I don't do autoremoves on that system. On others where I do use it, > > it has always (so far) kept only the 2 latest kernels, as expected. > > root@peregrine:~# pre ux-im ; uname -r > linux-image-6.12.111+deb13-amd64 6.12.111-1 amd64 > linux-image-6.12.113+deb13-amd64 6.12.113-1 amd64 > linux-image-6.12.115+deb13.1-amd64 6.12.115-2 amd64 > linux-image-6.12.116+deb13-amd64 6.12.116-1 amd64 > linux-image-6.12.117+deb13-amd64 6.12.117-1 amd64 > linux-image-amd64 6.12.117-1 amd64 > 6.12.117+deb13-amd64 > root@peregrine:~# apt-get -s upgrade > Reading package lists... Done > Building dependency tree... Done > Reading state information... Done > Calculating upgrade... Done > 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. > root@peregrine:~# apt-get -s autoremove > Reading package lists... Done > Building dependency tree... Done > Reading state information... Done > 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. > root@peregrine:~# I don't understand this output. I'd prefer to see the output from: $ dpkg -l | grep linux-image $ apt-get -s --purge autoremove Cheers, David.
Technical Details
Message-ID:
<NZMPU-c5zY-19@gated-at.bofh.it>Path:
mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomodReferences:
<NZvYJ-bW04-11@gated-at.bofh.it> <NZyDf-bXfH-5@gated-at.bofh.it> <NZAF3-bYAN-1@gated-at.bofh.it> <NZIMh-c35e-3@gated-at.bofh.it> <NZKEs-c49T-83@gated-at.bofh.it>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.corradoroberto.it!diesel.cu.mi.it!bofh.it!news.nic.it!robomod
From: David Wright <deblis@lionunicorn.co.uk>
Newsgroups: linux.debian.user
Subject: Re: APT::NeverAutoRemove::KernelCount "3"; Not quite working: I get more than three kernels
Date: Sun, 15 Nov 2026 19:10:02 +0100
Message-ID: <NZMPU-c5zY-19@gated-at.bofh.it>
References: <NZvYJ-bW04-11@gated-at.bofh.it> <NZyDf-bXfH-5@gated-at.bofh.it> <NZAF3-bYAN-1@gated-at.bofh.it> <NZIMh-c35e-3@gated-at.bofh.it> <NZKEs-c49T-83@gated-at.bofh.it>
X-Mailbox-Line: From debian-user-request@lists.debian.org Sun Nov 15 18:08:50 2026
Old-Return-Path: <nobody@lionunicorn.co.uk>
X-Amavis-Spam-Status: No, score=-2.098 tagged_above=-10000 required=5.3
tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001,
RCVD_IN_MSPIKE_WL=0.001] autolearn=ham autolearn_force=no
X-Policyd-Weight: using cached result; rate: -2.33
X-Sender-ID: thundermail|x-authsender|david@lionunicorn.co.uk
X-Sender-ID: thundermail|x-authsender|david@lionunicorn.co.uk
X-Mc-Relay: Junk
X-Mailchannels-Senderid: thundermail|x-authsender|david@lionunicorn.co.uk
X-Mailchannels-Auth-ID: thundermail
X-Spill-Celery: 608d636401da8938_1794766114830_3031399779
X-Mc-Loop-Signature: 1794766114830:4084151786
X-Mc-Ingress-Time: 1794766114829
Authentication-Results: cloud225.thundercloud.uk;
spf=pass (sender IP is 24.255.218.34) smtp.mailfrom=nobody@lionunicorn.co.uk smtp.helo=argo.corp
Received-Spf: pass (cloud225.thundercloud.uk: connection is authenticated)
Reply-To: debian-user@lists.debian.org
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
X-Ppp-Message-ID:
<179476611242.3438489.11652572417279364035@cloud225.thundercloud.uk>
X-Ppp-Vhost: lionunicorn.co.uk
X-Rspamd-Queue-ID: 4jSJrw48Z6zGnsc
X-Rspamd-Server: mailclean11
X-Rspamd-Action: no action
X-Spamd-Result: default: False [2.60 / 999.00];
REPLYTO_EQ_TO_ADDR(2.00)[];
ENVFROM_SERVICE_ACCT(1.00)[];
DMARC_POLICY_ALLOW_WITH_FAILURES(-0.50)[];
FORGED_SENDER(0.30)[deblis@lionunicorn.co.uk,nobody@lionunicorn.co.uk];
ONCE_RECEIVED(0.20)[];
R_DKIM_ALIGNED(-0.10)[strict];
REPLYTO_MX_GOOD(-0.10)[bendel.debian.org];
MIME_GOOD(-0.10)[text/plain];
MX_GOOD(-0.10)[mail.lionunicorn.co.uk];
UWH_IDENTITY(0.00)[1|f9bd8e6ee49548ca|t=131|r=0|m=postfix|n=17|h=pppm:1:15/1+pppv:1:16/0|f=nv];
FREEMAIL_ENVRCPT(0.00)[hotmail.co.uk];
R_DKIM_ALLOW(0.00)[lionunicorn.co.uk:s=default];
DMARC_POLICY_ALLOW(0.00)[lionunicorn.co.uk,none];
TO_MATCH_ENVRCPT_ALL(0.00)[];
MIME_TRACE(0.00)[0:+];
RCPT_COUNT_ONE(0.00)[1];
REPLYTO_DOM_NEQ_FROM_DOM(0.00)[];
DKIM_TRACE(0.00)[lionunicorn.co.uk:+];
ARC_NA(0.00)[];
R_SPF_SOFTFAIL(0.00)[~all];
FROM_NEQ_ENVFROM(0.00)[deblis@lionunicorn.co.uk,nobody@lionunicorn.co.uk];
FROM_HAS_DN(0.00)[];
RCVD_TLS_ALL(0.00)[];
TO_DN_NONE(0.00)[];
ASN(0.00)[asn:34931, ipnet:149.255.56.0/22, country:GB];
RCVD_VIA_SMTP_AUTH(0.00)[];
MISSING_XM_UA(0.00)[];
RCVD_COUNT_ONE(0.00)[1];
HAS_REPLYTO(0.00)[debian-user@lists.debian.org]
X-Mailing-List: <debian-user@lists.debian.org> archive/latest/832911
List-ID: <debian-user.lists.debian.org>
List-URL: <https://lists.debian.org/debian-user/>
List-Archive: https://lists.debian.org/msgid-search/avn1HIGw1_1mb5g_@argo.corp
Approved: robomod@news.nic.it
Lines: 52
Organization: linux.* mail to news gateway
Sender: robomod@news.nic.it
X-Original-Date: Sun, 15 Nov 2026 12:08:28 -0600
X-Original-Message-ID: <avn1HIGw1_1mb5g_@argo.corp>
X-Original-References: <20261114170142.1a7283e6@hawk.localdomain>
<avkeN-Tw0ppxgzqc@wooledge.org>
<20261114220535.588a318e@peregrine.localdomain>
<avm2v9BeMGRZx__7@wooledge.org>
<20261115084323.6000e2dc@peregrine.localdomain>