[erlang-questions] some questions about epmd and inet_dist_listen_min/max

Per Melin per.melin@REDACTED
Fri Apr 22 15:22:33 CEST 2011


On Fri, Apr 22, 2011 at 5:36 AM, zhangbo <bo.zhang86@REDACTED> wrote:
> Hi
>        Could someone tell me the function of inet_dist_listen_min/max in distributed env ?
>        Another, I guess there is a  relation between epmd and ports of inet_dist_listen_min/max, if it's true, could somebody tell me the detail about the relation?

When a node is started with -name or -sname it picks a free port
between inet_dist_listen_min and inet_dist_listen_max and listens to
it for connections from other nodes. epmd keeps track of which node is
on which port on the local machine.

$ erl -sname foo -kernel inet_dist_listen_min 30000
inet_dist_listen_max 30010 -detached
$ erl -sname bar -kernel inet_dist_listen_min 30000
inet_dist_listen_max 30010 -detached
$ epmd -names
epmd: up and running on port 4369 with data:
name bar at port 30001
name foo at port 30000



More information about the erlang-questions mailing list