[erlang-questions] How to reproduce OOM.

Daniil Churikov ddosia@REDACTED
Wed Jul 15 13:18:01 CEST 2015


Recently I was searching for robust way to restart elang VM in case of
sudden
stop (like crash or OOM).
And I found rather difficult to reproduce OOM conditions: I was trying to
create
gigantic list of integers, so VM would be killed.
I did this:

L1 = [I || I <- lists:seq(1, 1000)].
L2 = [L1 || _ <- lists:seq(1, 1000)].
L3 = [L2 || _ <- lists:seq(1, 1000)]. % here VM hangs

But according to syslog it doesn't look like OOM death, I can't see usual
log
entries like "Out of memory: Kill process 3855 (beam.smp) score 909 or
sacrifice
child" and others.

My current understanding is I asked more memory then I allowed to ask, and
b/c
OS is not willing to give this memory, erlang VM hangs.

If somebody have ideas how to reproduce OOM I would appreciate for sharing.

Thanks!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150715/6563c978/attachment.htm>


More information about the erlang-questions mailing list