error: rpmdb: BDB0113 Thread/process 27728/140114045668224 failed: BDB1507 Thread died in Berkeley DB libraryerror: db5 error(-30973) from dbenv->failchk: BDB0087 DB_RUNRECOVERY: Fatal error, run database recoveryerror: cannot open Packages index using db5 – (-30973)error: cannot open Packages database in /var/lib/rpmError: Error: rpmdb open failed

Got the below berkley error when installing a package from yum

[root@dgprim01 oracle]# yum install oracleasmlib
error: rpmdb: BDB0113 Thread/process 27728/140114045668224 failed: BDB1507 Thread died in Berkeley DB library
error: db5 error(-30973) from dbenv->failchk: BDB0087 DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db5 -  (-30973)
error: cannot open Packages database in /var/lib/rpm
Error: Error: rpmdb open failed

Followed these steps and worked perfect!

[root@dgprim01 oracle]# mkdir /var/lib/rpm/backup

[root@dgprim01 oracle]# cp -a /var/lib/rpm/__db* /var/lib/rpm/backup/
[root@dgprim01 oracle]# rm -f /var/lib/rpm/__db.[0-9][0-9]*
[root@dgprim01 oracle]# rpm --quiet -qa
[root@dgprim01 oracle]# rpm --rebuilddb
error: could not delete old database at /var/lib/rpmold.28200
[root@dgprim01 oracle]# yum clean all
24 files removed
[root@dgprim01 oracle]# yum install oracleasmlib oracleasm-support -y
Oracle Linux 8 BaseOS Lates  1% [                           ] 128 kB/s | 547 kB     05:07 ETA

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s