Bug 582

Summary: rpm crashes and dumps core when removing XFree86-devel
Product: [Retired] Red Hat Linux Reporter: yye
Component: rpmAssignee: David Lawrence <dkl>
Status: CLOSED WORKSFORME QA Contact:
Severity: high Docs Contact:
Priority: medium    
Version: 5.2CC: yye
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 1998-12-28 16:06:21 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:

Description yye 1998-12-25 06:43:02 UTC
I have XFree86-devel-3.3.2.3-25 installed with my RH 5.2
box, and I tried to update the package to 3.3.3-1, but I
can't seem to remove the old package:

# rpm -e XFree86-devel
package (null) contains no files
Segmentation fault

Strangely, I was able to upgrade the package on another RH
5.2 system.  The version of RPM on both systems is
rpm-2.5.5-5.2.

These are the last few lines from the strace output of "rpm
-Uvh XFree86-devel-3.3.3-1.i386.rpm":  I can provide the
full strace output and the core dump if you need it.

lseek(4, 4092504, SEEK_SET)             = 4092504
select(5, [4], NULL, NULL, {5, 0})      = 1 (in [4], left
{5, 0})
read(4, "\0\0\0+", 4)                   = 4
select(5, [4], NULL, NULL, {5, 0})      = 1 (in [4], left
{5, 0})
read(4, "\0\0\33\34", 4)                = 4
brk(0)                                  = 0x81aa000
brk(0x81ac000)                          = 0x81ac000
select(5, [4], NULL, NULL, {5, 0})      = 1 (in [4], left
{5, 0})
read(4, "\0\0\0d\0\0\0\10\0\0\0\0\0\0\0\10"..., 7628) = 7628
lseek(4, 7329944, SEEK_SET)             = 7329944
select(5, [4], NULL, NULL, {5, 0})      = 1 (in [4], left
{5, 0})
read(4, "\0\0\0\0", 4)                  = 4
select(5, [4], NULL, NULL, {5, 0})      = 1 (in [4], left
{5, 0})
read(4, "\0\0\0\0", 4)                  = 4
write(2, "package (null) contains no files"..., 32package
(null) contains no files) = 32
write(2, "\n", 1
)                       = 1
--- SIGSEGV (Segmentation fault) ---
+++ killed by SIGSEGV +++

Comment 1 Jeff Johnson 1998-12-28 16:06:59 UTC
You need to do
	rpm --rebuilddb
after any/every rpm segfault. Otherwise, the database can be
inconsistent leading to "weirdo" rpm seg faults such as you are
seeing.

Do "rpm --rebuilddb" and try your remove again.
If the problem persists, please reopen this bug.