Zimbra to Zimbra Migration
From Zimbra :: Wiki
|- This is certified documentation and is protected for editing by Zimbra Employees & Moderators only.|
|This article applies to the following ZCS versions.|
Importing Data between Different Version of ZCS servers using the Zimbra to Zimbra Migration Tool
Use the Zimbra to Zimbra migration tool zmztozmig to import account data from one Zimbra Collaboration Server to another Zimbra Collaboration Server that is running a different version of ZCS. This tool can be used to import files from ZCS 6.0.6 or later to the latest version of ZCS.
The process of migrating accounts to a ZCS server running a later version of ZCS includes:
- Provisioning the accounts on the destination server before running zmztozmig
- Editing the zmztozmig.conf file in /opt/zimbra/conf on the source server to configure the import settings
- Running zmztozmig to import the account’s data to the destination server
When zmztozmig is used to import files, after the data is imported, the data in the accounts on the destination server are not an exact replica of the data in the accounts on the source server. And account preferences are not imported. Also, if the destination accounts do not have the same account IDs as they had on the source server, files that were shared and appointments related to the original sender might not work.
Note: Use the zmmailboxmove command to move an account between two mailbox servers with the same LDAP master.
Note: 7.1.3 includes a new zmmboxmove command that has enhanced functionality of zmmailboxmove to handle cross mailstore version migrations (but not across ldap instance like zmztozmig).
Preparing the zmztozmig.conf file
Edit the zmztozmig.conf file in /opt/zimbra/conf on the source server to configure the import settings. Account data, including email messages, attachments, contacts, calendar, tasks and briefcase folders for accounts are imported as individual account tgz tar files. Content of the Junk and Trash folders are not imported.
The following information is configured in the file:
- Login information of the source server
- Login information of the destination server
- Domain mapping from source server to destination server
- Account import details, including which accounts’ to import from and what type of information should be imported
- Record keeping information, including log directory, whether to keep the tar files after migration, directory for failed migration files
- How to resolve account import conflicts (resolve)
- Number of mailboxes to import simultaneously (thread)
- (Optional) Changes to ZimbraMailTransport that may be required
Following is a description of the parameters that are edited in the zmztozmig.conf file.
|SourceZCSServer||IP address or name of the source server.||SourceZCSServer=<source.com>|
|SourceAdminUser||ZCS administrator name for the source server.||SourceAdminUser=<sourceadmin>|
|SourceAdminPwd||ZCS administrator password for the source server.||SourceAdminPwd=<adminpswrd>|
|SourceAdminPort||Source server admin port - 7071||SourceAdminPort=<port>|
|TargetZCSServer||IP address or name of the destination server where the data is imported.||TargetZCSServer=<destination.com>|
|TargetAdminUser||ZCS administrator name for the destination server.||TargetAdminUser=<targetadmin>|
|TargetAdminPwd||ZCS administrator password for the destination server.||TargetAdminPwd=<adminpswrd>|
|TargetAdminPort||Destination server admin port- 7071.||TargetAdminPort=<port>|
|Threads|| Set the number of accounts to be imported simultaneously. The default is 1.
Set this at a low number of threads. When you start to import the data, review the source/destination ZCS server CPU usage I/O rate and write to disk per second. If the server has power to run more threads, you can edit the zmztozmig.conf file to increase the threads one at a time.
|WorkingDirectory||The directory path to where the tar’d account data files are downloaded.||WorkingDirectory=/opt/zimbra/data/zmztozmig/work|
|FailedDirectory||The directory path to where tar’d account data files are moved if the account import fails.||FailedDirectory=/opt/zimbra/data/zmztozmig/failed|
|KeepSuccessFiles|| KeepSuccessFiles is set to FALSE. The tar files are deleted after the data is imported.
If you want to keep the downloaded tar files after they are imported, set this to TRUE.
|SuccessDirectory||If you set KeepSuccessFiles to TRUE, identify the directory where tar’d account files are moved after successful imported.||SuccessDirectory=/opt/zimbra/data/zmztozmig/successes|
|LogDirectory|| A common log file, ztozlog*.log, is created for the complete import process and separate log file are created for each account data file that is imported.
Configure the directory location where log files are saved.
|DomainMap|| If accounts are being migrated from one domain to another domain, specify the source domain and destination domain.
You can create multiple DomainMap entries if the Accounts list contains accounts from different domains.
|Accounts|| Specify which account’s data should be imported. This is a comma separated list of accounts.
If data from all accounts on the source server should be imported, enter all.
The Domains parameter must be set to list the domain from which the files are being imported.
|Domains||When the Accounts parameter is set to all, identify the domains.||Domains=domain1.example.com, domain2.example.com|
|Types|| Specify the type of data that should be imported. This is a comma separated list.
To import all content, do not set any values for “types” Comment it out.
| Types=message, conversation
|Resolve|| Use Resolve to determine how to resolve conflicts between the items being imported and the items already in the destination account.
Only one value at a time can be set.
|ZimbraMailTransport|| Using ZimbraMailTransport is optional.
Include this entry if you want to change the ZimbraMailTransport to some other MTA.
Provision Accounts on the Destination Server
The accounts that will have their data imported must be provisioned on the destination server before you can import the files.
See the Zimbra Collaboration Server Administration Guide for details about provisioning accounts.
Import Account Data to the New Zimbra Server
Run the zmztozmig migration tool on the source server as zimbra.
/opt/zimbra/libexec/zmztozmig –f /opt/zimbra/conf/zmztozmig.conf
The data on the source server is zipped and imported to the destination server. If you configured KeepSuccessFiles to FALSE, the tgz file is deleted by default once the account data is imported.
A common log file, ztozlog*.log, is created for the complete process and separate log files are created for data of each account that is imported. These should be saved until the new account data has been verified.
After you verify that the account data was imported correctly, you can delete the account on the source server.
|Verified Against: ZCS 7.x, ZCS 6.0.6||Date Created: 10/10/2011|
|Article ID: http://wiki.zimbra.com/index.php?title=Zimbra_to_Zimbra_Migration||Date Modified: 01/11/2012|