13.3 Node Connections
The nodes in a distributed Erlang system are loosely connected. The first time the name of another node is used, for example, if spawn(Node,M,F,A) or net_adm:ping(Node) is called, a connection attempt to that node is made.
Connections are by default transitive. If a node A connects to node B, and node B has a connection to node C, then node A also tries to connect to node C. This feature can be turned off by using the command-line flag -connect_all false, see the erl(1) manual page in ERTS.
If a node goes down, all connections to that node are removed. Calling erlang:disconnect_node(Node) forces disconnection of a node.
The list of (visible) nodes currently connected to is returned by nodes().