I've found that both openfire server and mysql uses about 50% of my server memory(1G)

as title described, OPENFIRE server uses about 250M memory , and the mysql server on the same machine uses almost the same count.

totally about half of the server memory.

So Now I want to migrate my openfire server to another centos, and mysql server to another too.

I found that openfire maybe use the root right to create tables?

Could I use the dumped sql scripts to copy mysql to another ?

If so , would I set up a openfire server again ? or simply use the old data?

Thanks very much .

As always, make sure that you have proper backups in place before you change anything.

I think that this would work:

  1. Migrate the database with the backup/restore tools provided by the vendor of your database (eg: mysqldump). Ensure that the database is fully and correctly restored on the new server.
  2. Re-install Openfire on the new server (make sure that you configure it to point at the new database).
  3. Copy the openfire/resources directory from your original Openfire (this is where your certificate stores are)
  4. Copy all plugins that you want to keep

I advice you to shut down (but not delete) your old Openfire AND database, before you verify that everything is back up and running. This ensures that you’re not accidentally using the old stuff.