<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">Hi!<br>
<br>
On 01/22/2013 04:38 PM, Eric Boyer wrote:<br>
</div>
<blockquote
cite="mid:CANKgVqSn6eZb_0BzLw=kkJKREOduY9qrVi8mwsAA3ni4Ktyshg@mail.gmail.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<div dir="ltr">Hi there,
<div><br>
</div>
<div style="">We're running R15B02 on Windows Server 2008 R2 on
a mainly IO bound application. Occasionally when it get busy
processing hundreds of files it will crash with the following
event log entry:</div>
<div style=""><br>
</div>
<div style="">
<div>Faulting application name: erl.exe, version: 0.0.0.0,
time stamp: 0x504492cf</div>
<div>Faulting module name: beam.smp.dll, version: 0.0.0.0,
time stamp: 0x50449201</div>
<div>Exception code: 0xc0000005</div>
<div>Fault offset: 0x00000000000c75f2</div>
<div>Faulting process id: 0x9d3c</div>
<div>Faulting application start time: 0x01cdf82413c26aeb</div>
<div><br>
</div>
<div style="">There is no erl_crash.dump generated and the
heart process does not restart the vm. Are there any ideas
as to why this is happening or what can be done so that
heart can properly restart the vm? I see the heart.exe
process active with the correct pid for the erlang process
but it doesn't seem to work in this case.</div>
<div style=""><br>
</div>
</div>
</div>
</blockquote>
Is the erl process still running? Windows has a tendency to try to
start a debugger or wait for you to meditate over if you want to
send a bug report to Microsoft or whatnot. If the process does not
really stop, heart can not detect that it's dead immediately (as it
is not dead). Then it would wait for timeout. However, after the
timeout it ought to try starting a new vm (after trying to kill the
process, which ultimately fails if Windows has set the process in
"Debugged"-mode). <br>
<br>
If you start the Erlang node in a windows command shell, you should
see what Heart tries to do. It may be that the new node cannot be
started because of a distribution name conflict, in which case your
heart-command could try to unregister the nodename from epmd prior
to restarting the node. You should also try to run erlang:halt() in
your Erlang node to verify that the heart command really works. To
force unregister on epmd, epmd has to be started with the flag
-relaxed_command_check to begin with (so it has to be started
manually before starting the erlang node), then do epmd -stop
<Nodename> before starting the new Erlang node. <br>
<br>
This looks like the VM crashing in a bad way, so it would be nice if
you could install a debugger on the system and connect it as a just
in time debugger, then mail me the stackdump or something. <br>
<br>
I usually use Windbg, which is included in the Microsoft SDK. If you
run "Windbg -I" it installs itself as a just-in-time debugger and
you could possibly get a look at erl.exe's stack at the point where
it fails. I recommend adding this in "File->Synmbol File Path":<br>
SRV*c:\SymbolCache*<a class="moz-txt-link-freetext" href="http://msdl.microsoft.com/download/symbols">http://msdl.microsoft.com/download/symbols</a>;<br>
after creating the directory c:\SymbolCache, otherwise you will get
corrupted stacks when you look into windows own code and the stacks
of Erlangs threads will often be unreadable.<br>
<blockquote
cite="mid:CANKgVqSn6eZb_0BzLw=kkJKREOduY9qrVi8mwsAA3ni4Ktyshg@mail.gmail.com"
type="cite">
<div dir="ltr">
<div style="">
<div style="">Thanks,</div>
<div style="">Eric</div>
<div style=""><br>
</div>
</div>
</div>
</blockquote>
Cheers,<br>
/Patrik<br>
<blockquote
cite="mid:CANKgVqSn6eZb_0BzLw=kkJKREOduY9qrVi8mwsAA3ni4Ktyshg@mail.gmail.com"
type="cite">
<div dir="ltr">
<div style="">
<div style="">Additional Information:</div>
<div style=""><br>
</div>
<div style="">vm.args is:</div>
<div style=""><br>
</div>
<div style="">
<div>## Name of the node</div>
<div>-name <snip></div>
<div><br>
</div>
<div>## Cookie for distributed erlang</div>
<div>-setcookie <snip></div>
</div>
<div style=""><br>
</div>
<div style="">
<div>## Heartbeat management; auto-restarts VM if it dies or
becomes unresponsive</div>
<div>## (Disabled by default..use with caution!)</div>
<div>-heart</div>
<div><br>
</div>
<div>## Enable kernel poll and a few async threads</div>
<div>+K true</div>
<div>+A 32</div>
<div>+P 1000000</div>
<div><br>
</div>
<div>## Increase number of concurrent ports/sockets</div>
<div>-env ERL_MAX_PORTS 100000</div>
<div><br>
</div>
<div>## Tweak GC to run more often</div>
<div>-env ERL_FULLSWEEP_AFTER 10</div>
<div><br>
</div>
<div><br>
</div>
<div style="">os:getenv("HEART_COMMAND") returns:</div>
<div style=""><br>
</div>
<div style="">%node_root%\bin\%node_name%.cmd start</div>
<div><br>
</div>
<div><br>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
erlang-questions mailing list
<a class="moz-txt-link-abbreviated" href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a>
<a class="moz-txt-link-freetext" href="http://erlang.org/mailman/listinfo/erlang-questions">http://erlang.org/mailman/listinfo/erlang-questions</a>
</pre>
</blockquote>
<br>
</body>
</html>