Move Azure VM to Another Subscription | Azure Tenant Management

Move Azure VM to Another Subscription

Question

You have an Azure tenant that contains two subscriptions named Subscription1 and Subscription2.

In Subscription1, you deploy a virtual machine named Server1 that runs Windows Server 2016. Server1 uses managed disks.

You need to move Server1 to Subscription2. The solution must minimize administration effort.

What should you do first?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D.

D

To move existing resources to another resource group or subscription, use the Move-AzureRmResource cmdlet.

https://docs.microsoft.com/en-in/azure/azure-resource-manager/resource-group-move-resources#move-resources

To move Server1 to Subscription2 while minimizing administrative effort, you can use the Azure Resource Manager portal or PowerShell. The recommended method is to use Azure Resource Manager portal, as it provides a simple, intuitive interface for managing resources in Azure.

To move Server1 to Subscription2, you can perform the following steps:

  1. Open the Azure portal and sign in with your Azure credentials.
  2. In the left navigation pane, click All services, and then select Subscriptions.
  3. Select Subscription1 and then click on the resource group containing Server1.
  4. Select Server1 from the list of resources.
  5. In the Overview tab, click on the Move button, and then select Move to another subscription.
  6. In the Move resources pane, select Subscription2 from the drop-down list, and then click OK.
  7. Review the details of the move, and then click OK to start the move.

The move process may take some time to complete, depending on the size of the virtual machine and the speed of your internet connection. During the move process, Server1 will be temporarily unavailable, so you should plan the move accordingly.

Alternatively, you can use Azure PowerShell to move Server1 to Subscription2. The steps are:

  1. Open Azure PowerShell and connect to your Azure account.
  2. Use the Get-AzureRmVM cmdlet to get information about Server1.
  3. Use the Move-AzureRmResource cmdlet to move Server1 to Subscription2.

The Move-AzureRmResource cmdlet moves a resource to a new resource group or subscription. To use this cmdlet, you need to specify the resource you want to move, the target resource group or subscription, and any additional options or parameters.

In this case, you would use the following command to move Server1 to Subscription2:

php
Move-AzureRmResource -ResourceId <Server1_ResourceId> -DestinationSubscriptionId <Subscription2_SubscriptionId>

You can find the ResourceId for Server1 by using the Get-AzureRmVM cmdlet, and the SubscriptionId for Subscription2 in the Azure portal.

Overall, the easiest and most efficient method to move a virtual machine with managed disks to another subscription is to use the Azure Resource Manager portal.