-
12th November 2009, 11:18 PM
#1
yum update - Fatal error, run database recovery
I am getting an error from yum update and Kpackagekit:
[root@asus-m4n82 tylerm]# yum update
Loaded plugins: refresh-packagekit
Setting up Update Process
rpmdb: page 18816: illegal page type or format
rpmdb: PANIC: Invalid argument
rpmdb: Packages: pgin failed for page 18816
error: db4 error(-30974) from dbcursor->c_get: DB_RUNRECOVERY: Fatal error, run database recovery
rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30974) from dbcursor->c_close: DB_RUNRECOVERY: Fatal error, run database recovery
No Packages marked for Update
rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30974) from db->close: DB_RUNRECOVERY: Fatal error, run database recovery
rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30974) from db->close: DB_RUNRECOVERY: Fatal error, run database recovery
rpmdb: File handles still open at environment close
rpmdb: Open file handle: /var/lib/rpm/Packages
rpmdb: Open file handle: /var/lib/rpm/Name
rpmdb: PANIC: fatal region error detected; run recovery
error: db4 error(-30974) from dbenv->close: DB_RUNRECOVERY: Fatal error, run database recovery
How do I "run recovery"?
Edit: Ok so it looks like I had som bad ram in my system that caused this - I found a site that told me to do this:
rm -f /var/lib/rpm/__db*
rpm –rebuilddb
yum clean all
I did this but now when I try something like yum install firefox it pulls in a ton of already installed packages. Any body know how to fix that?
-
13th November 2009, 09:40 AM
#2
If this were my system I'd run those commands again and see if anything changes.
-
7th September 2011, 12:39 PM
#3
Re: yum update - Fatal error, run database recovery
Originally Posted by
Thaidog
Edit: Ok so it looks like I had som bad ram in my system that caused this - I found a site that told me to do this:
rm -f /var/lib/rpm/__db*
rpm –rebuilddb
yum clean all
Thanks. That fixed my problem too. I screwed mine up by kill -9ing the process
-
10th November 2015, 02:44 PM
#4
Re: yum update - Fatal error, run database recovery
I am getting the same errors.
---------- Post added at 08:44 AM ---------- Previous post was at 08:42 AM ----------
dnf burped and this is part of my log file.
error: db5 error(-30973) from dbenv->open: 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
-
16th December 2015, 02:39 PM
#5
Re: yum update - Fatal error, run database recovery
I just had another dnf crash with error messages to run dnf database recovery. I found the posting above from Sept 2011
but the message now is "Cannot reconstruct rpm from disk files
Any idea as to what to do now?
-
16th December 2015, 03:59 PM
#6
Re: yum update - Fatal error, run database recovery
Use the -vv verbose option. Is it failing right away or on a specific package header?
You could attempt to remove a package from the db 'rpm --justdb -e <pkg>' to see
if that helps, but if there are several, you may have other issues.
Also, you can try to see if an export will work. Something like 'rpmdb --exportdb > /save/path'.
If that works out okay, then 'rm -rf /var/lib/rpm & rpmdb --initdb & rpmdb --importdb < /save/path'.
Of course, make sure to make a backup of your existing /var/lib/rpm directory before
attempting to do anything.
This would also be a good time to configure regular backups if you haven't already done so.
-
16th December 2015, 06:37 PM
#7
Re: yum update - Fatal error, run database recovery
The issue is that rpm has lost part of the database, the rebuild -vv runs OK now but packages are being skipped. I tried to manually install/reinstall the skipped packages to see if that will reinsert missing database table rows.
I tried installing/reinstalling without success. I will do an export and an import and see what happens next.
Time to add /var/lib/rpm directory to backup prior to running dnf.
Similar Threads
-
By icy-flame in forum Using Fedora
Replies: 6
Last Post: 1st August 2013, 05:53 PM
-
By Omega Blue in forum Using Fedora
Replies: 4
Last Post: 17th November 2006, 08:34 AM
-
By doyler78 in forum Using Fedora
Replies: 3
Last Post: 25th March 2006, 11:22 AM
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
[[template footer(Guest)]]