Bug 743014 - readEntry: Operation not permitted
Summary: readEntry: Operation not permitted
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: x86info
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Paul W. Frields
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-10-03 15:18 UTC by Andrew Jones
Modified: 2015-02-17 13:54 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-17 13:54:40 UTC
Type: ---


Attachments (Terms of Use)
full dmesg (19.23 KB, text/plain)
2011-10-06 15:29 UTC, Andrew Jones
no flags Details

Description Andrew Jones 2011-10-03 15:18:14 UTC
# rpm -q x86info
x86info-1.29-1.fc16.x86_64

# x86info
x86info v1.29.  Dave Jones 2001-2011
Feedback to <davej>.

readEntry: Operation not permitted
Found 2 identical CPUs


Can't read /dev/mem, here's the strace output

open("/dev/mem", O_RDONLY)              = 3
lseek(3, 1038, SEEK_SET)                = 1038
read(3, "\0\0", 2)                      = 2
lseek(3, 1043, SEEK_SET)                = 1043
read(3, "\0\0", 2)                      = 2
lseek(3, 67107840, SEEK_SET)            = 67107840
read(3, 0x7fff6dff2700, 1024)           = -1 EPERM (Operation not permitted)
dup(2)                                  = 4
fcntl(4, F_GETFL)                       = 0x8402 (flags O_RDWR|O_APPEND|O_LARGEFILE)
fstat(4, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 0), ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fc9fa5e9000
lseek(4, 0, SEEK_CUR)                   = -1 ESPIPE (Illegal seek)
write(4, "readEntry: Operation not permitt"..., 35readEntry: Operation not permitted
) = 35
close(4)                                = 0
munmap(0x7fc9fa5e9000, 4096)            = 0
write(1, "Found 2 identical CPUs", 22Found 2 identical CPUs)  = 22
exit_group(1)                           = ?

Comment 1 Andrew Jones 2011-10-03 15:22:44 UTC
The dmesg log

[   26.657234] Program x86info tried to access /dev/mem between 3fff000->3fff400.

Comment 2 Dave Jones 2011-10-05 18:41:15 UTC
what system is this ?

can you attach the whole dmesg log ?

Comment 3 Andrew Jones 2011-10-06 15:29:25 UTC
Created attachment 526726 [details]
full dmesg

This is an F16 (3.1.0-0.rc6.git0.3.fc16.x86_64) PV Xen guest running on a RHEL5 host. The full dmesg is now attached.

Comment 4 Dave Jones 2011-10-06 16:47:00 UTC
I think this might be a xen bug. On real hardware, the EBDA table which lives in low memory points to a reserved area of memory where the MP tables live. This area is marked in e820 as reserved. On Xen that doesn't seem to happen.

Comment 5 Andrew Jones 2011-10-07 08:09:36 UTC
Ah yes, the PV environment isn't a perfect emulation of hardware. I'd argue that x86info should print warnings when it doesn't find something it expects, such as mptables, rather than die though. Anything that still works should be output. In this case I only really wanted a cpuid dump. Strangely, if I run x86info as root and only specify '-r' it still tries to read the mptables which fails the whole thing, but if I run 'x86info -r' as a non-root user, then I get what I want.

Comment 6 Dave Jones 2011-10-07 15:47:12 UTC
I started adding some better handling of failure in the mptable code yesterday. 
It still needs to propagate the failure up to higher levels rather than just exit(EXIT_FAILURE), but it's getting there.

I'll poke at it some more today.

Comment 7 Adam Thompson 2012-08-31 15:31:51 UTC
This *exact* error (same memory range, even!) also occurs in x86info v1.25 in Ubuntu 12.04 running under ESXi5.0.
Like the original reporter, when run as non-root, it executes and displays most of the information I want.

Comment 8 Fedora End Of Life 2013-04-03 14:19:56 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

Comment 10 Fedora End Of Life 2015-01-09 16:48:27 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 11 Fedora End Of Life 2015-02-17 13:54:40 UTC
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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