From owner-freebsd-questions@FreeBSD.ORG Sun Dec 21 13:15:41 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 93BC488C for ; Sun, 21 Dec 2014 13:15:41 +0000 (UTC) Received: from mail-qc0-f169.google.com (mail-qc0-f169.google.com [209.85.216.169]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4E96F3FBD for ; Sun, 21 Dec 2014 13:15:40 +0000 (UTC) Received: by mail-qc0-f169.google.com with SMTP id w7so2469767qcr.28 for ; Sun, 21 Dec 2014 05:15:34 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=RSPVki6gE5IsZGrt1Jpf2sFIgk9D0SCJTFXUSTiernY=; b=iHkZT6hTu84jh0i6fvHVNqGu5Z9CFruk9QGfCrE0K/7MaW5O1rgNFEaKw9PN3PZoug qGX02y3lc9cq7u1KQP1CBlD7wCAHEuBOJEUURyvNMe2tqATA3Xwuw8h/nYO5wuDbQKD3 SO89ly7V2AN8tfsKDuI7O/oUlVkrzvWPFFvaB0+hDaOOkck7JdGKIsvRqc2u8Dw+cH8R /Vk7YJPOSJGEWppJ4AdTsBTsr4Jqoi1s3OeWg6PtN2OjeeujNbU2F0K0r1po+6wJ1TiB vYcHrL+nT87MPlKa3CQfFyEnP8RlvWWDmBXZEO0FqccU8ItbYGLf9EbqRl8XNUdRrOJP RGaQ== X-Gm-Message-State: ALoCoQmgtE+hKp13E1Y2COb+Be4Yn5cpjEykTHN3f4lzhG0z16R7Osx0zOda/mSZJEdd1OE3lC3k MIME-Version: 1.0 X-Received: by 10.140.102.13 with SMTP id v13mr27209235qge.68.1419167734299; Sun, 21 Dec 2014 05:15:34 -0800 (PST) Received: by 10.140.19.17 with HTTP; Sun, 21 Dec 2014 05:15:34 -0800 (PST) In-Reply-To: <5496A595.8090702@FreeBSD.org> References: <54941E41.3040807@hiwaay.net> <5496A595.8090702@FreeBSD.org> Date: Sun, 21 Dec 2014 08:15:34 -0500 Message-ID: Subject: Re: pkg versions don't match From: Alejandro Imass To: Matthew Seaman Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.18-1 Cc: FreeBSD Questions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Dec 2014 13:15:41 -0000 Thanks for the thorough explanation! On Sun, Dec 21, 2014 at 5:48 AM, Matthew Seaman wrote: > On 21/12/2014 02:25, Alejandro Imass wrote: > > Yeah but something doesn't seem quite right here. The option -f "force" > to > > check origin versions seems a bit obscure. If -f is needed for update to > > > [...] > When pkg(8) updates the repo, it does a series of things. Firstly it > downloads a copy of the repo catalogue -- that's a compressed file of > JSON data with selected bits of package metadata for all of the packages > in the repo. In order to avoid this resulting in a lot of unnecessary > work, pkg(8) basically checks to ensure that the timestamp on the > repository catalogue is unchanged using the standard HTTP 304 'Not > modified' status code mechanism. If it finds the catalogue hasn't > changed since the last time it downloaded it, then it stops there. > > This doesn't seem to be working very well or else why did my pkg keep saying it was up to date and yet the packages in remote had clearly changed ? [...] There is one circumstance when this is not true however: when pkg(8) > itself is updated, the schema of the sqlite database may change. The > format of the catalogue may similarly change, but it is carefully done > to remain backwards compatible with both older and newer versions of > pkg(8). Changes to the catalogue format and to the sqlite schemas are > mostly handled completely transparently to the user, but occasionally, > as in this case, forcing the update is required to populate the > new-style repo catalogue. > pkg did not get updated until after I forced pkg update so something else did not work very well at least in my case (timezone issues?). In any case the update process you describe with the metadata did not work. Best, -- Alejandro Imass