question

AgnieszkaMuszyska-9634 avatar image
0 Votes"
AgnieszkaMuszyska-9634 asked ajkuma-MSFT commented

AppServicePlan space monitoring

Hello everyone,
I need a hint: how can I monitor percentage of File system storage by external system like Zabbix or Grafana? What im trying to do here is to have monitoring of space currently used, and space available + alert when the used space is higher than lets say 80%.
Attached is the metric in Azureportal that i want to have in external system.

99494-image.png


azure-webapps
image.png (38.8 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

ajkuma-MSFT avatar image
0 Votes"
ajkuma-MSFT answered ajkuma-MSFT commented

@AgnieszkaMuszyska-9634, Thanks for posting this great question.

AFAIK, there is no direct way to feed this information.
There are some approaches outlined in the discussion thread:

You may try to call the GetDiskFreeSpace API to find out disk free space.
List usages by RESTAPI

On a similar lines, we have a request on Uservoice -Metric and alert for Web App file system used quota

You may also share your feedback on this on Uservoice -All of the feedback you share in these forums will be monitored and reviewed by the Microsoft engineering teams responsible for building Azure. Users with a similar request, can up-vote you post and add their comment.

· 3
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Having mentioned above, I'm also checking on this internally and will get back to you shortly.

0 Votes 0 ·

Hey,
Thanks for answering so quick!
We've reviewed the soultion you suggested. It provides info about space taken up by one AppService, not whole AppServicePlan. We would have to have some neat mechanism to sum up the values. And this is fine until I have 150 apps on the AppServicePlan...

Any other ideas?

0 Votes 0 ·

If you use GetDiskFreeSpace you can create your own API to retrieve that info. That call is virtualized, and it will return only the real still available free space for the site.

Just to highlight, the quota is set at the App Service Plan level so it is equivalent to the all available free space for all sites in the App Service Plan (which is a server farm).

As mentioned on the Azure Portal -“File system quota for App Service hosted apps is determined by the aggregate of App Service plans created in this region and resource group.”


Just to add clarity on the terminologies:

App Service – PAAS solution which enables you to build and host websites, mobile backends, and Web APIs.
Apps– Your individual Apps (Windows/Linux WebApps, Web App for containers, and Azure Functions), these apps run in App Service Plan.
App Service Plan (ASP) - An App Service plan, at high level is a container in which your apps run, ASP defines a set of compute resources for apps to run.

0 Votes 0 ·