[Fixed]: Exchange Public Folder Migration Stops at 95%

During the migration process, from local Exchange Server to Exchange Online, it may happen that the public folder batch process stops at 95%. To verify the status of the migration batch, you can use the following command in the Exchange Management Shell (EMS).

Get-PublicFolderMailboxMigrationRequest |Get-PublicFolderMailboxMigrationRequestStatistics -IncludeReport

Get-PublicFolderMailboxMigrationRequest

In the output, you will see that the process is in a failed state, with the Status Detail column showing FailedOther. This doesn’t give much information. So, you need to check the detailed error and possibly understand why the migration process has failed. You need to run the following command to get more information on the error message.

$r=Get-PublicFolderMailboxMigrationRequest -Status Failed | Get-PublicFolderMailboxMigrationRequestStatistics -IncludeReport;$r[0].report.failures[-1].Message

Once executed, you will get an error message, similar to the below.

FailureType: FailedToMailEnablePublicFoldersException

Message: Error: There are 13 Public Folders that could not be mail-enabled. Please, check the migration report starting at date/time for additional details. This may indicate that mail public folder objects in Exchange Online are out of sync with your Exchange deployment. You may need to rerun the script Sync-MailPublicFolders.ps1 on your source Exchange server to update mail-enabled public folder objects in Exchange Online Active Directory.

From the error message, it seems that there are 13 public folders which are not mail-enabled. However, all the mail-enabled public folders on the local Exchange Server have been synchronized. You might also get an error when you run the Sync-MailPublicFolders.ps1, which is in the bundle of the migration scripts. Locally on the server, when you use the command Get-MailPublicFolder, it doesn’t show any mail-enabled public folders.

From the information above, you can see that there is no mail-enabled public folders, but the error persists in the migration batch. Although this is right, there is a reason why this happened. When you disable a mail public folder using the Disable-MailPublicFolder command, it sets the MailEnabled property to False, apart from the cleanup process in the Exchange Server and database. There might be cases where the cleanup process is interrupted or not completed for a particular reason. It may not change the MailEnabled property to False, resulting in the public folder not being mail-enabled, but still marked as enabled.

Possible Solutions to Resolve the Public Folder Migration Stops at 95% Issue

There are two solutions to resolve the issue. The first one involves running a script to detect which public folders have this issue and the other one is to run a series of command. Let’s explore these solutions.

Method 1: Using the Script

You need to download the ValidateMailEnabledPublicFolders.ps1 script. This will report and list all orphaned mail-enabled public folders which are found under the NON_IPM_Subtree folder. It will also suggest possible fixes.

Once the script is downloaded, execute it from the Exchange Management Shell (EMS).

./ValidateEmailEnabledPublicFolders.ps1

This will give you information on all the public folders.

Once you fix the problem, you can re-run it to confirm that the problem has been resolved and then retry the migration batch.

Method 2: Using Commands

You can run the below command. It will list the public folders which are mail-enabled and have the property set as True.

$pf=Get-PublicFolder \ -recurse -ResultSize Unlimited | ? { $_.MailEnabled }; ForEach ($i in $pf) {$mesoObj = Get-MailPublicFolder $i.identity; if ($mesoObj -eq $null) {$i }}

public folders which are mail-enabled and have the property set as True

The command will put the mail-enabled public folders in the $pf variable.

Now, run the below command to disable the mail-enabled public folders.

$pf=Get-PublicFolder \ -recurse -ResultSize Unlimited | ? { $_.MailEnabled }; ForEach ($i in $pf) {$mesoObj = Get-MailPublicFolder $i.identity; if ($mesoObj -eq $null) { Disable-MailPublicFolder $i -confirm:$False} }

After this, you can try to re-run the public folder migration batch. Then, use the Get-PublicFolderMailboxMigrationRequest command to get the statistics and progress of the migration batch.

Conclusion

Unpredicted issues or errors can occur during the migration process. To avoid issues, you can use specialized EDB to PST Converter that can facilitate the migration process. Stellar Converter for EDB is one such application that surely makes the migration smooth and less complicated.

With Stellar Converter for EDB, you can open live or offline Exchange Server database from any Exchange Server version with no size limit. Once the database is opened, you will be presented with the entire structure of the database. You can pick and choose the data from the EDB file and export it to PST and other file formats. In this case, you can directly export the EDB data to a live Exchange Server or Office 365. Unlike other applications, Stellar Converter for EDB can process user mailboxes, archive mailboxes, shared mailboxes, disabled mailboxes, and public folders with ease and no complications.



Was this article helpful?
About The Author
author image
Shelly Bhardwaj linkdin Icon

Shelly is technology expert and core knowledge of Exchange Server, Outlook.

Table of Contents

WHY STELLAR® IS GLOBAL LEADER

Why Choose Stellar?
  • 0M+

    Customers

  • 0+

    Years of Excellence

  • 0+

    R&D Engineers

  • 0+

    Countries

  • 0+

    PARTNERS

  • 0+

    Awards Received