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 http://msdn.microsoft.com/en-us/library/windowsazure/jj554332.aspx 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 <
-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.