Migrate ExpressRoute-associated virtual networks from classic to Resource Manager

This article explains how to migrate ExpressRoute-associated virtual networks from the classic deployment model to the Azure Resource Manager deployment model after moving your ExpressRoute circuit.

Before you begin

Note

We recommend that you use the Azure Az PowerShell module to interact with Azure. To get started, see Install Azure PowerShell. To learn how to migrate to the Az PowerShell module, see Migrate Azure PowerShell from AzureRM to Az.

Supported and unsupported scenarios

  • An ExpressRoute circuit can be moved from the classic to the Resource Manager environment without any downtime. You can move any ExpressRoute circuit from the classic to the Resource Manager environment with no downtime. Follow the instructions in moving ExpressRoute circuits from the classic to the Resource Manager deployment model using PowerShell.
  • Virtual networks, gateways, and associated deployments within the virtual network that are attached to an ExpressRoute circuit in the same subscription can be migrated to the Resource Manager environment without any downtime. You can follow the steps described later to migrate resources such as virtual networks, gateways, and virtual machines deployed within the virtual network. You must ensure that the virtual networks are configured correctly before they're migrated.
  • Virtual networks, gateways, and associated deployments within the virtual network that aren't in the same subscription as the ExpressRoute circuit require some downtime to complete the migration. The last section of the document describes the steps to be followed to migrate resources.
  • A virtual network with both ExpressRoute Gateway and VPN Gateway can't be migrated.
  • ExpressRoute circuit cross-subscription migration isn't supported. For more information, see Microsoft.Network move support.

Move an ExpressRoute circuit from classic to Resource Manager

You must move an ExpressRoute circuit from the classic to the Resource Manager environment before you try to migrate resources that are attached to the ExpressRoute circuit. To accomplish this task, see the following articles:

This operation doesn't involve downtime. You can continue to transfer data between your premises and Azure while the migration is in progress.

Migrate virtual networks, gateways, and associated deployments

The steps you follow to migrate depend on whether your resources are in the same subscription, different subscriptions, or both.

Migrate virtual networks, gateways, and associated deployments in the same subscription as the ExpressRoute circuit

This section describes the steps to be followed to migrate a virtual network, gateway, and associated deployments in the same subscription as the ExpressRoute circuit. No downtime is associated with this migration. You can continue to use all resources through the migration process. The management plane is locked while the migration is in progress.

  1. Ensure that the ExpressRoute circuit migrated from the classic to the Resource Manager environment.

  2. Ensure that the virtual network gets prepared appropriately for the migration.

  3. Register your subscription for resource migration. To register your subscription for resource migration, use the following PowerShell snippet:

    Select-AzSubscription -SubscriptionName <Your Subscription Name>
    Register-AzResourceProvider -ProviderNamespace Microsoft.ClassicInfrastructureMigrate
    Get-AzResourceProvider -ProviderNamespace Microsoft.ClassicInfrastructureMigrate
    
  4. Validate, prepare, and migrate. To move the virtual network, use the following PowerShell snippet:

    Move-AzureVirtualNetwork -Validate -VirtualNetworkName $vnetName
    Move-AzureVirtualNetwork -Prepare -VirtualNetworkName $vnetName
    Move-AzureVirtualNetwork -Commit -VirtualNetworkName $vnetName
    

    You can also abort migration by running the following PowerShell cmdlet:

    Move-AzureVirtualNetwork -Abort $vnetName
    

Next steps