I'm trying to do call from nitrogen to a separate Erlang node on the same machine (currently testing it from the Nitrogen console, but the eventual goal is to have a call from a webapp to this other node). I've got an .erlang.cookie
file set up in my home directory.
First attempt, starting the other node with erl -name node_a
, then load
ing and start
ing an application, then doing
nitrogen@127.0.0.1> rpc:call(node_a@mymachine.fully.qualified.host, ps_bc, generate, [arglist]).
gives me
{badrpc, nodedown}
in the Nitrogen console, and
=ERROR REPORT==== 9-May-2012::14:25:28 ===
** Connection attempt from disallowed node 'nitrogen@127.0.0.1' **
in the node_a
console. I assume this means that Nitrogen isn't reading the same cookie file as node_a
. Is there a way of setting its cookie manually? Is there a way of getting the two nodes to play nice without setting the same cookie for both?
The recommended place to specify the Erlang cookie is in etc/vm.args. The first line should be a -setcookie
line.
There is new documentation in the works will properly document specifying the erlang cookie. Thank you for pointing out that it was not in fact documented anywhere. In fact the new documentation will include a complete configuration settings section to help just this kind of thing. Thanks again!
The "in-the-works" documentation for configuration can currently be found at https://github.com/choptastic/nitrogen_core/blob/config-docs/doc/org-mode/config.org (please be aware, this documentation is very raw).
Edit: This is now officially documented here: http://nitrogenproject.com/doc/config.html