1. 重建rpmdb
有时候rpm数据库偶尔发生损坏,无法安装新rpm包: rpmdb: Thread/process 21721/140622824318880 failed: Thread died in Berkeley DB library
error: db3 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db3 - (-30974)
error: cannot open Packages database in /var/lib/rpm
rpmdb: Thread/process 21721/140622824318880 failed: Thread died in Berkeley DB library
error: db3 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages database in /var/lib/rpm
这时候只需要重建就好了: mv /var/lib/rpm/__db* /tmp
yum clean all
yum update
rm -i /tmp/__db*
|