Description of problem: Hello, On some of my machines, when I try to manually do an "yum -y --obsoletes upgrade", I get this: [root@newton ~]# yum -y --obsoletes upgrade Loading "allowdowngrade" plugin Loading "fastestmirror" plugin Loading "installonlyn" plugin rpmdb: Lock table is out of available locker entries rpmdb: Unknown locker ID: 847 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 Traceback (most recent call last): File "/usr/bin/yum", line 29, in <module> yummain.main(sys.argv[1:]) File "/usr/share/yum-cli/yummain.py", line 82, in main base.getOptionsConfig(args) File "/usr/share/yum-cli/cli.py", line 146, in getOptionsConfig errorlevel=opts.errorlevel) File "/usr/lib/python2.5/site-packages/yum/__init__.py", line 153, in _getConfig self._conf = config.readMainConfig(startupconf) File "/usr/lib/python2.5/site-packages/yum/config.py", line 601, in readMainConfig yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg) File "/usr/lib/python2.5/site-packages/yum/config.py", line 664, in _getsysver idx = ts.dbMatch('provides', distroverpkg) TypeError: rpmdb open failed and also: rpm -qa rpmdb: Lock table is out of available locker entries rpmdb: Unknown locker ID: 849 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 Seems to be database-related - could you please check? Regards, Răzvan Version-Release number of selected component (if applicable): Can't verify, since the database is inaccesible. ;-) However, there are no custom packages - from official Fedora 7 only. How reproducible: On some F7 boxes. Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
The first thing to try is rm -f /var/lib/rpm/__db* Does that "fix"? NEEDINFO
Hello, Yes, it does, at least for the moment. I also noticed that completely rebooting the box also "fixes" the issue, but only for some time - the phenomenon occurs again after a while. Regards, Răzvan
The only particular thing about these machines is that they were upgraded from FC6 +updates to F7 via yum and not via regular install. However, from around 20 machines on which I've did that, only on two this issue is present. Regards, Răzvan
During reboot, there is a rm -f /var/lib/rpm/__db* so reboot is just a complicated way to do what can easily be done manually. Yes, one should not have to remove the stale locks at all. FYI: rpm-4.4.8 and later has automated stale lock removal for you. See http://rpm5.org if you are interested in the fix. UPSTREAM
*** This bug has been marked as a duplicate of 245389 ***