<div dir="ltr"><div><div>Hi Felix<br><br></div><div>1. after-the-@-sign part is just result of calling command 'hostname'.<br></div>2. Have you tried erl -name <a href="mailto:mynode@10.0.0.1">mynode@10.0.0.1</a> ?<br><br></div>Gleb<br><div><div class="gmail_extra"><br><div class="gmail_quote">2016-08-31 11:13 GMT+07:00 Felix Gallo <span dir="ltr"><<a href="mailto:felixgallo@gmail.com" target="_blank">felixgallo@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I would like to force my node's name to be in IPV4 format, e.g., '<a href="mailto:joe@10.0.0.1" target="_blank">joe@10.0.0.1</a>", rather than any hostname-related nameserved alternative. I would expect this to be possible, because erlang frequently operates in constrained environments and embedded environments where DNS is a luxury, etc., etc.<br><br>Reading <a href="http://erlang.org/doc/apps/erts/inet_cfg.html" target="_blank">http://erlang.org/doc/apps/<wbr>erts/inet_cfg.html</a> I get the strong impression that this is further supposed to be possible. For example, one might construct an inet_config file that looks like this:<br><br>%% erlang inetrc<br>{resolv_conf, ""}. %% do not use a resolv.conf file.<br>{file, hosts, "/dev/null"}. %% use a null hosts file. Note: "" throws weird error.<br>{hosts_file, ""}. %% further, don't keep tabs on that hosts file.<br>{cache_size, 0}. %% never care what happens with DNS caching.<br>{lookup, [file]}. %% only look up hostnames through the empty hosts file; no dns, no native.<br>clear_hosts. %% No hosts. Are we clear on this erlang? Are we?<br>clear_ns. %% No nameservers. None! You cannot look up names.<br>clear_search. %% No search domain. <br><br>and yet,<br><br>$ erl -kernel inetrc '"./erl_inetrc"' -name mynode<br>Erlang/OTP 19 [erts-8.0] [source-6dc93c1] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]<br><br><div>Eshell V8.0 (abort with ^G)<br>(<a href="mailto:mynode@spatula.att.net" target="_blank">mynode@spatula.att.net</a>)1> inet:get_rc().<br>[{domain,"<a href="http://att.net" target="_blank">att.net</a>"},<br> {resolv_conf,[]},<br> {hosts_file,[]},<br> {cache_size,0},<br> {lookup,[file]}]<br><br>note that the name of the machine ('spatula') and domain ('<a href="http://att.net" target="_blank">att.net</a>') have nevertheless been found out; and<br><br>$ erl -kernel inetrc '"./erl_inetrc"' -sname mynode<br>Erlang/OTP 19 [erts-8.0] [source-6dc93c1] [64-bit] [smp:4:4] [async-threads:10] [hipe] [kernel-poll:false]<br><br>Eshell V8.0 (abort with ^G)<br>(mynode@spatula)1> inet:get_rc().<br>[{resolv_conf,[]},<br> {hosts_file,[]},<br> {cache_size,0},<br> {lookup,[file]}]<br></div><div><br></div><div>This makes me sad. Am I missing something or is it not possible to force the after-the-@-sign part of a node's name to be simply dotted quads?</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>F.</div></font></span></div>
<br>______________________________<wbr>_________________<br>
erlang-questions mailing list<br>
<a href="mailto:erlang-questions@erlang.org">erlang-questions@erlang.org</a><br>
<a href="http://erlang.org/mailman/listinfo/erlang-questions" rel="noreferrer" target="_blank">http://erlang.org/mailman/<wbr>listinfo/erlang-questions</a><br>
<br></blockquote></div><br></div></div></div>