Skip to content

Some perf counters aren't collected when app is hosted on Azure WebApp #1685

@tukaef

Description

@tukaef

Repro Steps

  1. Specify the following pefr counters to collect:
  • \.NET CLR Memory(??APP_CLR_PROC??)\# Total committed Bytes
  • \ASP.NET Applications(??APP_W3SVC_PROC??)\Request Bytes In Total
  • \ASP.NET Applications(??APP_W3SVC_PROC??)\Request Bytes Out Total

Actual Behavior

The counters aren't collected. The following message is logged:

AI: Error collecting 3 of the configured performance counters. Please check the configuration.
Counter .NET CLR Memory(??APP_CLR_PROC??)# Total committed Bytes: Failed to perform the first read for web app performance counter. Please make sure it exists. Counter: # Total committed Bytes
Counter \ASP.NET Applications(??APP_W3SVC_PROC??)\Request Bytes In Total: Failed to perform the first read for web app performance counter. Please make sure it exists. Counter: Request Bytes In Total
Counter \ASP.NET Applications(??APP_W3SVC_PROC??)\Request Bytes Out Total: Failed to perform the first read for web app performance counter. Please make sure it exists. Counter: Request Bytes Out Total

Expected Behavior

The counters are collected with the values exposed as environment variables as stated here https://docs.microsoft.com/bs-latn-ba/azure/azure-monitor/app/performance-counters#performance-counters-for-applications-running-in-azure-web-apps

Version Info

SDK Version : 2.12.1
.NET Version : 4.7
Hosting Info : Azure WebApps

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions