Thursday, February 7, 2013

Copy VHD’s between Windows Azure Accounts

A colleague asked me how to copy aVirtual Hard Drive (VHD) from one Windows Azure subscription to another. Doing this is simple using the Windows Azure Powershell cmdlets.

First follow the instructions on to download and install the Windows Azure Powershell plugin. Once the installation has completed, you can execute this one line of code from the Windows Azure command-line:

azure vm disk upload <source-path> <target-blob-url> <target-storage-account-key>

Some information about the arguments:

  • <source-path>: The url of the VHD or blob that you want to copy.
  • <target-blob-url>: The url of the Windows Azure Storage container in the destination Azure subscription.
  • <target-storage-account-key>: The storage account key for the Windows Azure Storage container.

No comments: