Re: malloc error: can't allocate region
Lukas Larsson <[email protected]>
| Newsgroups | gmane.comp.lang.erlang.bugs |
|---|---|
| Message-ID | <[email protected]> |
Hello, This is most likely due to virtual/physical memory fragmentation of the Erlang VM process. Erlang process heaps require contiguous memory areas and when heaps grow very big it becomes more and more difficult to find slots where they fit. The only fix I can give you is to break the process into smaller processes that do not require such large heaps, or buy more RAM :) There have been internal discussions on how to solve this better, but they are far from fruition as it would entail a rewrite to the garbage collector for Erlang. Lukas On 24/06/14 14:30, Fredrik Linder wrote: > I have 16Gb RAM > 10Gb was in use before running the test > At time of crash 11.5Gb was in use (according to Activity Monitor) > > /Fredrik > http://whosawesome.com/ > > > On Tue, Jun 24, 2014 at 1:46 PM, Fredrik Linder > <[email protected] <mailto:[email protected]>> wrote: > > Hello > > I got a malloc error when running proper tests, thought you wanted > to know: > > ## system > > * R15B03-1 compiled using kerl > * default kerl compilation flags + see attached.kerlrc > * OS X 10.9.3, Build 13D65 > * proper git sha: 043f68f2102f366abaa5c5dbf2b55b833d7e90bd > * rebar git sha: 24ce11c3811424d7ee50d8ce59c00ceb3fc6bb2f > > ## output > > -*- mode: compilation; default-directory: "~/PLAT-1823/genq/" -*- > Compilation started at Tue Jun 24 13:21:46 > > cd ~/PLAT-1823/genq/ && PATH=$HOME/PLAT-1823/rebar:$PATH make > check-only s=genq_config > rebar eunit apps=genq suites=genq_config > ==> genq (eunit) > Compiled test/genq_config_tests.erl > .........................................................................beam.smp(10526,0xb022b000) > malloc: *** mach_vm_map(size=1140850688) failed (error code=3) > *** error: can't allocate region > *** set a breakpoint in malloc_error_break to debug > beam.smp(10526,0xb022b000) malloc: *** > mach_vm_map(size=1140850688) failed (error code=3) > *** error: can't allocate region > *** set a breakpoint in malloc_error_break to debug > beam.smp(10526,0xb022b000) malloc: *** > mach_vm_map(size=1140330496) failed (error code=3) > *** error: can't allocate region > *** set a breakpoint in malloc_error_break to debug > beam.smp(10526,0xb022b000) malloc: *** > mach_vm_map(size=1140330496) failed (error code=3) > *** error: can't allocate region > *** set a breakpoint in malloc_error_break to debug > > Crash dump was written to: erl_crash.dump > eheap_alloc: Cannot allocate 1140328500 bytes of memory (of type > "heap"). > make: *** [check-only] Abort trap: 6 > > Compilation exited abnormally with code 2 at Tue Jun 24 13:22:43 > > /Fredrik > http://whosawesome.com/ > > > > > _______________________________________________ > erlang-bugs mailing list > [email protected] > http://erlang.org/mailman/listinfo/erlang-bugs _______________________________________________ erlang-bugs mailing list [email protected] http://erlang.org/mailman/listinfo/erlang-bugs