Test-MigrationServerAvailability

This cmdlet is available only in the cloud-based service.

Use the Test-MigrationServerAvailability cmdlet to test the availability of an on-premises IMAP mail server or a Microsoft Exchange server. In both cases, the cmdlet will verify the connection settings.

Syntax

Test-MigrationServerAvailability [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Test-MigrationServerAvailability -Imap <SwitchParameter> -Port <Int32> -RemoteServer <Fqdn> [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Test-MigrationServerAvailability -Autodiscover <SwitchParameter> -Credentials <PSCredential> -EmailAddress <SmtpAddress> [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Test-MigrationServerAvailability -Credentials <PSCredential> -Exchange <SwitchParameter> -ExchangeServer <String> -RPCProxyServer <String> [-Authentication <Basic | Digest | Ntlm | Fba | WindowsIntegrated | LiveIdFba | LiveIdBasic | WSSecurity | Certificate | NegoEx | MaxValidValue | Misconfigured>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Detailed Description

The Test-MigrationServerAvailability cmdlet verifies that you can communicate with the on-premises mail server that houses the mailbox data that you want to migrate to cloud-based mailboxes. When you run this cmdlet, you must specify the migration type. You can specify whether to communicate with an IMAP server or with an Exchange server.

For an IMAP migration, this cmdlet uses the server’s FQDN and a port number to verify the connection. If the verification is successful, use the same connection settings when you create a new migration request with the New-MigrationBatch cmdlet.

For an Exchange migration, this cmdlet uses one of these set of settings to communicate with the on-premises server:

  • For Exchange 2003, it uses the server's FQDN and credentials for an administrator account that can access the server.
  • For Exchange 2007, you can connect using the Autodiscover service and the e-mail address of an administrator account that can access the server

If the verification is successful, the cmdlet returns output that includes the connection settings to the on-premises server. You can use these connection settings as input when you run the New-MigrationBatch cmdlet.

Parameters

Parameter Required Type Description

Autodiscover

Required

System.Management.Automation.SwitchParameter

For an Exchange migration, the Autodiscover parameter specifies whether to get other connection settings for the on-premises server from the Autodiscover service.

Credentials

Required

System.Management.Automation.PSCredential

For an Exchange migration, the Credentials parameter specifies the logon credentials for an account that can access mailboxes on the on-premises Exchange server. Specify the username in the domain\user format or the UPN (user@example.com) format.

EmailAddress

Required

Microsoft.Exchange.Data.SmtpAddress

For an Exchange migration, the EmailAddress parameter specifies the e-mail address of an administrator account that can access the on-premises Exchange server. This parameter is required only when you use the AutoDiscover parameter.

Exchange

Required

System.Management.Automation.SwitchParameter

The Exchange parameter specifies Exchange as the migration type. This parameter is required only when you want to migrate data from Microsoft Exchange to cloud-based mailboxes. This parameter is required when you don't use the AutoDiscover parameter.

ExchangeServer

Required

System.String

For an Exchange migration, the ExchangeServer parameter specifies the FQDN of the on-premises Exchange server. This parameter is required only when you use the Exchange parameter.

Imap

Required

System.Management.Automation.SwitchParameter

The Imap parameter specifies IMAP as the migration type. This parameter is required only when you want to migrate data from an IMAP mail server to cloud-based mailboxes.

Port

Required

System.Int32

For an IMAP migration, the Port parameter specifies the TCP port number used by the migration process to connect to the remote server. This parameter is required only when you want to migrate data from an on-premises IMAP server to cloud-based mailboxes.

The standard is to use port 143 for unencrypted connections, port 143 for TLS, and port 993 for SSL.

RemoteServer

Required

Microsoft.Exchange.Data.Fqdn

For an IMAP migration, the RemoteServer parameter specifies the FQDN of the on-premises mail server. This parameter is required only when you want to migrate data from an on-premises IMAP server to cloud-based mailboxes.

RPCProxyServer

Required

System.String

For an Exchange migration, the RPCProxyServer parameter specifies the FQDN of the RPC proxy server for the on-premises Exchange server. This parameter is required only when you don't use the Autodiscover parameter.

Authentication

Optional

Microsoft.Exchange.Data.Directory.SystemConfiguration.AuthenticationMethod

The Authentication parameter specifies the authentication method used by the on-premises mail server. Use Basic or NTLM. If you don't include this parameter, Basic authentication is used.

Confirm

Optional

System.Management.Automation.SwitchParameter

The Confirm switch causes the command to pause processing and requires you to acknowledge what the command will do before processing continues. You don't have to specify a value with the Confirm switch.

WhatIf

Optional

System.Management.Automation.SwitchParameter

The WhatIf switch instructs the command to simulate the actions that it would take on the object. By using the WhatIf switch, you can view what changes would occur without having to apply any of those changes. You don't have to specify a value with the WhatIf switch.

Input Types

To see the input types that this cmdlet accepts, see Cmdlet Input and Output Types. If the Input Type field for a cmdlet is blank, the cmdlet doesn’t accept input data.

Return Types

To see the return types, which are also known as output types, that this cmdlet accepts, see Cmdlet Input and Output Types. If the Output Type field is blank, the cmdlet doesn’t return data.

Errors

Error Description

 

Examples

EXAMPLE 1

This example verifies the connection to an IMAP mail server named imap.contoso.edu.

Test-MigrationServerAvailablity -Imap -RemoteServer imap.contoso.edu -Port 143

EXAMPLE 2

This example uses the Autodiscover parameter to verify the connection to an Exchange 2007 server.

$PSCredentials = Get-Credential
Test-MigrationServerAvailability -Autodiscover -EmailAddress administrator@contoso.edu -Credentials $PSCredentials

EXAMPLE 3

This example verifies the connection to an Exchange 2003 server named exch2k3.contoso.edu and uses NTLM for the authentication method.

$PSCredentials = Get-Credential
Test-MigrationServerAvailability -Exchange -ExchangeServer exch2k3.contoso.edu -Credentials $PSCredentials -RPCProxyServer mail.contoso.edu -Authentication NTLM