0

We're in the process of moving a lot of users from a cPanel-based email server (dovecot server). Since cPanel-based email server does not support email aliases, multiple user accounts were created for the same person.

So, for example, John Doe had: j.doe@contoso.com, john.doe@contoso.com and john.d@contoso.com. (Please don't ask me why they needed that many! lol)

Now, we'll be doing a mass transfer of all the email accounts from the dovecot server to Office 365/Exchange Online. So, each email will have a new account in Office 365. However, after the transfer we would like to merge all the email addresses for the same person, along with their emails, contacts and calendars, and then assign aliases.

How can this merging be achieved? (without using Outlook 2016 to copy each email account's mail box)

Andrew Schulman
  • 8,561
  • 21
  • 31
  • 47
  • You say you don't want to use Outlook but how are you planning on doing the transfer in the first place? Is there a utility or third party product that can transfer directly from the existing email server to Office 365? – joeqwerty Mar 09 '18 at 18:54
  • Like @joeqwerty says (hey Joe!). My recommendation in such a state as this would be to export all 3 mailboxes (mail, calendar, contacts) into a single PST file, create the consolidated mailbox for the user in O365, then import their PST back into their new O365 mailbox. – TheCleaner Mar 09 '18 at 19:05
  • 1
    (Hey, TheCleaner! Long time. Hope all is well!) - Additionally, you'll need to add all of the domains as verified domains in Office 365 and then you can create aliases for each user for each domain name. – joeqwerty Mar 09 '18 at 19:12
  • @joeqwerty I can bulk transfer all users emails using IMAP and then, I'll ask the users to import the contacts themselves (unless, I can bulk transfer their contacts as well) https://support.office.com/en-ie/article/migrate-other-types-of-imap-mailboxes-to-office-365-58890ccd-ce5e-4d94-be75-560a3b70a706 – Haneef Ibn Ahmad Mar 09 '18 at 19:14
  • @TheCleaner doing that for each person that has many user accounts will take a lot of time. Especially, when their mailboxes are in GBs. If this merging or consolidating could be done on the Exchange Online server itself, it'll save the load on my workstation and slow work-internet. In fact, this will save unnecessary traffic on Microsoft's Exchange Online servers as well, as consolidation will be done locally on their servers. – Haneef Ibn Ahmad Mar 09 '18 at 19:16
  • @joeqwerty yup, all domain are added separately, verified and MX records to be amended, once emails have been transferred/synced over to Exchange Online. – Haneef Ibn Ahmad Mar 09 '18 at 19:18
  • Can't you use the same method to import the additional source mailboxes into the desired target mailbox? So one import job for the primary source mailbox and another import job for the secondary source mailbox, rinse and repeat. – joeqwerty Mar 09 '18 at 19:21
  • @joeqwerty Good thought, I really hoped I would be able to do that actually! =) – Haneef Ibn Ahmad Mar 09 '18 at 19:26
  • @joeqwerty However, as shown in this example, only source 'EmailAddress' is specified. Exchange Online, automatically imports it to the same email address in the destination. https://support.office.com/en-ie/article/migrate-other-types-of-imap-mailboxes-to-office-365-58890ccd-ce5e-4d94-be75-560a3b70a706 – Haneef Ibn Ahmad Mar 09 '18 at 19:28
  • Right, but if you change the primary email address to the alias after the first import you can then import the alias mailbox into the desired target mailbox, no? It might be worth it to test it with one user. – joeqwerty Mar 09 '18 at 19:33
  • @HaneefIbnAhmad I get what you are saying, my statement was based on dealing with similar. I'm unaware of any way to do this short of using Outlook before or after the setup. Before would mean a single O365 mailbox to create. After would mean hoping the users really do move everything from mailbox 2 and 3 into 1 so you can consolidate on the back end. – TheCleaner Mar 09 '18 at 19:35
  • @joeqwerty hmm, I see. Excellent, sounds like a plan! Maybe, if I can create john.doe@contoso.com with aliases: j.doe@contoso.com and john.d@contoso.com, then put it all on the same import job! If this can be done, I'll be very happy! =) Hope Exchange Online recognises the source primary email addresses as an alias of an existing mailbox and imports it accordingly Anyone had any luck with that? (Reluctant to risk it with active users in a production environment) – Haneef Ibn Ahmad Mar 09 '18 at 19:41

1 Answers1

1

Depending on how you are doing your first migration, it might be better to just import/merge everything during that step, rather than importing to separate mailboxes and then merging them after the fact.

To answer the question: You could use several methods to copy data from each mailbox into the 'primary' one for the user:

  1. Using Search-Mailbox: Have Search-Mailbox go through the secondary mailboxes and specify the primary one as the target to copy the results to:

https://docs.microsoft.com/en-us/powershell/module/exchange/mailboxes/search-mailbox?view=exchange-ps

  1. Export the secondary mailboxes to a PST file, and then import them into the primary mailboxes:

Use the Compliance/eDiscovery search to export the data into a PST file: https://docs.microsoft.com/en-us/exchange/policy-and-compliance/ediscovery/export-results-to-pst?view=exchserver-2019

(N.B. If you're already exporting your data from your original server to PST files, you can use those.)

Then use the network upload / PST import part of the data migration facility to import that PST into the primary mailbox: https://docs.microsoft.com/en-us/office365/securitycompliance/use-network-upload-to-import-pst-files

Steltek
  • 11
  • 1