User Tools

Site Tools


internet:mail:zimbra:zimbra_migrate

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
internet:mail:zimbra:zimbra_migrate [2022/08/03 11:29]
gcooper
internet:mail:zimbra:zimbra_migrate [2023/09/20 09:42] (current)
gcooper
Line 1: Line 1:
 ====== Zimbra Migration ====== ====== Zimbra Migration ======
  
-FIXME This page is being rewritten!+**Method 1**: https://community.zextras.com/migrate-zimbra-from-one-server-to-another-server-method-1/
  
-**Zextras OSE**: https://www.zextras.com/zextras-build-based-on-zimbra-official-repository+**Method 2**: https://community.zextras.com/migrate-zimbra-from-one-server-to-another-server-method-2/
  
-**First Steps**: https://www.zextras.com/thankyou-zextras-build-zimbra/+**Method 3**: https://community.zextras.com/migrate-zimbra-from-one-server-to-another-server-method-3/
  
-**Requirements**https://www.zimbra.com/documentation/+See also **[[internet:mail:zimbra:zimbra_ose|Zimbra Collaboration Server OSE]]**
  
 **Migration Howto**: https://community.zextras.com/zimbra-migration-with-zextras-backup **Migration Howto**: https://community.zextras.com/zimbra-migration-with-zextras-backup
  
-===== Ubuntu Server =====+:!: Set the **[[internet:mail:zimbra:zimbra_max_msg_size|maximum message size]]** on the Zimbra server **before** proceeding with any inbound migration to avoid problems.
  
-**Install and update the latest supported Ubuntu Server OS** (Ubuntu 20.04 LTS as of this writing).+<note warning>Import and export of large mailboxes will cause high CPU and, especially, disk IO.  Try to perform import/export operations when users will be impacted the least.</note>
  
-<file> +===== Zextras Backup Migration =====
-apt install openssh-server net-tools wget +
-</file>+
  
-===== Install Zimbra =====+**Read this entire page first: [[https://community.zextras.com/zimbra-migration-with-zextras-backup|Migrate Using Zextras Backup]]**
  
-Get the latest Zimbra 9 OSE installer from Zextras (as root):+:!: If you are migrating from one Zimbra ZCS server to another, this is the way to go.  It is fairly simple and very effective.
  
-<file> +  * Accounts 
-cd ~ +  * CoS 
-wget download.zextras.com/zcs-9.0.0_OSE_UBUNTU20_latest-zextras.tgz +  * Mail 
-tar -xzvf zcs-9.0.0_OSE_UBUNTU20_latest-zextras.tgz +  * Calendar Items 
-</file>+  * Briefcase Items 
 +  * Drive Items 
 +  * Preferences 
 +  * Etc.
  
 +==== Overview ====
  
 +<note tip>For Zextras notifications regarding command line backup actions, see **Zimbra Admin -> Zextras -> Notifications**. </note>
  
 +<note tip>For best performance, use a fast disk as the migration backup location, rather than an NFS share. The difference can be hours instead of days!</note>
  
-:!: Set the **[[internet:mail:zimbra:zimbra_max_msg_size|maximum message size]]** on the Zimbra server **before** proceeding with any inbound migration to avoid problems.+<note tip>For best performance, use multiple accounts on your restore command to restore more than one user at a timeThe difference can be hours instead of days!</note>
  
 +  - Ensure that **Zextras Backup** is installed on **both** the source and destination servers
 +    * You can configure Zextras Backup on the destination server permanently
 +  - **Disable Zextras Backup Realtime Scanner** on both servers
 +  - **Disable scheduled SmartScans** on both servers
 +  - **Mount** the backup media on the source server
 +    * **Set permissions** to ''zimbra:zimbra''
 +    * Usually ''/opt/zimbra/backup/zextras''
 +  - Run a Zextras Backup **SmartScan** backup on the old server
 +    * Initializing Zextras Backup will run a SmartScan
 +    * May take hours
 +    * Do not run another Zextras Baackup (SmartScan) on the source server until you are ready for the final cutover
 +  - **Dismount** the backup media from the source server
 +  - **Mount** the backup media on the destination server
 +    * Use a **temporary mount point** such as ''/mnt/tmp''
 +    * **Reset the permissions** to ''zimbra:zimbra''
 +  - **Start** the restore
 +    * Use **multiple threads** for a quicker restore
 +    * May take days
 +  - **Dismount** the backup media from the destination server
 +  - **Mount** the migration backup media back on the source server
 +    * Use exactly the **same mount point** previously used
 +    * **Reset the permissions** to ''zimbra:zimbra''
 +  - When you want to do the actual migration, **stop mail flow** on port 25
 +    * **Verify** the mail has stopped flowing
 +    * Incoming mail will be delayed
 +  - Run another (final) **SmartScan** on the source server
 +    * It won't take long as it's an incremental backup
 +  - **Dismount** the migration backup media from the source server
 +  - **Mount** the migration backup media on the destination server
 +    * Use a **temporary mount point** such as ''/mnt/tmp''
 +    * **Reset the permissions** to ''zimbra:zimbra''
 +  - **Start** the restore
 +    * Use **multiple threads** for a quicker restore
 +    * This restore will be much quicker
 +    * May still take hours depending on how much mail has flowed since the first pass
 +  - **Dismount** the migration backup media from the destination server
 +  - **Enable Zextras Backup Realtime Scanner** on the destination server
 +  - **Enable scheduled SmartScans** on the destination server
  
----- 
  
-DELETEME Info below this point is old.+==== Restore ====
  
 +<file>
 +mkdir /mnt/tmp
 +chmod 777 /mnt/tmp/
 +mount -t nfs ip.of.nfs.svr:/path/to/backup /mnt/tmp/
 +chown -R zimbra:zimbra /mnt/tmp
 +su - zimbra
 +zxsuite backup doExternalRestore /mnt/tmp concurrent_accounts 5
 +</file>
  
 +==== Verify Proxy Settings ====
  
-**Zextras - Migrate to Network Edition**:+Check all domains:
  
-https://zimbra.github.io/adminguide/latest/index.html#MIG-88-incremental-migration-with-backup-from-old-to-88+<file> 
 +for dom in $(zmprov gad); do zmprov gd $dom zimbraPublicServiceProtocol zimbraPublicServiceHostname zimbraPublicServicePort; done 
 +</file>
  
-**Zextras - Migrate to OSE**+Modify all domains:
  
-https://wiki.zextras.com/wiki/ZxBackup:_Incremental_migration_with_ZeXtras_Backup+<file> 
 +for dom in $(zmprov gad); do zmprov md $dom zimbraPublicServiceProtocol https zimbraPublicServiceHostname zimbra.yourdomain.tld zimbraPublicServicePort 443; done 
 +</file>
  
-<note warning>Import and export of large mailboxes will cause high CPU and, especially, disk IO Try to perform import/export operations when users will be impacted the least.</note>+ 
 +---- 
 + 
 +---- 
 + 
 +DELETEME Info below this point is old.
  
 ===== CLI ===== ===== CLI =====
Line 171: Line 230:
  
 ==== Import ==== ==== Import ====
 +
 +<note tip>The ''resolve='' parameter has several options:
 +
 +  * ''skip'' ignores duplicates of old items, it’s also the default conflict-resolution.
 +  * ''modify'' changes old items.
 +  * ''reset'' will delete the old subfolder (or entire mailbox if /).
 +  * ''replace'' will delete and re-enter items
 +
 +:!: ''Reset'' will be a bit faster on an empty destination mailbox because it skips most dupe checks.</note> 
 +
 +
 +<note tip>If you get a timeout error, try changing this setting:
 +
 +<file>
 +zmlocalconfig socket_so_timeout
 +zmlocalconfig -e socket_so_timeout=3000000
 +
 +# change it back when you complete the import(s)
 +zmlocalconfig -e socket_so_timeout=30000
 +zmlocalconfig --reload
 +</file></note>
  
 === Merge with Existing === === Merge with Existing ===
Line 198: Line 278:
 See also **[[internet:mail:moving_to_new_mailserver#imap_to_zimbra_example|Migrating to a New Mail Server]]** See also **[[internet:mail:moving_to_new_mailserver#imap_to_zimbra_example|Migrating to a New Mail Server]]**
  
-===== Zextras Migration ===== 
  
-**Read this entire page first: [[https://docs.zextras.com/zextras-suite-documentation/latest/backup.html#_incremental_migration_with_zextras_backup|Migrate Using Zextras Backup]]** 
  
-:!: If you are migrating from one Zimbra ZCS server to another, this is the way to go.  It is fairly simple and very effective. 
- 
-  * Accounts 
-  * CoS 
-  * Mail 
-  * Calendar Items 
-  * Briefcase Items 
-  * Drive Items 
-  * Preferences 
-  * Etc. 
- 
-==== Overview ==== 
- 
-<note tip>For best performance, use a fast disk as the migration backup location, rather than an NFS share. The difference can be hours instead of days!</note> 
- 
-<note tip>For best performance, use multiple threads on your restore command to restore more than one user at a time. The difference can be hours instead of days!</note> 
- 
-  - Ensure that **Zextras Backup** is installed on **both** the source and destination servers 
-    * You can configure Zextras Backup on the destination server permanently 
-  - **Disable Zextras Backup Realtime Scanner** on both servers 
-  - **Disable scheduled SmartScans** on both servers 
-  - **Mount** the backup media on the source server 
-    * **Set permissions** to ''zimbra:zimbra'' 
-    * Usually ''/opt/zimbra/backup/zextras'' 
-  - Run a Zextras Backup **SmartScan** backup on the old server 
-    * Initializing Zextras Backup will run a SmartScan 
-    * May take hours 
-    * Do not run another Zextras Baackup (SmartScan) on the source server until you are ready for the final cutover 
-  - **Dismount** the backup media from the source server 
-  - **Mount** the backup media on the destination server 
-    * Use a **temporary mount point** such as ''/mnt/tmp'' 
-    * **Reset the permissions** to ''zimbra:zimbra'' 
-  - **Start** the restore 
-    * Use **multiple threads** for a quicker restore 
-    * May take days 
-  - **Dismount** the backup media from the destination server 
-  - **Mount** the migration backup media back on the source server 
-    * Use exactly the **same mount point** previously used 
-    * **Reset the permissions** to ''zimbra:zimbra'' 
-  - When you want to do the actual migration, **stop mail flow** on port 25 
-    * **Verify** the mail has stopped flowing 
-    * Incoming mail will be delayed 
-  - Run another (final) **SmartScan** on the source server 
-    * It won't take long as it's an incremental backup 
-  - **Dismount** the migration backup media from the source server 
-  - **Mount** the migration backup media on the destination server 
-    * Use a **temporary mount point** such as ''/mnt/tmp'' 
-    * **Reset the permissions** to ''zimbra:zimbra'' 
-  - **Start** the restore 
-    * Use **multiple threads** for a quicker restore 
-    * This restore will be much quicker 
-    * May still take hours depending on how much mail has flowed since the first pass 
-  - **Dismount** the migration backup media from the destination server 
-  - **Enable Zextras Backup Realtime Scanner** on the destination server 
-  - **Enable scheduled SmartScans** on the destination server 
  
 ===== Migrate a Domain Off Your Server ===== ===== Migrate a Domain Off Your Server =====
internet/mail/zimbra/zimbra_migrate.1659547759.txt.gz · Last modified: 2022/08/03 11:29 by gcooper