Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #205853 > unrolled thread
| Started by | Felix Rubio <felix@kngnt.org> |
|---|---|
| First post | 2019-03-01 09:50 +0100 |
| Last post | 2019-03-01 15:50 +0100 |
| Articles | 8 — 6 participants |
Back to article view | Back to linux.debian.user
prevent apt from downgrading packages Felix Rubio <felix@kngnt.org> - 2019-03-01 09:50 +0100
Re: prevent apt from downgrading packages "Alexander V. Makartsev" <avbetev@gmail.com> - 2019-03-01 10:50 +0100
Re: prevent apt from downgrading packages Andrea Borgia <andrea@borgia.bo.it> - 2019-03-01 11:10 +0100
Re: prevent apt from downgrading packages "Alexander V. Makartsev" <avbetev@gmail.com> - 2019-03-01 11:20 +0100
Re: prevent apt from downgrading packages Andrea Borgia <andrea@borgia.bo.it> - 2019-03-01 20:50 +0100
Re: prevent apt from downgrading packages john doe <johndoe65534@mail.com> - 2019-03-01 11:20 +0100
Re: prevent apt from downgrading packages Felix Rubio Dalmau <felix@kngnt.org> - 2019-03-01 21:30 +0100
Re: prevent apt from downgrading packages Dan Ritter <dsr@randomstring.org> - 2019-03-01 15:50 +0100
| From | Felix Rubio <felix@kngnt.org> |
|---|---|
| Date | 2019-03-01 09:50 +0100 |
| Subject | prevent apt from downgrading packages |
| Message-ID | <xwM1I-7L1-9@gated-at.bofh.it> |
Hi all,
I have mix stable+testing (~1200 packages from stable, ~20 packages
from testing). I have the following contents in
/etc/apt/preferences.d/pinning:
Package: *
Pin: release a=stable
Pin-Priority: 1001
Package: *
Pin: release a=testing
Pin-Priority: 200
Package: *
Pin: release a=experimental
Pin-Priority: -10
Package: *
Pin: release a=unstable
Pin-Priority: -10
What happens is: after an apt update, I list the packages to be upgraded
with apt list --upgradable, and I get only those that will be upgraded.
However, when I run apt upgrade, I get a number of packages that will be
downgraded. How can I prevent this downgrading from happening?
Thank you!
Felix
[toc] | [next] | [standalone]
| From | "Alexander V. Makartsev" <avbetev@gmail.com> |
|---|---|
| Date | 2019-03-01 10:50 +0100 |
| Message-ID | <xwMXL-8ps-1@gated-at.bofh.it> |
| In reply to | #205853 |
[Multipart message — attachments visible in raw view] — view raw
On 01.03.2019 13:27, Felix Rubio wrote: > Hi all, > > I have mix stable+testing (~1200 packages from stable, ~20 > packages from testing). I have the following contents in > /etc/apt/preferences.d/pinning: > This is something you should not do in first place. [1] The right and safe way to run stable branch and install packages from other branches (eg testing) is to make backports of them. [2] This is why debian-backports branch exists. When doing it right way you won't need any pinning and if package you backported will hit stretch-backports branch and will be newer version it will be upgraded just as regular package. [1] https://wiki.debian.org/DontBreakDebian#Don.27t_make_a_FrankenDebian [2] https://wiki.debian.org/SimpleBackportCreation -- With kindest regards, Alexander. ⢀⣴⠾⠻⢶⣦⠀ ⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system ⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org ⠈⠳⣄⠀⠀⠀⠀
[toc] | [prev] | [next] | [standalone]
| From | Andrea Borgia <andrea@borgia.bo.it> |
|---|---|
| Date | 2019-03-01 11:10 +0100 |
| Message-ID | <xwNh7-ja-1@gated-at.bofh.it> |
| In reply to | #205854 |
[Multipart message — attachments visible in raw view] — view raw
Il giorno ven 1 mar 2019 alle ore 10:46 Alexander V. Makartsev < avbetev@gmail.com> ha scritto: > On 01.03.2019 13:27, Felix Rubio wrote: > > I have mix stable+testing (~1200 packages from stable, ~20 packages > from testing). I have the following contents in > /etc/apt/preferences.d/pinning: > > This is something you should not do in first place. [1] > I have a "testing" installation with "stable" as additional source, meaning that in my case the numbers would probably be reversed. Is that still a no-no ? Regards, Andrea.
[toc] | [prev] | [next] | [standalone]
| From | "Alexander V. Makartsev" <avbetev@gmail.com> |
|---|---|
| Date | 2019-03-01 11:20 +0100 |
| Message-ID | <xwNqN-my-3@gated-at.bofh.it> |
| In reply to | #205856 |
[Multipart message — attachments visible in raw view] — view raw
On 01.03.2019 15:07, Andrea Borgia wrote: > > Il giorno ven 1 mar 2019 alle ore 10:46 Alexander V. Makartsev > <avbetev@gmail.com <mailto:avbetev@gmail.com>> ha scritto: > > On 01.03.2019 13:27, Felix Rubio wrote: >> I have mix stable+testing (~1200 packages from stable, ~20 >> packages from testing). I have the following contents in >> /etc/apt/preferences.d/pinning: > This is something you should not do in first place. [1] > > > I have a "testing" installation with "stable" as additional source, > meaning that in my case the numbers would probably be reversed. > Is that still a no-no ? > > Regards, > Andrea. > > This is something you have to decide for yourself and deal with unforeseen consequences. If you actually *build* packages from "stable" on "testing" system, using dependencies for building also from "testing" then it should be ok compatibility wise. If you simply *install* packages from various sources and branches then you asking for trouble. -- With kindest regards, Alexander. ⢀⣴⠾⠻⢶⣦⠀ ⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system ⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org ⠈⠳⣄⠀⠀⠀⠀
[toc] | [prev] | [next] | [standalone]
| From | Andrea Borgia <andrea@borgia.bo.it> |
|---|---|
| Date | 2019-03-01 20:50 +0100 |
| Message-ID | <xwWkp-5BJ-1@gated-at.bofh.it> |
| In reply to | #205857 |
Il 01/03/19 11:18, Alexander V. Makartsev ha scritto: > This is something you have to decide for yourself and deal with > unforeseen consequences. If you actually *build* packages from > "stable" on "testing" system, using dependencies for building also > from "testing" then it should be ok compatibility wise. If you simply > *install* packages from various sources and branches then you asking > for trouble. I'm installing from testing, except when the package was only available in stable. I haven't seen any particular issues so far, only problems I had were _before_ the upgrade when I had to purge a few packages and libraries from the old "debian-multimedia" repo... after that, the upgrade to testing went well and not a problem since. Il 01/03/19 11:18, john doe ha scritto:> On 3/1/2019 11:07 AM, Andrea Borgia wrote: > There are no good answers here. It is up to you, all depends on your > needs and environment. Noted. Thanks, Andrea.
[toc] | [prev] | [next] | [standalone]
| From | john doe <johndoe65534@mail.com> |
|---|---|
| Date | 2019-03-01 11:20 +0100 |
| Message-ID | <xwNqN-my-9@gated-at.bofh.it> |
| In reply to | #205856 |
On 3/1/2019 11:07 AM, Andrea Borgia wrote: > Il giorno ven 1 mar 2019 alle ore 10:46 Alexander V. Makartsev < > avbetev@gmail.com> ha scritto: > >> On 01.03.2019 13:27, Felix Rubio wrote: >> >> I have mix stable+testing (~1200 packages from stable, ~20 packages >> from testing). I have the following contents in >> /etc/apt/preferences.d/pinning: >> >> This is something you should not do in first place. [1] >> > > I have a "testing" installation with "stable" as additional source, meaning > that in my case the numbers would probably be reversed. > Is that still a no-no ? > There are no good answers here. It is up to you, all depends on your needs and environment. -- John Doe
[toc] | [prev] | [next] | [standalone]
| From | Felix Rubio Dalmau <felix@kngnt.org> |
|---|---|
| Date | 2019-03-01 21:30 +0100 |
| Message-ID | <xwWX7-64V-3@gated-at.bofh.it> |
| In reply to | #205854 |
On divendres, 1 de març de 2019 10:45:48 CET Alexander V. Makartsev wrote: > On 01.03.2019 13:27, Felix Rubio wrote: > > Hi all, > > > > I have mix stable+testing (~1200 packages from stable, ~20 > > packages from testing). I have the following contents in > > /etc/apt/preferences.d/pinning: > > > This is something you should not do in first place. [1] > The right and safe way to run stable branch and install packages from > other branches (eg testing) is to make backports of them. [2] This is > why debian-backports branch exists. > When doing it right way you won't need any pinning and if package you > backported will hit stretch-backports branch and will be newer version > it will be upgraded just as regular package. > > [1] https://wiki.debian.org/DontBreakDebian#Don.27t_make_a_FrankenDebian > [2] https://wiki.debian.org/SimpleBackportCreation > > Thank you for your advice. I have moved to stretch-backports as many packages as I could (I have to see what I do with the few, ~5, remaining). Regards! Felix
[toc] | [prev] | [next] | [standalone]
| From | Dan Ritter <dsr@randomstring.org> |
|---|---|
| Date | 2019-03-01 15:50 +0100 |
| Message-ID | <xwRE5-2OG-7@gated-at.bofh.it> |
| In reply to | #205853 |
Felix Rubio wrote:
> Hi all,
>
> I have mix stable+testing (~1200 packages from stable, ~20 packages from
> testing). I have the following contents in /etc/apt/preferences.d/pinning:
>
> Package: *
> Pin: release a=stable
> Pin-Priority: 1001
>
> Package: *
> Pin: release a=testing
> Pin-Priority: 200
>
> Package: *
> Pin: release a=experimental
> Pin-Priority: -10
>
> Package: *
> Pin: release a=unstable
> Pin-Priority: -10
>
> What happens is: after an apt update, I list the packages to be upgraded
> with apt list --upgradable, and I get only those that will be upgraded.
> However, when I run apt upgrade, I get a number of packages that will be
> downgraded. How can I prevent this downgrading from happening?
here are magic levels for the numbers in the priority field.
They are explained, at length, in man apt_preferences. The
highlights:
P >= 1000
causes a version to be installed even if this constitutes a
downgrade of the package
990 <= P < 1000
causes a version to be installed even if it does not come from the
target release, unless the installed version is more recent
500 <= P < 990
causes a version to be installed unless there is a version
available belonging to the target release or the installed version
is more recent
100 <= P < 500
causes a version to be installed unless there is a version
available belonging to some other distribution or the installed
version is more recent
0 < P < 100
causes a version to be installed only if there is no installed
version of the package
P < 0
prevents the version from being installed
Your downgrades are probably caused by the 1001 priority for
stable; changing that to 999 might be what you want.
-dsr-
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.user
csiph-web