Friday, February 11, 2011

PerfMon problems - Unable to Add Counters

"Unable to add these counters:

\Memory\Available MBytes
\Memory\% Committed Bytes In Use
\Memory\Cache Faults/sec
\Memory\Cache Faults/sec
\PhysicalDisk(*)\%Idle Time
\PhysicalDisk(*)\Avg. Disk Queue Length
\Network Interface(*)\Bytes Total/sec"

Solution

Click Start, type cmd right click cmd.exe, and select Run as administrator.
At the prompt, type lodctr /r and press ENTER. This will repair the pointers (those are stored in the registry).

C:\Windows\system32>lodctr /r


Info: Successfully rebuilt performance counter setting from system backup store

After this action it is possible that some providers are disabled. You can check the status with lodctr /q.

C:\Windows\system32>lodctr /q
Performance Counter ID Queries [PERFLIB]:
Base Index: 0x00000737 (1847)
Last Counter Text ID: 0x00001560 (5472)
Last Help Text ID: 0x00001561 (5473) [.NET CLR Data] Performance Counters (Enabled)
DLL Name: netfxperf.dll
Open Procedure: OpenPerformanceData
Collect Procedure: CollectPerformanceData
Close Procedure: ClosePerformanceData
First Counter ID: 0x00001080 (4224)
Last Counter ID: 0x0000108C (4236)
First Help ID: 0x00001081 (4225)
Last Help ID: 0x0000108D (4237)

etc

If it says (Disabled) next to a provider, you can enable it with lodctr /e:<provider name>. Use for <provider name> the string between the [ ] at the beginning of the entry.

No comments:

Post a Comment