ejabberd - Comments for "Move users to other virtual host" https://www.ejabberd.im/node/3868 en Quote: Hi, I have https://www.ejabberd.im/node/3868#comment-55290 <div class="quote-msg"> <div class="quote-author">Quote:</div> <p>I would like to know how switch all users from virtual host host1.domain.com to other virtual host (for example host2.mydomain.com). Is there any solution to do this ?</p></div> <p>If you have a small server (let's say around 1000 registered accounts or less) you can try this:</p> <p>1. Start ejabberd<br /> 2. Call this (or use the WebAdmin) to dump the internal Mnesia database to a text file: ejabberdctl dump /tmp/olddatabase.dump<br /> 3. Stop ejabberd<br /> 4. Copy that file to the name newdatabase.dump and edit it, or use 'sed', to replace all appearances of host1.domain.com with host2.domain.com<br /> 5. Edit your ejabberd.cfg, and make the same replacement<br /> 6. Find the Mnesia spool directory. It may be somewhere in /var/lib/ejabberd/ with files acl.DCD, ... *.DCD, *.DCL, *.DAT. Backup/copy those files. Then delete them.<br /> 7. Start ejabberd<br /> 8. Call: ejabberdctl load /tmp/newdatabase.dump<br /> 9. Check if you can login to the accounts with new jabber domain, they have the contacts updated...<br /> 10. Remember to delete or put in a secure place the files of /tmp.</p> Sat, 13 Feb 2010 10:12:00 +0000 mfoss comment 55290 at https://www.ejabberd.im