Bug 17489 - Segfault while upgrading
Segfault while upgrading
Status: CLOSED DUPLICATE of bug 19666
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-09-13 23:31 EDT by Enrico Scholz
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-10-03 17:55:36 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
rpm -qls openssl -vv (19.05 KB, text/plain)
2000-09-13 23:34 EDT, Enrico Scholz
no flags Details
rpm -qlp /usr/src/redhat/RPMS/i686/openssl-0.9.5a-14.i686.rpm -vv (5.36 KB, text/plain)
2000-09-13 23:37 EDT, Enrico Scholz
no flags Details
rpm -sql openssl -vv ## *after* rpm -e openssl; rpm -U openssl-...rpm (6.28 KB, text/plain)
2000-09-13 23:41 EDT, Enrico Scholz
no flags Details

  None (edit)
Description Enrico Scholz 2000-09-13 23:31:56 EDT
While upgrading an old openssl version I get:

# gdb rpmu
(gdb) r -U /usr/src/redhat/RPMS/i686/openssl-0.9.5a-14.i686.rpm
Program received signal SIGSEGV, Segmentation fault.
0x400816f4 in handleOverlappedFiles () from /usr/lib/librpm.so.0
(gdb) bt
#0  0x400816f4 in handleOverlappedFiles () from /usr/lib/librpm.so.0
#1  0x40083191 in rpmRunTransactions () from /usr/lib/librpm.so.0
#2  0x4007995c in rpmInstall () from /usr/lib/librpm.so.0
#3  0x804b095 in poptResetContext ()
#4  0x40160b65 in __libc_start_main (...)

Sorry I have no debuginformation compiled in, but I will attach some
information about the packages...
Comment 1 Enrico Scholz 2000-09-13 23:34:45 EDT
Created attachment 3420 [details]
rpm -qls openssl -vv
Comment 2 Enrico Scholz 2000-09-13 23:37:26 EDT
Created attachment 3421 [details]
rpm -qlp /usr/src/redhat/RPMS/i686/openssl-0.9.5a-14.i686.rpm -vv
Comment 3 Enrico Scholz 2000-09-13 23:41:43 EDT
Created attachment 3422 [details]
rpm -sql openssl -vv  ## *after* rpm -e openssl; rpm -U openssl-...rpm
Comment 4 Jeff Johnson 2000-09-14 05:48:25 EDT
What version of rpm?

Try doing "rpm --rebuilddb" first. Inconsistent data from the rpm database will
often cause segfaults.
(N.B. You will almost always have to do "rpm --rebuilddb" after any rpm seg
fault.)
Comment 5 Enrico Scholz 2000-09-14 06:02:26 EDT
# rpm -q rpm
rpm-4.0-4

`rpm --rebuild' was done shortly before I tried to install openssl
Comment 6 Enrico Scholz 2000-09-14 16:26:53 EDT
Was able to create debugable dump:

Core was generated by `rpm -U
/usr/src/redhat/RPMS/i686/openldap-1.2.11-15.i686.rpm /usr/src/redhat/RP'.
Program terminated with signal 11, Segmentation fault.
#0  0x806ebb9 in handleOverlappedFiles (fi=0xbfffefa0, ht=0x823cd98,
probs=0x81bd608, dsl=0xbffff040) at transaction.c:962
962                 for (otherFileNum = 0; otherFileNum < recs[otherPkgNum]->fc;
(gdb) bt
#0  0x806ebb9 in handleOverlappedFiles (fi=0xbfffefa0, ht=0x823cd98,
probs=0x81bd608, dsl=0xbffff040) at transaction.c:962
#1  0x30b in ?? ()
#2  0x80704fe in rpmRunTransactions (ts=0x81b0df0, notify=0x8066d80
<showProgress>, notifyData=0x20, okProbs=0x0, newProbs=0xbffff3f8, transFlags=0,
ignoreSet=0)
    at transaction.c:1597
#3  0x8067a74 in rpmInstall (rootdir=0x8168b6c "/rpm/rpmpopt-4.0",
fileArgv=0x81a46b0, transFlags=0, interfaceFlags=32, probFilter=0,
relocations=0x0) at rpminstall.c:370
#4  0x804b386 in main (argc=6, argv=0xbffff5f4) at rpm.c:1133
#5  0x81031ed in __libc_start_main (main=0x80499b0 <main>, argc=6,
ubp_av=0xbffff5f4, init=0x80480b4 <_init>, fini=0x8165ba0 <_fini+32>,
rtld_fini=0, stack_end=0xbffff5ec)
    at ../sysdeps/generic/libc-start.c:111

(gdb) p otherFileNum 
$3 = -1
(gdb) p otherPkgNum
$5 = 139
(gdb) p recs[139]
$6 = (TFI_t *) 0x11
(gdb) p filespec
$31 = 0x824f368 "/usr/share/openldap/migration/migrate_common.ph"
(gdb) p j
$48 = 136732936


I'm seeing a problem in transaction.c:951
for (j = 0; recs[j] != fi; j++) ;

(gdb) p numRecs 
$37 = 1
(gdb) p fi
$49 = (TFI_t *) 0xbfffefa0
(gdb) p recs[0]
$50 = (TFI_t *) 0xbfffeec8
(gdb) p recs[1]
$51 = (TFI_t *) 0x30a
Comment 7 Jeff Johnson 2000-10-03 13:23:40 EDT
Hmmm, weirdness. Can you send me <jbj@redhat.com> a copy (or pointers) to a
tarball of the database and the package being installed? I'll take a look.
Meanwhile, since I have not a prayer
of reproducing this problem otherwise, I'm gonna close this bug. Please reopen
if you have
a reproducible test case.
Comment 8 Enrico Scholz 2000-10-03 17:55:34 EDT
An example:

0. empty %_netsharedpath, rpm-4.0-4, db1-1.85-4, db3-3.1.14-6, glibc-2.1.94-1
(packages are self-compiled for target i586)

1. rpm -U
ftp://ftp.tu-chemnitz.de/pub/linux/redhat-ftp/redhat/redhat-7.0/i386/en/RedHat/RPMS/urw-fonts-2.0-8.noarch.rpm
--force --nodeps --justdb
2. echo '%_netsharedpath /usr/share' >>/etc/rpm/macros
3. rpm -U
ftp://ftp.tu-chemnitz.de/pub/linux/redhat-ftp/redhat/redhat-7.0/i386/en/RedHat/RPMS/urw-fonts-2.0-8.noarch.rpm
--force --nodeps --justdb
Segmentation fault (core dumped)
Comment 9 Jeff Johnson 2001-01-08 10:42:09 EST
I believe that I know what's happening here, rpm ignored _netsharedpath for
config
files.  The fix is closely related to #19666, so I'm gonna mark as a dupe.

*** This bug has been marked as a duplicate of 19666 ***

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