This week at a customer, I had to get a bunch of their data into Azure Blob storage. It was too much to send over the pipe so we had to resort to copying it to a hard drive and shipping it to Microsoft to then import. While Microsoft has very generic steps on how to do this scattered about the internet, they didn't have what I considered a cohesive guide on how to do it with practical, easy to follow steps. Since I was able to figure it out and given the amount of trouble I had trying to figure it out, I present to you the steps on how I did it in an effort to save someone else some time.
- An existing Azure subscription and one or more storage accounts to use the Import/Export service.
- A 3.5 inch SATA II/III hard drive (up to 6TB)
- Only the first partition on the drive will be processed.
- The partition must be formatted with NTFS using the true logical size sector (likely 512B)
- This was a paint point of ours. We used a WD MyBook and just took it apart and shipped the drive to Microsoft who then couldn't read it. Apparently the adapter in the MyBooks now try to write using 4K blocks (AF, Advanced Format) which Microsoft doesn't support at this time. The easiest way to avoid this is by reading the next bullet point.
- A SATA II/III USB Adapter
- We used a Startech SATADOCK22UE but you can find a list of adapters they recommend here:
Preparing the Drive
- Create one partition for the whole drive, format it with NTFS using the default block size and assign a drive letter to it.
- Encrypt the drive with BitLocker.
- If you are presented with the option, select to only encrypt the existing data on drive and do future encryption on the fly. Since there shouldn't be any this process should complete fairly quickly. If you choose to encrypt the entire drive now and have something like a 2TB drive, you are looking at HOURS just to encrypt the blank drive which isn't worth it.
- Make note of where you save the recovery key file to. You will need it for another step.
Copying the Data
- Download the Azure Import/Export Tool to the server and extract it to it's own folder.
Open a CMD prompt as Administrator and navigate to the folder where you extracted the Import/Export Tool and run the following command
When the copy has completed, if you need to include another folder, run the following command
- WAImportExport.exe PrepImport /j:import.jrn /id:session#1 /sk:VkGbrUqBWLYJ6zg1m29VOTrxpBgdNOlp+kp0C9MEdx3GELxmBw4hK94f7KysbbeKLDksg7VoN1W/a5UuM2zNgQ== /bk:442926-020713-108086-436744-137335-435358-242242-279598 /t:f /srcdir:d:\movies\drama /dstdir:movies/drama/
- /j: Journal file name. Can be whatever you want. Will be saved in your current directory, which should be the WAImportExport tool folder.
- /id: Copy session ID used. Can be whatever you want but must be unique per copy.
- /sk: Storage Key for the Azure Storage blob where the data will be imported.
- /bk: Bit Locker recovery key for the drive you are using from the file in the above steps.
- /t: Target drive letter of the above prepared hard drive to be shipped to Azure.
- /srcdir: Source path of where the files are that are going to be copied
- /dstdir: Destination path of where the files will be imported to in the Azure Storage container.
- Must use forward slashes and end with a forward slash.
- WAImportExport.exe PrepImport /j:import.jrn /id:session#2 /srcdir:d:\movies\action /dstdir:movies/action/
- /j: Must be the same journal file as used in the first copy session.
- /id: Must be unique/different from the session ID used in any previous copies referencing the same journal file.
Creating the Import Job
- Once you have prepared the drive, navigate to your storage account in the Management Portal, and view the Dashboard. Under Quick Glance, click Create an Import Job.
- In Step 1 of the wizard, indicate that you have prepared your drive and that you have the drive journal file available.
- In Step 2, provide contact information for the person responsible for this import job.
- In Step 3, upload the drive journal files that you obtained during the drive preparation step. You'll need to upload one file for each drive that you have prepared.
- In Step 4, enter a descriptive name for the import job.
Next, select your data center region from the list. The data center region will indicate the data center and address to which you must ship your package.
In Step 5, select your return carrier from the list, and enter your carrier account number. Microsoft will use this account to ship your drives back to you once your import job is complete.
- Note that the name you enter may contain only lowercase letters, numbers, hyphens, and underscores, must start with a letter, and may not contain spaces. You'll use the name you choose to track your jobs while they are in progress and once they are completed.
If you have your tracking number, then select your delivery carrier from the list (again, FedEx is the only option), and enter your tracking number.
- At present only FedEx is available.
Ship your drive to Microsoft and keep and eye on the Import Job. When they receive it, the status will change to Importing and you should begin to see your files appearing in your storage container.
When the import is complete, the status of the job will change to Completed and Microsoft will ship you the drive back.
- If you do not have a tracking number yet, choose I will provide my shipping information for this import job once I have shipped my package, then complete the import process.
- To enter your tracking number after you have shipped your package, return to the Import/Export page for your storage account in the Management Portal, select your job from the list, and choose Shipping Info. Navigate through the wizard and enter your tracking number in Step 2.
- If the tracking number is not updated within 2 weeks of creating the job, the job will expire.
I hope that this proves useful to someone out there and helps you avoid the time we spent figuring out what works and doesn't work.
Labels: Azure, Backup, Blob, Import