Mail Migration (*administrator only)
You can migrate emails from external sources (e.g., Gmail or on-premises mail servers) to Synology MailPlus Server for centralized management.
Task Setup
At Server Management > Mail Migration > Create, you can create a mail migration task. See the following sections to learn how to set up a task.
To define general task settings:
Go to General to specify basic task information:
- Task: Customize a task name.
- Select the server type: Select from external mail providers like Gmail, or self-owned mail servers like Microsoft Exchange.
- G Suite: Migrate via Gmail API.
- Please refer to this article to create a G Suite service key.
- After obtaining the service key, please click the folder icon next to the G Suite service key field to upload the .JSON key file.
- Other server types: Migrate via IMAP protocol.
- Server address: Specify the source server IP address or domain name.
- Port: Specify the source server port.
- Enable secure connection (SSL): Tick the checkbox to migrate emails over SSL connection.
- IMAP path prefix: Specify the IMAP path prefix (a prefix common to all folders, usually used as the IMAP namespace for the folder names) depending on the source server type:
- On-premises IMAP servers and Microsoft Exchange servers: Go to the server settings to find out this information.
- Third-party email services: Gmail and Yahoo Mail have a blank IMAP path prefix; for other services, enter
INBOX
(commonly used) or consult the relevant documentation for details.
- Migrate mail with the delegate account (for Microsoft Exchange): Tick the checkbox to specify a delegate account that has full access permissions of all other source accounts. With the delegate account, you can migrate emails without the access permissions of each source account.
- Accounts to migrate per time period: Define how many source accounts will be migrated per work session.
- Schedule email migration: Set a schedule for the task to avoid heavy traffic time.
Note:
- The task name cannot be specified as ".." or ".".
- The task name cannot contain any of the following characters: / \ : "
- To send success or failure notifications, make sure Enable SMTP is ticked (at Service > Protocol > SMTP).
- If you provide an IP address for Server Address, success or failure notifications may not be sent.
- When the source mail server is Gmail/G Suite or Yahoo!, consider additional requirements below:
- Gmail/G Suite: All accounts to migrate should turn on Less secure app access (see here) or have an App password (see here).
- Yahoo!: All accounts to migrate should have app passwords (see here).
To set up email and mailbox filters:
Go to Filter and specify which email messages and mailboxes to migrate:
- Discard mail received before the date and Discard mail received after the date: Discard emails received before or after the specified date during migration. Emails received on the specified date will not be discarded.
- Skip trash mail and Skip spam mail: Skip mailboxes that carry the "\Trash" or "\Junk" attribute as defined in RFC6154.
- Maximum size per email (KB): Tick the checkbox to specify the maximum size of a migrated email.
- Enable mailbox filter: Tick the checkbox to decide which mailbox to skip or migrate by keyword:
- Filter policy: Select Skip mailboxes by keyword or Migrate mailboxes by keyword.
- Set Keywords: Click to fine-tune filter policies through the two sections:
- Keyword: Add keywords here to process mailboxes that match the filter policy.
- Exceptions: Add keywords here so that matched mailboxes will not be processed according to the filter policy.
Note:
- You can set a regular expression as a filter. You should add a slash (/) before and after the regular expression (e.g., /^RegExp$/).
To receive migration notifications:
Go to Notification to set up the notification service to know each account's migration result.
- Send success notification: Tick the checkbox to receive notifications when each account's mail migration completes. You can further decide where the notification should go to.
- Send failure notification: Tick the checkbox to receive notifications when each account's mail migration fails. You can further decide where the notification should go to.
To import the user list:
First, prepare a user list following the requirements below:
- The user list should be a .CSV file. It can be generated with Microsoft Excel or Google spreadsheets.
- List one user account information in one row.
- List each user's following information from left to right: the source account, the source account password, and the corresponding Synology MailPlus Server account.
- Separate each type of information with a comma (,).
- When the source server type is set to Microsoft Exchange and Migrate mail with the delegate account is enabled, you can omit the source account passwords (e.g., source_account_X,,MailPlus_Server_account_X).
For example, if a user with a source account name "John" wants to migrate his emails to Synology MailPlus Server, and his account name of MailPlus Server is "John_new", he should type "John", the password for the source account, and "John_new" into grids one by one from left to right.
Then, you should have a valid user list like this:
John,John's source account password,John_new |
Ann,Ann's source account password,Ann_new |
Andrew,Andrew's source account password,Andrew_new |
... |
source_account_N,source_account_N_password,MailPlus_Server_account_N |
Last, go to User List to import the user list and have it checked:
- Import: Click to import a user list that specifies source accounts, source account passwords, and corresponding Synology MailPlus Server accounts.
- Delete: Click to delete unwanted user data.
- Check: Click to check if all imported source accounts are correct and if all corresponding Synology MailPlus Server accounts are enabled.
Note:
- A source account or a corresponding Synology MailPlus Server account cannot contain the ":" character.
Task Management
After a mail migration task is fully set up, you can manage it and view its status.
To view task status:
To view the task status, go to Server Management > Mail Migration. To see task summary and logs, click Information (the document icon).
To run a task:
- Go to Server Management > Mail Migration.
- Select a task and click Start.
Note:
- To avoid migration errors, do not do either of the following during mail migration:
- Changing the IMAP/POP3 settings on Synology MailPlus Server
- Moving or deleting emails on the source mail server