Bug 64008 - rpm operations segfault; corrupt database
rpm operations segfault; corrupt database
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
Depends On:
  Show dependency treegraph
Reported: 2002-04-23 13:49 EDT by Rodent of Unusual Size
Modified: 2008-05-01 11:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-04-23 15:59:25 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Rodent of Unusual Size 2002-04-23 13:49:29 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.76 [en] (WinNT; U)

Description of problem:
Shortly after upgrading from RH 5.2 to RH 72 (from the vanilla CDs), my RPM database became damaged.
I am not sure of the exact sequence, but the entry for 'gnuchess' appears to be the culprit.  I tried to
'rpm -e gnuchess' and started getting complaints about database problems and __db.00[12] files.
An 'rpm -qa' lists all packages up to and including gnuchess, but then segfaults.  It appears that
attempts to manipulate packages that appear after gnuchess will fail, but I cannot state that

I tried rebuilding the database with 'rpm --rebuillddb' and got a segfault.
I tried exporting and importing the database through dumpdb_031 and
dbimport_031; no errors were encountered, but the database appears
to still be corrupt.

This problem is causing up2date to fail, and there are a lot of updates I
want to apply. :-)

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. rm -f /var/lib/rpm/__db.00[12]
2. rpm -qa   OR   rpm --rebuilddb

Actual Results:  # rpm -qa
Segmentation fault

# rpm --rebuilddb
Segmentation fault

Both leave /var/lib/rpm/__db.00? droppings.

Expected Results:  I should have gotten a complete and failure-free list of all installed packages.
I should have gotten a failure-free rebuilt package database.

Additional info:

I am classifying this as a security bug because the database corruption
is preventing me from applying security errata.
Comment 1 Jeff Johnson 2002-04-23 15:18:46 EDT
A pointer (i.e. URL, attachments won't work) of
a tarball of your database please:
	cd /var/lib
	tar czvf /tmp/rpmdb-64008.tar.gz rpm
Comment 2 Rodent of Unusual Size 2002-04-23 15:59:20 EDT
Online at <URL:http://Source-Zone.Org/rpmdb-64008.tar.gz>.
Comment 3 Jeff Johnson 2002-04-24 08:19:12 EDT
Instance #174 (dip IIRC) was damaged. I've deleted
that instance, and a fixed copy of your rpm/Packages is at

Download and install by doing
	cd /var/lib
	mv rpm/Packages rpm/Packages-ORIG
	tar xzvf rpmdb-64008-FIX.tar.gz
	rpm --rebuilddb -vv
	rpm -qa

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