Bug 109274

Summary: rpm database corrupted, segfault when trying to repair
Product: [Retired] Red Hat Linux Reporter: Andrea Gangini <a.gangini>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED WORKSFORME QA Contact: Mike McLean <mikem>
Severity: high Docs Contact:
Priority: medium    
Version: 9   
Target Milestone: ---   
Target Release: ---   
Hardware: i586   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-12-06 19:42:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
rpm -qa output none

Description Andrea Gangini 2003-11-06 13:16:37 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5)
Gecko/20031007

Description of problem:
Hi, I've made all the steps described there
http://www.rpm.org/hintskinks/repairdb-2003-06/
with no luck...

Also I tried to recover the database using

[root@zenone rpm]# /usr/lib/rpm/rpmdb_dump Packages_ORIG |
/usr/lib/rpm/rpmdb_load Packages

But then..
[root@zenone rpm]# rpm -qa
error: rpmdbNextIterator: skipping h#     701 Header V3 DSA signature:
BAD, key ID db42a60e
Segmentation fault

Are there any other procedures to recover the rpm database? The
machine with this problem is a server, and reinstalling is really the
last option.
Thanks.


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

How reproducible:
Always

Steps to Reproduce:
rpm --rebuilddb

Actual Results:  error: rpmdbNextIterator: skipping h#     701 Header
V3 DSA signature: BAD, key ID db42a60e
Segmentation fault

Additional info:

If you require it, I have a saved version of a rpm -qa output, before
this problem occurred

Comment 1 Andrea Gangini 2003-11-06 13:19:37 UTC
Created attachment 95758 [details]
rpm -qa output 

No other packages where installed after this last rpm -qa, so this should be an
accurate package snapshot

Comment 2 Jeff Johnson 2003-12-05 16:16:48 UTC
Try removing (or renaming) /var/lib/rpm/Pubkeys and then
doing rpm --rebuilddb -vv.

Does that fix the segfault?

Comment 3 Andrea Gangini 2003-12-05 16:41:32 UTC
Yes, thank you, it was the Pubkeys database: removing and then
rebuilding solved the problem.