microsoft / AzureStorageExplorer

Easily manage the contents of your storage account with Azure Storage Explorer. Upload, download, and manage blobs, files, queues, tables, and Cosmos DB entities. Gain easy access to manage your virtual machine disks. Work with either Azure Resource Manager or classic storage accounts, plus manage and configure cross-origin resource sharing (CORS) rules.
Creative Commons Attribution 4.0 International
378 stars 87 forks source link

Fail to paste blobs which support access tier to a BlockBlobStorage blob container with the setting 'Preserve blob access tier' enabled #8214

Closed v-xianya closed 1 month ago

v-xianya commented 1 month ago

Storage Explorer Version: 1.36.0-dev (101) Build Number: 20240929.1 Branch: rel/1.36.0 Platform/OS: Windows11/Windows 10/Linux Ubuntu 22.04/MacOS Sequoia 15.0(Apple M1 Pro) Architecture: arm64/x64/x64/arm64 How Found: From running test cases Regression From: Previous release (1.32.1)

Steps to Reproduce

  1. Launch Storage Explorer -> Go to 'Settings -> Transfers' -> Enable the setting 'Preserve blob access tier'.
  2. Expand one GPV2 storage account -> Blob Containers -> Create a blob container.
  3. Upload a block blob -> Copy the blob.
  4. Expand one BlockBlobstorage account -> Blob Containers -> Open one blob container -> Paste the blob.
  5. Check whether succeeds to paste the blob.

Expected Experience

Succeed to paste the blob.

Actual Experience

Fail to paste the blob. image

Additional Context

Here is the Azcopy log:

393357b6-b73b-6047-65a4-a9ed938d9c34.log

craxal commented 1 month ago
2024/09/29 09:07:42 ==> REQUEST/RESPONSE (Try=1/4.0054ms, OpTime=5.0063ms) -- RESPONSE STATUS CODE ERROR
   PUT https://ablock.blob.core.windows.net/ablob/file10.txt?se=2024-10-29T09%3A07%3A40Z&sig=-REDACTED-&sp=rwlt&sr=c&sv=2023-01-03
   ...
   --------------------------------------------------------------------------------
   RESPONSE Status: 400 Blob access tier is not supported on this storage account type.
JasonYeMSFT commented 1 month ago

@v-xianya I can also repro this issue in 1.32.1. Could you double check if this is a regression? 1.32.1-copy-to-blockblobstorage.log

v-xianya commented 1 month ago

Hi @JasonYeMSFT I am unable to repro this issue in 1.32.1. Below is the record. Animation01

JasonYeMSFT commented 1 month ago

OK, I see what's going on here. AzCopy 10.20.1 (used by Storage Explorer 1.32.1) is not sending the access tier when writing the blob. I don't know if it's because of a bug or it smartly detects that the target doesn't support access tier. In new versions of AzCopy, it does that and causes the operation to fail.

The current behavior is still reasonable because the target storage account indeed doesn't support access tiers. The workaround is simple: just disable preserve access tier. Since this is an old regression from 1.32.1 and we haven't received complaints so far, I am going to close this as won't fix for now.