Active/passive S2S setup?

I’d like to have two openfire servers running at the same time (Openfire 3.6.4 on Ubuntu 9). If the primary goes down, then users will reconnect to the secondary (passive) server. I understand that without clustering, this would cause a brief outage as clients reconnect.

Questions:

  1. How do the Openfire databases stay sync’d with eachother (buddy lists, etc). I’m using mysql for that. Is this a feature that Openfire just does “automatically”?

  2. What is a recommended way to have clients directed to the secondary server (different IP) when the primary is unavailable?

Thanks