Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure App Service Memory Usage. Where to see full breakdown?

We recently ran out of memory on our sites under an Azure App Service Plan.

This threw a "Memory Resource Exhausted" error on all Apps.

Clicking "CPU Percentage and Memory Percentage" shows a spike to 82% in last 24 hours.

Navigating to "Metrics per Instance (App Service Plan)" I get a visual of all Web Apps.. Adding up ALL their Working Set in MBs added up to 22% at time of 82% App Service Plan usage.

This SO answer suggests viewing memory usage in Kudu.

Does Azure Dashboard or Kudu have any way to show a break down of specifically "App Service Plan" memory usage?

like image 318
ttugates Avatar asked Jan 16 '18 23:01

ttugates


People also ask

How do I check Azure app memory usage?

Go to any site (app) that's part of the App Service Plan. Click on "Diagnose and Solve Problems" Click on Performance Counters (on the right side of the screen) Check e.g. the "Average Memory Working Set" checkbox.

How do I check service memory usage?

Check Computer Memory Usage EasilyTo open up Resource Monitor, press Windows Key + R and type resmon into the search box. Resource Monitor will tell you exactly how much RAM is being used, what is using it, and allow you to sort the list of apps using it by several different categories.

How do I check for a memory leak in Azure?

This information can be obtained from the notification. Diagnose. The detection contains the memory leak pattern, showing memory consumption of the process over time. You can also use the related items and reports linking to supporting information, to help you further diagnose the issue.

How do I check memory on Azure VM?

Enable memory usage monitoring You can find this option on the Infrastructure tab of the Component Blueprints page. See Add Azure Services to the Catalog for more information. In the manual provisioning wizard, choose the storage account that will be used to save the data.


2 Answers

Watch a quick video to understand different aspects shown in this view https://www.youtube.com/watch?v=lWeutt1GvRs

  1. Go to the Diagnose and Solve Problems blade for your Azure App in the Azure Portal.
  2. Choose the Availability and Performance category
  3. Choose either Memory Analysis on the left or click on the Memory Usage card on the right
  4. This launches the Memory Analysis tool.

Under the Memory analysis tool:-

  • The very first thing shown is App Service Plan Density – This checks looks for overstuffed App Service Plans and beeps if it finds that you have too many apps in the same app service plan
  • An insight is shown if we detect or more apps consuming high memory
  • Private Bytes consumption for the current app
  • Physical memory in use for each instance allotted to the App Service Plan
  • And then Memory Drill down shows Per instance memory drilldown for each app and its associated process running on that instance.

Screenshot of Memory Drilldown view

App Level Breakdown

enter image description here

like image 197
Puneet Gupta Avatar answered Oct 16 '22 18:10

Puneet Gupta


A dated question, but I've found a view that shows this data that I believe did not exist at the time this question was posted.

Go to Diagnose and solve problems and search for "memory" in the input box labeled "Search App Service Diagnostics" at the top of the view. Choose Memory Drill Down in the results. There you will see a full breakdown of all the apps running per instance on your App Service Plan:

Screenshot 1: Search results for "Memory" in "Diagnose and solve problems" view Screenshot 1

Screenshot 2: Full breakdown of memory usages per app per instance on your App Service Plan Screenshot 2

like image 4
taviandir Avatar answered Oct 16 '22 16:10

taviandir