shutting down a node remotely

Serge Aleynikov serge@REDACTED
Mon Jun 6 19:33:52 CEST 2005


I need to shut down a node from another node.  I know how it can be done 
with a function like:

f(Node) ->
   rpc:cast(Node, init, stop, []).

but is there a way to accomplish the same using "-remsh" or another 
erl's command-line option, like:

host> erl -remsh b@REDACTED -sname a -cookie COOKIE -s init stop

What I am getting in this case is that init:stop() gets evaluated at the 
a@REDACTED node instead of b@REDACTED

I was also thinking of something like:

erl -sname a -s rpc cast 't@REDACTED' init stop []

but the interpreter doesn't parse the last [] parameter as a list.

Serge



More information about the erlang-questions mailing list