Bug 133317 - 64-bit "prelink -y" fails on 32-bit objects
64-bit "prelink -y" fails on 32-bit objects
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
3
x86_64 Linux
medium Severity medium
: ---
: ---
Assigned To: Dave Jones
Brian Brock
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-09-23 00:33 EDT by Nicholas Miell
Modified: 2015-01-04 17:09 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2005-07-15 18:43:57 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)

  None (edit)
Description Nicholas Miell 2004-09-23 00:33:15 EDT
[nicholas@entropy ~]$ rpm -q --qf "%{n}-%{v}-%{r}.%{arch}\n" prelink
prelink-0.3.2-6.x86_64

[nicholas@entropy ~]$ file /usr/sbin/prelink
/usr/sbin/prelink: ELF 64-bit LSB executable, AMD x86-64, version 1
(SYSV), for GNU/Linux 2.4.0, statically linked, stripped

[nicholas@entropy ~]$ prelink -vvvvvv -y --sha /usr/bin/xml_parser
Checking executable /usr/bin/xml_parser
Checking shared library /usr/lib/libestbase.so.1.2.2.1
Checking shared library /usr/lib/libeststring.so.1.2
Checking shared library /lib/libgcc_s-3.4.2-20040908.so.1
Checking shared library /lib/tls/libc-2.3.3.so
Checking shared library /lib/ld-2.3.3.so
Checking shared library /lib/libtermcap.so.2.0.8
Checking shared library /lib/libdl-2.3.3.so
Checking shared library /lib/tls/libm-2.3.3.so
Checking shared library /usr/lib/libstdc++.so.6.0.2
prelink: /tmp/#prelink#.8wz2rn: Recorded 9 dependencies, now seeing -1

[nicholas@entropy ~]$ prelink -vvvvvv -y --sha /lib/libdl-2.3.3.so
Checking shared library /lib/libdl-2.3.3.so
Checking shared library /lib/tls/libc-2.3.3.so
Checking shared library /lib/ld-2.3.3.so
prelink: /tmp/#prelink#.cNHace: Recorded 2 dependencies, now seeing -1
Comment 1 Jakub Jelinek 2004-09-26 18:15:56 EDT
This looks like a kernel issue.
All arches seem to flags &= ~(MAP_EXECUTABLE | MAP_DENYWRITE)
in their native mmap/mmap2 wrappers around do_mmap_pgoff.
On x86-64, for 32-bit binaries sys32_mmap2 does that too, but
sys32_mmap does not.
On i386, this masking off is done in do_mmap2, which is called
by both sys_mmap2 and old_mmap.

On the other side, I wonder why this masking off these bits is done
on all arches.  If that is reverted, prelink will need to change
to cope with it for --verify.
Comment 2 Jakub Jelinek 2004-10-02 13:05:08 EDT
I have changed prelink-0.3.2-10 so that it doesn't keep the fd open
in read-only over running ld.so on it.  Still, at least for consistency
the kernel IMHO should be changed, either way.
Comment 3 Dave Jones 2005-07-15 14:41:01 EDT
An update has been released for Fedora Core 3 (kernel-2.6.12-1.1372_FC3) which
may contain a fix for your problem.   Please update to this new kernel, and
report whether or not it fixes your problem.

If you have updated to Fedora Core 4 since this bug was opened, and the problem
still occurs with the latest updates for that release, please change the version
field of this bug to 'fc4'.

Thank you.
Comment 4 Nicholas Miell 2005-07-15 16:01:20 EDT
Huh. I didn't realize this was still open. It hasn't been a problem for ....
long enough for me to forget about it, anyway.

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