Random tech posts

Menu

Copying blobs between Azure accounts with AzureCopy

One feature in AzureCopy which was never fully implemented was being able to copy between 2 different Azure accounts while using the CopyBlob API. Everything was there *except* for the Shared Access Signature generation for the source URL. This has now been rectified. The fix has been checked into Github and will go into the next Nuget/command releases whenever they’re made.

So from a practical point of view you can now enter 2 AzureAccountKey “secrets” one for source and one for target (these are called SrcAzureAccountKey and TargetAzureAccountKey funnily enough). You can then issue the command:

azurecopy –i

“https://account1.blob.core.windows.net/mycontainer/myhugeblob” –o

“https://account2.blob.core.windows.net/myothercontainer/” –blobcopy

This will copy from account1 to account2 and use the fantastic Azure CopyBlob API which means your bandwidth will not be used (direct DC to DC copy).