Cloning a 2016 version of MailCleaner to a 2019 version

MailCleaner Support
Added 2 months ago

If you have a 2016.xx version of MailCleaner (or earlier) and want to migrate it to our latest version, this is sadly not doable via the migration script we then provided. (The new underlaying version of Debian is changing from time to time and maintining this script would be a quite huge task in regard of the number of unmigrated MailCleaner hosts.

We still have a solution for you.

Install one of our VM images that you will find at

https://cdn.mailcleaner.net/downloads/vm/

Go through the configurator process as described in the text file provided with the image. Then register your MailCleaner server.

Once this is done, stop MailCleaner services on BOTH servers

//usr/mailcleaner/etc/init.d/exim_stage1 stop
/usr/mailcleaner/etc/init.d/exim_stage2 stop
/usr/mailcleaner/etc/init.d/exim_stage4 stop

then on the old server, run

wget --no-check-certificate https://www.mailcleaner.net/downloads/vm/export_tables.sh
chmod +x export_tables.sh
./export_tables.sh

This will download a script to backup the MailCleaner s configuration from MySQL into the file

/tmp/migration.tar.gz

You now have to copy this file to the new server in /tmp . Then run on the new server :

wget --no-check-certificate https://www.mailcleaner.net/downloads/vm/import_tables.sh
chmod +x import_tables.sh
./import_tables.sh

On the old server run : (make please sure you ll have enough place on this partition

tar -czf /var/mailcleaner/quarantine.tar.gz /var/mailcleaner/spool/mailscanner/quarantine
tar -czf /var/mailcleaner/spam.tar.gz /var/mailcleaner/spam

Copy those 2 files to the new server and run in the directory where you copied these .tar.gz files

tar -xzf quarantine.tar.gz -C /
tar -xzf spam.tar.gz -C /

Some features have not yet be incorported in the database and are activated with flag file
so please copy all

/var/mailcleaner/spool/mailcleaner/mc-experimental-*

from the old server to the new one

You now can restart exim with :

//usr/mailcleaner/etc/init.d/exim_stage1 start
/usr/mailcleaner/etc/init.d/exim_stage2 start
/usr/mailcleaner/etc/init.d/exim_stage4 start