Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to listen to IPv4 only #3

Open
func0der opened this issue Oct 6, 2020 · 1 comment
Open

Option to listen to IPv4 only #3

func0der opened this issue Oct 6, 2020 · 1 comment

Comments

@func0der
Copy link

func0der commented Oct 6, 2020

I am trying to setup epmd to listen to only ONE local IPv4.
No binding to 0.0.0.0 or :::.

$ ERL_EPMD_ADDRESS=10.40.95.10 epmd -d
epmd: Tue Oct  6 21:38:18 2020: epmd running - daemon = 0
epmd: Tue Oct  6 21:38:18 2020: failed to bind on ipaddr 0.0.0.0: Cannot assign requested address

It tries to listen to ::1, too, as an strace shows.
I think this is either a bug or needs a -4 parameter to only listen to IPv4 addresses.

For context: I am trying to setup rabbitmq. Not 100% sure, if this is the correct epmd.

@nh2
Copy link

nh2 commented Jul 15, 2021

https://github.com/erlang/epmd/blame/c27e1e3d37f9bb7f657782be5809b78a58b98b4d/README.md#L43

Note: $ERL_EPMD_ADDRESS and address is not yet implemented.

I suspect you'd have to change these lines:

epmd/src/epmd.erl

Lines 106 to 108 in c27e1e3

get_address() ->
Addr = "0.0.0.0",
Addr.

to read it from an env var like these lines:

epmd/src/epmd.erl

Lines 110 to 111 in c27e1e3

get_port() ->
application:get_env(epmd, port, ?EPMD_DEFAULT_PORT).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants