Public Folders Migration from Exchange 2007/2010 to Exchange 2013
Public Folders has been discussed before and after every new Exchange server release but there are many Microsoft customers who are using it that Microsoft is not preferring to remove it completely.
The Serial migration method used in this article is no longer supported by Microsoft. Please refer to our new article on performing a Batch Migration of Public folders from legacy servers to Exchange 2016/ Exchange 2013.
Exchange 2016 / Exchange 2013 Public Folder Batch Migration Method: https://msexchangeguru.com/2016/06/15/publicfolder-batch-migration/
Even today with the great functionality of sharepoint, Microsoft decided to keep PF in the Exchange so that it can give an option to use PF or Sharepoint.
I would highly recommend our high Public Folders users to start using Sharepoint but if you have less Public Folders Data then we can still migrate Public Folder Database to Public Folder Mailboxes.
By changing the Design from Database to Mailbox, Public Folders has become highly available with DAG. So if your mailbox database is up and running in DAG then Public Folders are also available.
Public Folders Limits can be reviewed here.
Assumptions:
-Exchange 2010 is Exchange 2010 SP3 or later
-Exchange 2007 is Exchange 2007 SP3 RU10 or later
-Login id has Organization Management and Recipient Management Permissions
-All the mailboxes have been moved to Exchange 2013
-Ensure we announce downtime or do this over the weekend
-Perform a backup of your public folder databases
–Removed space and from the alias of 2007/2010 Public Folders.
Public Folder Migration Steps:
1. Snapshot of the current Public Folders: In the following steps we will take the snapshot of the current Public Folders which will be compare post migration.
-Run the following command to take a snapshot of the original source folder structure.
Get-PublicFolder -Recurse | Export-CSV C:PFMigrationEx2010_PFStructure.csv
-Run the following command to take a snapshot of the public folder statistics such as item count, size, and owner.
Get-PublicFolder -Recurse | Get-PublicFolderStatistics | Export-CSV C:PFMigrationEx2010_PFStatistics.csv
-Run the following command to take a snapshot of the permissions.
Get-PublicFolder -GetChildren | Get-PublicFolderClientPermission | Select-Object Identity,User -ExpandProperty AccessRights | Export-CSV C:PFMigrationEx2010_PFPerms.csv
Save the information from the above commands for comparison at the end of the migration.
2. Preparation on Legacy Exchange server (2010/2007): We need to do the following check before preparing public folders migration.
-Validate Exchange 2010/2007 Public Folder database is mounted
-Validate no record of previous successful migration is present
-Use the below cmdlet to check if there was a previous successful migration completed
Get-OrganizationConfig | fl PublicFoldersLockedforMigration, PublicFolderMigrationComplete
-If you find any True, then use the below cmdlet, this will take some time to become effective:
Set-OrganizationConfig -PublicFoldersLockedforMigration:$false -PublicFolderMigrationComplete:$false
-Validate no migration currently in progress by running following cmdlet
Get-PublicFolderMigrationRequest
Get-publicfolderdatabase
And
Get-publicfolder
Or
Get-Mailbox -PublicFolder
You should see the below output:
-Run the below cmdlets to remove any previous Public Folders:
Get-PublicFolderMigrationRequest | Remove-PublicFolderMigrationRequest -Confirm:$false
Get-MailPublicFolder | where $_.EntryId -ne $null | Disable-MailPublicFolder -Confirm:$false
Get-PublicFolder -GetChildren | Remove-PublicFolder -Recurse -Confirm:$false
Get-Mailbox -PublicFolder |Remove-Mailbox -PublicFolder -Confirm:$false
4. Export public folder hierarchy from source into CSV file: On Exchange 2010/2007 run the following script which will generate a csv file:
Important: In Exchange 2007 you might need to remove “ResultSize:unlimited” on line number 91 of the script “Export-PublicFolderstatiscis.ps1”. Don’t change anything unless you face any issue.
.Export-PublicFolderStatistics.ps1 servernamepathfilename.csv
Example file output
.PublicFolderToMailboxMapGenerator.ps1 MailboxSize ImportFilePAth ExportFilePath
ImportFilepath is the file name which was created in previous step.
Output file screen
5. Create public folder mailboxes in Exchange 2013: We will run the below cmdlet to create public folders mailboxes in hold for migration mode.
Important: The name of the public folder mailboxes that you create must match the name of the TargetMailbox in the mapping file. You can edit the TargetMailbox names in the mapping file to match your organization’s naming conventions.
New-Mailbox -PublicFolder MailboxName -HoldForMigration:$true –Database “2013DB”
-Continue creating the new mailboxes as per the output file. In my case it was only one.
6. Migration Request creation: In this step we will rung the migration request cmdlet
Before creating migration request it will be good to run the below command to avoid “The Microsoft Exchange Administrator has made a change that requires you quit and restart Outlook” prompt. This command will stop this mailbox serving the hierarchy.
“Set-Mailbox <PublicFolderMailboxName> –PublicFolder –IsExcludedFromServingHierarchy:$True”
Now run the migration request
“New-PublicFolderMigrationRequest -SourceDatabase (Get-PublicFolderDatabase -Server <Source server name>) -CSVData (Get-Content <Folder to mailbox map path> -Encoding Byte)”
Example: New-PublicFolderMigrationRequest -SourceDatabase (Get-PublicFolderDatabase -Server Exch2010) -CSVData (Get-Content C:tempMapgen.csv -Encoding Byte)
-Move will begin as an online move and reach auto suspended state
-Run the following cmdlet to verify the migration status.
Get-PublicFolderMigrationRequest | Get-PublicFolderMigrationRequestStatistics -IncludeReport | fl
-Below is sample screen – Normally you get 2-3GB per hour migration output.
When the status reaches Autosuspended, we can move to next step
7. Lock source (Exchange 2010/2007) for final migration:
-Once Auto Suspend state is reached, set the bit on the org object that you are making the switch
-Downtime will be required depends on how much new content was generated since the migration reached the AutoSuspended state.
-The cmdlet will log off the users from the public folders and lock the folders while the migration completes its final synchronization. Users won’t be able to access public folders during this process.
-It is recommended to run the following cmdlet on Exchange 2010/2007 but this does not matter in the same org as this is org level configuration.
Set-OrganizationConfig –PublicFoldersLockedForMigration:$true
-If multiple source PF databases, wait Replication Interval+1 hour after locking source so they can replicate. Alternatively you can restart the Microsoft Exchange Information Store service to bypass the waiting time.
8. Complete the suspended migration by running below 2 cmdlet:
-Set flag on migration request that finalization has been triggered
Set-PublicFolderMigrationRequest –Identity PublicFolderMigration -PreventCompletion:$false
-Resume migration request
Resume-PublicFolderMigrationRequest –Identity PublicFolderMigration
-Migration will reach completed state
Once migration completes run the below command to allow this mailbox to serve the Hierarchy requests
“Set-Mailbox <PublicFolderMailboxName> –PublicFolder –IsExcludedFromServingHierarchy:$False”
9. Validation
-Check that source public folders have been moved to Exchange 2013
-Check that hierarchy matches the source setup
10. Removing PF Database in Exchange 2010/2007
Once you are satisfied, you can go ahead and delete the Public Folder Database from Exchange 2010/2007 then remove the database and log files from folder directory
Public Folder Migration ends here.
Rollback Steps:
If you run into issues with the migration and need to reactivate your Exchange 2010 public folders, perform the following steps:
Important: After the migration is complete, any changes you made to your Exchange 2013 public folders won’t be reflected in the Exchange 2010/2007. As a result, you may lose public folder data if you roll back the migration.
1. To unlock legacy Exchange public folders, run the following command on the legacy Exchange server.
Set-OrganizationConfig -PublicFoldersLockedForMigration:$False
2. To set the PublicFolderMigrationComplete flag to $false, run the following command on the Exchange 2010 SP3 server:
Set-OrganizationConfig -PublicFolderMigrationComplete:$False
3. If Public Folders will be present in exchange 2013 then users will not go to exchange 2010/2007. To remove the public folders, run the below cmdlets
Get-PublicFolderMigrationRequest | Remove-PublicFolderMigrationRequest -Confirm:$false
Get-MailPublicFolder | Disable-MailPublicFolder -Confirm:$false
Get-PublicFolder -GetChildren | Remove-PublicFolder -Recurse -Confirm:$false
Get-Mailbox -PublicFolder |Remove-Mailbox -PublicFolder -Confirm:$false
For On Prem to Office 365 migrations, use this technet which has slight changed steps are step number 5. - https://technet.microsoft.com/en-us/library/dn874017%28v=exchg.150%29.aspx
Best of Luck, feel free to contact us in case of any issue
Prabhat Nigam | MVP Exchange Server
Team@ MSExchangeGuru
Keywords: Exchange 2010 public folder migration, Exchange 2013 public folders, how to migrate public folders to Exchange 2013, exchange 2013, exchange 2013 PF migration, how to migrate public folders from Exchange 2007 to exchange 2013
October 28th, 2016 at 3:07 pm
I don’t have the domain suffix specified on the nic in 2013 (nor on 2010, for that matter). It picks it up automatically (“Append primary and connection specific DNS suffixes -> Append parent suffixes of the primary DNS suffix” is checked).
The servers are registering properly in DNS and WINS.
November 4th, 2016 at 1:50 pm
I think you ended up being right, everything started working after my firewall team figured out they weren’t completely accurate when they said the communication was wide open. So in the end, it was a firewall problem. Thanks!
November 4th, 2016 at 2:10 pm
Great to hear that your issue has fixed.
November 16th, 2016 at 4:31 am
Recently we have migrated PF from 2010. All gone well. In EAC we noticed quota limit exceeded for some mailbox. So decided to move few PF to different dbs. new-moverequest -identity -targetdatabase will do or any other way.
November 16th, 2016 at 2:02 pm
Either move the mailbox or move the PF. Move mailbox is new-moverequest but move PF is PS1 file check the details here. https://technet.microsoft.com/en-us/library/jj906435%28v=exchg.150%29.aspx?f=255&MSPPError=-2147217396