Unable to create system performance counter with error code PDH_CSTATUS_NO_MACHINE

One of our case we faced with annoying ULS log errors about performace counters. Multiple errors like below filling ULS logs and keep inflated rapidly.

Unable to create system performance counter ComputerName\Memory\Available Mbytes\. The following exception was thrown: System.ComponentModel.Win32Exception: Unknown error (0x800007d0) at Microsoft.SharePoint.Win32.SPPdh.CheckReturnValue(PDH_STATUS status, Boolean throwOnError) at Microsoft.SharePoint.Utilities.SPPerformanceCounter.Initialize() at Microsoft.SharePoint.Utilities.SPPerformanceCounter.NextValue(Int32 retry, Int32 retryInterval) at Microsoft.SharePoint.Utilities.SPPerformanceCounterMonitorInternal.UpdateValue() at Microsoft.SharePoint.Utilities.SPPerformanceCounterMonitorInternal.Create(String computer, String category, String counter, String instance)
Performance Counter OS (pdh) call failed with error code PDH_CSTATUS_NO_MACHINE.

Cause:
Microsoft Sharepoint Timer Service’s account does not have the necessary permissions to access the performance counters on the server.

Resolution:
Find Microsoft Sharepoint Timer Service account and set the account as local admin on all machines in farm.

Advertisements