Problems migrating ejabberd database to another server
Such simple task, like moving ejabberd from one server to another, costs me about one hour of time. Moving procedure very good described here, and everything goes smoothly, untill i get following error:
RPC failed on the node restore: nodedown
I have read a lot of docs, blogs, etc. There was some references regarding ejabberdctl tuning on FreeBSD, but unfortunately without any details. And i have found solution myself.
ejabberdctl under FreeBSD should run under user ejabberd.
For me it was looks like that:
su ejabberd -c "/usr/local/bin/ejabberdctl ejabberd@jabber restore /tmp/ejabberd2.backup"
Seems like ejabberdctl wants read .erlang.cookie file. That file created every time when ejabberd starts. And that file placed in /var/spool/ejabberd/ directory, home directory of user ejabberd.
Thats all.
# su ejabberd -c "/usr/local/bin/ejabberdctl ejabberd@jabber status"
Node ejabberd@jabber is started. Status: started
ejabberd is running
Next I’m going to implement shared roster.