Sometimes you may get the below error while running “rpm -qa” or any other rpm listing command. This error suggests that the RPM db is corrupted and you need to clean it up.

rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30977) from dbenv->open: DB_RUNRECOVERY

Here are the steps to do it.

  1. Remove the rpm db lock information files

    rm -f /var/lib/rpm/__db*

  2. Run the rpm rebuild database command . The rpm –rebuilddb option will rebuild the database indices from the installed RPM package headers. This process will take a while to complete. Once it is completed, the rpm -qa and other rpm listing commands will work.

    rpm –rebuilddb

0 Shares:
Leave a Reply

Your email address will not be published. Required fields are marked *

You May Also Like
Read More

Netapp : SNMP tips

How to enable SNMP on a netapp filer filer1> options snmp.enable onfiler1> options snmpsnmp.access                  legacy   snmp.enable                  on        filer1>…
Read More

Netapp Snapvault guide

Netapp SnapVault is a heterogeneous disk-to-disk backup solution for Netapp filers and heterogeneous OS systems (Windows, Linux ,…
Read More

Useful AIX tips

Display paging space details # lsps -aPage Space      Physical Volume   Volume Group    Size %Used Active  Auto  Typehd6             hdisk1           …