Move Azure Virtual Machine to Another Subscription | Step-by-Step Guide

Move Server1 to Subscription2

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.

B

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

The correct answer is D. Create a new virtual machine in Subscription2.

Explanation:

Moving a virtual machine between subscriptions is not possible. Instead, you must create a new virtual machine in Subscription2 and move the data from the old virtual machine to the new one. Here's how you can do it:

  1. In Subscription2, create a new virtual machine with the same configuration as the existing virtual machine. You can do this using the Azure portal or Azure PowerShell. Be sure to use the same operating system and disk type (managed disks) as the existing virtual machine.

  2. Stop the existing virtual machine in Subscription1 to ensure that no changes are made to the data during the migration process.

  3. Copy the data from the existing virtual machine to the new virtual machine in Subscription2. There are several ways to do this:

  • Use Azure Site Recovery to replicate the data from the existing virtual machine to the new virtual machine.
  • Use Azure Backup to back up the data from the existing virtual machine and restore it to the new virtual machine.
  • Use the Azure Storage Explorer to copy the VHD file(s) from the existing virtual machine's managed disk to the new virtual machine's managed disk.
  1. Once the data has been copied to the new virtual machine in Subscription2, start the new virtual machine and test it to ensure that everything is working correctly.

Option A (create a copy of the virtual disk) is not a valid solution because virtual disks cannot be moved between subscriptions.

Option B (run the Move-AzureRmResource cmdlet) is not a valid solution for moving a virtual machine between subscriptions. This cmdlet is used to move resources within the same subscription.

Option C (create a snapshot of the virtual disk) is not a valid solution because snapshots cannot be moved between subscriptions.