skip to Main Content

Using PowerShell for view and export information about mailbox migration to Office 365 | Part 2#5

In the following article and the next article, we review the various PowerShell cmdlets, that we can use for view, and export information about the process of Exchange mailbox migration process.

Most of the time, the main use for viewing and export information about the mailbox migration process is, for the purpose of – troubleshooting a problematic migration process.

Using the information that we “collect” about the migration process, can help us to understand better what is the specific problem that is causing mailbox migration failure.

The mailbox migration “concept” in Exchange-based environment.

In the Exchange environment, the technical term that we use for relating to the process of mailbox
migration is – “Move requests”.

The mailbox migration (the Move request), define the process in which we “move” Exchange mailbox from the “Exchange source server” (the Exchange that hosts the mailbox) to other Exchange database or another Exchange server.

Exchange on-Premises versus Exchange Online

The focus in this article, relate to a scenario in which we implement a process of mailbox migration from Exchange On-Premises server to Office 365 (Exchange Online).

Although the article refers to Office 365 environment, most of the PowerShell commands that we review in this article, are relevant also to Exchange On-Premises environment

Using PowerShell for display and export mailbox migration information

Generally speaking, we can use the web-based Exchange Online admin center interface, for getting information about the mailbox migration process and in addition export information about specific move request.

The notable advantage of using PowerShell is our ability to export the information to various file type such as – TXT, CSV, and XML, that we can use for further analysis in a scenario of “troubleshooting mailbox migration problems”.

After we collect the required data, we can analyze the data by our self or, send the information to the Office 365 support technical team for further analysis.

The article stricture

The information about the various PowerShell commands, divided into sections that relate to each of the separated “entities” that are involved in the mail migration process.

Note – you can read more information about the “Migration entities” that are involved in the mailbox migration process in the former article.

Displaying information versus exporting information

The PowerShell commands that we review, belong to the “Get family” meaning, PowerShell commands that we use for getting information.

In this article (and the next article), most of the PowerShell command syntax examples include the PowerShell parameters, that we use for exporting the information that we get to various file formats such as – TXT, CSV and XML files.

There are two main reasons for the “need” to export the information to files:
1. Limitation of the PowerShell console

In a scenario in which we “fetch” information about the mailbox migration process, the “amount of data” that we get, can be considered as a large amount of information, and most of the time, the interface of the PowerShell console is not the best option for reading the data.

2. Save data for further analysis

Saving the migration information to files can help us to improve the troubleshooting process. For example, looking for specific errors and so on.

The export “path” and file name

In our example, we export the information to drive C: to a folder named TEMP

Regarding the “file name”, the file name syntax that I use in the PowerShell command examples, are just arbitrary file names. You can use any file name that will be suitable for your needs.

PowerShell commands additional parameters

Most of the PowerShell command syntax examples that we review include the “basic PowerShell command + additional parameters such as “-Diagnostic” and “-IncludeReport”.

These parameters can help us to get more details about a specific mailbox migration entity.

The IncludeReport parameter

The IncludeReport switch specifies whether to return additional details, which can be used for troubleshooting.

The Diagnostic parameter

The Diagnostic switch specifies whether to return extremely detailed information in the results. Typically, you use this switch only at the request of Microsoft Customer Service and Support to troubleshoot problems.

The use of this “additional parameters” is not mandatory, but in a scenario of troubleshooting, the basic rule is to get as much as we can information about specific objects that are involved in the migration process.

1. Migration Endpoint | Get + Export Information

The term – “Migration EndPoint” define an entity that serves as a “logical container”, that contain the set of configuration settings, that Exchange Online server uses for addressing Exchange on-Premises mail server.

Get information about specific EndPoint

PowerShell command syntax

Get-MigrationEndpoint -Identity <Migration endpoint name> |Format-List | Out-File <Path>

Get + Export information about specific EndPoint | Example

Get-MigrationEndpoint -Identity OnboardingME01 |Format-List | Out-File c:\temp\"Get-MigrationEndpoint-Diagnostic.txt" -Encoding UTF8

Get + Export information about ALL existing EndPoints

PowerShell command example

Get-MigrationEndpoint -Diagnostic |Format-List | Out-File c:\temp\"Get ALL MigrationEndpoint-Diagnostic.txt" -Encoding UTF8

The o365info Team

The o365info Team

This article was written by our team of experienced IT architects, consultants, and engineers.

This Post Has 0 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *