Microsoft KB Archive/266416

= How to troubleshoot WinMgmt-based performance counter errors =

Article ID: 266416

Article Last Modified on 10/11/2007

-

APPLIES TO


 * Microsoft Windows Server 2003, Standard x64 Edition
 * Microsoft Windows Server 2003, Enterprise x64 Edition
 * Microsoft Windows Server 2003, Datacenter x64 Edition
 * Microsoft Windows Server 2003, Standard Edition (32-bit x86)
 * Microsoft Windows Server 2003, Enterprise Edition
 * Microsoft Windows Server 2003, Datacenter Edition (32-bit x86)
 * Microsoft Windows Server 2003, Web Edition
 * Microsoft Windows 2000 Server
 * Microsoft Windows 2000 Professional Edition

-



This article was previously published under Q266416



Important This article contains information about how to modify the registry. Make sure to back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry



SYMPTOMS
When you view the Application Event Viewer log on your computer, one or more of the following events may be logged.

Event message 1

Event Type: Error

Event Source: WinMgmt

Event Category: None

Event ID: 37

Description: WMI ADAP was unable to load the  performance library due to an unknown problem within the library: 0x0

Event message 2

Event Type: Error

Event Source: WinMgmt

Event Category: None

Event ID: 41

Description: WMI ADAP was unable to create Object Index  from the Performance Library   because the value is not found in 009 subkey

Event message 3

Event Type: Error

Event Source: WinMgmt

Event Category: None

Event ID: 61

Description: WMI ADAP was unable to process the  performance library due to a time violation in the open function



CAUSE
This behavior can occur because either there may be a problem in the counter, or there may be a false-positive return value in the Windows Management Instrumentation (WMI) Performance Library dredger. If there is a false-positive return value in the WMI Performance Library dredger, in certain situations, the dredger may incorrectly determine that a library is invalid even though the counter works correctly.



WORKAROUND
Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall your operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.

Try to dredge the computer's performance libraries again by using the following commands:

winmgmt /clearadap

This command clears all WMI-related values from the service's performance registry key.

winmgmt /resyncperf &quot;winmgmt service pid&quot;

This command registers the computer's performance libraries with the WMI.

You can find the WMI service PID information on the Process tab of Windows Task Manager.

The performance registry keys for the involved services include the following registry keys:

WbemAdapFileSize

WbemAdapFileTime

WbemAdapStatus

Note For more information about the command options that are available with WMI, type winmgmt/? at a command prompt.

Another possible cause for the events may be that the counters are slow to respond due to other activities during startup. You can tune this timeout by adding the value Collect Timeout REG_DWORD 10000 to the appropriate registry location:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\[counterfile]\Performance

Where [counterfile] is the  performance library listed in the error message from Event Viewer.

For example, if the message in Event Viewer is

WMI ADAP was unable to process the perfproc.dll performance library due to a time violation in the open function

then the registry key will be:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\PerfProc\Performance

Please note that this registry path does not include the file extension (.dll). If events continue to be logged after you make these changes, change the WbemAdapStatus value manually to REG_DWORD 0 under the service's performance registry key, and then increase the ADAPPerflibTimeout value to REG_DWORD 180 in the following registry key:

HKEY_LOCAL_MACHINE\Software\Microsoft\Wbem\CIMOM

Note You must enter all registry changes as decimal values.

In addition, you can disable performance counters for a specific service with the Exctrlst.exe utility from the Windows 2000 Resource Kit. This utility disables the specific counter by adding a registry key similar to the example below. You can add these registry entries under the specific counter entry manually if Exctrlst.exe is not available or desirable.

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Spooler\Performance

Value name: Disable Performance Counters

Value type: REG_DWORD

Value data: 1

Note To use these commands, click Start, Run, and then type cmd to access the command prompt.



MORE INFORMATION
The AutoDiscovery/AutoPurge (ADAP) process is responsible for collecting and maintaining performance counter objects in WMI that are registered on the computer.

The ADAP process starts when the WinMgmt service is started or when you install or uninstall the performance libraries, which contain the performance counters, by using either the Lodctr or Unlodctr utilities.

Although the events are logged, the counters are still available.

For more information about event ID 41, visit the following Microsoft Web site:

http://www.microsoft.com/technet/support/ee/SearchResults.aspx?Type=1&Source=WinMgmt&ID=41&Product=Windows%20Operating%20System&Language=1033

Technical support for x64-based versions of Microsoft Windows
If your hardware came with a Microsoft Windows x64 edition already installed, your hardware manufacturer provides technical support and assistance for the Windows x64 edition. In this case, your hardware manufacturer provides support because a Windows x64 edition was included with your hardware. Your hardware manufacturer might have customized the Windows x64 edition installation by using unique components. Unique components might include specific device drivers or might include optional settings to maximize the performance of the hardware. Microsoft will provide reasonable-effort assistance if you need technical help with a Windows x64 edition. However, you might have to contact your manufacturer directly. Your manufacturer is best qualified to support the software that your manufacturer installed on the hardware. If you purchased a Windows x64 edition such as a Microsoft Windows Server 2003 x64 edition separately, contact Microsoft for technical support.

For product information about Microsoft Windows XP Professional x64 Edition, visit the following Microsoft Web site:

http://www.microsoft.com/windowsxp/64bit/default.mspx

For product information about x64-based versions of Microsoft Windows Server 2003, visit the following Microsoft Web site:

http://www.microsoft.com/windowsserver2003/64bit/x64/default.mspx

Additional query words: wmi performance counter event adap kbfaqw2kperf Winx64 Windowsx64 64bit 64-bit

Keywords: kbprb KB266416

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.