Unable to Retrieve Logs for Authentication Errors in Azure Blob Storage

Abdul 2,650 Reputation points Microsoft External Staff Moderator
2024-07-31T09:47:47.23+00:00

Why am I unable to retrieve logs for Authentication Errors in Azure Blob Storage, even though my application shows multiple errors?

 "PS - Based on common issues that we have seen from customers and other sources, we are posting these questions to help the Azure community."

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

1 answer

Sort by: Most helpful
  1. Abdul 2,650 Reputation points Microsoft External Staff Moderator
    2024-07-31T09:51:20.61+00:00

    Welcome!
    The issue arises because the customer is facing intermittent failures when uploading images to a Blob in Azure. Although the application monitoring tool shows 81 Authentication Errors, only 2 errors are found when querying the logs in the log analytic workspace. This discrepancy occurs because the analytical logging might take some time to reflect the logs when queried.

    To resolve this, it is recommended to enable storage analytical logging, which provides more detailed logging information and helps troubleshoot intermittent issues effectively. Additionally, ensure that you are querying the logs at the correct timestamps when the errors occurred and using the appropriate query as mentioned in the sample queries provided by Azure documentation.

    Here are the steps to enable storage analytical logging:

    1. Navigate to the Azure portal and select your storage account.
    2. Under the "Monitoring" section, click on "Diagnostic settings (classic)".
    3. Add a diagnostic setting and select the "StorageRead", "StorageWrite", and "StorageDelete" operations.
    4. Configure the destination to send the logs either to a Log Analytics workspace, Event Hub, or storage account.
    5. Save the configuration.

    Refer to the following documentation for more details on forming the StringToSign and troubleshooting authentication issues:

    Resources:

    Hope this helps. If you have any follow-up questions, please let me know. I would be happy to help.

    Please do not forget to "up-vote" wherever the information provided helps you, as this can be beneficial to other community members.

    0 comments No comments

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.