Migrate VMware VMs to Azure (agentless) - PowerShell

In this article, you'll learn how to migrate discovered VMware VMs with the agentless method using Azure PowerShell for Azure Migrate: Server Migration.

You learn how to:

  • Retrieve discovered VMware VMs in an Azure Migrate project.
  • Start replicating VMs.
  • Update properties for replicating VMs.
  • Monitor replication.
  • Run a test migration to make sure everything's working as expected.
  • Run a full VM migration.

Note

Tutorials show you the simplest deployment path for a scenario so that you can quickly set up a proof-of-concept. Tutorials use default options where possible and don't show all possible settings and paths.

If you don't have an Azure subscription, create a free account before you begin.

1. Prerequisites

Before you begin this tutorial, you should:

  1. Complete the Tutorial: Discover VMware VMs with Server Assessment to prepare Azure and VMware for migration.
  2. Complete the Tutorial: Assess VMware VMs for migration to Azure VMs before migrating them to Azure.
  3. Install the Az PowerShell module

2. Install Azure Migrate PowerShell module

Azure Migrate PowerShell module is available as part of Azure PowerShell (Az). Run the Get-InstalledModule -Name Az.Migrate command to check if the Azure Migrate PowerShell module is installed on your machine.

3. Sign in to your Microsoft Azure subscription

Sign in to your Azure subscription with the Connect-AzAccount cmdlet.

Connect-AzAccount

Select your Azure subscription

Use the Get-AzSubscription cmdlet to get the list of Azure subscriptions you have access to. Select the Azure subscription that has your Azure Migrate project to work with using the Set-AzContext cmdlet.

Set-AzContext -SubscriptionId 00000000-0000-0000-0000-000000000000

4. Retrieve the Azure Migrate project

An Azure Migrate project is used to store discovery, assessment, and migration metadata collected from the environment you're assessing or migrating. In a project you can track discovered assets, orchestrate assessments, and perform migrations.

As part of prerequisites, you would have already created an Azure Migrate project. Use the Get-AzMigrateProject cmdlet to retrieve details of an Azure Migrate project. You'll need to specify the name of the Azure Migrate project (Name) and the name of the resource group of the Azure Migrate project (ResourceGroupName).

# Get resource group of the Azure Migrate project
$ResourceGroup = Get-AzResourceGroup -Name MyResourceGroup

# Get details of the Azure Migrate project
$MigrateProject = Get-AzMigrateProject -Name MyMigrateProject -ResourceGroupName $ResourceGroup.ResourceGroupName

# View Azure Migrate project details
Write-Output $MigrateProject

5. Retrieve discovered VMs in an Azure Migrate project

Azure Migrate uses a lightweight Azure Migrate appliance. As part of the prerequisites, you would have deployed the Azure Migrate appliance as a VMware VM.

To retrieve a specific VMware VM in an Azure Migrate project, specify name of the Azure Migrate project (ProjectName), resource group of the Azure Migrate project (ResourceGroupName), and the VM name (DisplayName).

# Get a specific VMware VM in an Azure Migrate project
$DiscoveredServer = Get-AzMigrateDiscoveredServer -ProjectName $MigrateProject.Name -ResourceGroupName $ResourceGroup.ResourceGroupName -DisplayName MyTestVM | Format-Table DisplayName, Name, Type

# View discovered server details
Write-Output $DiscoveredServer

We'll migrate this VM as part of this tutorial.

You can also retrieve all VMware VMs in an Azure Migrate project by using the (ProjectName) and (ResourceGroupName) parameters.

# Get all VMware VMs in an Azure Migrate project
$DiscoveredServers = Get-AzMigrateDiscoveredServer -ProjectName $MigrateProject.Name -ResourceGroupName $ResourceGroup.ResourceGroupName

If you have multiple appliances in an Azure Migrate project, you can use (ProjectName), (ResourceGroupName), and (ApplianceName) parameters to retrieve all VMs discovered using a specific Azure Migrate appliance.

# Get all VMware VMs discovered by an Azure Migrate Appliance in an Azure Migrate project
$DiscoveredServers = Get-AzMigrateDiscoveredServer -ProjectName $MigrateProject.Name -ResourceGroupName $ResourceGroup.ResourceGroupName -ApplianceName MyMigrateAppliance

6. Initialize replication infrastructure

Azure Migrate: Server Migration leverages multiple Azure resources for migrating VMs. Server Migration provisions the following resources, in the same resource group as the project.

  • Service bus: Server Migration uses the service bus to send replication orchestration messages to the appliance.
  • Gateway storage account: Server Migration uses the gateway storage account to store state information about the VMs being replicated.
  • Log storage account: The Azure Migrate appliance uploads replication logs for VMs to a log storage account. Azure Migrate applies the replication information to the replica-managed disks.
  • Key vault: The Azure Migrate appliance uses the key vault to manage connection strings for the service bus, and access keys for the storage accounts used in replication.

Before replicating the first VM in the Azure Migrate project, run the following command to provision the replication infrastructure. This command provisions and configures the aforementioned resources so that you can start migrating your VMware VMs.

Note

One Azure Migrate project supports migrations to one Azure region only. Once you run this script, you can't change the target region to which you want to migrate your VMware VMs. You'll need to run the Initialize-AzMigrateReplicationInfrastructure command if you configure a new appliance in your Azure Migrate project.

In the article, we'll initialize the replication infrastructure so that we can migrate our VMs to Central US region.

# Initialize replication infrastructure for the current Migrate project
Initialize-AzMigrateReplicationInfrastructure -ResourceGroupName $ResourceGroup.ResourceGroupName -ProjectName $MigrateProject. Name -Scenario agentlessVMware -TargetRegion "CentralUS" 

7. Replicate VMs

After completing discovery and initializing replication infrastructure, you can begin replication of VMware VMs to Azure. You can run up to 500 replications simultaneously.

You can specify the replication properties as follows.

  • Target subscription and resource group - Specify the subscription and resource group that the VM should be migrated to by providing the resource group ID using the (TargetResourceGroupId) parameter.
  • Target virtual network and subnet - Specify the ID of the Azure Virtual Network and the name of the subnet that the VM should be migrated to by using the (TargetNetworkId) and (TargetSubnetName) parameters respectively.
  • Target VM name - Specify the name of the Azure VM to be created by using the (TargetVMName) parameter.
  • Target VM size - Specify the Azure VM size to be used for the replicating VM by using (TargetVMSize) parameter. For instance, to migrate a VM to D2_v2 VM in Azure, specify the value for (TargetVMSize) as "Standard_D2_v2".
  • License - To use Azure Hybrid Benefit for your Windows Server machines that are covered with active Software Assurance or Windows Server subscriptions, specify the value for (LicenseType) parameter as WindowsServer. Otherwise, specify the value for (LicenseType) parameter as "NoLicenseType".
  • OS Disk - Specify the unique identifier of the disk that has the operating system bootloader and installer. The disk ID to be used is the unique identifier (UUID) property for the disk retrieved using the Get-AzMigrateDiscoveredServer cmdlet.
  • Disk Type - Specify the value for the (DiskType) parameter as follows.
    • To use premium-managed disks, specify "Premium_LRS" as value for (DiskType) parameter.
    • To use standard SSD disks, specify "StandardSSD_LRS" as value for (DiskType) parameter.
    • To use standard HDD disks, specify "Standard_LRS" as value for (DiskType) parameter.
  • Infrastructure redundancy - Specify infrastructure redundancy option as follows.
    • Availability Zone to pin the migrated machine to a specific Availability Zone in the region. Use this option to distribute servers that form a multi-node application tier across Availability Zones. This option is only available if the target region selected for the migration supports Availability Zones. To use availability zones, specify the availability zone value for (TargetAvailabilityZone) parameter.
    • Availability Set to place the migrated machine in an Availability Set. The target Resource Group that was selected must have one or more availability sets to use this option. To use availability set, specify the availability set ID for (TargetAvailabilitySet) parameter.
  • Boot Diagnostic Storage Account - To use a boot diagnostic storage account, specify the ID for (TargetBootDiagnosticStorageAccount) parameter.
    • The storage account used for boot diagnostics should be in the same subscription that you're migrating your VMs to.
    • By default, no value is set for this parameter.

Replicate VMs with all disks

In this tutorial, we'll replicate all the disks of the discovered VM and specify a new name for the VM in Azure. We specify the first disk of the discovered server as OS Disk and migrate all disks as Standard HDD. The OS disk is the disk that has the operating system bootloader and installer. The cmdlet returns a job that can be tracked for monitoring the status of the operation.

# Retrieve the resource group that you want to migrate to
$TargetResourceGroup = Get-AzResourceGroup -Name MyTargetResourceGroup

# Retrieve the Azure virtual network and subnet that you want to migrate to
$TargetVirtualNetwork = Get-AzVirtualNetwork -Name MyVirtualNetwork

# Start replication for a discovered VM in an Azure Migrate project
$MigrateJob =  New-AzMigrateServerReplication -InputObject $DiscoveredServer -TargetResourceGroupId $TargetResourceGroup.ResourceId -TargetNetworkId $TargetVirtualNetwork.Id -LicenseType NoLicenseType -OSDiskID $DiscoveredServer.Disk[0].Uuid -TargetSubnetName $TargetVirtualNetwork.Subnets[0].Name -DiskType Standard_LRS -TargetVMName MyMigratedTestVM -TargetVMSize Standard_DS2_v2

# Track job status to check for completion
while (($MigrateJob.State -eq 'InProgress') -or ($MigrateJob.State -eq 'NotStarted')){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $MigrateJob = Get-AzMigrateJob -InputObject $MigrateJob
}
#Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $MigrateJob.State

Replicate VMs with select disks

You can also selectively replicate the disks of the discovered VM by using New-AzMigrateDiskMapping cmdlet and providing that as an input to the (DiskToInclude) parameter in the New-AzMigrateServerReplication cmdlet. You can also use New-AzMigrateDiskMapping cmdlet to specify different target disk types for each individual disk to be replicated.

Specify values for the following parameters of the New-AzMigrateDiskMapping cmdlet.

  • DiskId - Specify the unique identifier for the disk to be migrated. The disk ID to be used is the unique identifier (UUID) property for the disk retrieved using the Get-AzMigrateDiscoveredServer cmdlet.
  • IsOSDisk - Specify "true" if the disk to be migrated is the OS disk of the VM, else "false".
  • DiskType - Specify the type of disk to be used in Azure.

In the following example, we'll replicate only two disks of the discovered VM. We'll specify the OS disk and use different disk types for each disk to be replicated. The cmdlet returns a job which can be tracked for monitoring the status of the operation.

# View disk details of the discovered server
Write-Output $DiscoveredServer.Disk

# Create a new disk mapping for the disks to be replicated
$DisksToReplicate = @()
$OSDisk = New-AzMigrateDiskMapping -DiskID $DiscoveredServer.Disk[0].Uuid -DiskType StandardSSD_LRS -IsOSDisk true
$DataDisk = New-AzMigrateDiskMapping -DiskID $DiscoveredServer.Disk[1].Uuid -DiskType Premium_LRS -IsOSDisk false

$DisksToReplicate += $OSDisk
$DisksToReplicate += $DataDisk

# Retrieve the resource group that you want to migrate to
$TargetResourceGroup = Get-AzResourceGroup -Name MyTargetResourceGroup

# Retrieve the Azure virtual network and subnet that you want to migrate to
$TargetVirtualNetwork = Get-AzVirtualNetwork -Name MyVirtualNetwork

# Start replication for the VM
$MigrateJob =  New-AzMigrateServerReplication -InputObject $DiscoveredServer -TargetResourceGroupId $TargetResourceGroup.ResourceId -TargetNetworkId $TargetVirtualNetwork.Id -LicenseType NoLicenseType -DiskToInclude $DisksToReplicate -TargetSubnetName $TargetVirtualNetwork.Subnets[0].Name -TargetVMName MyMigratedTestVM -TargetVMSize Standard_DS2_v2

# Track job status to check for completion
while (($MigrateJob.State -eq 'InProgress') -or ($MigrateJob.State -eq 'NotStarted')){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $MigrateJob = Get-AzMigrateJob -InputObject $MigrateJob
}
# Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $MigrateJob.State

8. Monitor replication

Replication occurs as follows:

  • When the Start Replication job finishes successfully, the machines begin their initial replication to Azure.
  • During initial replication, a VM snapshot is created. Disk data from the snapshot is replicated to replica-managed disks in Azure.
  • After initial replication finishes, delta replication begins. Incremental changes to on-premises disks are periodically replicated to the replica disks in Azure.

Track the status of the replication by using the Get-AzMigrateServerReplication cmdlet.

# List replicating VMs and filter the result for selecting a replicating VM. This cmdlet will not return all properties of the replicating VM.
$ReplicatingServer = Get-AzMigrateServerReplication -ProjectName $MigrateProject.Name -ResourceGroupName $ResourceGroup.ResourceGroupName -MachineName MyTestVM

# Retrieve all properties of a replicating VM 
$ReplicatingServer = Get-AzMigrateServerReplication -TargetObjectID $ReplicatingServer.Id

You can track the Migration State and Migration State Description properties in the output.

  • For initial replication, the values for Migration State and Migration State Description properties will be InitialSeedingInProgress and Initial replication respectively.
  • During delta replication, the values for Migrate State and Migration State Description properties will be Replicating and Ready to migrate respectively.
  • After you complete the migration, the values for Migrate State and Migration State Description properties will be Migration succeeded and Migrated respectively.
AllowedOperation            : {DisableMigration, TestMigrate, Migrate}
CurrentJobId                : /Subscriptions/xxx/resourceGroups/xxx/providers/Micr
                              osoft.RecoveryServices/vaults/xxx/replicationJobs/None
CurrentJobName              : None
CurrentJobStartTime         : 1/1/1753 1:01:01 AM
EventCorrelationId          : 9d435c55-4660-41a5-a8ed-dd74213d85fa
Health                      : Normal
HealthError                 : {}
Id                          : /Subscriptions/xxx/resourceGroups/xxx/providers/Micr
                              osoft.RecoveryServices/vaults/xxx/replicationFabrics/xxx/replicationProtectionContainers/xxx/
                              replicationMigrationItems/10-150-8-52-b090bef3-b733-5e34-bc8f-eb6f2701432a_5009e941-3e40-
                              39b2-1e14-f90584522703
LastTestMigrationStatus     :
LastTestMigrationTime       :
Location                    :
MachineName                 : MyTestVM
MigrationState              : InitialSeedingInProgress
MigrationStateDescription   : Initial replication
Name                        : 10-150-8-52-b090bef3-b733-5e34-bc8f-eb6f2701432a_5009e941-3e40-39b2-1e14-f90584522703
PolicyFriendlyName          : xxx
PolicyId                    : /Subscriptions/xxx/resourceGroups/xxx/providers/Micr
                              osoft.RecoveryServices/vaults/xxx/replicationPolicies/xxx
ProviderSpecificDetail      : Microsoft.Azure.PowerShell.Cmdlets.Migrate.Models.Api20180110.VMwareCbtMigrationDetails
TestMigrateState            : None
TestMigrateStateDescription : None
Type                        : Microsoft.RecoveryServices/vaults/replicationFabrics/replicationProtectionContainers/replicationMigrationItems

For details on replication progress, run the following cmdlet.

Write-Output $replicatingserver.ProviderSpecificDetail

You can track the initial replication progress using the Initial Seeding Progress Percentage properties in the output.

    "DataMoverRunAsAccountId": "/subscriptions/xxx/resourceGroups/xxx/providers/Microsoft.OffAzure/VMwareSites/xxx/runasaccounts/xxx",
    "FirmwareType":  "BIOS",
    "InitialSeedingProgressPercentage": 20,
    "InstanceType":  "VMwareCbt",
    "LastRecoveryPointReceived":  "\/Date(1601733591427)\/",
    "LicenseType":  "NoLicenseType",
    "MigrationProgressPercentage":  null,
    "MigrationRecoveryPointId":  null,
    "OSType":  "Windows",
    "PerformAutoResync":  "true",

Replication occurs as follows:

  • When the Start Replication job finishes successfully, the machines begin their initial replication to Azure.
  • During initial replication, a VM snapshot is created. Disk data from the snapshot is replicated to replica-managed disks in Azure.
  • After initial replication finishes, delta replication begins. Incremental changes to on-premises disks are periodically replicated to the replica disks in Azure.

9. Retrieve the status of a job

You can monitor the status of a job by using the Get-AzMigrateJob cmdlet.

# Retrieve the updated status for a job
$job = Get-AzMigrateJob -InputObject $job

10. Update properties of a replicating VM

Azure Migrate:Server Migration allows you to change target properties, such as name, size, resource group, NIC configuration and so on, for a replicating VM.

The following properties can be updated for a VM.

  • VM Name - Specify the name of the Azure VM to be created by using the [TargetVMName] parameter.

  • VM size - Specify the Azure VM size to be used for the replicating VM by using [TargetVMSize] parameter. For instance, to migrate a VM to D2_v2 VM in Azure, specify the value for [TargetVMSize] as Standard_D2_v2.

  • Virtual Network - Specify the ID of the Azure Virtual Network that the VM should be migrated to by using the [TargetNetworkId] parameter.

  • Resource Group - Specify the ID of the resource group that the VM should be migrated to by providing the resource group ID using the [TargetResourceGroupId] parameter.

  • Network Interface - NIC configuration can be specified using the New-AzMigrateNicMapping cmdlet. The object is then passed an input to the [NicToUpdate] parameter in the Set-AzMigrateServerReplication cmdlet.

    • Change IP allocation -To specify a static IP for a NIC, provide the IPv4 address to be used as static IP for the VM using the [TargetNicIP] parameter. To dynamically assign an IP for a NIC, provide auto as the value for the TargetNicIP parameter.
    • Use values Primary, Secondary or DoNotCreate for [TargetNicSelectionType] parameter to specify whether the NIC should be primary, secondary, or is not to be created on the migrated VM. Only one NIC can be specified as the primary NIC for the VM.
    • To make a NIC primary, you'll also need to specify the other NICs that should be made secondary or are not to be created on the migrated VM.
    • To change the subnet for the NIC, specify the name of the subnet by using the [TargetNicSubnet] parameter.
  • Availability Zone - To use availability zones, specify the availability zone value for [TargetAvailabilityZone] parameter.

  • Availability Set - To use availability set, specify the availability set ID for [TargetAvailabilitySet] parameter.

The Get-AzMigrateServerReplication cmdlet returns a job which can be tracked for monitoring the status of the operation.

# List replicating VMs and filter the result for selecting a replicating VM. This cmdlet will not return all properties of the replicating VM.
$ReplicatingServer = Get-AzMigrateServerReplication -ProjectName $MigrateProject.Name -ResourceGroupName $ResourceGroup.ResourceGroupName -MachineName MyTestVM

# Retrieve all properties of a replicating VM 
$ReplicatingServer = Get-AzMigrateServerReplication -TargetObjectID $ReplicatingServer.Id

# View NIC details of the replicating server
Write-Output $ReplicatingServer.ProviderSpecificDetail.VMNic

In the following example, we'll update the NIC configuration by making the first NIC as primary and assigning a static IP to it. we'll discard the second NIC for migration and update the target VM name and size.

# Specify the NIC properties to be updated for a replicating VM.
$NicMapping = @()
$NicMapping1 = New-AzMigrateNicMapping -NicId $ReplicatingServer.ProviderSpecificDetail.VMNic[0].NicId -TargetNicIP ###.###.###.### -TargetNicSelectionType Primary
$NicMapping2 = New-AzMigrateNicMapping -NicId $ReplicatingServer.ProviderSpecificDetail.VMNic[1].NicId -TargetNicSelectionType DoNotCreate

$NicMapping += $NicMapping1
$NicMapping += $NicMapping2

# Update the name, size and NIC configuration of a replicating server
$UpdateJob = Set-AzMigrateServerReplication -InputObject $ReplicatingServer -TargetVMSize Standard_DS13_v2 -TargetVMName MyMigratedVM -NicToUpdate $NicMapping

# Track job status to check for completion
while (($UpdateJob.State -eq 'InProgress') -or ($UpdateJob.State -eq 'NotStarted')){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $UpdateJob = Get-AzMigrateJob -InputObject $UpdateJob
}
# Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $UpdateJob.State

11. Run a test migration

When delta replication begins, you can run a test migration for the VMs before running a full migration to Azure. We highly recommend that you do test migration at least once for each machine before you migrate it. The cmdlet returns a job which can be tracked for monitoring the status of the operation.

  • Running a test migration checks that migration will work as expected. Test migration doesn't impact the on-premises machine, which remains operational, and continues replicating.
  • Test migration simulates the migration by creating an Azure VM using replicated data (usually migrating to a non-production VNet in your Azure subscription).
  • You can use the replicated test Azure VM to validate the migration, perform app testing, and address any issues before full migration.

Select the Azure Virtual Network to be used for testing by specifying the ID of the virtual network using the [TestNetworkID] parameter.

# Retrieve the Azure virtual network created for testing
$TestVirtualNetwork = Get-AzVirtualNetwork -Name MyTestVirtualNetwork

# Start test migration for a replicating server
$TestMigrationJob = Start-AzMigrateTestMigration -InputObject $ReplicatingServer -TestNetworkID $TestVirtualNetwork.Id

# Track job status to check for completion
while (($TestMigrationJob.State -eq 'InProgress') -or ($TestMigrationJob.State -eq 'NotStarted')){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $TestMigrationJob = Get-AzMigrateJob -InputObject $TestMigrationJob
}
# Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $TestMigrationJob.State

After testing is complete, clean-up the test migration using the Start-AzMigrateTestMigrationCleanup cmdlet. The cmdlet returns a job that can be tracked for monitoring the status of the operation.

# Clean-up test migration for a replicating server
$CleanupTestMigrationJob = Start-AzMigrateTestMigrationCleanup -InputObject $ReplicatingServer

# Track job status to check for completion
while (($CleanupTestMigrationJob.State -eq "InProgress") -or ($CleanupTestMigrationJob.State -eq "NotStarted")){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $CleanupTestMigrationJob = Get-AzMigrateJob -InputObject $CleanupTestMigrationJob
}
# Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $CleanupTestMigrationJob.State

12. Migrate VMs

After you've verified that the test migration works as expected, you can migrate the replicating server using the following cmdlet. The cmdlet returns a job that can be tracked for monitoring the status of the operation.

If you don't want to turn-off the source server, then don't use [TurnOffSourceServer] parameter.

# Start migration for a replicating server and turn off source server as part of migration
$MigrateJob = Start-AzMigrateServerMigration -InputObject $ReplicatingServer -TurnOffSourceServer

# Track job status to check for completion
while (($MigrateJob.State -eq 'InProgress') -or ($MigrateJob.State -eq 'NotStarted')){
        #If the job hasn't completed, sleep for 10 seconds before checking the job status again
        sleep 10;
        $MigrateJob = Get-AzMigrateJob -InputObject $MigrateJob
}
#Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
Write-Output $MigrateJob.State

13. Complete the migration

  1. After the migration is done, stop replication for the on-premises machine and clean-up replication state information for the VM using the following cmdlet. The cmdlet returns a job that can be tracked for monitoring the status of the operation.

    # Stop replication for a migrated server
    $StopReplicationJob = Remove-AzMigrateServerReplication -InputObject $ReplicatingServer
    
    # Track job status to check for completion
    while (($StopReplicationJob.State -eq 'InProgress') -or ($StopReplicationJob.State -eq 'NotStarted')){
            #If the job hasn't completed, sleep for 10 seconds before checking the job status again
            sleep 10;
            $StopReplicationJob = Get-AzMigrateJob -InputObject $StopReplicationJob
    }
    # Check if the Job completed successfully. The updated job state of a successfully completed job should be "Succeeded".
    Write-Output $StopReplicationJob.State
    
  2. Install the Linux agent on the migrated machines if the machine has Linux OS. We automatically install the VM agent for Windows VMs during migration.

  3. Perform any post-migration app tweaks, such as updating database connection strings, and web server configurations.

  4. Perform final application and migration acceptance testing on the migrated application now running in Azure.

  5. Cut over traffic to the migrated Azure VM instance.

  6. Remove the on-premises VMs from your local VM inventory.

  7. Remove the on-premises VMs from local backups.

  8. Update any internal documentation to show the new location and IP address of the Azure VMs.

14. Post-migration best practices