1

Topic: Suggestion: Database migration script

==== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Manage mail accounts with iRedAdmin-Pro?
- Related log if you're reporting an issue:
====

Hello Zhang!

I followed yesterday your migration guide at http://www.iredmail.org/docs/migrate.to … erver.html
Thanks for that good documentation, it helped a lot! smile

I the section which describes the database migration, I had some troubles.
I was migrating from iRedMail 0.9.3 (MySQL 5.1 on Debian 7) to 0.9.6 (MySQL 5.7 on Ubuntu 16.04) and this involved some fiddeling and manual work with SQL dumps to

- remove duplicates (postmaster account)
- adjust SQL dumps to allow proper import (amavisd -> policy missed "other_quarantine_to" field so adding and removing field like you described with others was required)

This was my third iRedMail migration since I use your product and it gets easier every time smile

Suggestion: It would be great to have a script which does an automatic migration of the database from an old server to a new one.
Basically all steps you describe in your migration guide can be automated. In addition, this would allow the settings to be kept or converted in a new format (in the past I had issues with lost greylisting settings due to policyd -> cluebringer -> iredapd migration)

In particular for iRedMail 1.0 I have seen changes to vmail table and this would really help a lot to have a script which does that work.

During a migration there is still a ton of other manual work to do (SSL certificates, docecot, postfix, webserver settings etc..)
But as you have noted several times: Migration is always the best and supported way to update iRedMail to the latest release.

Best regards,
Bernhard

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Suggestion: Database migration script

Thanks for the feedback. It would be great if you can help make it happen. was too busy working on iRedMail cluster and iRedAdmin-Pro, also migrating iRedMail installer to Ansible.