Bug 803866 - rpm update breaks rpm
Summary: rpm update breaks rpm
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Fedora
Classification: Fedora
Component: rpm
Version: 16
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-03-15 19:15 UTC by Steven Dake
Modified: 2016-04-26 22:48 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-05-08 11:48:28 UTC
Type: ---


Attachments (Terms of Use)
yum update log (68.83 KB, text/x-log)
2012-03-15 19:25 UTC, Steven Dake
no flags Details

Description Steven Dake 2012-03-15 19:15:46 UTC
Description of problem:
ran yum update, now have following error:
[root@beast log]# rpm -qa
error: rpmdb: Thread/process 19010/140712016480000 failed: Thread died in Berkeley DB library
error: db4 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db4 -  (-30974)
error: cannot open Packages database in /var/lib/rpm
error: rpmdb: Thread/process 19010/140712016480000 failed: Thread died in Berkeley DB library
error: db4 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages database in /var/lib/rpm

rpm cannot rebuild the database:
[root@beast log]# rpm --rebuilddb
error: rpmdb: Thread/process 19010/140712016480000 failed: Thread died in Berkeley DB library
error: db4 error(-30974) from dbenv->failchk: DB_RUNRECOVERY: Fatal error, run database recovery
error: cannot open Packages index using db4 -  (-30974)


Version-Release number of selected component (if applicable):
Mar 15 08:54:46 Updated: rpm-4.9.1.2-6.fc16.x86_64


How reproducible:
not sure - rpm unusable and can't downgrade

Steps to Reproduce:
1. yum update (to install the new rpm packages)
2.
3.
  
Actual results:
system is broke

Expected results:
system isn't broke

Additional info:

Comment 1 Steven Dake 2012-03-15 19:25:13 UTC
Created attachment 570418 [details]
yum update log

Comment 2 Steven Dake 2012-03-15 19:32:30 UTC
rebooting seems to fix the problem....

Comment 3 Panu Matilainen 2012-03-16 05:09:44 UTC
The "Thread died in Berkeley DB library" error means that rpm was *previously* either crashed or was forcefully kill while it was doing database operations. Logs should give a clue if it was a crash, other than that there's no way of knowing after the fact.

To clear that condition, 'rm -f /var/lib/rpm/__db.*' is normally sufficient, and a reboot will do that as a side-effect of sorts.

As for what caused it, like said there's no telling after the fact unless logs indicate a crash. Over time there have been all sorts of external causes to this: once upon time it was PackageKit killing its query backend with kill -9, another truly bizarre one involving NetworkManager invoking gdb upon crash and then gdb getting killed while accessing the rpmdb...

This is unlikely to have to do with the rpm update itself, but whether it is just an isolated incidence or whether there's a new rpm killer on the loose remains to be seen. If you want to catch future cases of this occurring, see bug 672932 from comment 16 onwards on how to enable tracking it via audit.

Comment 4 Panu Matilainen 2012-05-08 11:48:28 UTC
Since it appears to have been an isolated incident - most likely *something* forcibly killed rpm/yum but there's no telling after the fact if its not reproducable. Actual crashes should be visible in abrt and/or logs.


Note You need to log in before you can comment on or make changes to this bug.