erlang crashes in user mode linux
rage machine
slasci@REDACTED
Thu Jul 20 14:07:33 CEST 2006
Hi
When running erlang in user mode linux I get segmentation fault.
erlang@REDACTED:~$ erl
Segmentation fault
Some info about the uml:
erlang@REDACTED:~/otp/bin$ ROOTDIR=/home/erlang/otp/lib/erlang
erlang@REDACTED:~/otp/bin$ BINDIR=$ROOTDIR/erts-5.5/bin
erlang@REDACTED:~/otp/bin$ EMU=beam
erlang@REDACTED:~/otp/bin$ PROGNAME=erl
erlang@REDACTED:~/otp/bin$ export EMU
erlang@REDACTED:~/otp/bin$ export ROOTDIR
erlang@REDACTED:~/otp/bin$ export BINDIR
erlang@REDACTED:~/otp/bin$ export PROGNAME
erlang@REDACTED:~/otp/bin$ /home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
Segmentation fault
erlang@REDACTED:~/otp/bin$ gdb /home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
GNU gdb 6.4.90-debian
Copyright (C) 2006 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu"...Using host libthread_db
library "/lib/tls/libthread_db.so.1".
(gdb) run
Starting program: /home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
[New LWP 1287]
Program received signal SIGSEGV, Segmentation fault.
[Switching to LWP 1287]
0x00000000 in ?? ()
(gdb) The program is running. Exit anyway? (y or n) y
erlang@REDACTED:~/otp/bin$ valgrind -v --db-attach=yes --tool=memcheck
/home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
==1288== Memcheck, a memory error detector.
==1288== Copyright (C) 2002-2006, and GNU GPL'd, by Julian Seward et al.
==1288== Using LibVEX rev 1606, a library for dynamic binary translation.
==1288== Copyright (C) 2004-2006, and GNU GPL'd, by OpenWorks LLP.
==1288== Using valgrind-3.2.0-Debian, a dynamic binary instrumentation
framework.
==1288== Copyright (C) 2000-2006, and GNU GPL'd, by Julian Seward et al.
==1288==
--1288-- Command line
--1288-- /home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
--1288-- Startup, with flags:
--1288-- -v
--1288-- --db-attach=yes
--1288-- --tool=memcheck
--1288-- Contents of /proc/version:
--1288-- Linux version 2.6.17.6 (shrek@REDACTED) (gcc version 4.0.4 20060507
(prerelease) (Debian 4.0.3-3)) #1 Sun Jul 16 12:25:48 CEST 2006
--1288-- Arch and hwcaps: X86, x86-sse1-sse2
--1288-- Valgrind library directory: /usr/lib/valgrind
--1288-- Reading syms from /lib/ld-2.3.6.so (0x4000000)
--1288-- Reading debug info from /lib/ld-2.3.6.so...
--1288-- ... CRC mismatch (computed 8D0DB48E wanted BF5D33FD)
--1288-- object doesn't have a symbol table
--1288-- Reading syms from /home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
(0x8048000)
--1288-- Reading syms from /usr/lib/valgrind/x86-linux/memcheck (0x38000000)
--1288-- object doesn't have a dynamic symbol table
--1288-- Reading suppressions file: /usr/lib/valgrind/default.supp
Valgrind's memory management: out of memory:
initialiseSector(TC)'s request for 20127744 bytes failed.
15462400 bytes have already been allocated.
Valgrind cannot continue. Sorry.
erlang@REDACTED:~/otp/bin$
erlang@REDACTED:~/otp/bin$ strace
/home/erlang/otp/lib/erlang/erts-5.5/bin/erlexec
...
open("/etc/localtime", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=56, ...}) = 0
fstat64(3, {st_mode=S_IFREG|0644, st_size=56, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x40019000
read(3, "TZif\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\1\0\0\0\1\0"..., 4096) =
56
close(3) = 0
munmap(0x40019000, 4096) = 0
rt_sigaction(SIGINT, {0x8105970, [], SA_STACK}, {SIG_DFL}, 8) = 0
rt_sigaction(SIGUSR1, {0x81059a0, [], SA_STACK}, {SIG_DFL}, 8) = 0
rt_sigaction(SIGQUIT, {0x81059f0, [], SA_STACK}, {SIG_DFL}, 8) = 0
gettimeofday({1153397168, 556219}, NULL) = 0
times({tms_utime=0, tms_stime=0, tms_cutime=0, tms_cstime=0}) = 65006
pipe([3, 4]) = 0
fcntl64(3, F_GETFL) = 0 (flags O_RDONLY)
fcntl64(3, F_SETFL, O_RDONLY|O_NONBLOCK) = 0
rt_sigaction(SIGPIPE, {SIG_IGN}, {SIG_DFL}, 8) = 0
rt_sigaction(SIGCHLD, {0x8105c40, [], SA_STACK}, {SIG_DFL}, 8) = 0
rt_sigprocmask(SIG_BLOCK, [INT USR1 CHLD], [], 8) = 0
mmap2(NULL, 8388608, PROT_READ|PROT_WRITE|PROT_EXEC,
MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x404fb000
mprotect(0x404fb000, 4096, PROT_NONE) = 0
clone(child_stack=0x40cfa4c4,
flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID|CLONE_DETACHED,
parent_tidptr=0x40cfabf8, {entry_number:0, base_addr:0x40cfabb0,
limit:1048575, seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1,
seg_not_present:0, useable:1}, child_tidptr=0x40cfabf8) = 1291
+++ killed by SIGSEGV +++
Process 1290 detached
erlang@REDACTED:~$ erlc -h
Usage: erlc [options] file.ext ...
Options:
-b type type of output file (e.g. jam or beam)
-d turn on debugging of erlc itself
erlang@REDACTED:~$ free
total used free shared buffers cached
Mem: 30188 15416 14772 0 1512 9004
-/+ buffers/cache: 4900 25288
Swap: 0 0 0
erlang@REDACTED:~$ uname -a
Linux uml0 2.6.17.6 #1 Sun Jul 16 12:25:48 CEST 2006 i686 GNU/Linux
erlang@REDACTED:~$
More information about the erlang-questions
mailing list