Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Snapshots appear as Exceptions in the Application Insights pane of the Azure portal. View debug snapshots in the Azure portal to examine the call stack and inspect variables at each call stack frame.
For a more powerful debugging experience with source code, open snapshots with Visual Studio Enterprise. You can also set SnapPoints to interactively take snapshots without waiting for an exception. For more information, see Debug live ASP.NET Azure apps.
Prerequisites
Snapshots might include sensitive information. You can view snapshots only if you have the Application Insights Snapshot Debugger role.
Access debug snapshots in the Azure portal
After an exception occurs in your application and a snapshot is created, you can view snapshots in the Azure portal within 5 to 10 minutes.
From the Failures pane
In your Application Insights resource, in the left menu, select Investigate > Failures.
In the Failures pane, select either:
- The Operations tab
- The Exceptions tab
Select the [x] Samples in the center column of the page to generate a list of sample operations or exceptions to the right.
From the list of samples, select an operation or exception to open the End-to-End Transaction Details page. From here, select the exception event you'd like to investigate.
- If a snapshot is available for the given exception, select Open debug snapshot in the right pane to view the Debug Snapshot page.
- If you don't see this option, there might be no snapshot available. See the troubleshooting guide.
In the Debug Snapshot page, you see a call stack with a local variables pane. Select a call stack frame to view local variables and parameters for that function call in the variables pane.
Download snapshots to view in Visual Studio
To view snapshots in Visual Studio 2017 Enterprise or greater:
Select Download Snapshot in the Debug Snapshot page to download a
.diagsessionfile, which can be opened by Visual Studio Enterprise.In Visual Studio, make sure you have the Snapshot Debugger Visual Studio component installed.
- For Visual Studio 2017 Enterprise and greater: The required Snapshot Debugger component can be selected from the Individual Component list in the Visual Studio installer.
- For a version older than Visual Studio 2017 version 15.5: Install the extension from the Visual Studio Marketplace.
Open the
.diagsessionfile in Visual Studio to generate the Minidump Debugging page.Select Debug Managed Code to start debugging the snapshot. The snapshot opens to the line of code where the exception was thrown.
Note
The downloaded snapshot includes any symbol files found on your web application server. These symbol files are required to associate snapshot data with source code. For App Service apps, make sure to enable symbol deployment when you publish your web apps.
Related content
Enable the Snapshot Debugger in your: