Use VirtualBox Disk or VM in Azure

What if you have a virtual machine in VirtualBox on your computer and want to deploy that VM to Microsoft Azure? The problem is that a VHD created in VirtualBox, uploaded to Azure, and attached to an Azure VM will crash the VM. The Azure machine will spend some time trying to start, but will then go to status: Stopped (could not start). Here is how you can work around this problem.

The key is to create an empty disk in Azure first. You can do this by attaching an empty disk to an Azure VM. Then the VHD corresponding to the disk is downloaded to your computer, attached to a VirtualBox VM, and VirtualBox is used to install and configure an operating system on the VHD disk. Then the VHD is uploaded back to Azure, an Azure disk is created from it, and an Azure VM is instantiated from the disk. Important: make sure you specify that the disk contains the appropriate type of OS when creating a disk from the VHD!

Leave a Reply

Your email address will not be published. Required fields are marked *