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

Re: how to keep the most recent stable kernel?



Hi Soren, hi Jens, hi.

Soren Stoutner - 08.11.24, 00:39:24 MEZ:
> > > If you set apt to prefer backports over stable, then it will
> > > automatically update.
> > > 
> > > For example, you can create the following file:
> > > 
> > > /etc/apt/preferences.d/bookworm-backports
> > > 
> > > With these contents:
> > > 
> > > Package: *
> > > Pin: release n=bookworm-backports
> > > Pin-Priority: 600
> > 
> > …which is not the recommended way, to get all backports, no matter
> > what. Backports should always be installed explicitely. They will be
> > upgraded automatically if there is a newer version on bpo, without
> > hacking the /etc/apt/preferrences
[…]
> If you don't want to enable automatic updates for all backports
> packages, you can do so just for a specific package by changing the
> "Package: *" line.
> 
> Package: linux-image-amd64
> 
> There are a few syntax examples at:
> 
> https://wiki.debian.org/AptConfiguration

While something like

Explanation: Automatic update of packages from experimental
Package: *
Pin: release a=experimental
Pin-Priority: 200

is needed *only* in case you like to automatically update packages you 
have installed from experimental which default to a priority of 1 which is 
never automatically upgraded, to my knowledge it is not needed for 
packages from backports because of:

"Release files make this possible, and all backported packages are pinned 
to priority 100 via ButAutomaticUpgrades: yes."

https://backports.debian.org/Instructions/

Also by pinning above 500 you cause apt to upgrade every package in stable 
which has a version in backports and this is not recommended practice. 
This is why above example for experimental is below 500. Thus only 
packages that have been installed from experimental *by choice* *and* are 
of higher version in there are automatically upgraded. This means you can 
install Plasma 6.2 from experimental and keep it up to date until it gets 
uploaded to unstable in a newer version. Then apt keeps it up to date from 
unstable again and will not automatically pick up any future newer version 
in experimental until you install it by choice.

That is at least my understanding of pinning. Please correct any 
inaccuracies you find. See apt_preferences(5) for further details.

Best,
-- 
Martin



Reply to: