The following examples demonstrate how to migrate mailboxes from/to Archive Manager instance:
Table 40: Scenario: Migrating data
Operation | Command | Description |
---|---|---|
Migrating data from one Archive Manager instance to another |
$target = Attach-RMEArchiveManager -ServerName AMserver1.mycompany.corp -Port 5555 -Authentication Forms -UserName AM1admin -Password P@ssw0rd1 -ExportDirectory "C:\AMLoadDir" Attach-RMEArchiveManager -ServerName AMserver2.mycompany.corp -Port 5555 -Authentication Forms -UserName AM2admin -Password P@ssw0rd2 | Get-RMEMailbox "Administrator" | Restore-RMEMailbox -TargetFolder $target |
In the first line of this example, the Attach-RMEArchiveManager cmdlet connects to the target Archive Manager server. The -ExportDirectory parameter specifies the folder from which Archive Manager can load data (C:\AMLoadDir). In the second line of this example, the Attach-RMEArchiveManager cmdlet connects to the source Archive Manager server, and then pipes the server object to the Get-RMEMailbox cmdlet. The Get-RMEMailbox retrieves the Administrator mailbox from AMserver2, and then pipes the mailbox to the Restore-RMEMailbox cmdlet, which restores the mailbox to the Archive Manager server saved in the $target variable. |
Migrating data from the source Archive Manager server to .pst on the target Archive Manager server |
$AMSourceStorage = Attach-RMEArchiveManager -ServerName <ArchiveManagerServer name> -Port 80 -TargetDomain $AMdomain -UserName $AMUser -Password $AMPassword -Authentication Windows –LoadAllMailboxes $AMSourceStorage | Get-RMEMailbox | Restore-RMEMailbox -TargetPath "C:\Exported\PST" |
The Attach-RMEArchiveManager cmdlet connects to the source Archive Manager server. In the second line of this example, Get-RMEMailbox cmdlet retrieves all the mailboxes from the source server. Then, the Restore-RMEMailbox cmdlet restores each of the mailboxes to an individual .pst file in the specified folder on the target Archive Manager server. |
Migrating data from Archive Manager to on-premises Exchange |
$AMSourceStorage = Attach-RMEArchiveManager -ServerName <ArchiveManagerServer> -Port 80 -TargetDomain $AMdomain -UserName AMUser -Password $AMPassword -Authentication Windows –LoadAllMailboxes $AMSourceStorage | Get-RMEMailbox | % { Restore-RMEMailbox $_ -TargetFolder (Attach-RMEExchangeMailbox -ConnectionMethod Auto -MailboxName $_.DisplayName) } |
The Attach-RMEArchiveManager cmdlet connects to the source Archive Manager server. In the second line, Get-RMEMailbox cmdlet retrieves all the mailboxes from the source. Then, the Restore-RMEMailbox cmdlet restores each of the mailboxes to corresponding live Exchange Server mailbox. Attach-RMEExchangeMailbox establishes a connection to the live Exchange Server mailbox you specify. In this example, mailboxes are matched by DispalyName. |
Migrating data from Archive Manager to Office 365 |
$AMSourceStorage = Attach-RMEArchiveManager -ServerName <ArchiveManagerServer> -Port 80 -TargetDomain $AMdomain -UserName $AMUser -Password $AMPassword -Authentication Windows –LoadAllMailboxes $O365Storage = Attach-RMEExchangeOnline -MicrosoftOnlineServicesID $O365UserName -Password $O365Password -ConnectionMethod Auto $AMSourceStorage | Get-RMEMailbox | % {$O365Mailbox = $O365Storage | Get-RMEMailbox $_.DisplayName Restore-RMEMailbox $_ -TargetFolder $O365Mailbox} |
The Attach-RMEArchiveManager cmdlet connects to the source Archive Manager server. In the second line, Attach-RMEExchangeOnline connects to the target Office 365. The Get-RMEMailbox cmdlet retrieves all the mailboxes from the source. Then, the Restore-RMEMailbox cmdlet restores each of the mailboxes to corresponding Office 365 mailbox. In this example, mailboxes are matched by DispalyName. |
Migrating data from Archive Manager to Office 365 with the CSV mapping file |
$Source_To_Target_Map = Import-Csv $sourceCsvFile | ? {$_.SrcMailbox} $AMSourceStorage = Attach-RMEArchiveManager -ServerName $AMServer -Port 80 -Authentication Windows $O365Storage = Attach-RMEExchangeOnline -MicrosoftOnlineServicesID $O365UserName -Password $O365Password -ConnectionMethod Auto foreach($obj in $Source_To_Target_Map) { $AMailbox = $AMSourceStorage | Get-RMEMailbox $obj.SrcMailbox $O365Mailbox = $O365Storage | Get-RMEMailbox $obj.TrgMailbox $AMailbox | Restore-RMEMailbox -TargetFolder $O365Mailbox }
Example of CSV file: SrcMailbox,TrgMailbox “Erika.Robinson”, “E_Robinson” “Gregory.Anderson” , “G_Anderson” |
In the first line of this example, you import the specified CSV file. In the second line of this example, the Attach-RMEArchiveManager cmdlet connects to the source Archive Manager server. The Attach-RMEExchangeOnline connects to the target Office 365. Then, Get-RMEMailbox cmdlet retrieves all the mailboxes from the source and from the target. In this example, mailboxes are matched according to the specified the specified CSV file. Then, the Restore-RMEMailbox cmdlet restores each of the mailboxes to corresponding Office 365 mailbox. |
Migrating PST contents to the target Archive Manager server | (Attach-RMEPersonalFolders 'c:\ExportArchive\PST\AmeliaSpringdee.pst' -IsSource).Root | Restore-RMEFolder -TargetFolder ((Attach-RMEArchiveManager -ServerName 'ArchiveManager' -Authentication Windows -ExportDirectory "\\ArchiveManager\c$\Quest\ArchiveManager\Export" | Get-RMEMailbox 'AmeliaSpring').Root |
The Attach-RMEPersonalFolders establishes a connection to the specified .pst on the source. The Attach-RMEArchiveManager cmdlet connects to the target Archive Manager server. Then, Restore-RMEFolder restores the .pst contents to the specified target folder. |