[PLUG] apt-get: why "kept back"?

Jeme A Brelin jeme at brelin.net
Wed Apr 28 14:20:03 UTC 2004


On Wed, 28 Apr 2004, Steven Raymond wrote:
> Why do I get this message about certain packages not being installed, when
> doing an "apt-get upgrade":
>
> The following packages have been kept back:
> discover gnomemeeting gnumeric kamera kcmlinuz kcoloredit kcron
> kdat kdead.....
>
> It seems that the work-around is to go "apt-get install <paste>" where
> paste is the list of packages from above.  While it seems to work, why the
> hassle?
>
> What is the reason for the packages being held back in the first place?

"apt-get upgrade" will update existing packages, but will NOT install new
packages.

If the dependencies have changed for the existing packages and the upgrade
would require the installation of new packages, then "upgrade" will leave
the packages with unmet dependencies untouched.

There are other reasons why a package might be "kept back".  It is best to
see what happens with the package when you try to "install" it.  It's a
tiny bit dangerous to just go ahead and "install" it, though... so do
this:
apt-get -s install <package kept back>

This will do a dry run, but not actually change anything.  You can figure
out from that output why "upgrade" didn't touch it.

> Someone in #orlug said it was because of a dependency problem.  I
> thought the purpose or goal of apt was to fix all dependency problems
> for you?

Yeah, apt handles dependencies just fine.  But "upgrade" isn't for making
major changes to a system (like adding new packages), but for safely
upgrading all of your existing packages.

> How do I make it not hold back any packages with apt-get upgrade?

If it's a production system, I promise you that the behavior is exactly
what you want.  If it's a desktop system, you can either do the dangerous
"dist-upgrade" (dangerous only because it'll install any new available
packages with whatever dependencies it deems fit, so you might end up with
a substantially less secure and sleek system than before).

J.
--
   -----------------
     Jeme A Brelin
    jeme at brelin.net
   -----------------
 [cc] counter-copyright
 http://www.openlaw.org




More information about the PLUG mailing list