Bug 104050

Summary: rpm -q segfault
Product: Red Hat Enterprise Linux 3 Reporter: Michael Redinger <michael.redinger>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED NOTABUG QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: msw
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-09-11 09:53:10 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 -q gawk-3.1.1-9 strace output
none
rpm -q grub-0.93-4 strace output
none
rpm -q gzip-1.3.3-9 strace output none

Description Michael Redinger 2003-09-09 14:09:26 UTC
For some packages, rpm seg faults if the package specified is
name-version-release. If I only query name-version, it works fine.

Example (run as root):

# rpm -q gawk-3.1.1-9
Segmentation fault
# rpm -q gawk-3.1.1
gawk-3.1.1-9


This worked fine for all other packages in beta2 for me when run as root.
But when I run this as non-root, there are two more packages that cannot be
queried this way:

$ rpm -q grub-0.93-4
Segmentation fault
$ rpm -q gzip-1.3.3-9
Segmentation fault

I am attaching the strace output of the three failed queries.

Comment 1 Michael Redinger 2003-09-09 14:11:12 UTC
Created attachment 94327 [details]
rpm -q gawk-3.1.1-9 strace output

Comment 2 Michael Redinger 2003-09-09 14:12:02 UTC
Created attachment 94328 [details]
rpm -q grub-0.93-4 strace output

Comment 3 Michael Redinger 2003-09-09 14:13:26 UTC
Created attachment 94329 [details]
rpm -q gzip-1.3.3-9 strace output

Comment 4 Matt Wilson 2003-09-09 15:47:48 UTC
works for me:

[msw@sid lib]$ rpm -q gawk-3.1.1-9
gawk-3.1.1-9
[msw@sid lib]$ rpm -q grub-0.93-4
grub-0.93-4
[msw@sid lib]$ rpm -q gzip-1.3.3-9
gzip-1.3.3-9
[msw@sid lib]$ rpm -q rpm
rpm-4.2.1-0.31

Can you use gdb, that is more useful than strace in getting a diagnosis.


Comment 5 Michael Redinger 2003-09-09 16:53:27 UTC
I am trying to do so (rebuilt rpm and installed debuginfo), but ddd/gdb keep
telling me 
"[New Thread -1218546256 (LWP 12320)]
Cannot find user-level thread for LWP 12320: generic error"

However, I found out more:

# LANG=en_US.UTF-8 rpm -q gawk-3.1.1-9
Segmentation fault
# LANG=en_GB.UTF-8 rpm -q gawk-3.1.1-9
Segmentation fault
# LANG=C rpm -q gawk-3.1.1-9
gawk-3.1.1-9
# LANG=de_AT rpm -q gawk-3.1.1-9
gawk-3.1.1-9
# LANG=de_AT.UTF-8 rpm -q gawk-3.1.1-9
gawk-3.1.1-9
# LANG=de_DE.UTF-8 rpm -q gawk-3.1.1-9
gawk-3.1.1-9

(Same for the other packages, when run as normal user)

Can you reproduce it now?


Comment 6 Michael Redinger 2003-09-09 16:57:07 UTC
I forgot this one:

# LANG=en_US.UTF-8 LC_MESSAGES=C rpm -q gawk-3.1.1-9
gawk-3.1.1-9


Comment 7 Matt Wilson 2003-09-09 16:58:55 UTC
still can't reproduce

Comment 8 Matt Wilson 2003-09-10 20:31:26 UTC
try rpm --rebuilddb?


Comment 9 Michael Redinger 2003-09-11 09:53:10 UTC
Forgot that one.
It actually helps - I do not know why ... closing.