Migrating ejabberd from one ISP to another

We're about to migrate our ejabberd installation from one ISP to another because we've been unhappy with the support received from our current ISP.

From what I understand, there are two possible ways to do this:

1) The traditional way. Shut down ejabberd. Copy database over to the other ISP machine. Bring up ejabberd on the new machine.

2) The clustering way. (Is this even possible across ISPs?) Create a cluster between the two machines and cut over the DNS.

We'd like to this without any disruption to our current service, if at all possible, which is why we need to look into option 2.

Does anyone have experience doing this? What are the pitfalls?

Does anyone have a documented procedure for doing (2) smoothly?

We would appreciate any and all help we can get. Thanks in advance!

What about this procedure?

I've not tried the full procedure, but it sounds as if it can work:

  1. On newhost, install ejabberd from scratch (same version of erlang and ejabberd as on oldhost).
  2. Interconnect the two Erlang nodes. This deals mostly with cookies. Interconnecting Erlang Nodes
  3. Setup both ejabberds as required to build a cluster. This deals mostly with setting Mnesia. ejabberd Guide.
  4. Now you will have two ejabberd servers, both serving the same domain, but each one on a different host (and a different IP address, of course). Only of them has the correct DNS name. Both ejabberd nodes share the database, and changes are replicated instantly.
  5. If you want to play: how to connect to the Jabber server that does not match DNS-name with Host-name? Most Jabber clients allow you to specify the machine to connect to, additionally to the Jabber server.
  6. Modify the DNS so jabber.server.com points to the newhost, instead of the oldhost.
  7. When the clients try to connect, they will connect directly to the newhost, instead of oldhost. The clients that are already connected to oldhost will not be disconnected, or moved magically.
  8. You can wait one or two days, waiting for clients to connect to the newhost. Once there are only a few clients on oldhost, you can send them a massive message indicating that the server will be restarted. Stop oldhost forever.

Thanks!

That sounds reasonable, thanks!

AFAIR, this procedure was

AFAIR, this procedure was used on the jabber.ru server a long time ago (maybe 2 years). Try to talk to ermine or alexey as they will know more of it. You can do this via the mailing list or via the chatroom.

--
sander

Syndicate content