[erlang-questions] How to catch a killer?
Michal Ptaszek
michal.ptaszek@REDACTED
Fri Jul 1 08:50:09 CEST 2011
Hi Evan,
try to play with dbg:
dbg:tracer(),
dbg:p(all, call),
dbg:tp(erlang, exit, 2, []).
If you know the pid of the gen_server that is killed, you
might exchange '[]' with dbg:fun2ms and provide a pattern
that will match only on that process:
Pid = pid(X, Y, Z), %% Pid of your gen_server
dbg:tp(erlang, exit, 2, dbg:fun2ms(fun([Pid, kill]) -> ok end)).
Best regards,
Michal Ptaszek
On Jul 1, 2011, at 2:17 AM, Evan Miller wrote:
> I have gen_server that is being killed predictably but mysteriously
> (its supervisor receives a "killed" message). Are there any debugging
> tools available for figuring out who is sending the exit(kill)
> message? Tracing the process reveals nothing.
>
> The bug is probably something dumb in my code, but I'm surprised that
> a process can assassinate another process and leave behind no
> evidence. How can I catch the killer?
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
More information about the erlang-questions
mailing list