Date: Sat, 30 Mar 2013 08:38:11 +0000 From: Matthew Seaman <matthew@FreeBSD.org> To: freebsd-questions@freebsd.org Subject: Re: Ah crap! pkg_version: the package info for package '...' is corrupt Message-ID: <5156A473.4030501@FreeBSD.org> In-Reply-To: <10944.1364631449@server1.tristatelogic.com> References: <10944.1364631449@server1.tristatelogic.com>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2OOQAASWDJRKSNFOVRREN Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 30/03/2013 08:17, Ronald F. Guilmette wrote: >=20 >=20 > Today my system crashed twice while I was doing "portupgrade -a". >=20 > I'm not sure but I suspect the new cards I have installed recently may > just be a bit too much for the old power supply I have. (When the thin= g > crashed, the machine just simply shut itself off. This exact same thin= g > has also happened a couple of other times in the past week.) >=20 > I'll deal with the power issue soon, but right now I am more worried ab= out > this new, different, and additional problem I seem to have created for > myself. When I run pkg_version, I am getting a bunch of messages of > the following general form: >=20 > pkg_version: the package info for package 'PKG' is corrupt >=20 > where `PKG' is the name of some package or another that I have installe= d. >=20 > I have at least 6 such messages for different packages I have installed= =2E.. > and probably more. Are you using pkgng? If so, you'll get the "'PKG' is corrupt" message for everything when you use pkg_version. That's because on a pkgng-ized you should instead be using 'pkg version'. Same command flags, just s/_/ /. > I googled around a bit and did not find any good explanation for the > above error or, more importantly, what to do about it. >=20 > I gather however that my package data base has become corrupted. >=20 > OK, so how does one rebuild that from scratch? >=20 > Please don't tell me that I have to reinstall every bleedin' port from > scratch! >=20 >=20 > Regards, > rfg >=20 >=20 > P.S. Oh! I just remembered. I made a full system backup quite recent= ly... > thank god. Do I just simply need to get the entire contents of /var/db= /pkg/ > from that and then do "rm -fr /var/db/pkg" and then copy my backup copy= > of /var/db/pkg to the real /var/db/pkg ? >=20 > Hummm.. that won't reflect the several things that _did_ managed to get= > updated, you know, before my system crashed. Assuming you *aren't* on a pkgng-ized system: If you have a recent backup of /var/db/pkg then you should restore from there. If you installed or updated any ports between taking the backup and the crash, then reinstalling those ports will fixup the /var/db/pkg entries for them. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. PGP: http://www.infracaninophile.co.uk/pgpkey ------enig2OOQAASWDJRKSNFOVRREN 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.16 (Darwin) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iEYEARECAAYFAlFWpHMACgkQ8Mjk52CukIwwQACggkpX4HoB/2fzg7pOPMRUW4kv LhcAmwUz9KIOCYU+mwr9CjTS5QyB3ABH =q0dg -----END PGP SIGNATURE----- ------enig2OOQAASWDJRKSNFOVRREN--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5156A473.4030501>