[Gllug] Broken RPM Database
Daniel P. Berrange
dan at berrange.com
Sun Jan 15 12:09:14 UTC 2006
On Sun, Jan 15, 2006 at 11:30:45AM +0000, Lee, Paul wrote:
> Hi
> Has anyone on the list successfully rebuilt their RPM database? I don't
> mean rpm --rebuilddb. I've tried that and that was only partially
> successful. This partly rebuilt a list of 71 packages (when the real
> number will be over 300). rpm -Va reveals a list of failed dependencies.
>
> I had just carried out an update of my Centos 3.6 using yum when I
> discovered rpm was broken with `error: db4 error(-30989) from
> dbcursor->c_get: DB_PAGE_NOTFOUND: Requested page not found` - I think
> it might be this bug..
If you're lucky then you'll be able to recover this corruption by following
the dump/load procedure I outline here:
http://people.redhat.com/berrange/notes/rpmrecovery.html
> I can think there are ways of manually recreating or initialising the
> database again but I'm wondering if it might be just best to start from
> scratch. The system works fine - it obviously can't be updated via RPM
> at them moment!
If the DB is totally trashed, then look at the various /var/log/rpmpkgs
Hopefully one of the backups will have the complete list of RPMs. At
which point you can re-populate the RPM db by re-installing each RPM
using the --justdb flag to tell it only to updat the database.
Then again a re-install might be simpler
> I've never really `lost` an RPM database before, --rebuilddb usually
> doing its thing, but searching the Centos forums this would appear to be
> a very rare event. It's strange that rebuilddb is only partially
> rebuilding the list.
The --rebuilddb flag is incredibly badly named - it basically does
nothing of the sort. It merely re-creates various de-normalizations
and indexes.
Dan.
--
|=- GPG key: http://www.berrange.com/~dan/gpgkey.txt -=|
|=- Perl modules: http://search.cpan.org/~danberr/ -=|
|=- Projects: http://freshmeat.net/~danielpb/ -=|
|=- berrange at redhat.com - Daniel Berrange - dan at berrange.com -=|
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 196 bytes
Desc: Digital signature
URL: <http://mailman.lug.org.uk/pipermail/gllug/attachments/20060115/b7d27732/attachment.pgp>
-------------- next part --------------
--
Gllug mailing list - Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug
More information about the GLLUG
mailing list