ejabberd - Comments for "&amp;quot;Upgrade&amp;quot; from 1.1.1 on one machine to 2.0.2 on a different machine" https://www.ejabberd.im/node/3273 en Other solution to try: edit node name in ejabberdctl.cfg https://www.ejabberd.im/node/3273#comment-53774 <div class="quote-msg"> <div class="quote-author"><em>jb</em> wrote:</div> <p>I copied over all the files from the old machine's spool directory to the new machines spool directory. Next, I went in with a hex editor to each file and changed every reference to the old machine name to the new machine name.</p></div> <p>I arrived a little late, but anyway: in the config dir of 2.0.2 and newer, the file ejabberdctl.cfg allows you to define the erlang node name: "ERLANG_NODE=ejabberd@localhost". The next time that Mnesia doesn't start because the node name doesn't match, you can try setting there the old node name (you can see it in log files).</p> <p>In future ejabberd releases, when Mnesia doesn't start maybe it's clever enough to show a meaningful error message to the administrator.</p> Sun, 16 Nov 2008 19:37:00 +0000 mfoss comment 53774 at https://www.ejabberd.im "solution" https://www.ejabberd.im/node/3273#comment-53769 <p>Here was the "solution" to my particular problem. </p> <p>Since I couldn't get any kind of upgrade scenario to work, and we don't really need any of the new features of ejabberd (1.1.1 has been rock solid for two years), I just installed 1.1.1 on the new machine (along with version R10B-10 of Erlang/OTP).</p> <p>Then with the new jabber server not running, I copied over all the files from the old machine's spool directory to the new machines spool directory. Next, I went in with a hex editor to each file and changed every reference to the old machine name to the new machine name.</p> <p>That did the trick. We're back up and running.</p> <p>Thanks, badlop, for pointing me to the log files.<br /> JB</p> Fri, 14 Nov 2008 22:09:54 +0000 jb comment 53769 at https://www.ejabberd.im Narrow down issue https://www.ejabberd.im/node/3273#comment-53768 <p>So I figured I would try to narrow down where the issue is.</p> <p>I tried upgrading from 1.1.1 to 2.0.2 on the *same* machine. Didn't work; "Error reading Mnesia database".<br /> Then I tried upgrading to just 1.1.4, then 1.1.3 and then 1.1.2. No go on all three. FYI. I did uninstall the Erlang package that 1.1.1 relied on (which I believe is no longer needed from 1.1.2 on).</p> <p>sasl.log (1.1.2):<br /> error_info: {bad_return,{{ejabberd_app,start,[normal,[]]},<br /> {'EXIT',{{badmatch,{aborted,{no_exists,config}}},<br /> [{ejabberd_config,set_opts,1},<br /> {ejabberd_app,start,2},<br /> {application_master,start_it_old,4}]}}}}</p> <p>So I can't even upgrade from 1.1.1 to 1.1.2 on the same machine. I'll do some searching around.</p> <p>Thanks,<br /> JB</p> Fri, 14 Nov 2008 14:55:32 +0000 jb comment 53768 at https://www.ejabberd.im Updated host name in Mnesia files https://www.ejabberd.im/node/3273#comment-53759 <p>I manually went through all the DCL/DCD/DAT/etc. files and updated the host name to the new machine's name.</p> <p>I don't see the "Error reading Mnesia database" now. However, I'm still getting a "bad_return".</p> <p>=CRASH REPORT==== 12-Nov-2008::08:57:25 ===<br /> crasher:<br /> pid: &lt;0.35.0&gt;<br /> registered_name: []<br /> exception exit: {bad_return,<br /> {{ejabberd_app,start,[normal,[]]},<br /> {'EXIT',<br /> {aborted,<br /> {node_not_running,ejabberd@localhost}}}}}<br /> in function application_master:init/4<br /> initial call: application_master:init(&lt;0.5.0&gt;,&lt;0.34.0&gt;,<br /> ...</p> Fri, 14 Nov 2008 13:45:19 +0000 jb comment 53759 at https://www.ejabberd.im Crash... https://www.ejabberd.im/node/3273#comment-53736 <p>Thanks for the reply.</p> <p>sas.log is showing a crash report upon reading the Mnesia database. </p> <p>Is 1.1.1 and 2.0.2 possibly too different in this regard? I'm pulling the DCL/DCD/DAT/etc. files over from a working 1.1.1 install. I also tried stopping the 1.1.1 service and then moving the database files, but I got the same result.</p> <p>=CRASH REPORT==== 10-Nov-2008::11:17:41 ===<br /> crasher:<br /> pid: &lt;0.35.0&gt;<br /> registered_name: []<br /> exception exit: {bad_return,{{ejabberd_app,start,[normal,[]]},<br /> {'EXIT',"Error reading Mnesia database"}}}<br /> in function application_master:init/4<br /> initial call: application_master:init(&lt;0.5.0&gt;,&lt;0.34.0&gt;,<br /> {appl_data,ejabberd,<br /> [ejabberd,ejabberd_sup,<br /> ejabberd_auth,ejabberd_router,<br /> ejabberd_sm,ejabberd_s2s,<br /> ejabberd_local,ejabberd_listeners,<br /> ejabberd_iq_sup,<br /> ejabberd_service_sup,<br /> ejabberd_s2s_out_sup,<br /> ejabberd_s2s_in_sup,<br /> ejabberd_c2s_sup,<br /> ejabberd_mod_roster,<br /> ejabberd_mod_echo,<br /> ejabberd_mod_pubsub,<br /> ejabberd_mod_irc,ejabberd_mod_muc,<br /> ejabberd_offline,random_generator],<br /> undefined,<br /> {ejabberd_app,[]},<br /> [acl,adhoc,configure,<br /> cyrsasl_anonymous,cyrsasl,<br /> cyrsasl_digest,cyrsasl_plain,<br /> ejabberd_admin,ejabberd_app,<br /> ejabberd_auth_anonymous,<br /> ejabberd_auth,<br /> ejabberd_auth_external,<br /> ejabberd_auth_internal,<br /> ejabberd_auth_ldap,<br /> ejabberd_auth_odbc,<br /> ejabberd_auth_pam,ejabberd,<br /> ejabberd_c2s,ejabberd_c2s_config,<br /> ejabberd_config,ejabberd_ctl,<br /> ejabberd_frontend_socket,<br /> ejabberd_hooks,ejabberd_http,<br /> ejabberd_http_bind,<br /> ejabberd_http_poll,<br /> ejabberd_listener,ejabberd_local,<br /> ejabberd_logger_h,<br /> ejabberd_loglevel,<br /> ejabberd_node_groups,<br /> ejabberd_rdbms,ejabberd_receiver,<br /> ejabberd_router,ejabberd_s2s,<br /> ejabberd_s2s_in,ejabberd_s2s_out,<br /> ejabberd_service,ejabberd_sm,<br /> ejabberd_socket,ejabberd_sup,<br /> ejabberd_system_monitor,<br /> ejabberd_tmp_sup,ejabberd_update,<br /> ejabberd_web_admin,ejabberd_web,<br /> ejabberd_zlib,ejd2odbc,eldap,<br /> eldap_filter,eldap_pool,<br /> eldap_utils,'ELDAPv3',extauth,<br /> gen_iq_handler,gen_mod,<br /> gen_pubsub_node,<br /> gen_pubsub_nodetree,iconv,idna,<br /> jd2ejd,jlib,mod_adhoc,<br /> mod_announce,mod_caps,<br /> mod_configure2,mod_configure,<br /> mod_disco,mod_echo,mod_http_bind,<br /> mod_http_fileserver,mod_irc,<br /> mod_irc_connection,mod_last,<br /> mod_last_odbc,mod_muc,mod_muc_log,<br /> mod_muc_room,mod_offline,<br /> mod_offline_odbc,mod_privacy,<br /> mod_privacy_odbc,mod_private,<br /> mod_private_odbc,mod_proxy65,<br /> mod_proxy65_lib,<br /> mod_proxy65_service,<br /> mod_proxy65_sm,mod_proxy65_stream,<br /> mod_pubsub,mod_register,<br /> mod_roster,mod_roster_odbc,<br /> mod_service_log,mod_shared_roster,<br /> mod_stats,mod_time,mod_vcard,<br /> mod_vcard_ldap,mod_vcard_odbc,<br /> mod_version,node_buddy,node_club,<br /> node_default,node_dispatch,<br /> node_pep,node_private,node_public,<br /> nodetree_default,nodetree_virtual,<br /> p1_fsm,p1_mnesia,<br /> ram_file_io_server,randoms,sha,<br /> shaper,stringprep,stringprep_sup,<br /> tls,translate,xml,xml_stream,<br /> 'XmppAddr'],<br /> [],infinity,infinity},<br /> normal)<br /> ancestors: [&lt;0.34.0&gt;]<br /> messages: [{'EXIT',&lt;0.36.0&gt;,normal}]<br /> links: [&lt;0.34.0&gt;,&lt;0.5.0&gt;]<br /> dictionary: []<br /> trap_exit: true<br /> status: running<br /> heap_size: 987<br /> stack_size: 23<br /> reductions: 160<br /> neighbours:</p> Mon, 10 Nov 2008 22:39:47 +0000 jb comment 53736 at https://www.ejabberd.im Database not read, or admin privileges not granted https://www.ejabberd.im/node/3273#comment-53731 <p>The problem can be that either</p> <ul> <li>The database is not read correctly, so you don't have any accounts. You can verify that easily: can Jabber clients login to the accounts, or do they need to create the accounts? </li><li>If the database was read correctly, and the users that were admins can login using Jabber, then the problem may be that those accounts do not have 'admin' privilege. To grant admin privilege to a Jabber account you need to specify in ejabberd.cfg. Check the ejabberd Guide. </li></ul> <p>In all cases you should look at ejabberd.log and sasl.log because maybe there is some error message that points to the problem.</p> Mon, 10 Nov 2008 10:49:57 +0000 mfoss comment 53731 at https://www.ejabberd.im