just a warning?

Stephen Ryan taketwoaspirin at gmail.com
Thu Jun 29 19:19:12 UTC 2006


On 6/29/06, Me - Atlantic <jdangler at atlantic.net> wrote:
>
> > Even a box that is on 24/7 with a full-time
> > connection can have this problem if there's a transient failure
> > elsewhere in the Internet.
> >
> > I used to get this on my laptop pretty regularly before I upgraded to
> > dapper, because I'd boot it while traveling, away from an Internet
> > connection, but haven't seen it since installing dapper.
>
> So the concensus is that it's a transient failure somewhere else on the
> internet, or that somehow upgrading to Dapper "fixes" the problem.
>
> I'm not sure how upgrading the version of the OS will resolve this,
> since apt will be running the current release of apt regardless of the
> OS version.

??? Not unless you're screwing around with mixing releases, in which
case you should already know a lot more about this than the
information that has been posted in this thread.

[warning: long explanation follows]

"apt" is a program that runs on your system; it downloads a list of
packages from each of the servers listed in /etc/apt/sources.list, via
a request such as "apt-get update", "aptitude update", or by clicking
the "Reload" button in Synaptic, because Synaptic uses apt to do the
low-level work.  It can also do this when one of these commands is run
automatically; a default Ubuntu installation has such an automatic
job, installed in /etc/cron.daily/apt, which checks for updates every
day.  This is how the icon in the system tray knows if there are
updates to be downloaded and installed.

"apt" also handles downloading and installing new packages; it uses
previously-downloaded list of packages to work out which other
packages and versions are necessary to make the requested packages
functional, determines the URLs for those package files, downloads
them, unpacks them and configures them.  All of this is good magic.

An up-to-date Breezy installation should have version 0.6.40.1ubuntu10
of apt; Dapper has apt version 0.6.43.3ubuntu2.  apt's changelog
(found at http://changelogs.ubuntu.com/changelogs/pool/main/a/apt/apt_0.6.43.3ubuntu2/changelog)
 lists the following for version 0.6.43.3:

....
  * cmdline/apt-get.cc: only run the list-cleaner if a update was
    successfull
  * apt-get update errors are only warnings nowdays
  * be more careful with the signature file on network failures
[sic]


What happened was that when the apt version in Breezy tried to
download the package lists and failed for any reason, it assumed that
the repository in question had gone away and therefore it deleted the
associated package list, so that it wouldn't be confused when trying
to compute dependency chains with versions of packages that couldn't
actually be downloaded.  Because apt was set to automatically update
package lists in the middle of the night (or just after boot, if not
on at the appropriate time in the middle of the night), it might trip
over a network error of some sort that would otherwise not be a
problem.  A laptop that was booted away from a network is a common
trigger for this, as would be anyone on an intermittent connection,
such as dial-up.  In either case, apt would delete the package lists
silently, and the hapless user is not aware of this until much later.

apt version 0.6.43.3 is much smarter about the possibility of
transient network failures, and so doesn't delete the cached package
lists quite so readily.  In particular, it doesn't delete them in the
middle of the night without warning.  The only reason upgrading to
dapper fixes this particular bug is because dapper has version
0.6.43.3 of apt, and breezy does not.

Note that upgrading to a more recent version of apt only fixes the
problem where a transient network problem in the middle of the night /
at boot time would make apt/Synaptic toss up this error later;
obviously, it can't magically fix the Internet or make otherwise
un-downloadable things be downloadable.  It just reduces the
probability of having something go wrong while nobody is watching.

> As to the transient problem somewhere else on the web (like the
> mirrors/servers that apt is getting its data from) seems much more
> likely.  I've had the same problem with Breezy since Dapper was
> released, and chalked it up to the fact that everyone is pounding the
> servers for updates.




More information about the ubuntu-users mailing list