Erlang Long Node Creation

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Erlang Long Node Creation

Gattu shiva krishna
Hi all,

     In my application there is a requirement to have two erlang long
nodes with different IP addresses(I've two ethernet interfaces in my PC).

The queries I've are:

1. Is it possible to create a different erlang long node(with different
IP address) from the existing(already running) erlang node?
If so what is the best way of doing it? Since os:cmd/1 function failed
with the message "*** Terminating erlang"


Regards,
Gattu shivakrishna.





_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Erlang Long Node Creation

Oliver Korpilla
Hello, Gattu.

You could for example use the slave API. IIRC it has a few caveats like setting the code loading paths for the slave, but in principle you can start additional erlang nodes this way.

I have an example lying around here somewhere, line looked like this:

slave:start(net_adm:localhost(), name , '-pa #{string:join(code:get_path, ' -pa ') }')

Excuse any mistakes, the example was actually in elixir calling into Erlang. I hope it still provides some pointers. I just tried to adapt the syntax... not sure about correct quoting here.

Regards,
Oliver
 
 

Gesendet: Dienstag, 30. Mai 2017 um 07:52 Uhr
Von: "Gattu shiva krishna" <[hidden email]>
An: [hidden email]
Betreff: [erlang-questions] Erlang Long Node Creation
Hi all,

In my application there is a requirement to have two erlang long
nodes with different IP addresses(I've two ethernet interfaces in my PC).

The queries I've are:

1. Is it possible to create a different erlang long node(with different
IP address) from the existing(already running) erlang node?
If so what is the best way of doing it? Since os:cmd/1 function failed
with the message "*** Terminating erlang"


Regards,
Gattu shivakrishna.





_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Loading...