where does the virtual machine files are stored in Windows Azure and how to retrieve them with Azure SDK?

210 views Asked by At

where are the virtual machine files stored in windows azure and how to retrieve them programmatically with Azure Java SDK?

2

There are 2 answers

0
BrentDaCodeMonkey On

The Virtual Datastore is essentially the Azure storage account where your virtual machines are stored. It contains the OS and Data Disks that comprise the VM (as Hyper-V VHD's). You can download them using any number Azure Storage tools, or write your own using your SDK of preference (such as the Azure Java SDK).

1
Simon W On

Raja - using the Java SDK you should.

  1. Connect to your subscription. See Brady's post.
  2. Enumerate your Virtual Machines (and filter appropriately) using ComputeManagementClient.
  3. For all Virtual Machines you care about look at their Disk collections and then using the URL of the VHD you can use the StorageManagementClient to download the VHD.

Note that you'd most likely want the VM switched off before doing the retrieval of the VHD.