Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 Oct 2013 20:41:36 +0100
From:      Matthew Seaman <matthew@FreeBSD.org>
To:        freebsd-ports@freebsd.org
Subject:   Re: pkg: sqlite: database disk image is malformed (pkgdb.c:1274)
Message-ID:  <525AF770.4090307@FreeBSD.org>
In-Reply-To: <201310131924.r9DJO0GA005315@mech-cluster241.men.bris.ac.uk>
References:  <201310131924.r9DJO0GA005315@mech-cluster241.men.bris.ac.uk>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--95iXTQ28rxqEWClKj7HwnDNEHBAb0F2bC
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On 13/10/2013 20:24, Anton Shterenlikht wrote:
> My box crashed during "pkg upgrade".
> On reboot I get:
>=20
> # pkg update
> Updating repository catalogue
> pkg: sqlite: database disk image is malformed (pkgdb.c:1274)
> #
>=20
> What's broken?
> And how can I recover?

Not sure exactly what's broken, but you can usually recover by:

rm /var/db/pkg/repo-*.sqlite

and then use pkg as normal.  It's safe to delete the repo sqlite files
as all the information in them comes from the repository catalogues and
can be regenerated from source as desired.

Failing that, there should be a nightly backup in
/var/backups/pkgdb.bak.tbz but that can be up to a day old, so be
prepared to redo any package updates from the day in order to resynch it
with what's on the filesystem.

	Cheers,

	Matthew



--=20
Dr Matthew J Seaman MA, D.Phil.
PGP: http://www.infracaninophile.co.uk/pgpkey



--95iXTQ28rxqEWClKj7HwnDNEHBAb0F2bC
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/

iQJ8BAEBCgBmBQJSWvd4XxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NTNBNjhCOTEzQTRFNkNGM0UxRTEzMjZC
QjIzQUY1MThFMUE0MDEzAAoJELsjr1GOGkATdYEQAKdmkEsnC8X7zGifJjCK7tYW
3und5QFJHOvYeqH6U+5Ja/Ry3kLk+U5/7cF6CY7wuVeJdHQFjLdrQ8IfDVGkQAOx
9FUGbg6PRcDg165Nadjj00ytuo4X46hugiDiMvP4+Y1FCGZKEK4pUwmBkt9B4k6o
Hxbky6UKjF4neU5tvpb6QDYf0qD63DyvZCk8T9GxIFrDpD8z9fu4S8er0WFOg//A
nHIB1phDszeJ/thhc0TbbUkyuR0cQzrOEk7eu9/1kvXBMrtrJxjRBGwKMd4xR7Hz
j/zrnIKZ1bDwxWi7B8cDWD37G8wREMytDE8y2xBQ8UydyEuZr2YIgOZhDzf9cFen
nNDdznknGmmugsVTg5dLzslzxNfRDfd7tjC68DzE48K6TfT5vgo9fwR09D18rXm9
kQhPjcLYO6MBN+pe6o8nIInFDTOlfmPwc6s+R/5/kPVSTBmJrZMcZXNNyIjoa9JI
RYQrrpa4QCkfcrentmu9Is8De/6FP0YzSUB/yZyXMcg+/B31YKiJDyn6RcdPzKEF
Ay+5/JQt22X48rFiPI2acUUR/IYtAl0HQcp1O5Ui3nnM88py5cZSXeu4dqIj5nyx
z29R/gK+AR42eR08cYX04D+VYiXPp+4BpJBqg+JHP7xObnBG9/izqiPoTjIdVbH+
+tG4ylnaUplLZupOQF1p
=IbgL
-----END PGP SIGNATURE-----

--95iXTQ28rxqEWClKj7HwnDNEHBAb0F2bC--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?525AF770.4090307>