Importing users from jabberd

Hi everyone!

We have a Jabberd Version: 1.4.3-3 installed in Ubuntu 8.04 box and we are migrating to ejabberd Version: 2.0.1-2~hardy1 over a similar box.

The issues appears when importing the two thousands users to the new ejabberd server.

after installing the server, using dpkg-reconfigure, the node and admin user are created succefully such that we can access the admin web interface without problems.

Following the instructions found on
http://www.ejabberd.im/jabberd1-to-ejabberd

we exectute ejabberdctl --node ejabberd@server import-dir PATH_TO_SPOOL_directory_of_the_jabberd_server

after that, things start ok but when reaching 600 aprox users imported, the server crashes saying: RPC failed: nodedown

and when trying to start the server

ejabberdctl start
RPC failed on the node ejabberd@server: {'EXIT',
{badarg,
[{ets,
lookup,
[hooks,
{ejabberd_ctl_process,global}]},
{ejabberd_hooks,run_fold,4},
{ejabberd_ctl,process,1},
{rpc,'-handle_call/3-fun-0-',5}]}}

The above only can be solved by reinstalling and purging all the conf files.
We changed the log level to debug and the following appears during the import process:

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:ejabberd_sm:372) : session manager
from {jid,"marianela",
"jabber.mydomain",
"Just another jabber client",
"marianela",
"jabber.mydomain",
"Just another jabber client"}
to {jid,"howard_em",
"jabber.mydomain",
[],
"howard_em",
"jabber.mydomain",
[]}
packet {xmlelement,"message",
[{"type","error"},{"to",[...]},{[...],...}],
[{xmlelement,[...],...},{xmlelement,...}]}

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:iq:register"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "storage:client:avatar"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:xdb:nslist"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:iq:register"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:xdb:nslist"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace ""

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:iq:browse"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "jabber:iq:filter"

=INFO REPORT==== 2009-05-28 15:01:12 ===
D(<0.383.0>:jd2ejd:183) : jd2ejd: Unknown namespace "storage:client:avat

the later was for every imported user.

Also, we have found that the server runs out of free kernel buffers during the import process.

Any suggestions???

Thanks in advance,
vila

Determine the problematic files, and don't import them

vila wrote:

We have a Jabberd Version: 1.4.3-3 installed in Ubuntu 8.04 box and we are migrating to ejabberd Version: 2.0.1-2~hardy1 over a similar box.

The issues appears when importing the two thousands users to the new ejabberd server.

after installing the server, using dpkg-reconfigure, the node and admin user are created succefully such that we can access the admin web interface without problems.

Following the instructions found on
http://www.ejabberd.im/jabberd1-to-ejabberd

we exectute ejabberdctl --node ejabberd@server import-dir PATH_TO_SPOOL_directory_of_the_jabberd_server

after that, things start ok but when reaching 600 aprox users imported, the server crashes saying: RPC failed: nodedown

So you have around 2000 XML files generated by jabberd-1.4.3 over the last years of life of your server. ejabberd successfully imports 612 of them, but when reaching the 613th, which may be of account marianela or of howard_em, ejabberd crashes.

Maybe some of your XML files are not XML correct, or they contain something that ejabberd is not able to read and crashes.

One solution is to determine which files are problematic and move them away of the automatic import. Let's imagine 1997 files can be imported successfully, and other 3 are problematic. If you could know which ones are those three files, and you know they are of people that nowadays does not use their accounts, then you can delete those files and don't care about importing them.

To determine what are the problematic files, if you find no elegant solution you can try the tricky way: split your jabberd spool dir in several subdirs with subsets of your xml files. jab1 contains from 1 to 500, jab2 contains from 501 to 1000, ...

Syndicate content