Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #194223 > unrolled thread

apt{-cache,-get,itude} show wrong version of package after update

Started byJean-Baptiste Thomas <cau2jeaf1honoq@laposte.net>
First post2018-03-27 20:00 +0200
Last post2018-04-02 17:50 +0200
Articles 16 — 8 participants

Back to article view | Back to linux.debian.user

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  apt{-cache,-get,itude} show wrong version of package after update Jean-Baptiste Thomas <cau2jeaf1honoq@laposte.net> - 2018-03-27 20:00 +0200
    Re: apt{-cache,-get,itude} show wrong version of package after  update Abdullah Ramazanoglu <ar018@yahoo.com> - 2018-03-27 20:30 +0200
      Re: apt{-cache,-get,itude} show wrong version of package after  update Abdullah Ramazanoglu <ar018@yahoo.com> - 2018-03-27 21:00 +0200
    Re: apt{-cache,-get,itude} show wrong version of package after  update Abdullah Ramazanoglu <ar018@yahoo.com> - 2018-03-27 21:30 +0200
    Re: apt{-cache,-get,itude} show wrong version of package after update Mark Fletcher <mark27q1@gmail.com> - 2018-03-28 00:50 +0200
      Re: apt{-cache,-get,itude} show wrong version of package after update <tomas@tuxteam.de> - 2018-03-28 09:40 +0200
        Re: apt{-cache,-get,itude} show wrong version of package after update Mark Fletcher <mark27q1@gmail.com> - 2018-04-06 00:40 +0200
          Re: apt{-cache,-get,itude} show wrong version of package after update David Wright <deblis@lionunicorn.co.uk> - 2018-04-06 02:40 +0200
            Re: apt{-cache,-get,itude} show wrong version of package after update Curt <curty@free.fr> - 2018-04-06 11:00 +0200
              Re: apt{-cache,-get,itude} show wrong version of package after update David Wright <deblis@lionunicorn.co.uk> - 2018-04-07 17:20 +0200
    Re: apt{-cache,-get,itude} show wrong version of package after update "John Crawley (johnraff)" <john@bunsenlabs.org> - 2018-03-28 03:10 +0200
      Re: apt{-cache,-get,itude} show wrong version of package after  update Jean-Baptiste Thomas <cau2jeaf1honoq@laposte.net> - 2018-03-28 21:10 +0200
        Re: apt{-cache,-get,itude} show wrong version of package after update songbird <songbird@anthive.com> - 2018-03-29 01:00 +0200
        Re: apt{-cache,-get,itude} show wrong version of package after update David Wright <deblis@lionunicorn.co.uk> - 2018-03-29 01:10 +0200
          Re: apt{-cache,-get,itude} show wrong version of package after  update Jean-Baptiste Thomas <cau2jeaf1honoq@laposte.net> - 2018-04-02 11:00 +0200
            Re: apt{-cache,-get,itude} show wrong version of package after update David Wright <deblis@lionunicorn.co.uk> - 2018-04-02 17:50 +0200

#194223 — apt{-cache,-get,itude} show wrong version of package after update

FromJean-Baptiste Thomas <cau2jeaf1honoq@laposte.net>
Date2018-03-27 20:00 +0200
Subjectapt{-cache,-get,itude} show wrong version of package after update
Message-ID<vy134-7tp-5@gated-at.bofh.it>
After apt-get update, attempting to install ntp tries to
download version 1:4.2.8p10+dfsg-3+deb9u1 and fails. It tries
to download +deb9u1 because

  $ aptitude show ntp
  Package: ntp
  Version: 1:4.2.8p10+dfsg-3+deb9u1
  State: not installed
  [...]

and it fails because the version of the package in the Debian 9
mirror listed in /etc/apt/sources.list is +deb9u2 :

  ntp_4.2.8p10+dfsg-3+deb9u2_amd64.deb

I don't understand what went wrong. apt-get update seemed to go
well, only complaining about missing "DEP-11 64x64 Icons", which
are presumably not a vital part of ntp.

How is this possible ? I'm confused.

[toc] | [next] | [standalone]


#194224 — Re: apt{-cache,-get,itude} show wrong version of package after update

FromAbdullah Ramazanoglu <ar018@yahoo.com>
Date2018-03-27 20:30 +0200
SubjectRe: apt{-cache,-get,itude} show wrong version of package after update
Message-ID<vy1w5-85u-1@gated-at.bofh.it>
In reply to#194223
On Tue, 27 Mar 2018 19:50:03 +0200 (CEST) Jean-Baptiste Thomas said:

> After apt-get update, attempting to install ntp tries to
> download version 1:4.2.8p10+dfsg-3+deb9u1 and fails. It tries
> to download +deb9u1 because
> 
>   $ aptitude show ntp
>   Package: ntp
>   Version: 1:4.2.8p10+dfsg-3+deb9u1
>   State: not installed
>   [...]
> 
> and it fails because the version of the package in the Debian 9
> mirror listed in /etc/apt/sources.list is +deb9u2 :
> 
>   ntp_4.2.8p10+dfsg-3+deb9u2_amd64.deb
> 
> I don't understand what went wrong. apt-get update seemed to go
> well, only complaining about missing "DEP-11 64x64 Icons", which
> are presumably not a vital part of ntp.
> 
> How is this possible ? I'm confused.

Seems like you didn't run "apt-get update" before install? If the
problem still persists after "apt-get update" (or [Reload] in Synaptic)
could you post the outpout of "apt-cache policy ntp" ?

Regards
-- 
Abdullah Ramazanoglu

[toc] | [prev] | [next] | [standalone]


#194226 — Re: apt{-cache,-get,itude} show wrong version of package after update

FromAbdullah Ramazanoglu <ar018@yahoo.com>
Date2018-03-27 21:00 +0200
SubjectRe: apt{-cache,-get,itude} show wrong version of package after update
Message-ID<vy1Z8-8qg-23@gated-at.bofh.it>
In reply to#194224
On Tue, 27 Mar 2018 21:26:42 +0300 Abdullah Ramazanoglu said:
> On Tue, 27 Mar 2018 19:50:03 +0200 (CEST) Jean-Baptiste Thomas said:

>> After apt-get update, attempting to install ntp tries to...

> Seems like you didn't run "apt-get update" before install?

Oops, sorry, you have already stated that you have run "apt-get
update". So maybe there was a temporary propagation problem. Please
retry update + install steps to see if the problem persists. If it
does, then I would suggest changing the archive mirror you use
in /etc/apt/sources.list

Regards
-- 
Abdullah Ramazanoglu

[toc] | [prev] | [next] | [standalone]


#194227 — Re: apt{-cache,-get,itude} show wrong version of package after update

FromAbdullah Ramazanoglu <ar018@yahoo.com>
Date2018-03-27 21:30 +0200
SubjectRe: apt{-cache,-get,itude} show wrong version of package after update
Message-ID<vy2s9-nG-1@gated-at.bofh.it>
In reply to#194223
On Tue, 27 Mar 2018 19:50:03 +0200 (CEST) Jean-Baptiste Thomas said:

> How is this possible ? I'm confused.

In my Buster system the situation is like this:

~$ apt-cache policy ntp
ntp:
  Installed: (none)
  Candidate: 1:4.2.8p10+dfsg-6
  Version table:
     1:4.2.8p10+dfsg-6 500
        500 http://ftp.tr.debian.org/debian testing/main amd64 Packages
     1:4.2.8p10+dfsg-3+deb9u1 500
        500 file:/sdb6/software/debian-9.2.1-amd64-DVD-1 stretch/main
amd64 Packages

Version 1:4.2.8p10+dfsg-3+deb9u1 is on the Stretch installation DVD
(the bottom line) and the latest version in Buster repo is
1:4.2.8p10+dfsg-6 which do exist in my mirror
( http://ftp.tr.debian.org/debian/pool/main/n/ntp/ )

So, I think it seems like your update procedure didn't work for some
reason, or you might have somehow pinned ntp package (you can check in
Synaptic if ntp is "locked") to its original "deb9u1" version.

Regards
-- 
Abdullah Ramazanoglu

[toc] | [prev] | [next] | [standalone]


#194228

FromMark Fletcher <mark27q1@gmail.com>
Date2018-03-28 00:50 +0200
Message-ID<vy5zH-2uZ-1@gated-at.bofh.it>
In reply to#194223
On Tue, Mar 27, 2018 at 07:50:03PM +0200, Jean-Baptiste Thomas wrote:
> After apt-get update, attempting to install ntp tries to
> download version 1:4.2.8p10+dfsg-3+deb9u1 and fails. It tries
> to download +deb9u1 because
> 
>   $ aptitude show ntp
>   Package: ntp
>   Version: 1:4.2.8p10+dfsg-3+deb9u1
>   State: not installed
>   [...]
> 
> and it fails because the version of the package in the Debian 9
> mirror listed in /etc/apt/sources.list is +deb9u2 :
> 
>   ntp_4.2.8p10+dfsg-3+deb9u2_amd64.deb
> 
> I don't understand what went wrong. apt-get update seemed to go
> well, only complaining about missing "DEP-11 64x64 Icons", which
> are presumably not a vital part of ntp.
> 
> How is this possible ? I'm confused.

I'm not sure if you really did what it sounds like you did here, but if 
you did... you can't mix and match commands to apt-get and aptitude.

You did apt-get update so you need to use apt-get upgrade, or 
dist-upgrade, or whatever the apt-get command is (I don't much use 
apt-get, have switched to the apt command since upgrading to stretch).

If you want to use aptitude upgrade, or dist-upgrade, or safe-upgrade, 
or whatever the command is (embarrassingly I have forgotten, I used 
aptitude for years _before_ upgrading to stretch) you need to first do 
aptitude update.

apt-get update followed by aptitude upgrade will lead to pain.

Hope that helps

Mark

[toc] | [prev] | [next] | [standalone]


#194232

From<tomas@tuxteam.de>
Date2018-03-28 09:40 +0200
Message-ID<vydQB-a3-7@gated-at.bofh.it>
In reply to#194228
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wed, Mar 28, 2018 at 07:47:05AM +0900, Mark Fletcher wrote:

[...]

> I'm not sure if you really did what it sounds like you did here, but if 
> you did... you can't mix and match commands to apt-get and aptitude.

I think this is false, at least in such an unrestricted and
sweeping way. Apt (and apt-get, its younger cousin) and aptitude
are just front ends to dpkg and use the same data bases in
the background.

In particular...

> You did apt-get update so you need to use apt-get upgrade, or 
> dist-upgrade, or whatever the apt-get command is

...apt update and apt-get update are equivalent (as most
probably aptitude update is).

>                                             (I don't much use 
> apt-get, have switched to the apt command since upgrading to stretch).

Apt is just a friendlier front-end for apt-get: the command
outputs are not compatible (and you'll see a warning to that
effect in apt, aimed at those who want to use apt's output
in scripts), and aptitude has, AFAIK, some *extra* databases
to record user intention, and a different dependency resolver,
but the basic data sets (which packages are available, what
state each is in, etc.) are common.

> If you want to use aptitude upgrade, or dist-upgrade, or safe-upgrade, 
> or whatever the command is (embarrassingly I have forgotten, I used 
> aptitude for years _before_ upgrading to stretch) you need to first do 
> aptitude update.
> 
> apt-get update followed by aptitude upgrade will lead to pain.

I don't think so: but I'm ready to be proven wrong!

Cheers
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlq7RL8ACgkQBcgs9XrR2kaZxwCdG1yySXVjC7MUhxIgK1oxoHC1
XPsAn1fHEltkoY62cvsZGkrGqgqsKycI
=IloX
-----END PGP SIGNATURE-----

[toc] | [prev] | [next] | [standalone]


#194534

FromMark Fletcher <mark27q1@gmail.com>
Date2018-04-06 00:40 +0200
Message-ID<vBlHY-29p-9@gated-at.bofh.it>
In reply to#194232
On Wed, Mar 28, 2018 at 09:31:11AM +0200, tomas@tuxteam.de wrote:
> On Wed, Mar 28, 2018 at 07:47:05AM +0900, Mark Fletcher wrote:
> 
> [...]
> 
> > I'm not sure if you really did what it sounds like you did here, but if 
> > you did... you can't mix and match commands to apt-get and aptitude.
> 
> I think this is false, at least in such an unrestricted and
> sweeping way. Apt (and apt-get, its younger cousin) and aptitude
> are just front ends to dpkg and use the same data bases in
> the background.
> 
> In particular...
> 
> > You did apt-get update so you need to use apt-get upgrade, or 
> > dist-upgrade, or whatever the apt-get command is
> 
> ...apt update and apt-get update are equivalent (as most
> probably aptitude update is).
> 

It wasn't apt and apt-get that were being compared though, it was 
aptitude and apt-get. And there _is_ some sort of difference between 
those two such that you have to update with the right one; I'm sure I've 
seen discussion of that on this forum before (I don't have links 
though).

> >                                             (I don't much use 
> > apt-get, have switched to the apt command since upgrading to stretch).
> 
> Apt is just a friendlier front-end for apt-get: the command
> outputs are not compatible (and you'll see a warning to that
> effect in apt, aimed at those who want to use apt's output
> in scripts), and aptitude has, AFAIK, some *extra* databases
> to record user intention, and a different dependency resolver,
> but the basic data sets (which packages are available, what
> state each is in, etc.) are common.

See above. The only person who mentioned apt was me, and even then only 
in the context of that's what I use nowadays. The OP never mentioned apt.

In any case, those "extra databases" are probably a pretty good reason 
not to mix and match front-ends in quite the way the OP was doing, even 
if it doesn't immediately lead straight to trouble trying to get one's 
system updated properly in the way I suggested it might.
> 
> > If you want to use aptitude upgrade, or dist-upgrade, or safe-upgrade, 
> > or whatever the command is (embarrassingly I have forgotten, I used 
> > aptitude for years _before_ upgrading to stretch) you need to first do 
> > aptitude update.
> > 
> > apt-get update followed by aptitude upgrade will lead to pain.
> 
> I don't think so: but I'm ready to be proven wrong!
> 

Certainly I have no proof except my experience and my (patchy) memory 
that I have seen discussion of this point on this list before.

Anyway the actual issue in this case turned out to be nothing to do with 
mixing and matching front-ends to dpkg. Glad the OP got his problem 
figured out.

Mark

[toc] | [prev] | [next] | [standalone]


#194537

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2018-04-06 02:40 +0200
Message-ID<vBnA5-3wp-1@gated-at.bofh.it>
In reply to#194534
On Fri 06 Apr 2018 at 07:36:09 (+0900), Mark Fletcher wrote:
> On Wed, Mar 28, 2018 at 09:31:11AM +0200, tomas@tuxteam.de wrote:
> > On Wed, Mar 28, 2018 at 07:47:05AM +0900, Mark Fletcher wrote:
> > 
> > [...]
> > 
> > > I'm not sure if you really did what it sounds like you did here, but if 
> > > you did... you can't mix and match commands to apt-get and aptitude.
> > 
> > I think this is false, at least in such an unrestricted and
> > sweeping way. Apt (and apt-get, its younger cousin) and aptitude
> > are just front ends to dpkg and use the same data bases in
> > the background.
> > 
> > In particular...
> > 
> > > You did apt-get update so you need to use apt-get upgrade, or 
> > > dist-upgrade, or whatever the apt-get command is
> > 
> > ...apt update and apt-get update are equivalent (as most
> > probably aptitude update is).
> > 
> 
> It wasn't apt and apt-get that were being compared though, it was 
> aptitude and apt-get. And there _is_ some sort of difference between 
> those two such that you have to update with the right one; I'm sure I've 
> seen discussion of that on this forum before (I don't have links 
> though).
> 
> > >                                             (I don't much use 
> > > apt-get, have switched to the apt command since upgrading to stretch).
> > 
> > Apt is just a friendlier front-end for apt-get: the command
> > outputs are not compatible (and you'll see a warning to that
> > effect in apt, aimed at those who want to use apt's output
> > in scripts), and aptitude has, AFAIK, some *extra* databases
> > to record user intention, and a different dependency resolver,
> > but the basic data sets (which packages are available, what
> > state each is in, etc.) are common.
> 
> See above. The only person who mentioned apt was me, and even then only 
> in the context of that's what I use nowadays. The OP never mentioned apt.
> 
> In any case, those "extra databases" are probably a pretty good reason 
> not to mix and match front-ends in quite the way the OP was doing, even 
> if it doesn't immediately lead straight to trouble trying to get one's 
> system updated properly in the way I suggested it might.

I assume you're talking about aptitude's files in /var/lib/aptitude/.
I don't see any version information there, so what do you expect their
effect to be on updating/upgrading?

> > > If you want to use aptitude upgrade, or dist-upgrade, or safe-upgrade, 
> > > or whatever the command is (embarrassingly I have forgotten, I used 
> > > aptitude for years _before_ upgrading to stretch) you need to first do 
> > > aptitude update.
> > > 
> > > apt-get update followed by aptitude upgrade will lead to pain.
> > 
> > I don't think so: but I'm ready to be proven wrong!
> > 
> 
> Certainly I have no proof except my experience

Correct me if I'm wrong but I don't think you've shared any.

> and my (patchy) memory 
> that I have seen discussion of this point on this list before.
> 
> Anyway the actual issue in this case turned out to be nothing to do with 
> mixing and matching front-ends to dpkg. Glad the OP got his problem 
> figured out.

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#194542

FromCurt <curty@free.fr>
Date2018-04-06 11:00 +0200
Message-ID<vBvnX-jh-1@gated-at.bofh.it>
In reply to#194537
On 2018-04-06, David Wright <deblis@lionunicorn.co.uk> wrote:
>> 
>> Certainly I have no proof except my experience
>
> Correct me if I'm wrong but I don't think you've shared any.

I've found something ambivalently concrete.

 Note
 Since apt / apt-get and aptitude share auto-installed package status
 (see Section 2.5.5, “The package state for APT”) after lenny, you can
 mix these tools without major troubles (see Bug #594490).

https://www.debian.org/doc/manuals/debian-reference/ch02.en.html#_basic_package_management_operations

Not *that* reassuring. Who wants *minor* troubles, anyway? I look at them
binarily; you can't be a little bit pregnant.

>> and my (patchy) memory 
>> that I have seen discussion of this point on this list before.
>> 
>> Anyway the actual issue in this case turned out to be nothing to do with 
>> mixing and matching front-ends to dpkg. Glad the OP got his problem 
>> figured out.
>
> Cheers,
> David.
>
>


-- 
The time-state of attainment eliminates so accurately the time-state of
aspiration, that the actual seems the inevitable, and, all conscious
intellectual effort to reconstitute the invisible and unthinkable as a reality
being fruitless, we are incapable of appreciating our joy by comparing it with
our sorrow.  --Samuel Beckett

[toc] | [prev] | [next] | [standalone]


#194575

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2018-04-07 17:20 +0200
Message-ID<vBXNf-3Ld-1@gated-at.bofh.it>
In reply to#194542
On Fri 06 Apr 2018 at 08:54:56 (+0000), Curt wrote:
> On 2018-04-06, David Wright <deblis@lionunicorn.co.uk> wrote:
> >> 
> >> Certainly I have no proof except my experience
> >
> > Correct me if I'm wrong but I don't think you've shared any.
> 
> I've found something ambivalently concrete.
> 
>  Note
>  Since apt / apt-get and aptitude share auto-installed package status
>  (see Section 2.5.5, “The package state for APT”) after lenny, you can
>  mix these tools without major troubles (see Bug #594490).
> 
> https://www.debian.org/doc/manuals/debian-reference/ch02.en.html#_basic_package_management_operations
> 
> Not *that* reassuring. Who wants *minor* troubles, anyway? I look at them
> binarily; you can't be a little bit pregnant.

And what symptoms of mixing and matching are shown here (in view of
the continuing lack of recounted experiences)?

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#194229

From"John Crawley (johnraff)" <john@bunsenlabs.org>
Date2018-03-28 03:10 +0200
Message-ID<vy7Lc-4nN-9@gated-at.bofh.it>
In reply to#194223
On 2018-03-28 02:50, Jean-Baptiste Thomas wrote:
> After apt-get update, attempting to install ntp tries to
> download version 1:4.2.8p10+dfsg-3+deb9u1 and fails. It tries
> to download +deb9u1 because
> 
>    $ aptitude show ntp
>    Package: ntp
>    Version: 1:4.2.8p10+dfsg-3+deb9u1
>    State: not installed
>    [...]
> 
> and it fails because the version of the package in the Debian 9
> mirror listed in /etc/apt/sources.list is +deb9u2 :
> 
> How is this possible ? I'm confused.

Try running:
sudo apt-get update # one more time, to be sure
# then
apt-cache policy ntp

and see what version it refers to.

-- 
John

[toc] | [prev] | [next] | [standalone]


#194240 — Re: apt{-cache,-get,itude} show wrong version of package after update

FromJean-Baptiste Thomas <cau2jeaf1honoq@laposte.net>
Date2018-03-28 21:10 +0200
SubjectRe: apt{-cache,-get,itude} show wrong version of package after update
Message-ID<vyoCl-715-1@gated-at.bofh.it>
In reply to#194229
> Try running:
> sudo apt-get update # one more time, to be sure
> # then
> apt-cache policy ntp
>
> and see what version it refers to.

Thanks for the suggestions folks but there's not much to see
there, no packages are pinned.

I've made some progress, though. A closer look at the output
reveals that "Packages" is "Ign:", which is apparently [1]
apt-get's way of saying "I was unable to download it but that's
not a problem".

  # apt-get update
  Ign:1 http://mymirror/debian stretch InRelease
  [...]
  Get:3 http://mymirror/debian stretch Release [118 kB]
  Get:4 http://mymirror/debian stretch Release.gpg [2434 B]
  Ign:5 http://mymirror/debian stretch/main amd64 Packages
  [...]

strace tells me that apt-get uses the cached version in
/var/lib/apt/lists/, which may be why it thinks that not being
able to download it is not a problem.

Unfortunately, the Packages file in /var/lib/apt/lists/ is out
of date by months because it pertains to 9.2 while the mirror
has 9.4. Diffing the two shows why apt-get looks for the wrong
version of ntp :

 Package: ntp
-Version: 1:4.2.8p10+dfsg-3+deb9u1
+Version: 1:4.2.8p10+dfsg-3+deb9u2
 Installed-Size: 1804

What I'd like to know now is : what prevents apt-get from
downloading the Packages file from the mirror ? Wget can !

[1] https://superuser.com/questions/454867/

[toc] | [prev] | [next] | [standalone]


#194245

Fromsongbird <songbird@anthive.com>
Date2018-03-29 01:00 +0200
Message-ID<vyscV-Og-3@gated-at.bofh.it>
In reply to#194240
Jean-Baptiste Thomas wrote:
> /var/lib/apt/lists/, which may be why it thinks that not being
> able to download it is not a problem.
>
> Unfortunately, the Packages file in /var/lib/apt/lists/ is out
> of date by months because it pertains to 9.2 while the mirror
> has 9.4. Diffing the two shows why apt-get looks for the wrong
> version of ntp :
>
>  Package: ntp
> -Version: 1:4.2.8p10+dfsg-3+deb9u1
> +Version: 1:4.2.8p10+dfsg-3+deb9u2
>  Installed-Size: 1804
>
> What I'd like to know now is : what prevents apt-get from
> downloading the Packages file from the mirror ? Wget can !
>
> [1] https://superuser.com/questions/454867/

  since you seem to be skipping versions a bit i'd
try:

  apt-get dist-upgrade

  or similar command using your preferred tool.

  may help or give more information...

  if you are using a certain repository and are
still seeing errors after that it may be worth
specifying a different one or the more general
default.

  usually when i do this i erase all my local
apt files in /var/lib/apt/lists) so they will be
redownloaded.


  songbird

[toc] | [prev] | [next] | [standalone]


#194247

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2018-03-29 01:10 +0200
Message-ID<vysmB-16L-3@gated-at.bofh.it>
In reply to#194240
On Wed 28 Mar 2018 at 21:07:35 (+0200), Jean-Baptiste Thomas wrote:
> > Try running:
> > sudo apt-get update # one more time, to be sure
> > # then
> > apt-cache policy ntp
> >
> > and see what version it refers to.
> 
> Thanks for the suggestions folks but there's not much to see
> there, no packages are pinned.
> 
> I've made some progress, though. A closer look at the output
> reveals that "Packages" is "Ign:", which is apparently [1]
> apt-get's way of saying "I was unable to download it but that's
> not a problem".
> 
>   # apt-get update
>   Ign:1 http://mymirror/debian stretch InRelease
>   [...]
>   Get:3 http://mymirror/debian stretch Release [118 kB]
>   Get:4 http://mymirror/debian stretch Release.gpg [2434 B]
>   Ign:5 http://mymirror/debian stretch/main amd64 Packages
>   [...]
> 
> strace tells me that apt-get uses the cached version in
> /var/lib/apt/lists/, which may be why it thinks that not being
> able to download it is not a problem.
> 
> Unfortunately, the Packages file in /var/lib/apt/lists/ is out
> of date by months because it pertains to 9.2 while the mirror
> has 9.4. Diffing the two shows why apt-get looks for the wrong
> version of ntp :
> 
>  Package: ntp
> -Version: 1:4.2.8p10+dfsg-3+deb9u1
> +Version: 1:4.2.8p10+dfsg-3+deb9u2
>  Installed-Size: 1804
> 
> What I'd like to know now is : what prevents apt-get from
> downloading the Packages file from the mirror ? Wget can !
> 
> [1] https://superuser.com/questions/454867/

Move all the files out of /var/lib/apt/lists/ so that apt-get update
has to download fresh copies. That should get you back on track.

By all means take the opportunity to compare the old and the new files
to look for causes. In the simplest scenario, which probably is not
the cause but might illustrate the kind of problem, a failed download
could leave a file with a timestamp at the point of failure. That
erroneous timestamp would be more recent than the mirror's (correct)
timestamp and could cause update to think there's nothing to do on
subsequent runs until the original file on the mirror was modified.

Cheers,
David.

[toc] | [prev] | [next] | [standalone]


#194389 — Re: apt{-cache,-get,itude} show wrong version of package after update

FromJean-Baptiste Thomas <cau2jeaf1honoq@laposte.net>
Date2018-04-02 11:00 +0200
SubjectRe: apt{-cache,-get,itude} show wrong version of package after update
Message-ID<vA3tL-7su-13@gated-at.bofh.it>
In reply to#194247
>> What I'd like to know now is : what prevents apt-get from
>> downloading the Packages file from the mirror ? Wget can !
>
> Move all the files out of /var/lib/apt/lists/ so that apt-get update
> has to download fresh copies. That should get you back on track.
> 
> By all means take the opportunity to compare the old and the new files
> to look for causes. In the simplest scenario, which probably is not
> the cause but might illustrate the kind of problem, a failed download
> could leave a file with a timestamp at the point of failure. That
> erroneous timestamp would be more recent than the mirror's (correct)
> timestamp and could cause update to think there's nothing to do on
> subsequent runs until the original file on the mirror was modified.

The problem is not that apt-get sees the new Packages file and
decides that it does not need to be downloaded. If that were the
case, the output would be

  Hit http://mymirror/debian stretch/main amd64 Packages

The actual output is

  Ign:5 http://mymirror/debian stretch/main amd64 Packages

which indicates that it tried to download it but failed. At
least if the link I gave previously is correct (and it appears
to be).

The reason why it failed is that it looked for Packages.xz which
did not exist on my mirror. The reason why my mirror did not
have a Packages.xz file is that it was made with the version of
debmirror in Debian 8, which only concerns itself with
Packages.gz and Packages.bz2.

Those files *were* there and apt-get could have used them but,
in its wisdom, it didn't even try.

I solved the problem by installing the latest version of
debmirror on the Debian 8 machine where the mirror is.
Thankfully, there were no dependency problems.

There is probably material for a few bug reports in there.

Thank you.

[toc] | [prev] | [next] | [standalone]


#194403

FromDavid Wright <deblis@lionunicorn.co.uk>
Date2018-04-02 17:50 +0200
Message-ID<vA9Sy-3fF-15@gated-at.bofh.it>
In reply to#194389
On Mon 02 Apr 2018 at 10:53:07 (+0200), Jean-Baptiste Thomas wrote:

> The reason why it failed is that it looked for Packages.xz which
> did not exist on my mirror. The reason why my mirror did not
> have a Packages.xz file is that it was made with the version of
> debmirror in Debian 8, which only concerns itself with
> Packages.gz and Packages.bz2.
> 
> Those files *were* there and apt-get could have used them but,
> in its wisdom, it didn't even try.
> 
> I solved the problem by installing the latest version of
> debmirror on the Debian 8 machine where the mirror is.
> Thankfully, there were no dependency problems.
> 
> There is probably material for a few bug reports in there.

I've run into similar problems with running apt-cacher-ng on a wheezy
machine that's serving jessie and stretch ones. Backports and Sloppy
Backports have come to the rescue with the exception of handling the
bug reports, so I run as far as   apt-get -d upgrade   with the proxy,
but go direct for the actual installation (by which time the .deb file
is in the local /var/cache/apt/archives/).

Cheers,
David.

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.user


csiph-web