I am new the Erlang. Currently, we are using ejabberd for our xmpp service. Recently, dues to some capability issue, I have written a distributed erlange program. I need to run rpc:call between two machines. I can do the rpc:call successfully on erl simulator. But our current system was using ejabberdctl to start the ejabberd service. I have check and try to modify the ejabberdctl file. But I can't add -setcookie successfully.
the code section in ejabberdctl is
ctlexec()
{
CONN_NAME=$1; shift
COMMAND=$@
$EXEC_CMD "$ERL \
$NAME ${CONN_NAME} \
-noinput \
-hidden \
-pa $EJABBERD_EBIN_PATH \
$KERNEL_OPTS \
-s ejabberd_ctl -extra $ERLANG_NODE $COMMAND"
}
the problem caused by the last two line:
$KERNEL_OPTS \
-s ejabberd_ctl -extra $ERLANG_NODE $COMMAND"
I think this file is referenced some one's before, but I don't know where are there from. Does anybody know how can I add -setcookie abc to this erl command? If I can't change the ejabberdctl file or the worse case, I can't change the current system. i.e. I don't have a chance to add setcookie to the ejabberd system. How can I connect my new node to the existing ejabberd node(our current system).
The ejabberd suppose to start first.