Cloud platforms
Questions about AWS, Azure, and Google Cloud Platform.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Resolve Azure SFTP File Count Metric Issues Across Containers

john_schell_avo
Visitor

I’m trying to get file count metrics and create alerts when a certain number of files exist in an Azure SFTP storage account.

Here’s what I’ve done so far:

  • The storage account has multiple containers within a file share.

  • I’ve connected Dynatrace to Azure and added the Azure Storage File Service.

  • I’ve added the File Count metric to the service, and I’m receiving data.

However, I’ve noticed a few issues:

  1. The File Count metric seems to report the total number of files across all containers, not per individual container.

  2. The data points are spaced 1 hour apart, even though the polling interval is set to 5 minutes.

  3. The file count doesn’t update when adding or removing files within the 5–60 minute range, it only seems to refresh every few hours.

Has anyone worked with this before or found a way to get accurate, per-container file counts for Azure SFTP in Dynatrace? Ideally, I’d like to alert when a container has files that remain beyond a certain threshold or time period.

Thanks in advance for any insights!

2 REPLIES 2

IzabelaRokita
Community Team
Community Team

Hey @john_schell_avo ,
I just wanted to check in and see if you still need help with this. If so, I’d be happy to look into it for you! 😊
Please let me know what works best for you.

GarethE
Dynatrace Enthusiast
Dynatrace Enthusiast

Hello @john_schell_avo ,
See responses inline:

1. The File Count metric seems to report the total number of files across all containers, not per individual container.

I would just like to clarify: in your original question, you reference both Azure Files and Blob Storage. Are you referring to this Blob storage feature - SFTP support for Azure Blob Storage - Azure Storage | Microsoft Learn

I believe the backing store for this Azure feature is Blob storage, and with this in mind, I can confirm that the Azure Monitor BlobCount metric does not have a dimension that would allow us to split by blob container. Conversely, in Azure File Shares, the FileCount metric does support a dimension "FileShare," which would allow us to do this.

2. The data points are spaced 1 hour apart, even though the polling interval is set to 5 minutes.

Microsoft decides the minimum time granualrity for each metric, in the case of FileCount and BlobCount they are emitted with hourly granularity

3. 
The file count doesn’t update when adding or removing files within the 5–60 minute range, it only seems to refresh every few hours.
According to the Microsoft documentation some of the storage metrics are produced by a background aggregation job that runs on an hourly cadence and emits the metric value retrospectively, meaning the data point is written with a timestamp in the past (this could be 1+ hours behind wall clock time).
"The Blob Capacity and Blob Count metric are emitted hourly. A background process computes these metrics and updates them multiple times a day" - Monitoring data reference for Azure Blob Storage | Microsoft Learn

Hope this clarifies things for you?

Regards

Gareth

Featured Posts