System.PlatformNotSupportedException: Performance Counters are not supported on this platform

As per agent logs, we receive error System.PlatformNotSupportedException: Performance Counters are not supported on this platform
due to which System metrics won't be collected. Can Someone help me with this, we are using public API for manual instrumentation of our Application (windows service)

Full logs -
2024-07-26 14:19:34.6630|ERROR|glodsm02z02454|54928|73|{SystemTotalCpuProvider} Error instantiating 'Processor' performance counter|Axis.Streams.Common.General.Apm.ApmLoggerAdapter.Log|System.PlatformNotSupportedException: Performance Counters are not supported on this platform.
at System.Diagnostics.PerformanceCounter..ctor(String categoryName, String counterName, String instanceName)
at Elastic.Apm.Metrics.MetricsProvider.SystemTotalCpuProvider.GetSamples()
2024-07-26 14:19:34.6837|WARN|glodsm02z02454|54928|73|{SystemTotalCpuProvider} System metrics won't be collected|Axis.Streams.Common.General.Apm.ApmLoggerAdapter.Log|
2024-07-26 14:19:34.6837|WARN|glodsm02z02454|54928|73|{MetricsCollector} Failed reading total system CPU time 1 times: no valid samples|Axis.Streams.Common.General.Apm.ApmLoggerAdapter.Log|
.Net Core - 6
Elastic.APM Package - 1.26
Agent Version - 1.25

Thanks in Advance.

Hi,

the error is very clear: PerformanceCounter is only supported on Windows - I guess you are on Linux?

Best regards
Wolfram

@Wolfram_Haussig We have all windows servers on which applications are hosted. Not sure what are we missing here?