If yum command throws some errors and rpm says “rpmdb: Lock table is out of available locker entries”, you can apply this action plan.
Why does this happen?
While rpm access the database files, it makes a temporary locker entry with tables while it searches data. If you send a break command this problem can occur because the locker never cleared.
Error:
rpmdb: Lock table is out of available locker entries
rpmdb: Unknown locker ID: 16a99
error: db4 error(22) from db->close: Invalid argument
error: cannot open Packages index using db3 – Cannot allocate memory (12)
error: cannot open Packages database in /var/lib/rpm
Unable to connect to Subscription Management Service
rpmdb: Lock table is out of available locker entries
Solution:
Step 1:Take backup of /var/lib/rpm .
#tar cvzf rpmdb-backup.tar.gz /var/lib/rpm
Step 2: Remove db file under this directory and rebuild RPM database
#rm /var/lib/rpm/__db.00*
Step 3:Rebuild Db files.
#rpm –rebuilddb