In part 1 we covered the deployments steps for Exchange 2013, in Part 2 of this series we covered Exchange 2013 configurations and testing, in part 3 started our migration process. In this final post we will walk through the final steps in migration, then remove our legacy server.
This phase is very well documented online, accordingly we will walk through the steps with minimum explanations, to understand the whole processes check this Link.
Before you begin Download all four of the Microsoft Exchange 2013 public folder migration scripts.
Open Exchange 2007 Management Shell and run the following commands:
Get-PublicFolder -Recurse | Export-CliXML C:\PFMigration\Legacy_PFStructure.xml
Get-PublicFolderStatistics | Export-CliXML C:\PFMigration\Legacy_PFStatistics.xml
Get-PublicFolder -Recurse | Get-PublicFolderClientPermission | Select-Object Identity,User -ExpandProperty AccessRights | Export-CliXML C:\PFMigration\Legacy_PFPerms.xml
If the name of a public folder contains a backslash \, the public folders will be created in the parent public folder when migration occurs. You have to rename any public folders that have a backslash in the name.
To get Public folders with backslash, run the following command:
Get-PublicFolderDatabase | ForEach {Get-PublicFolderStatistics -Server $_.Server | Where {$_.Name -like "*\*"}}
Change the public folder name as shown below:
Set-PublicFolder -Identity 000000001A447390AA6611CD9BC800AA002FC45A0300D13A87259D34A142BB480F3E89AA82BF00004FD5389E0000 -name "MCS TF2"
Get-OrganizationConfig | Format-List PublicFoldersLockedforMigration, PublicFolderMigrationComplete
On Exchange 2007 run the below script to create the folder name-to-folder size mapping file, the file will create the folders and its sizes
.\Export-PublicFolderStatistics.ps1 PFStat.csv e12-01
Copy this file to Exchange 2013 and run the below script to create the second CSV, which will let you know how many mailboxes will be required for your folders based on the mailbox you will set as show below:
.\PublicFolderToMailboxMapGenerator.ps1 1GB PFStat.csv FolderToMailbox.csv
As I have a very small PF only one Mailbox is required as below:
New-Mailbox -PublicFolder Mailbox1 –Database DB01 –HoldForMigration: $true
New-PublicFolderMigrationRequest -SourceDatabase (Get-PublicFolderDatabase -Server e12-01.contoso.local) -CSVData (Get-Content FolderToMailbox.csv -Encoding Byte)
Once the migration reached the AutoSuspended state as shown below, proceed to the next steps, otherwise you must wait as this may take some time based on your PF size.
Get-PublicFolderMigrationRequest | Get-PublicFolderMigrationRequestStatistics
Set-OrganizationConfig -PublicFoldersLockedForMigration:$true
Set-PublicFolderMigrationRequest -Identity \PublicFolderMigration -PreventCompletion:$false
Resume-PublicFolderMigrationRequest -Identity \PublicFolderMigration
I will configure a test user to use the new PF using the following command:
Set-Mailbox -Identity mohsaeed -DefaultPublicFolderMailbox mailbox1
Open the test user mailbox and run some tests: Create new post, view old posts, check permissions
If all tests passed successful proceed to next step.
Get-Mailbox -PublicFolder | Set-Mailbox -PublicFolder -IsExcludedFromServingHierarchy $false
Set-OrganizationConfig -PublicFolderMigrationComplete:$true
Remove Mailbox Databases, open Exchange 2007 management shell, and run the following command:
Get-MailboxDatabase | Remove-MailboxDatabase
Remove your PF Databse using guidelines in this link.
Open cmd, navigate to bin directory and run the below command:
Setup.com /mode:uninstall
Regards,
Mohammad
Does one uninstall the exchange 2007 edge server as well ?
What about PF migration if I have more than one PF database on Exchange 2007? Should I wait for copying all PF in each database then lock them, and repeat this for each PF database?
Great and useful Article tx for your time sharing it with us !!!!
Hey Tom. Techs do things in the command line. His process was right on.
@Mihail Stacanov
Right, you should wait for copying all PF DB then lock them and repeat all steps. PF Migration step is painful, finally don't forget latest CU2 update! There is a bug in Exchange Server 2013 CU2 about PF permissions. You should install all Exchange Server 2013 with the latest updates.
Check this out; blogs.technet.com/.../now-available-updated-release-of-exchange-2013-rtm-cu2.aspx
You missed very important steps for Exchange 2013 / Configure service connection point, Outlook Anywhere, Exchange 2013 Client Access Server Configuration. You described perfect clean installation. you have to focus on many points in real environment that you cannot missed.
- Proxy over RPC on Exchange 2007 etc etc...
Great article, spot on made my migration so much easy. thanks for sharing
We have many Distribution Group (that were created in Exchange 2007)... how do we go about migrating with these groups? Thank you
In previous version migrations, I'm used to having the need to move arbitration or system mailboxes from the old server prior to deleting the legacy MB DB. I can't find any good info anywhere else to know if this is required and what steps are needed - Ex2007 -->Ex 2013
Hello Mohammad, thank you for your quick guide. It is essential and useful. I found an issue during a migration. The http redirect to the exchane 2007 always prompt for double credential. One on the EX2013 owa and then to the Ex2007. At the end I was able to pass through the credential between 2k13 and 2k7 configuring the owa vtrutal directory on 2k7: Set-OwaVirtualDirectory -Identity "CAS_Server_Name\OWA (Default Web Site)" –ExternalURL $Null –formsAuthentication $true –WindowsAuthentication $true. Sincerely, it works, but it seems a bit strange to me I have to activate the FBA
Thanks Mohammad, Great guide! i had to lol at this guys comment "I found this entire series rather useless. Just a series of command line stuff without explanation."
Can you verify that this command Set-OrganizationConfig -PublicFoldersLockedForMigration:$true is run on the new Exchange server and not the old? The screendump doesn't say wich server it's run on.
First of all, THANK YOU for writing up this post. I'm sure it is useful for "some" folks is not for all. I did well all the way until this page. I get all the to "Start the Migration Request" and things fall apart there. This is what I get.... [PS] C:\PFScripts>New-PublicFolderMigrationRequest -SourceDatabase (Get-PublicFolderDatabase -Server SRVMAIL1.intermedia -advertising.com) -CSVData (Get-Content FolderToMailbox.csv -Encoding Byte) Couldn't connect to the source mailbox. + CategoryInfo : NotSpecified: (:) [New-PublicFolderMigrationRequest], RemoteTransientException + FullyQualifiedErrorId : [Server=SRVMAIL2,RequestId=3c0b298c-9742-41b4-afbe-0db8389bacef,TimeStamp=2/10/2014 8:51 :21 PM] B2D33BC1,Microsoft.Exchange.Management.RecipientTasks.NewPublicFolderMigrationRequest + PSComputerName : srvmail2.intermedia-advertising.com Any help is very much appreciated.
[PS] C:\PFScripts>New-PublicFolderMigrationRequest -SourceDatabase (Get-PublicFolderDatabase -Server SRVMAIL1.intermedia -advertising.com) -CSVData (Get-Content FolderToMailbox.csv -Encoding Byte) Couldn't connect to the source mailbox. + CategoryInfo : NotSpecified: (:) [New-PublicFolderMigrationRequest], RemoteTransientException + FullyQualifiedErrorId : [Server=SRVMAIL2,RequestId=3c0b298c-9742-41b4-afbe-0db8389bacef,TimeStamp=2/10/2014 8:51 :21 PM] B2D33BC1,Microsoft.Exchange.Management.RecipientTasks.NewPublicFolderMigrationRequest + PSComputerName : srvmail2.intermedia-advertising.com
Sorry about the duplicate.