-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Conf option to have an end to end ipv6 otp release #602
base: maint
Are you sure you want to change the base?
Conversation
The problem this pull request solves is when you want to run Erlang in a full IPV6 environment, with ipv6 nodes communicating through ipv6 sockets with EPMD :
I am using this patch in production since Erlang R14 : running some of my company erlang applications and many riak nodes in an ipv6 only environment and it works well. So I though maybe this option can be useful to other users. |
c36eb2e
to
cf835a5
Compare
Patch has passed first testings and has been assigned to be reviewed I am a script, I am not human |
1 similar comment
Patch has passed first testings and has been assigned to be reviewed I am a script, I am not human |
I ping you again about this since I continue to need this change, do you think there is an issue with this request ? |
We will consider this patch for 18.1 |
18.1 has been released and still no ipv6 :) Do you have any idea if there is any problem in this PR / feature ? Do you plan to propose this feature otherwise ? |
There are several related PR/patches in this area. We are working on evaluating them, and we passed an IPV6 patch related to the distribution just recently. At the moment we have asked if this patch could be rebased and if so we think that yours need to be rebased upon it afterwards. |
Patch has passed first testings and has been assigned to be reviewed I am a script, I am not human |
PR 864 is now on its way to be accepted, and then we hopefully can get somewhere with this PR and PR 708. |
Very good news, thank you for the update. Ipv6 is critical in our use. If you need feedback of using it with otp, I am available.(many production apps in my company using full ipv6 erlang with this patch) |
I have now merged PR 864, should be visible soon at github. When it is please consider the consequences for this PR and maybe rebase it. Also the following diff that is now being tested and hopefully merged tomorrow as an improvment
|
OK actually the ipv6 registration part has collisions between the two PR, I am looking into it |
OK currently I am not seeing it on github, neither in maint , maint-18, master... please tell me if I am wrong be it seems that the commit is not currently visible. I will look for it again tomorrow |
It should be here now. |
- add support for ipv6 connections to Epmd (removed from PR because added into commit 75bc5be with the merge of PR-864/OTP-13364) - add a macro to define the default epmd ip: "::1" or "127.0.0.1" - add a macro to define the default proto_dist: inet_tcp or inet6_tcp - add a configure option to compile the whole otp in ipv6 default mode The option --enable-epmd-ipv6 configures: - the -DEPMD6 CFLAG for epmd compilation - the default proto_dist (without init arg) to "inet6_tcp" - the epmd connection ip to "::1"
f6d5adc
to
f53fc31
Compare
OK actually the PR 864 covers exactly the same feature exactly the same way (except with an added check of So there will be no conflict, even with the diff you quoted. |
Thank you for the quick update. This change however is to late for 18.3 code freeze. Code that changes configure has an earlier freeze than other less sensitive code. Also there has come up some questions about if configure is the way to go or should it be solved by runtime options or environment variables instead. We will have to come back to this. |
Patch has passed first testings and has been assigned to be reviewed I am a script, I am not human |
Any updates on this? Some projects and environments increasingly dictate IPv6 connectivity as a must and Erlang software effectively cannot comply if |
A general principle we have is that we don't use conditional builds of Erlang code. (only debug, test can be conditional) Erlang can be started with |
By the way I think I was wrong when I stated that EPMD can not support both IPv4 and IPv6 at the same time. It can do that. |
Hi, The bug is the follow:
Even the Is there something we can do to help on this issue, to get merged this PR? (that should solve the problem:) ) Thank you |
Looked inside this issue and I have seen that: gabriele@linux-cnyy:~/otp-OTP-21.3.3> bin/erl -sname hello -proto_dist inet6_tcp
Erlang/OTP 21 [erts-10.3.2] [source] [64-bit] [smp:1:1] [ds:1:1:10] [async-threads:1] [hipe]
Eshell V10.3.2 (abort with ^G)
(hello@linux-cnyy)1> net_adm:names(localhost).
{error,address}
%% staring trace
(hello@linux-cnyy)6> net_adm:names(localhost).
(<0.89.0>) call inet_db:res_option(inet6)
(<0.89.0>) call inet_db:res_optname(inet6)
(<0.89.0>) returned from inet_db:res_optname/1 -> res_inet6
(<0.89.0>) call inet_db:db_get(res_inet6)
(<0.89.0>) returned from inet_db:db_get/1 -> false
(<0.89.0>) returned from inet_db:res_option/1 -> false
(<0.89.0>) call inet_db:res_option(lookup)
(<0.89.0>) call inet_db:res_optname(lookup)
(<0.89.0>) returned from inet_db:res_optname/1 -> res_lookup
(<0.89.0>) call inet_db:db_get(res_lookup)
(<0.89.0>) returned from inet_db:db_get/1 -> [native]
(<0.89.0>) returned from inet_db:res_option/1 -> [native]
(<0.89.0>) call inet_db:register_socket(#Port<0.11>,inet_tcp)
(<0.89.0>) returned from inet_db:register_socket/2 -> true
{error,address}
(hello@linux-cnyy)7> The (<0.105.0>) call erl_epmd:get_names({127,0,0,1})
(<0.105.0>) call erl_epmd:open({127,0,0,1})
(<0.105.0>) call erl_epmd:get_epmd_port()
(<0.105.0>) returned from erl_epmd:get_epmd_port/0 -> 4369
(<0.105.0>) call inet_db:register_socket(#Port<0.14>,inet_tcp)
(<0.105.0>) returned from inet_db:register_socket/2 -> true
(<0.105.0>) returned from erl_epmd:open/1 -> {error,econnrefused}
(<0.105.0>) returned from erl_epmd:get_names/1 -> {error,address} By changing (only for test of course) gethostbyname(Name) ->
gethostbyname_tm(Name, inet6, false). The (hello@linux-cnyy)7> net_adm:names(localhost).
(<0.89.0>) call erl_epmd:names(localhost)
(<0.89.0>) call inet_db:res_option(lookup)
(<0.89.0>) call inet_db:res_optname(lookup)
(<0.89.0>) returned from inet_db:res_optname/1 -> res_lookup
(<0.89.0>) call inet_db:db_get(res_lookup)
(<0.89.0>) returned from inet_db:db_get/1 -> [native]
(<0.89.0>) returned from inet_db:res_option/1 -> [native]
(<0.89.0>) call erl_epmd:get_names({0,0,0,0,0,0,0,1})
(<0.89.0>) call erl_epmd:open({0,0,0,0,0,0,0,1})
(<0.89.0>) call erl_epmd:get_epmd_port()
.......
{ok,[{"hello",46579}]} and it works. So I agree with @kennethlakin we can support both, I don't know exactly why the thank you |
|
Found this one, very helpful change. It is likely outdated, but is there any interest in reviving the PR? We experience same issues with IPv6 only servers. |
The option --enable-epmd-ipv6 configure: