Migrate Azure VM’s between Azure Tenants
In this post, we will look at a request from a customer to assist them with migrating Azure VM’s from one Azure Tenant to another. This request come at the back of a merger and the VM’s had complex configurations which will take longer to rebuild. The customer wanted a solution that will save them time and efforts.
As part of this VM migration process I will use the Azure Storage Explorer which can be downloaded HERE.
To get started we need to launch the Storage Explorer and Add accounts from both Tenants which has permissions in the Subscriptions under Accounts.
Select a subscription in each Tenant, where the VM is located and where you want to move it to.
During this process the VM in the source subscription should be powered Off, if not powered Off the Copy process will fail.
Once done, click on “Open Explorer” at the bottom of the page.
In the explorer view you will see the two Subscriptions one in each Azure Tenant.
Migrate the VM
In this step we will copy the VM disk from the one subscription to another, to do this we need to browse to the location where the VM disks are located.
- Expand Disks and select the resource group where the VM disks are located.
- On the right-hand side select the VM disk.
- Once selected, click on “Copy” at the top of the screen.
- Now we need to head over to the second subscription and expand Disks and then select the Resource group where you want to past the VM Disk.
- Click on “Past” from the top of the screen.
- Next you will need to specify some additional information for the disk that you are moving to the new tenant.
- Availably Zone
- Account Type
In my scenario I don’t need to change any of the above and will keep the default as displayed. Click on “Past” to start the process.
You can monitor the copy process at the bottom of the screen under activities.
You can click on refresh on storage explorer to view the newly copied disk.
New step is to create a new VM from the dis that we have just copied.
Navigate to the Azure Portal > Resource Groups open the resource group where you have copied to disk to and click on the newly copied disk.
- Click on + Create VM
- Complete all the needed information for creating a new VM. I won’t go through the whole process of creating a VM.
You will notice under “Image” the disk you copied will be listed here.
Now that we have completed the VM creation lets connect to the VM using RDP.
To access the VM you will need to use the admin credentials stored on the copied disk.
Launch the downloaded RDP file or select your preferred method to connect to Azure VM’s.
And there you have it, successfully connected to the VM that we have moved from the one Tenant to another.
This is a quick and easy way of moving VM’s between Tenants and reduces the added complexity of setting up VPN gateways etc.
Hope those reading finds its useful.
Be First to Comment