erlang +R emulator flag question

Devangana Tarafdar devangana@REDACTED
Fri Sep 24 23:30:04 CEST 2010


Hello,

I had a confusion regarding the erlang emulator flag +R <ReleaseVersion> as
given in the erlang man page for "erl".

I am attempting to connect to a node that is running an older version of
erlang, from an erlang node that I know is running Release R11B. As regards
the version of the older erlang node, I am giving the results of the
commands that I ran to find the version but I am still not quite clear what
the version is.


1. Old node snapshot:

$ erl -name X -setcookie mycookie
Erlang (BEAM) emulator version 2002.03.23 [source]

Eshell V2002.03.23  (abort with ^G)
(X@REDACTED)1> erlang:system_info(version).
"2002.03.23"
(X@REDACTED)2> init:script_id().
{"OTP  APN 181 01","P9"}
(X@REDACTED)3> erlang:system_info(otp_release).

=ERROR REPORT==== 24-Sep-2010::15:51:20 ===
Error in process <0.29.0> on node 'X@REDACTED' with exit value:
{badarg,[{erlang,system_info,[otp_release]},{erl_eval,expr,3},{erl_eval,exprs,4},{shell,eval_loop,2}]}
** exited: {badarg,[{erlang,system_info,[otp_release]},
                    {erl_eval,expr,3},
                    {erl_eval,exprs,4},
                    {shell,eval_loop,2}]} **
(X@REDACTED)4>

2. Similar commands run from the new node;

erl -name X -setcookie mycookie
Erlang (BEAM) emulator version 5.5.5 [source] [async-threads:0]
[kernel-poll:false]

Eshell V5.5.5  (abort with ^G)

(X@REDACTED)2> erlang:system_info(version).
"5.5.5"
(X@REDACTED)3> erlang:system_info(otp_release).
"R11B"
(X@REDACTED)4> init:script_id().
{"OTP  APN 181 01","R11B"}

My question is as follows:
I attempted to successively  connect to the older node by using the emulator
flags +R 9, +R 8, +R 7 in turn . and  I could successfully get a "pong"
reply to the command net_adm:ping('X@REDACTED')  on the newer node in
all the 3 cases. The documentation states that "The release number must be
in the range 7..<current release>. This limits the emulator, making it
possible for it to communicate with Erlang nodes (as well as C- and Java
nodes) running that earlier release." but maybe I am missing something here.

 I am wondering which flag  to use "safely".

Any suggestions / corrections would be greatly appreciated.

Regards,
Devangana


More information about the erlang-questions mailing list