This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: glibc-2.3.4 .so on glibc-2.6.1 system = mmap error


On 4/29/08, Florian Weimer <fw@deneb.enyo.de> wrote:
> * Michael B. Allen:
>
>
>  > Does anyone have any suggestions or diagnostics that might help
>  > identify the problem?
>
>
> Can you show us some strace output, and the /proc/$PID/smaps file when
>  the mmap call fails?

Hi Florian,

I have attached a tar.gz. The mmap call that is failing unexpectedly
is on line 1421 of the strace.txt output.

The smaps.txt was generated by calling cat /proc/PID/smaps through
system(3) immediately before the offending mmap call.

Here is a snipplet of strace.txt:

open("/var/lib/plexcel/plexcel.sga", O_RDWR) = 10
open("/var/lib/plexcel/plexcel.sga", O_RDONLY|O_CREAT, 0666) = 11
stat("/var/lib/plexcel/plexcel.sga", {st_mode=S_IFREG|0666,
st_size=2097152, ...}) = 0
semget(0x102c1bf, 1, 0)                 = -1 ENOENT (No such file or directory)
semget(0x102c1bf, 1, IPC_CREAT|IPC_EXCL|0666) = 1212416
semctl(1212416, 0, SETVAL, 0x7fff00000000) = 0
semop(1212416, 0x7fffed064950, 1)       = 0
close(11)                               = 0
semtimedop(1212416, 0x7fffed064af0, 1, NULL) = 0
open("/var/lib/plexcel/plexcel.sga", O_RDWR) = 11
fstat(11, {st_mode=S_IFREG|0666, st_size=2097152, ...}) = 0
mmap(NULL, 544, PROT_READ|PROT_WRITE, MAP_SHARED, 11, 0) = 0x2b83c9dea000
close(11)                               = 0
msync(0x2b83c9dea000, 544, MS_ASYNC)    = 0
munmap(0x2b83c9dea000, 544)             = 0
ftruncate(10, 2097152)                  = 0
rt_sigaction(SIGINT, {SIG_IGN}, {SIG_DFL}, 8) = 0
rt_sigaction(SIGQUIT, {SIG_IGN}, {SIG_DFL}, 8) = 0
rt_sigprocmask(SIG_BLOCK, [CHLD], [], 8) = 0
clone(child_stack=0, flags=CLONE_PARENT_SETTID|SIGCHLD,
parent_tidptr=0x7fffed064678) = 5297
wait4(5297, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 5297
rt_sigaction(SIGINT, {SIG_DFL}, NULL, 8) = 0
rt_sigaction(SIGQUIT, {SIG_DFL}, NULL, 8) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
--- SIGCHLD (Child exited) @ 0 (0) ---
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3519, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3519, ...}) = 0
stat("/etc/localtime", {st_mode=S_IFREG|0644, st_size=3519, ...}) = 0
write(9, "Apr 29 15:24:31 src/sga.c:219:sg"..., 79) = 79
mmap(NULL, 2097152, PROT_READ|PROT_WRITE, MAP_SHARED, 10, 0) = -1
ENOMEM (Cannot allocate memory)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
open("/proc/meminfo", O_RDONLY)         = 11
fstat(11, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1,
0) = 0x2b83c9fea000
read(11, "MemTotal:       123996 kB\nMemFre"..., 1024) = 725
close(11)                               = 0
munmap(0x2b83c9fea000, 4096)            = 0
semctl(1212416, 0, IPC_RMID, 0x1)       = 0
close(10)                               = 0

Mike


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]