[update-manager-core] do-release-upgrade removing pinned / locked version packages

Bug #1166568 reported by B Bobo
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
New
Undecided
Unassigned
update-manager-core (Ubuntu)
New
Undecided
Unassigned

Bug Description

I want to upgrade Ubuntu, but do-release-upgrade removes even locked-version packages. The problem is certain packages, e.g. harpia and shogun-octave, no longer exist in recent Ubuntu versions. I need those packages. This makes upgrading impossible.

$ lsb_release -d
Ubuntu 12.04.2 LTS

$ do-release-upgrade -d
raring.tar.gz

Packages to be removed: [...] harpia shogun-octave

Packages to be installed: [... harpia and shogun-octave not listed ...]

Packages to be upgraded: [... harpia and shogun-octave not listed ...]

I think packages with locked versions and their dependencies should be left alone during an upgrade.

B Bobo (yout-bobo123)
description: updated
B Bobo (yout-bobo123)
affects: apt → apt (Ubuntu)
tags: added: apt update-manager-core
summary: - [update-manager-core] do-release-upgrade removing locked version
- packages
+ [update-manager-core] do-release-upgrade removing pinned / locked
+ version packages
Revision history for this message
Daniel Hartwig (wigs) wrote :

What do you mean “locked version”? There are multiple programs and documents using this term to mean different things, please state exactly how you “locked” these packages.

tags: removed: apt update-manager-core
Revision history for this message
B Bobo (yout-bobo123) wrote :

Versions locked using Synaptic per Ubuntu Pinning Howto https://help.ubuntu.com/community/PinningHowto#line-97
and Ubuntu Apt Get Howto https://help.ubuntu.com/community/AptGet/Howto#line-67

Revision history for this message
Daniel Hartwig (wigs) wrote : Re: [Bug 1166568] Re: [update-manager-core] do-release-upgrade removing pinned / locked version packages

On 31 May 2013 12:49, B Bobo <email address hidden> wrote:
> Versions locked using Synaptic per Ubuntu Pinning Howto https://help.ubuntu.com/community/PinningHowto#line-97
> and Ubuntu Apt Get Howto https://help.ubuntu.com/community/AptGet/Howto#line-67
>

[It seems the advise in those documents is outdated and inaccurate. I
will file some reports on that.]

Synaptic version locking is ineffective in other apt tools. See bug
#42178
. The same issue exists with aptitude holds.

The only solution is to use apt/dpkg holds, supported everywhere. The
PinningHowto says to do:
# echo libxfont1 hold | dpkg --set-selections

If your apt is recent enough, you can instead use:
# apt-mark hold harpia shogun-octave

After applying this hold, confirm the changes with e.g.:
$ dpkg -s harpia | grep Status
Status: hold ok installed

Revision history for this message
Daniel Hartwig (wigs) wrote :

On 31 May 2013 13:15, Daniel Hartwig <email address hidden> wrote:
> After applying this hold, confirm the changes with e.g.:
> $ dpkg -s harpia | grep Status
> Status: hold ok installed

At that point ‘apt-get upgrade’ should not remove the packages, and
‘apt-get dist-upgrade’ should give a warning.

I leave it to Ubuntu-types to identify the expected interaction of
‘do-release-upgrade’ and held packages.

Revision history for this message
B Bobo (yout-bobo123) wrote :

Thank you for explaining that.

It is sad and ironic that synaptic was deliberately changed (according to comment#1 at https://bugs.launchpad.net/ubuntu/+source/synaptic/+bug/42178#bug-branches-container) to use /var/lib/synaptic/preferences instead of the global preferences file /etc/apt/preferences

I think synaptic is actually more confusing because of that change! I agree with what you wrote on the bug report. I too would like to see the 2004 change reverted, so that synaptic uses the global preferences file in future.

Revision history for this message
Daniel Hartwig (wigs) wrote :

On 31 May 2013 15:34, B Bobo <email address hidden> wrote:
> Thank you for explaining that.
>

Once setting the holds with dpkg or apt-mark, does
‘do-release-upgrade’ work as expected?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.