[erlang-questions] Distributed OTP Apps: Failover and Takeover

Andreas Pauley apauley@REDACTED
Mon Feb 11 13:31:30 CET 2013

Hi everyone,

I've made a demo app of mine distributed to test failover and
takeover, after reading the "Distributed OTP Applications" chapter in
Learn you some Erlang.

The failover and takeover works great if I kill the running beam (eg.
with kill -9).

However, I tried sending kill signals to the Pids of both my
application behavior and the top supervisor that gets started by the
This crashes the VM, but failover does not happen.

Is this unsupported, or should I do something to enable failover in
this scenario?

I've done a more complete writeup with code and output here:

But in a nutshell, I crash the VM with the commands below, and then
automatic failover to my second node does not happen:

$ ./rel/overlord/bin/overlord console
Erlang R15B03 (erts- [source] [64-bit] [smp:8:8]
[async-threads:0] [hipe] [kernel-poll:false] [dtrace]

14:03:20.581 overlord@REDACTED [overlord_app] <0.56.0> || Starting app: normal
14:03:20.582 overlord@REDACTED [hypnosponge_sup] <0.57.0> || Hello
from the hypnosponge supervisor
(overlord@REDACTED)1> Sup = pid(0, 57, 0).
(overlord@REDACTED)2> exit(Sup, kill).

=ERROR REPORT==== 11-Feb-2013::14:04:46 ===
** Generic server minion_supersup terminating
** Last message in was {'EXIT',<0.57.0>,killed}
** When Server state == {state,
** Reason for termination ==
** killed
=INFO REPORT==== 11-Feb-2013::14:04:46 ===
    application: overlord
    exited: killed
    type: permanent

(overlord@REDACTED)3> {"Kernel pid

Crash dump was written to: erl_crash.dump
Kernel pid terminated (application_controller)


More information about the erlang-questions mailing list