How do I verify the integrity of the rpm database Packages file in Red Hat Enterprise Linux?

Updated -

Run the following commands:

# cd /var/lib/rpm
# /usr/lib/rpm/rpmdb_verify Packages

Alternatively try reading from the Packages file and writing a new file with the following command:

# /usr/lib/rpm/rpmdb_dump Packages |/usr/lib/rpm/rpmdb_load Packages.test

If the verify fails and the dump succeeds, this could be used to...

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.