Bug 57055 - rpm -qa Segmentation fault (core dumped)
rpm -qa Segmentation fault (core dumped)
Status: CLOSED WORKSFORME
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
7.2
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Jeff Johnson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-12-03 16:43 EST by Need Real Name
Modified: 2007-04-18 12:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2001-12-04 11:50:29 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
Core file from crash (1.12 MB, application/octet-stream)
2001-12-03 16:46 EST, Need Real Name
no flags Details
bzip file of /var/lib/rpm (5.35 MB, application/octet-stream)
2001-12-03 16:56 EST, Need Real Name
no flags Details

  None (edit)
Description Need Real Name 2001-12-03 16:43:44 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; WinNT4.0; en-US; rv:0.9.6+) Gecko/20011130

Description of problem:
My rpm database has had a stroke. Any rpm operations now result
in a segmentation fault. Ex. "rpm -qa" lists files up to the last
package I installed and then crashes.

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


How reproducible:
Always

Steps to Reproduce:
1. rpm -qa
2.
3.
	

Actual Results:  rpm -qa
.....
printtool-3.54-1
XFree86-libs-4.0.3-5
vixie-cron-3.0.1-62
util-linux-2.11f-11.7.1
db1-1.85-7
rpm-python-4.0.3-1.03
compat-glibc-6.2-2.1.3.2
kernel-2.4.3-12
zlib-1.1.3-24
bzip2-1.0.1-4
rpmdb-redhat-7.2-0.20010924
gpgp-0.4-2
svgalib-devel-1.4.1-2
howto-6.1-1
snort-1.7-1
XFree86-devel-4.0.3-5
sendmail-cf-8.11.6-1.7.1
Segmentation fault (core dumped)



Expected Results:  complete listing of packages installed

Additional info:

I'll attach my database files and core when I get the attachment.
Comment 1 Need Real Name 2001-12-03 16:46:07 EST
Created attachment 39507 [details]
Core file from crash
Comment 2 Need Real Name 2001-12-03 16:56:13 EST
Created attachment 39510 [details]
bzip file of /var/lib/rpm
Comment 3 Jeff Johnson 2001-12-03 17:09:54 EST
Please, a URL instead, core files and rpm databases are often
too large for bugzilla attachments

Also, before sending me the database, can you try
rpm-4.0.3? You'll probably need to install using
rpm2cpio. Download all the packages from
	ftp://ftp.rpm.org/pub/rpm/dist/rpm-4.0.x
There are 6 packages
	popt-1.6.3
	rpm-4.0.3
	rpm-devel
	rpm-build
	rpm-python
	rpm-perl
Assuming all the packages in /var/tmp, you can install
using rpm2cpio by
	mkdir /var/tmp/xxx
	cd /var/tmp/xxx
	for i in ../{rpm,popt}-*
	do
	    rpm2cpio $i | cpio -dim
	done
	find . -type d -exec chmod 755 {} \;
	tar cf - . | (cd /; tar xvf -)
Then a rpm --rebuilddb should fix what's wrong.
Comment 4 Need Real Name 2001-12-03 17:43:31 EST
Sorry, but I had already sent the core and lib files before I saw
the message not to send them. Thanks for the swift response.

I downloaded 
popt-1.6.3-7x.i386.rpm
rpm-4.0.3-7x.i386.rpm
rpm-build-4.0.3-7x.i386.rpm
rpm-devel-4.0.3-7x.i386.rpm
rpm-perl-4.0.3-7x.i386.rpm
rpm-python-4.0.3-7x.i386.rpm

and then followed the rpm2cpio instructions.

I then get,

[root@wolf tmp]# rpm --rebuilddb
Segmentation fault (core dumped)


Comment 5 Jeff Johnson 2001-12-04 08:33:34 EST
A URL to a tarball, please of your database
	cd /var/lib
	tar czvf /tmp/rpmdb-57055.tar.gz rpm
and I'll take a look.
Comment 6 Need Real Name 2001-12-04 11:50:25 EST
Here is the URL http://www.cimsoft.com/tmp/rpmdir.tar.gz
Comment 7 Jeff Johnson 2001-12-04 17:06:58 EST
Thanks for the URL. I'll send you a fix by private e-mail.
Comment 8 Brian Exelbierd 2004-06-13 16:50:40 EDT
I am having the same problem -- rpm -qa segfaults.

These solutions are always provided by private mail, so how can I get 
a copy of the solution?  I will provide any files requested.

Please be advised, I have not updated the rpm version (still 4.0.2-
6x) as I believe the problems resides in packages.rpm with the glib 
entry.

see below:

# rpm -qa
tmpwatch-2.8-0.6.x
setup-2.1.8-1
filesystem-1.3.5-1
basesystem-6.0-4
ldconfig-1.9.5-16
anacron-2.1-6
bash-1.14.7-23.6x
shadow-utils-19990827-10
termcap-10.2.7-9
libtermcap-2.0.8-20
bind-utils-8.2.3-0.6.x
MAKEDEV-2.5.2-1
ximian-wallpapers-0.2-ximian.1
ximian-faq-1.0-ximian.2
rxvt-2.6.1-8
info-4.0-5
fwbuilder-0.8.7-2
Segmentation fault

# rpm -q glib
Segmentation fault

This is the package right before fwbuilder in the nameindex.rpm 
file.  The file before glib is X11R6-Contrib .. it works fine:

# rpm -q X11R6-contrib
X11R6-contrib-3.3.2-11

Comments?

Thanks,

bex

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