The copy blob operation never finished

Artem Shaturskyi 220 Reputation points
2025-05-20T13:09:40.3033333+00:00

Hello!
I am copying a VM disk snapshot to Blob Storage using an HTTP action in a Logic App. The code view is:
"type": "Http",

"inputs": {

"uri": "https://<storageaccount>.blob.core.windows.net/snapshots/@{concat(variables('date'),'-',last(split(items('For_each_-_VM_Disk'),'/')))}.vhd",

"method": "PUT",

"headers": {

"Authorization": "<AccessKey>",

"x-ms-date": "@{utcNow('R')}",

"x-ms-version": "2025-05-05",

"x-ms-copy-source": "@{body('HTTP_-_Grants_Access_to_Snapshot')['accessSAS']}"

},

"authentication": {

"type": "ManagedServiceIdentity",

"identity": "",

"audience": "https://storage.azure.com/"

}

}
I do this for a number of disks. Most of them are copied successfully, but copying one of them never finishes - it hangs in a pending state. I'm unable to find the reason why. I would appreciate any advice on how to troubleshoot this issue.

Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
3,186 questions
0 comments No comments
{count} votes

Accepted answer
  1. Hari Babu Vattepally 3,270 Reputation points Microsoft External Staff Moderator
    2025-05-20T15:00:27.8766667+00:00

    Hi @Artem Shaturskyi ,

    Coping blob operations, hangs in pending state occurs due to couple of reasons. Please follow the below troubleshooting steps to resolve the issue:

    If the copy operation returns a status code of 202 (Accepted) with x-ms-copy-status: pending, it signifies that the operation is ongoing. You can confidently poll the destination blob using Get File Properties to monitor the x-ms-copy-status until it either completes or fails.

    Also, please be aware that a pending Copy File operation has a two-week timeout. If it hasn't finished within this time frame, it will time out and leave an empty file with a failed status.

    However, sometimes, intermittent, non-fatal errors can occur during the copy operation. Check the x-ms-copy-status-description header for any error details that might explain the delay. Also, please check the x-ms-copy-st.atus to failed.

    Please make sure that there are no existing copy operations on the destination blob. A blob can only have one outstanding copy operation at a time. If you try to initiate another copy, you'll receive a 409 (conflict) status code.

    Sometimes the copy operation can hang due to intermittent errors. Check if there are any descriptions in the x-ms-copy-status-description that could give you more insight into what might be going wrong. If the operation seems stuck, you can call the Abort Copy File operation. This will set the x-ms-copy-status to aborted, and you can then retry the original copy operation.

    Also, please double-check that your access keys or SAS tokens used in the Authorization header are valid and have the necessary permissions to perform copy operations.

    For more information, please refer the below documents:

    Hope by following the above troubleshooting steps this issue will be resolved. Please let us know if there are any further questions.

    Please do consider to “Accept the answer” wherever the information provided helps you, this can be beneficial to other community members.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.