[ejabberd] Migrating from another server with just the database spool dir

Zhan Caibao zhancaibao at gmail.com
Tue Feb 3 04:55:21 MSK 2009


You can't use ejabberdctl stop and ejabberdctl status continues to tell me
"nodedown" for ejabberdctl can't connect to the node/hostname. Mayber you
could add info to hosts file.

2009/2/3 Jehan Pagès <jehan.marmottard at gmail.com>

> Hi,
>
> I have migrated my server with ejabberd installed to another. For
> information, it was a 2.0.1, and I am reinstalling a 2.0.3. Unfortunately I
> did it fastly and simply saved the "Database spool dir" (the directory
> containing all the .DCD, .DCL, etc.). Then I read this:
> http://www.ejabberd.im/migrate-host . Apparently I needed to make a binary
> backup of my old database, which I haven't done and now I have no more any
> access to the old db.
>
> I tried anymore to start it with:
> /opt/sbin/ejabberdctl start --spool /the/path/to/my/spool/dir/
>
> But it failed with this error in the log:
> ------
> =ERROR REPORT==== 2009-02-03 01:13:11 ===
> E(<0.36.0>:ejabberd_config:278) : Error reading Mnesia database spool
> files:
> The Mnesia database couldn't read the spool file for the table 'config'.
> ejabberd needs read and write access in the directory:
>    /home/ejabberd/db
> Maybe the problem is a change in the computer hostname,
> or a change in the Erlang node name, which is currently:
>    ejabberd at ks34186
> Check the ejabberd guide for details about changing the
> computer hostname or Erlang node name.
>
> =INFO REPORT==== 2009-02-03 01:13:11 ===
>     application: ejabberd
>     exited: {bad_return,{{ejabberd_app,start,[normal,[]]},
>                          {'EXIT',"Error reading Mnesia database"}}}
>     type: temporary
> ------
>
> Indeed when I open the binary file CONFIG.DCL/DCD (and many others files in
> this dir), I can see some reference to the old node name: ejabberd at ks34186.
>
> So I tried to start changing the node name:
> /opt/sbin/ejabberdctl start --spool /the/path/to/my/spool/dir/ --node
> ejabberd at ks34186
>
> Then it fails according to the:
>
> -----
> ks34186 ejabberd # /opt/sbin/ejabberdctl status
> RPC failed on the node ejabberd at ks34186: nodedown
>
> =ERROR REPORT==== 3-Feb-2009::01:50:20 ===
>
> _atom,["ejabberd at ks36767
> "]},{dist_util,recv_challenge,1},{dist_util,handshake_we_started,1}]}
> -----
>
> But in fact, the server is well started because I can connect with my
> account, get my roster, speak with others, etc. And a ps gives me a beam
> process using my spool dir as mnesia dir, etc. So all seems perfect except
> that ejabberdctl status continues to tell me "nodedown" and so I have no
> control on my server instance.
>
> For instance, I cannot stop it properly (with ejabberdctl stop). I always
> need to kill the beam process.
>
> Moreover I wanted to try the binary backup: « ejabberd_ctl ejabberd at ks36767backup /tmp/ejabberd.backup », this way I would have been able to change the
> node name, but it fails again with the same error "nodedown".
>
> As a conclusion, would anyone have a solution for me to get back a stable
> and "clean" ejabberd server? Apparently with this spool dir, I have
> everything to have a working server, so the database is full and intact.
> From this directory, I should be able to get a new and clean db, no?
> Thanks!
>
> Jehan
>
> _______________________________________________
> ejabberd mailing list
> ejabberd at jabber.ru
> http://lists.jabber.ru/mailman/listinfo/ejabberd
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.jabber.ru/pipermail/ejabberd/attachments/20090203/92f3a6b2/attachment-0001.htm>


More information about the ejabberd mailing list