Article ID: 922775 - View products that this article applies to.
This article describes how to use common language runtime (CLR) performance counters and how to resolve known issues that occur when you use performance counters in the Microsoft .NET Framework 2.0. To monitor performance counters on a remote computer, you must be an administrator on the remote computer. If the remote computer is running Microsoft Windows Server 2003, you must be in the Performance Log Users (PLU) group or in the Performance Monitor Users (PMU) group. To log CLR performance counters, configure the user to run as a user who has administrative permissions. This article discusses issues that are related to monitoring or logging on CLR performance counters on remote computers.
The CLR supplies managed code together with services such as the following:
The following known issues may occur when you use CLR performance counters in the .NET Framework 2.0.
You cannot remotely monitor the CLR performance countersWhen you try to monitor the CLR performance counters on a remote computer in Perfmon, you receive an error message that resembles the following:
To resolve this issue, use one of the following methods.
Unable to connect to machine
Method 1: Verify that the Remote Registry service is running on the remote computerWhen this issue occurs, verify that the Remote Registry service is running on the remote computer. To do this, follow these steps:
Method 2: Verify that you have the required permissionsTo monitor CLR performance counters on a remote computer, the following conditions must be true:
You cannot view CLR performance counters even though you can connect to the remote computerIf the Windows Server 2003-based remote computer is running the Microsoft .NET Framework 1.1 Service Pack 1 (SP1), apply the hotfix that is described in the following Microsoft Knowledge Base article:
(http://support.microsoft.com/kb/924421/ )FIX: Application performance deteriorates or the computer stops responding when you run a .NET Framework 1.1 Service Pack 1-based application on a Windows 2003-based computer
You receive an "ACCESS_DENIED" error message when you try to start logging CLR performance countersWhen you try to start logging CLR performance counters, you may receive an error message that resembles the following:
This issue occurs because the first process to load the CLR performance counter DLL (Corperfmonext.dll) creates a named event for Inter-Process Communication (IPC) communication. A named event is created that uses the permissions for the user ID of the process.
Error code 5 (ACCESS_DENIED)
Unable to open shim database version registry key - v2.0.50727.00000. The Open Procedure for service ".NETFramework" in DLL "D:\WINNT\system32\mscoree.dll" failed. Performance data for this service will not be available. The Status code returned is the first DWORD in the attached data. The status code is 5 (ACCESS_DENIED)
For example, a user who has administrative permissions starts Perfmon. Then, the user begins to monitor CLR performance counters. The named event is created by using permissions that are granted to the Administrator group. In this scenario, the user receives the error message if the user tries to start logging CLR performance counters. This issue occurs because the "Performance Logs and Alerts" service cannot access the named event.
To work around this issue, load the Corperfmonext.dll file in the "Performance Logs and Alerts" service first. To do this, follow these steps:
You cannot monitor 32-bit managed programs in the 64-bit version of PerfmonThis issue occurs because the 64-bit version of the Corperfmonext.dll file only enumerates 64-bit processes. Additionally, the 32-bit version of the Corperfmonext.dll file only enumerates 32-bit processes. To view 32-bit managed programs on a 64-bit computer, click Start, click Run, type SystemRoot%\SysWOW64\perfmon.exe, and then click OK.
Note This issue is scheduled to be fixed in a future version of the .NET Framework.
Perfmon does not detect when a managed program restarts on the remote computerThis issue occurs because the Remote Registry service runs under the Local Service account. The Local Service account is not a member of the Performance Monitor Users group or of the Performance Log Users group. Therefore, the Local Service account does not have access to the CLR performance counter IPC block. Nevertheless, you can monitor CLR performance counters because the Remote Registry service impersonates the user who initiated the monitoring.
However, if the monitored process restarts, a new IPC block is opened by an auxiliary thread in the Remote Registry service. This auxiliary thread does not impersonate the user on the client. Therefore, the thread cannot access the CLR performance counter IPC block. To work around this issue, restart the performance counter monitoring from the client.
Multiple CLR performance counters appear that have names that resemble "W3wp#1"When multiple ASP.NET workers processes are running, CLR performance counters that have names that resemble "W3wp#1" or "W3sp#2" may appear. In the .NET Framework 2.0, a counter that is named Process ID was added to the .NET CLR Memory performance object. This counter displays the process ID for an instance. You can use this counter to determine the CLR performance counter that is associated with a process.
If you cannot see a counter that is named Process ID under .NET CLR Memory, the performance counter symbols may not be installed correctly. To resolve this issue, follow these steps: