Iis – ASPNET WMI class not available

iisperformance-counterswmi

I need to extract the ASPNET\Requests Queued performance counter from some IIS servers via WMI.

The WMI class for this sort of thing appears to be contained in Win32_PerfFormattedData_ASPNET_ASPNET. I've queried all available classes in root\cimv2 on my Win 2003/IIS6 servers, and it's not listed.

It is, however, available on an unrelated Win2008/IIS7 box (which is interesting but doesn't really help me much). I can view these counters in PerfMon without any issues.

What gives? Why is this WMI class not available on my Windows 2003 servers?

Best Answer

Check the following registry keys and ensure "Disable Performance Counters" is either not present, or set to 0:


HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ASP.NET\Performance\Disable Performance Counters
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ASP.NET_2.0.50727\Performance\Disable Performance Counters
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ASP.NET_64\Performance\Disable Performance Counters
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ASP.NET_64_2.0.50727\Performance\Disable Performance Counters

If you have a 32-bit OS, only the first two keys will be present. If you have a 64-bit OS, all 4 keys will be present.

Related Topic