apt-get -y --ignore-hold fails due to a held package

Bug #1226168 reported by Josh Smift
20
This bug affects 4 people
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

I install an older version of a package:

  wget http://updates.onlab.us/GPG-KEY-ONLAB
  sudo apt-key add GPG-KEY-ONLAB

  sudo sh -c 'echo "deb http://updates.onlab.us/debian stable/" >> /etc/apt/sources.list'

  sudo apt-get update
  sudo apt-get -y install flowvisor=0.8.7-1

I then tell dpkg to hold this package:

  echo "flowvisor hold" | sudo /usr/bin/dpkg --set-selections

I then try to upgrade the package:

  sudo apt-get install -y --ignore-hold flowvisor=0.8.17-3

I expected that to succeed non-interactively, because I said -y and --ignore-hold. Instead, I get this error:

  [12:49:25] jbs@jbsofsw-ubuntu:/home/jbs
  +$ sudo apt-get install -y --ignore-hold flowvisor=0.8.17-3
  Reading package lists... Done
  Building dependency tree
  Reading state information... Done
  The following held packages will be changed:
    flowvisor
  The following packages will be upgraded:
    flowvisor
  1 upgraded, 0 newly installed, 0 to remove and 110 not upgraded.
  Need to get 7245 kB of archives.
  After this operation, 2179 kB disk space will be freed.
  E: There are problems and -y was used without --force-yes

If I remove the hold:

  echo "flowvisor install" | sudo /usr/bin/dpkg --set-selections

I can then upgrade it with -y just fine.

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: apt 0.8.16~exp12ubuntu10.5
ProcVersionSignature: Ubuntu 3.2.0-32.51-virtual 3.2.30
Uname: Linux 3.2.0-32-virtual x86_64
ApportVersion: 2.0.1-0ubuntu14
Architecture: amd64
Date: Mon Sep 16 13:48:19 2013
Ec2AMI: ami-00000085
Ec2AMIManifest: FIXME
Ec2AvailabilityZone: nova
Ec2InstanceType: xo.medium
Ec2Kernel: unavailable
Ec2Ramdisk: unavailable
SourcePackage: apt
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Josh Smift (irilyth+ubuntu) wrote :
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in apt (Ubuntu):
status: New → Confirmed
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.