Troubleshoot performance issues on Azure virtual machines using Performance Diagnostics (PerfInsights) - Virtual Machines (2024)

  • Article

Applies to: ✔️ Linux VMs ✔️ Windows VMs

Use the Performance Diagnostics tool to identify and troubleshoot performance issues on your Azure virtual machine (VM) in one of two modes:

  • Continuous diagnostics (preview) collects data at five-second intervals and reports actionable insights about high resource usage every five minutes.
  • On-demand diagnostics helps you troubleshoot an ongoing performance issue with more in-depth data, insights, and recommendations based on data collected at a single point in time.

Performance Diagnostics stores all insights and reports in a storage account, which you can configure for short data retention to minimize costs.

Run Performance Diagnostics directly from the Azure portal, where you can also review insights and a report on various logs, rich configuration, and diagnostics data. We recommend that you run Performance Diagnostics and review the insights and diagnostics data before you contact Microsoft Support.

This article explains how to use Performance Diagnostics and what the continuous and on-demand modes offer.

Note

Continuous diagnostics (preview) is being rolled out gradually and is currently supported only on Windows. If the preview feature is available for your machines, you'll see the option to enable both on-demand and continuous diagnostics, as described in Install and run Performance Diagnostics on your VM.

Prerequisites

  • To run continuous and on-demand diagnostics on Windows, you need .NET SDK version 4.5 or a later.

Note

To run Performance Diagnostics on classic VMs, see Azure Performance Diagnostics VM extension.

Permissions required

ActionPermissions required
View Performance Diagnostics insights and reportsMicrosoft.Storage/storageAccounts/listKeys/action permissions to the storage account, as provided by the built-in Storage Account Contributor role, for example.

Supported operating systems

Windows

The following operating systems are currently supported for both on-demand and continuous diagnostics:

  • Windows Server 2022
  • Windows Server 2019
  • Windows Server 2016
  • Windows Server 2012 R2
  • Windows Server 2012
  • Windows 11
  • Windows 10

Linux

Note

CentOS referenced in this article is a Linux distribution and will reach End Of Life (EOL). Consider your use and plan accordingly. For more information, see CentOS End Of Life guidance.

The following distributions are currently supported for on-demand diagnostics:

Note

Microsoft has only tested the versions that are listed in the table. If a version isn't listed in the table, then it isn't explicitly tested by Microsoft, but the version might still work.

DistributionVersion
Oracle Linux Server6.10 [*], 7.3, 7.5, 7.6, 7.7, 7.8, 7.9
CentOS6.5 [*], 7.6, 7.7, 7.8, 7.9
RHEL7.2, 7.5, 8.0 [*], 8.1, 8.2, 8.6, 8.8
Ubuntu14.04, 16.04, 18.04, 20.04, 22.04
Debian8, 9, 10, 11 [*]
SLES12 SP4 [*], 12 SP5 [*], 15 [*], 15 SP1 [*], 15 SP2 [*], 15 SP4 [*]
AlmaLinux8.4, 8.5
Azure Linux2.0

Install and run Performance Diagnostics on your VM

Performance Diagnostics installs a VM extension that runs a diagnostics tool, called PerfInsights. PerfInsights is available for both Windows and Linux.

To install and run Performance Diagnostics:

  1. In the Azure portal, select Virtual machines.

  2. From the list of VM names, select the VM that you want to run diagnostics on.

  3. In the Help section, select Performance Diagnostics.

  4. Select Enable Performance Diagnostics

  5. Select the options to install and run for the tool.

    This table describes the available options:

    OptionDescription
    Enable continuous diagnosticsGet continuous, actionable insights into high resource usage with data collected every 5 seconds and updates uploaded every 5 minutes to address performance issues promptly. Store insights in your preferred storage account. The storage account retains insights based on the account retention policies, which you can configure to manage the data lifecycle effectively. You can disable continuous diagnostics at any time.
    Run on-demand diagnosticsGet on-demand, actionable insights into high resource usage and various system configurations. Receive a downloadable report with comprehensive diagnostics data to address performance issues. Store insights and reports in your preferred storage account. The storage account retains insights based on the account retention policies, which you can configure to manage the data lifecycle effectively. You can initiate on-demand diagnostics at any time using the specific analysis type you need:
    • Performance analysis
      Includes all checks in the Quick analysis scenario, and monitors high resource consumption. Use this version to troubleshoot general performance issues, such as high CPU, memory, and disk usage. This analysis takes 30 seconds to 15 minutes, depending on the selected duration. Learn more Windows or Linux
    • Quick analysis
      Checks for known issues, analyzes best practices, and collects diagnostics data. This analysis takes several minutes to run. Learn more Windows or Linux
    • Advanced performance analysis [*]
      Includes all checks in the Performance analysis scenario, and collects one or more of the traces, as listed in the following sections. Use this scenario to troubleshoot complex issues that require more traces. Running this scenario for longer periods increases the overall size of diagnostics output, depending on the size of the VM and the trace options that are selected. This analysis takes 30 seconds to 15 minutes to run, depending on the selected duration. Learn more
    • Azure file analysis [*]
      Includes all checks in the Performance analysis scenario, and captures a network trace and SMB counters. Use this scenario to troubleshoot the performance of Azure files. This analysis takes 30 seconds to 15 minutes to run, depending on the selected duration. Learn more
    Storage accountOptionally, if you want to use a single storage account to store the Performance Diagnostics results for multiple VMs, you can select a storage account from the dropdown. If you don't specify a storage account, Performance Diagnostics uses the default diagnostics storage account or creates a new storage account.

    Note

    [*] These analysis scenarios are only supported on Windows.

  6. Review the legal terms and privacy policy, and select the corresponding checkbox to acknowledge (required).

    To install and run Performance Diagnostics, you must agree to the legal terms and accept the privacy policy.

  7. Select Apply to apply the selected options and install the tool.

    A notification is displayed as Performance Diagnostics starts to install. After the installation is completed, you see a notification that indicates that the installation is successful. If the Run on-demand diagnostics option is selected, the selected performance analysis scenario is then run for the specified duration.

View insights and reports

This table compares the data provided by Continuous and On-demand Performance Diagnostics. For a complete list of all the collected diagnostics data, see What kind of information is collected by PerfInsights? on Windows or Linux.

Continuous Performance DiagnosticsOn-demand Performance Diagnostics
AvailabilityCurrently supported only for Windows VMsSupported for both Windows and Linux VMs
Insights generatedContinuous actionable insights into high resource usage, such as high CPU, high memory, and high disk usageOn-demand actionable insights into high resource usage and various system configurations
Data collection frequencyCollects data every 5 seconds, updates uploaded every 5 minutesCollect data on demand for the selected duration of the on-demand run
Reports generatedDoesn't generate a reportGenerates a report with comprehensive diagnostics data

View Performance Diagnostics insights

The Performance Diagnostics insights tab lists insights for the selected time period. Each row presents an insight, its impact level, category, and related recommendations. Select Refresh to view newly generated continuous diagnostics insights.

Use filters to retrieve insights by timestamp, impact, category, or diagnostic type.

Select a row to view more details.

View or download the Performance Diagnostics report for an on-demand insight in the list by selecting View or Download, respectively. For more information, see Download and review the full Performance Diagnostics report.

Use the grouping dropdown to group or ungroup insights. You can group on-demand and continuous insights by category, insight, or recommendation.

View Performance Diagnostics reports

The Performance Diagnostics reports tab list all of the on-demand diagnostics reports that were run. The list indicates the type of analysis that was run, insights that were found, and their impact levels.

Select a row to view more details.

Each Performance Diagnostics report might contain several insights, and each insight includes recommendations.

The Impact column indicates an impact level of High, Medium, or Low, which shows the potential for performance issues, based on factors such as misconfiguration, known problems, or issues that are reported by other users. You might not yet be experiencing one or more of the listed issues. For example, you might have SQL log files and database files on the same data disk. This condition has a high potential for bottlenecks and other performance issues if the database usage is high, whereas you might not notice an issue if the usage is low.

Select the Download report button to download an HTML report that contains richer diagnostics information, such as storage and network configuration, performance counters, traces, list of processes, and logs. The content depends on the selected analysis. For advanced troubleshooting, the report might contain additional information and interactive charts related to high CPU usage, high disk usage, and processes that consume excessive memory. For more information about the Performance Diagnostics report, see Windows or Linux.

Note

You can download Performance Diagnostics reports from the Performance Diagnostics screen within 30 days after you generate them. After 30 days, you might get an error when you download a report from the Performance Diagnostics screen. To get a report after 30 days, go to the storage account and download it from a binary large object (BLOB) container that's named azdiagextnresults. You can view the storage account information by using the Settings button on the toolbar.

View and manage storage account and stored data

Performance Diagnostics stores all insights and reports in a storage account, which you can configure for short data retention to minimize costs.

To ensure Performance Diagnostics functions correctly, you must enable the Allow storage account key access setting for the storage account. To enable this setting, follow these steps:

  1. Navigate to your storage account.
  2. In the storage account settings, locate the Configuration section.
  3. Find the Allow storage account key access option and set it to Enabled.
  4. Save your changes.

You can use the same storage account for multiple VMs that use Performance Diagnostics. When you change the storage account, the old reports and insights aren't deleted. However, they'll no longer be displayed in the list of diagnostics reports.

Note

Performance Diagnostics stores insights in Azure tables and stores reports in a binary large object (BLOB) container.

If your storage account uses private endpoints, to make sure that Performance Diagnostics can store insights and reports in the storage account:

  1. Create separate private endpoints for Table and BLOB.
  2. Add DNS configuration to each separate private endpoint.

View diagnostics data stored in your account

To view these files:

  1. Navigate to your storage account.

  2. Select Storage browser.

    Troubleshoot performance issues on Azure virtual machines using Performance Diagnostics (PerfInsights) - Virtual Machines (8)

    Performance Diagnostics stores reports in a binary large object (BLOB) container, named azdiagextnresults, and insights in tables.

    Insights include:

    • All the insights and related information about the run.
    • An output compressed (.zip) file (named PerformanceDiagnostics_yyyy-MM-dd_hh-mm-ss-fff.zip) on Windows and a tar file (named PerformanceDiagnostics_yyyy-MM-dd_hh-mm-ss-fff.tar.gz) on Linux that contains log files.
    • An HTML report.
  3. To download a report, select Blob containers > azdiagextnresults > <report name> > Download.

Change storage accounts

To change storage accounts:

  1. Select the Settings toolbar button to change the storage account where the diagnostics insights and output are stored.

    This opens the Performance diagnostic settings screen.

  2. Select Change storage account to select a different storage account.

Uninstall Performance Diagnostics

Uninstalling Performance Diagnostics from a VM removes the VM extension but doesn't affect any diagnostics data in the storage account.

To uninstall Performance Diagnostics, select the Uninstall button on the toolbar.

Frequently asked questions

When you open a support ticket with Microsoft, it's important to share the Performance Diagnostics report from an on-demand Performance Diagnostics run. The Microsoft CSS contact will provide you with the option to upload the on-demand Performance Diagnostics report to a workspace. There are two ways to download the on-demand Performance Diagnostics report to share with Microsoft CSS:

Option 1: Download the report from Performance Diagnostics blade, as described in View Performance Diagnostics reports.

Option 2: Download the report from the storage account, as described in View and manage storage account and stored data.

How do I capture diagnostics data at the correct time?

We recommend you run Continuous Performance Diagnostics, which captures VM diagnostics data on an ongoing basis.

The On-demand Performance Diagnostics run has two stages:

  1. Install or update the Performance Diagnostics VM extension.
  2. Run the diagnostics for the specified duration.

Currently, there's no easy way to know exactly when the VM extension installation is complete. It takes about 45 seconds to 1 minute to install the VM extension. After the VM extension is installed, you can run your repro steps to have the On-deman Performance Diagnostics capture the correct set of data for troubleshooting.

Will Performance Diagnostics continue to work when I move my Azure VM across regions?

Azure VMs, and related network and storage resources, can be moved across regions by using Azure Resource Mover. However, moving VM extensions across regions, including the Azure Performance Diagnostics VM extension, isn't supported. You have to install the extension manually on the VM in the target region after you move the VM. For more information, see Support matrix for moving Azure VMs between Azure regions.

What is the performance impact of enabling Continuous Performance Diagnostics?

We ran 12-hour tests of Continuous Performance Diagnostics on a range of Windows OS versions, Azure VMs of sizes, and CPU loads.

The test results, presented in this table, show that Continuous Performance Diagnostics provides valuable insights with minimal impact on system resources:

OS versionVM sizeCPU loadAvgerage CPU usage90 percentile CPU usage99 percentile CPU usageMemory usage
Windows Server 2019B2s, A4V2, D5v220%, 50%, 80%<0.5%2%3%42-43 MB
Windows Server 2016 SQLB2s, A4V2, D5v220%, 50%, 80%<0.5%2%3%42-43 MB
Windows Server 2019B2s, A4V2, D5v220%, 50%, 80%<0.5%2%3%42-43 MB
Windows Server 2022B2s, A4V2, D5v220%, 50%, 80%<0.5%<0.5%3%42-43 MB

Back of the napkin calculations of storage costs

Continuous Performance Diagnostics stores insights in a table and a JSON file in a blob container. Given that each row is approximately 0.5 KB (kilobyte) and the report is approximately 9 KB before compression, two rows every five minutes plus the corresponding report upload comes out to 10 KB, or 0.00001 GB.

Now, let’s calculate the storage cost:

  • Rows per month: 17,280
  • Size per row: 0.00001 GB

Total data size: 17,280 x 0.000001 = 0.1728 GB

Data storage cost: $0.1728 x $0.045 = $0.007776

Therefore, assuming steady stress on the VM, the storage cost is estimated to be less than one cent per month, assuming you use locally redundant storage.

If you have questions or need help, create a support request, or ask Azure community support. You can also submit product feedback to Azure feedback community.

Troubleshoot performance issues on Azure virtual machines using Performance Diagnostics (PerfInsights) - Virtual Machines (2024)
Top Articles
How to Mix One Part Solution to Four Parts Water
Chia Network Price | XCH Price, USD converter, Charts | Crypto.com
Northern Counties Soccer Association Nj
#ridwork guides | fountainpenguin
Joliet Patch Arrests Today
Citibank Branch Locations In Orlando Florida
Unitedhealthcare Hwp
2024 Fantasy Baseball: Week 10 trade values chart and rest-of-season rankings for H2H and Rotisserie leagues
Boggle Brain Busters Bonus Answers
Holly Ranch Aussie Farm
Atrium Shift Select
Minn Kota Paws
Mawal Gameroom Download
Ukraine-Russia war: Latest updates
Hssn Broadcasts
Summer Rae Boyfriend Love Island – Just Speak News
Non Sequitur
Sivir Urf Runes
Operation Cleanup Schedule Fresno Ca
What is Rumba and How to Dance the Rumba Basic — Duet Dance Studio Chicago | Ballroom Dance in Chicago
Nissan Rogue Tire Size
The Exorcist: Believer (2023) Showtimes
Band Of Loyalty 5E
Bekijk ons gevarieerde aanbod occasions in Oss.
Trivago Myrtle Beach Hotels
Bento - A link in bio, but rich and beautiful.
Strange World Showtimes Near Savoy 16
Drying Cloths At A Hammam Crossword Clue
Fuse Box Diagram Honda Accord (2013-2017)
Dell 22 FHD-Computermonitor – E2222H | Dell Deutschland
Weather Underground Durham
Tracking every 2024 Trade Deadline deal
Craig Woolard Net Worth
Pipa Mountain Hot Pot渝味晓宇重庆老火锅 Menu
R/Orangetheory
Baddies Only .Tv
Chris Provost Daughter Addie
Case Funeral Home Obituaries
Pp503063
Rs3 Bis Perks
Taylor University Baseball Roster
Trivago Anaheim California
Busted Newspaper Mcpherson Kansas
Powerboat P1 Unveils 2024 P1 Offshore And Class 1 Race Calendar
Television Archive News Search Service
Makes A Successful Catch Maybe Crossword Clue
Breaking down the Stafford trade
Neil Young - Sugar Mountain (2008) - MusicMeter.nl
Minecraft: Piglin Trade List (What Can You Get & How)
Rocket Bot Royale Unblocked Games 66
Haunted Mansion Showtimes Near The Grand 14 - Ambassador
Emmi-Sellers
Latest Posts
Article information

Author: Domingo Moore

Last Updated:

Views: 5823

Rating: 4.2 / 5 (73 voted)

Reviews: 80% of readers found this page helpful

Author information

Name: Domingo Moore

Birthday: 1997-05-20

Address: 6485 Kohler Route, Antonioton, VT 77375-0299

Phone: +3213869077934

Job: Sales Analyst

Hobby: Kayaking, Roller skating, Cabaret, Rugby, Homebrewing, Creative writing, amateur radio

Introduction: My name is Domingo Moore, I am a attractive, gorgeous, funny, jolly, spotless, nice, fantastic person who loves writing and wants to share my knowledge and understanding with you.