Perfmon:哪个计数器标识线程正在等待?

在加载testingASP.NET应用程序时,我们发现页面在重负载下需要20-30秒。

我们怀疑这是因为页面正在等待数据库调用或Web服务。

是否有一个特定的perfmon计数器可以识别这种Web服务器上的瓶颈? CPU,内存和磁盘是正常的。

或者我们必须使用perfmon以外的工具来追踪这个瓶颈?

如果您怀疑特定应用程序或服务导致内存泄漏,请使用以下计数器调查应用程序的内存使用情况:

Memory\Available Bytes reports available bytes; its value tends to fall during a memory leak. Memory\Committed Bytes reports the private bytes committed to processes; its value tends to rise during a memory leak. Process\Private Bytes reports bytes allocated exclusively for a specific process; its value tends to rise for a leaking process. Process\Working Set reports the shared and private bytes allocated to a process; its value tends to rise for a leaking process. Process\Page Faults/sec reports the total number of faults (hard and soft faults) caused by a process; its value tends to rise for a leaking process. Process\Page File Bytes reports the size of the paging file; its value tends to rise during a memory leak. Process\Handle Count reports the number of handles that an application opened for objects it creates. Handles are used by programs to identify resources they must access. The value of this counter tends to rise during a memory leak; however, you cannot rule out a leak simply because this counter's value is stable. 

内存泄漏和非分页池

尽pipe任何泄漏都是严重的,但是当涉及非分页池时,内存泄漏尤其值得关注。 许多系统服务从非分页池中分配内存,因为它们在处理中断时需要引用它,并且当时不能引发页面错误。 要确定泄漏是否会影响非分页池,请在监视中包含以下计数器:

 Memory\Pool Nonpaged Bytes Memory\Pool Nonpaged Allocs Process\Pool Nonpaged Bytes 

如何识别:泄漏的应用程序不断要求更多的内存。 它的特点是以与系统提交字节相同的速率增加进程/页面文件字节; 即所有的记忆承诺是由于一个过程。 可用字节数量在不断减less,直到系统页面出来,然后虚拟字节增加,为更多可用字节腾出空间。 泄漏应用程序的工作集实际上会在部分页面被调出时降低。 请注意,“可用字节数”下降时页​​面错误数/秒数将增加。

Windows资源工具包包含一个名为LeakyApp.exe的示例程序。 这个程序有不断分配越来越多内存的典型错误。