Search code examples
azureazure-virtual-machineazure-devtest-labs

Move DevTest Lab VM to another DevTest Lab


I'm trying to move a VM custom image from one DevTest Lab to another and can't seem to find an easy way to accomplish that. My VM is using managed disks and also has a data disk.

I've read the following article https://azure.microsoft.com/en-us/updates/azure-devtest-labs-changes-in-exporting-custom-image-vhd-files/ and it states that

Azure DevTest Lab now generates a managed image and "…This allows Sysprep'ed/deprovisioned custom images to support data disks in addition to the OS disk through a single image."

This is fine but the image that is created can't be exported.

Is it even possible to accomplish, am I missing something?

Thanks for your help


Solution

  • This is fine but the image that is created can't be exported.

    The article you posted is right, you can follow it to export the VM OS disk(not image) to your local machine. You should export the VM OS disk from the Resource group which contains your Devtest VM. The main steps are below:

    1. Generate your VM

    2. Go to Azure Portal > find the resource group which name contains your DevtestLab VM : enter image description here

    3. Then, you can find the Disk and export it to your local machine: enter image description here

    4. Go to your another Devtest Lab > Configuration and plocies > Custom images > Add > Enter your VHD location and choose the OS type > OK > the coustom image will be uploaded Then you can use it to create your Devtest VM. enter image description here