Bug 64008 - rpm operations segfault; corrupt database
Summary: rpm operations segfault; corrupt database
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: rpm
Version: 7.2
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact:
URL: http://Source-Zone.Org/rpmdb-64008.ta...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-04-23 17:49 UTC by Rodent of Unusual Size
Modified: 2008-05-01 15:38 UTC (History)
0 users

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2002-04-23 19:59:25 UTC
Embargoed:


Attachments (Terms of Use)

Description Rodent of Unusual Size 2002-04-23 17:49:29 UTC
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
categorically.

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:
Always

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

Actual Results:  # rpm -qa
gnome-linuxconf-0.14-4rh
sag-0.6-1
    :
dip-3.3.7o-12
gnuchess-4.0.pl77-5
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 19:18:46 UTC
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 19:59:20 UTC
Online at <URL:http://Source-Zone.Org/rpmdb-64008.tar.gz>.
Thanks.

Comment 3 Jeff Johnson 2002-04-24 12:19:12 UTC
Instance #174 (dip IIRC) was damaged. I've deleted
that instance, and a fixed copy of your rpm/Packages is at
	ftp://people.redhat.com/jbj/rpmdb-64008-FIX.tar.gz

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.