question

ChaitanyaNaykodiMSFT-9638 avatar image
0 Votes"
ChaitanyaNaykodiMSFT-9638 asked MichelleBlum-2831 answered

How to capture Memory Dump of Consumption Plan Function App?

I have a Function with some performance issues for my App and I would like to use a memory dump to debug it. For Azure Web Apps I can navigate to Diagnose and Solve Problems and Collect Memory Dump to do this, but for my Function App it does not look like I have the same option. I am guessing this is because my Function is on a Consumption Plan, however I am still wondering if there is a way for me to get this dump and further troubleshoot my issue.

98001-image.png


azure-functions
image.png (67.6 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

MichelleBlum-2831 avatar image
1 Vote"
MichelleBlum-2831 answered

We can collect a dump to further troubleshoot issues for a Consumption Plan Function App. While the app is running / encountering the performance issue, please follow the below steps to capture the dump-
Navigate to Kudu (<Function-App-Name>.scm.azurewebsites.net) -> Process Explorer
Find the w3wp.exe Process ID (four digit number usually) that does not have the "SCM" tag next to it
In another tab navigate in Kudu to Debug Console -> CMD -> Drop down in folders into D:/home/Logfiles directory
Run the following command replacing PID with the process ID captured- d:\devtools\sysinternals\procdump -accepteula -ma PID

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.