AzCopy is a command-line utility that can use to transfer data in or out from s storage account (blobs or files). This can be used in Windows, Linux or macOS systems. The same utility also can use to migrate data from one storage account to another.
In this demo, I am going to demonstrate how to use AzCopy to,
• Upload data to the storage account
• Download data from the storage account
• Migrate data from one storage account to another
Create Storage Account
Before using AzCopy, first, let's go ahead and create a storage account. I am going to use Azure PowerShell for this task. So, please make sure you have the Azure PowerShell module installed. More info about it can find under https://docs.microsoft.com/en-us/powershell/azure/install-az-ps?view=azps-2.6.0
1. Launch PowerShell console and connect to Azure using Connect-AzAccount
2. Create a new resource group using,
New-AzResourceGroup -Name REBELRG -Location "East US"
3. Then create a new storage account using,
New-AzStorageAccount -ResourceGroupName REBELRG -Name rebelstorageacc1 -Location "East US" -SkuName Standard_LRS -Kind StorageV2
In the above, rebelstorageacc1 is the storage account name. It is using Locally redundant storage (LRS) as the replication option. It is also created as general purpose v2 storage account.
4. As the next step let's go ahead and create Azure file share.
$storageacc = Get-AzStorageAccount -ResourceGroupName REBELRG -Name rebelstorageacc1
New-AzStorageShare -Context $storageacc.Context -Name rebelshare1
In the above, rebelshare1 is the new file share name and it is created under rebelstorageacc1 storage account. [Read more…] about Step-by-Step Guide: How to transfer data to or from storage account using AzCopy