Monitoring of nodes..

Martin Bjorklund mbj@REDACTED
Wed May 17 09:15:29 CEST 2000

Pekka.Hedqvist@REDACTED wrote:
> What have I missed if I have three (3) nodes <a@REDACTED,b@REDACTED,c@REDACTED>, they
> are all "connected" with each other. Node 'a@REDACTED' does BIF calls to
> monitor_node(b@REDACTED, true) and monitor_node(c@REDACTED,true). Now node
> 'a@REDACTED' monitors both node 'b@REDACTED' and node 'c@REDACTED'. If I terminate
> node 'b@REDACTED', node 'a@REDACTED' should receive an {nodedown, b@REDACTED} message
> which it does. 
> BUT, if I then terminate the 'c@REDACTED' node I do NOT receive any
> {nodedown, c@REDACTED} message. Now, is this the correct behaviour? It's
> not what I expected anyway..?

I've tried this as well, and it seems to work just fine:

(a@REDACTED)1> nodes().
(a@REDACTED)2> erlang:monitor_node(b@REDACTED, true).
(a@REDACTED)3> erlang:monitor_node(c@REDACTED, true).

  terminating b@REDACTED

(a@REDACTED)4> flush().
Shell got {nodedown,b@REDACTED}

  terminating c@REDACTED

(a@REDACTED)5> flush().
Shell got {nodedown,c@REDACTED}

Could you post your program?


More information about the erlang-questions mailing list