[erlang-bugs] heart prevents beam from creating crash dumps

PAILLEAU Eric eric.pailleau@REDACTED
Mon Aug 27 21:43:14 CEST 2012


Hi,
some thoughs :

as far 'heart' is child of erl, getppid() is not equal to 1 until the
parent process exits.

we can imagine that the crashdump is created by 'erl' process as
crashdump.{pid} before to be renamed to final name by 'heart' process .

'heart' process is able to see that crashdump.{pid} is increasing in
size while its parent is not 1 .

if its parent becomes 1 , the 'heart' process renames itself the file to
final name before restarting the erl command.

If the size does not change for the HEART_BEAT_TIMEOUT timeout while
parent is not 1, maybe the parent is a zombi. 'heart' kill SIGKILL its
parent and restart the erl process.

imply that the delay of restart can be twice the HEART_BEAT_TIMEOUT in
case of a zombi parent,
or any time otherwise (the time the crashdump is created).
this is not maybe what it is expected by lot of people.

in such case a  -safeheart option could be created for this...

I don't know if such behaviour can be done on Windows ?

regards






More information about the erlang-bugs mailing list