From owner-freebsd-questions@FreeBSD.ORG Fri Apr 18 19:02:21 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 2E8602E8 for ; Fri, 18 Apr 2014 19:02:21 +0000 (UTC) Received: from smtp.infracaninophile.co.uk (smtp6.infracaninophile.co.uk [IPv6:2001:8b0:151:1:3cd3:cd67:fafa:3d78]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.infracaninophile.co.uk", Issuer "ca.infracaninophile.co.uk" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id C96901393 for ; Fri, 18 Apr 2014 19:02:20 +0000 (UTC) Received: from seedling.black-earth.co.uk (seedling.black-earth.co.uk [81.2.117.99]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.14.8/8.14.8) with ESMTP id s3IJ1w9d006760 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Fri, 18 Apr 2014 20:02:02 +0100 (BST) (envelope-from m.seaman@infracaninophile.co.uk) DKIM-Filter: OpenDKIM Filter v2.8.3 smtp.infracaninophile.co.uk s3IJ1w9d006760 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infracaninophile.co.uk; s=201001-infracaninophile; t=1397847723; bh=ozzjBSKIzHSBZsvr23zGaO6v/7vuQ8v8yDj4T77XUR0=; h=Date:From:To:Subject:References:In-Reply-To; z=Date:=20Fri,=2018=20Apr=202014=2020:01:47=20+0100|From:=20Matthew =20Seaman=20|To:=20"lokadamus@gmx .de"=20,=20freebsd-questions@freebsd.org|Subject :=20Re:=20pkg=20don't=20recognize=20installed=20packages|Reference s:=20<53514A68.806@gmx.de>=20<535153CC.5050000@infracaninophile.co .uk>=20<53515A87.8010307@gmx.de>|In-Reply-To:=20<53515A87.8010307@ gmx.de>; b=R3KxXFR+mN8hoDFsJA6shk97wFaaHd7duMkahO0SaCgCDJPnBpSUZLQGrci1i3GrV gxuQSeK9eqRzqKIV2FQorWFoAtD6lwA7jad5n+LDKISgIH7c3tlxOcsuEAIVisbgTT YAzsPPk1+4QXdndkkAlREDbXFSZXrIpdCN84twNU= Message-ID: <5351769B.6080209@infracaninophile.co.uk> Date: Fri, 18 Apr 2014 20:01:47 +0100 From: Matthew Seaman User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: "lokadamus@gmx.de" , freebsd-questions@freebsd.org Subject: Re: pkg don't recognize installed packages References: <53514A68.806@gmx.de> <535153CC.5050000@infracaninophile.co.uk> <53515A87.8010307@gmx.de> In-Reply-To: <53515A87.8010307@gmx.de> X-Enigmail-Version: 1.6 OpenPGP: id=E7F39EBF Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Jnccoolgw1VfPFFApWMSp4mxkJkxNL4XP" X-Virus-Scanned: clamav-milter 0.98.1 at lucid-nonsense.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-3.0 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lucid-nonsense.infracaninophile.co.uk X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 Apr 2014 19:02:21 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --Jnccoolgw1VfPFFApWMSp4mxkJkxNL4XP Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 18/04/2014 18:01, lokadamus@gmx.de wrote: > System is 10.0-RELEASE-p1 (clean install in january) and last week all > was working fine. > In december i had trouble with /var/db/pkg/local.sqlite and had to > remove it for a new one. > This time this way isn't working. It creates a new local.sqlite, but > dosn't recognize > installed programs. Right. This is obviously relevant information you might have considered including in your original posting. > Is there a command that pkg will reread all installed ports? > Or can portmaster do this? local.sqlite is *the* database of installed packages. If you destroy it, there's nowhere else pkg(8) can get the information about what packages are already installed. That's why there are periodic jobs to take a backup each night, which you might find in /var/backups. Hopefully it hasn't been so long that there is still useful data preserved there. Failing that, you will need to reinstall all your packages to repopulate your package database. Today's lesson is this: deleting the package database is not a good idea. Two seconds to do, hours if not days to recover and forever afterwards to regret. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. PGP: http://www.infracaninophile.co.uk/pgpkey JID: matthew@infracaninophile.co.uk --Jnccoolgw1VfPFFApWMSp4mxkJkxNL4XP Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.20 (Darwin) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQJ8BAEBCgBmBQJTUXamXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NTNBNjhCOTEzQTRFNkNGM0UxRTEzMjZC QjIzQUY1MThFMUE0MDEzAAoJELsjr1GOGkATo7wP/jBcFi1b4vwM3LTf26coZetO n8YXWIDK+CVsNzKVbahaCQ1hXUiuSwMaSwST9JCOSAKBfQGr5Etcus08wlGgEKiT l6bzbGPL0AqXNe+3sEWjRiw9HsPypcKGSzZ5KTQZOm/NhdQKAPJDdZN9bn1hdUFK W2XP8LzgDwZcIWS/J9ueYfq8vvl6ImQ2OKVobnDM5Ad5Brdym6v+jrb8Dv35D102 ppw1QtZr1HTehA93lMbtUTQpvZB6MtdjfYlXRvv9DVwbU/zI8yA5uEqmnEkSkGpj 7nOkhW39+9yc996+jz6yC5sjy4uuLDW78I6SrIj36FekQgzXj1Se+vM+YFvlNHvx 9esDbhfh8Nl8uhxLoFOLcQk9FzIxEYjVRdQz50vCRSoYj0g0s/V5ZBFL0bYMNrK0 gaprLtli9feO8COgKKSRNRvlnc/IwHOKqVA7z7V+1mOUpnkaUnf5gFg10sLeRsEs ddt8oeOsb9RkTAWMXU0M+WanaWmHa5l5/MVJ/X0ksmvLYQEnEjiFqOfDu+zHZg8o ncf/ARm9qdtLABYgHe3SjQOisTnUmgqxtOGuKZuBHjXqjEGkJneXJFdfyQ7MJTEP mX4nboUeEwFI+/bn1DZ9kDigiMf2XSqibtgYrG4woW+0aesNZ3+b1LgnjSs0DD3G 6S6p0Mo8NFkXhlr8hYGB =IPTp -----END PGP SIGNATURE----- --Jnccoolgw1VfPFFApWMSp4mxkJkxNL4XP--