Bug 59088 - RPM 4.0.3 and 4.0.4 segfaulting at a probably corrupt database
Summary: RPM 4.0.3 and 4.0.4 segfaulting at a probably corrupt database
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: rpm
Version: 7.2
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact:
URL: http://www.cs.unipr.it/~bagnara/rpmdb...
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-01-30 19:26 UTC by Roberto Bagnara
Modified: 2008-05-01 15:38 UTC (History)
1 user (show)

(edit)
Clone Of:
(edit)
Last Closed: 2002-01-30 19:26:59 UTC


Attachments (Terms of Use)

Description Roberto Bagnara 2002-01-30 19:26:53 UTC
Description of Problem:

after doing `rpm -Fvh some-packages' I got a message saying something
about the database being not in good shape.  Then I tried to rebuild
the database, but I get

# rpm --rebuilddb
error: rpmdb: damaged header instance #266 retrieved, skipping.
error: rpmdb: damaged header instance #278 retrieved, skipping.
error: rpmdb: damaged header instance #312 retrieved, skipping.
error: rpmdb: damaged header instance #794 retrieved, skipping.
error: rpmdb: damaged header instance #834 retrieved, skipping.
error: rpmdb: damaged header instance #878 retrieved, skipping.
error: rpmdb: damaged header instance #886 retrieved, skipping.
error: rpmdb: damaged header instance #954 retrieved, skipping.
error: rpmdb: damaged header instance #980 retrieved, skipping.
error: rpmdb: damaged header instance #1043 retrieved, skipping.
Segmentation fault
# rpm -q rpm
rpm-4.0.3-1.03

I have also tried with version 4.0.4 which gives me a slightly
more informative message

# ./rpm --rebuilddb
error: rpmdb: damaged header instance #266 retrieved, skipping.
error: rpmdb: damaged header instance #278 retrieved, skipping.
error: rpmdb: damaged header instance #312 retrieved, skipping.
error: rpmdb: damaged header instance #794 retrieved, skipping.
error: rpmdb: damaged header instance #834 retrieved, skipping.
error: rpmdb: damaged header instance #878 retrieved, skipping.
error: rpmdb: damaged header instance #886 retrieved, skipping.
error: rpmdb: damaged header instance #954 retrieved, skipping.
error: rpmdb: damaged header instance #980 retrieved, skipping.
error: rpmdb: damaged header instance #1043 retrieved, skipping.
*** dbiUpdateRecord: uh is NULL
Segmentation fault

Comment 1 Jeff Johnson 2002-01-30 23:36:01 UTC
Hmmm, something else is going on, as rpm --rebuilddb worked
flawlessly for me.

There's a tarball of your rebuilt database at
	ftp://people.redhat.com/jbj/rpmdb-59088-FIX.tar.gz
if that helps. Do
	cd /var/lib
	mv rpm rpm-SAVE
	tar xzvf rpmdb-59088-FIX.tar.gz
to replace. An rpm -qa is a pretty good check, try a rpm --rebuilddb -vv
as well.


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