<---- template headericclude ----->
yum update - Fatal error, run database recovery
FedoraForum.org - Fedora Support Forums and Community
Results 1 to 7 of 7
  1. #1
    Join Date
    Feb 2006
    Posts
    184
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Question 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?

  2. #2
    Join Date
    Mar 2004
    Location
    In your closet
    Posts
    16,270
    Mentioned
    5 Post(s)
    Tagged
    0 Thread(s)
    If this were my system I'd run those commands again and see if anything changes.

  3. #3
    Join Date
    Jul 2006
    Location
    Transgression
    Age
    43
    Posts
    1,182
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Thumbs up Re: yum update - Fatal error, run database recovery

    Quote 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

  4. #4
    Join Date
    Jun 2005
    Location
    Montreal, Québec, Canada
    Posts
    9,105
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)

    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
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840
    We get too soon old, and too late smart!

  5. #5
    Join Date
    Jun 2005
    Location
    Montreal, Québec, Canada
    Posts
    9,105
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)

    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?
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840
    We get too soon old, and too late smart!

  6. #6
    Join Date
    Jul 2008
    Posts
    1,347
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    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.

  7. #7
    Join Date
    Jun 2005
    Location
    Montreal, Québec, Canada
    Posts
    9,105
    Mentioned
    23 Post(s)
    Tagged
    0 Thread(s)

    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.
    Leslie in Montreal

    Interesting web sites list
    http://forums.fedoraforum.org/showth...40#post1697840
    We get too soon old, and too late smart!

Similar Threads

  1. rpmdb: PANIC: fatal region error detected; run recovery
    By icy-flame in forum Using Fedora
    Replies: 6
    Last Post: 1st August 2013, 05:53 PM
  2. Error (-30977): run database recovery
    By Omega Blue in forum Using Fedora
    Replies: 4
    Last Post: 17th November 2006, 08:34 AM
  3. Yum update fatal error
    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
  •  
[[template footer(Guest)]]