Monitoring of nodes..

Martin Bjorklund <>
Wed May 17 08:45:59 CEST 2000


Geoff Wong <> wrote:
> 
> Indeed net_kernel:monitor_nodes(true) also gives unexpected behaviour.
> 
> If we do:
> 
> net_kernel:monitor_nodes(true),
> net_adm:ping(),  % assuming this is up and responds with 'ping'
> receive X -> X end.
> 
> Then terminate  and we never get a nodedown message 
> on the node which ran net_kernel:monitor_nodes().

Note that you'll receive a nodeup message as well when you ping the
node:

()1> net_kernel:monitor_nodes(true).
ok
()2> net_adm:ping().
pong
()3> receive X -> X end.
{}
()4> receive Y -> Y end.
  
  [terminating ]

{}


If the node was already connected before thr ping, you wouldn't have
received the nodeup though.  (however, you do receive the nodedown).



/martin



More information about the erlang-questions mailing list