[翻译文章]性能监视器的计数器 之二 内存性能计数器

作者: 小古 分类: 电脑技术 发布时间: 2011-12-25 ė12368 次浏览 60 条评论
  • 处理器性能计数器. 这部分描述了与处理器对象相关的最重要的计数器.
  • 内存性能计数器. 这部分描述了与内存对象相关联的最重要的计数器.
  • 磁盘性能计数器. 这部分描述了与物理磁盘和逻辑磁盘对象相关联的最重要的计数器.
  • 网络性能计数器. 这部分描述了与网络接口, 网络分段, TCP/IP组件相关的最重要的计数器.
  • 内存性能计数器

    ====================

    下面的计数器们都与内存管理的问题有关. 另外, 其中还有一些计数器可以协助你确定你所面对的问题是不是一个内存问题.

    Memory : Page Faults/sec.

    --------------------------

    这个计数器给予我们一个基本的想法: 发生过多少次被请求的信息并不在应用程序所期望这些信息应该在的地方. 这个信息一定要被得到, 要么从内存的另一个地方, 要么在页面文件中. 请注意, 当这里出现一个持续的值的时候, 你应该多留意"硬页面错误", 它带博鳌这对磁盘的真实读写操作. 记住, 磁盘访问比内存要慢很多很多.

    Memory : Pages Input/sec.

    --------------------------

    用这个计数器跟Page Faults/sec计数器进行比较, 来确定页面错误是硬页面错误的概率.

    因此, Pages Input/sec / Page Faults/sec = % Hard Page Faults. 该值持续的超过百分之40%, 大体上说明某种内存不足的情况正在发生. 通过这点, 你知道系统中现在存在着某种内存不足, 但这还不能完全作为系统需要马上进行内存升级的证据.

    Memory : Pages Output/sec.

    --------------------------

    随着所需求的内存越来越多, 你可以预期到从内存中移出的信息量会增长. 这甚至可以在硬页面错误之前先暴露出来成为问题. 随着内存越用越少, 系统首先会试图将应用程序的working set降到最小值. 这意味着从内存中移出更多的信息到磁盘上. 因而, 如果你系统濒临于真正的内存枯竭的时候, 你会看到这个值的攀升. 经常地先从内存中被移出的页面时数据页. 因为代码页会经历多次的重复使用.

    Memory : Pages/sec.

    -----------------------------

    这个值经常被与Page Faults/sec混淆. Pages/sec计数器是Pages Input/secPages Output/sec两个计数器的组合. 请注意, Page Faults/sec 是硬页面错误和软页面错误的组合. 这个计数器, 总的来说, 是一个系统使用硬盘来存储或读取相关数据的频率的一个大体指示器.

    Memory : Page Reads/sec.

    ----------------------------

    这个计数器可能是内存不足的最佳指示器了, 因为它指示着系统从由于硬页面错误而从磁盘读取数据的频率. 系统永远都在使用pagefile, 即使系统中有足够的内存来支持所有的应用程序. 因此, 某种程度上的页面读取总是会遇到的. 然而, 持续的超过5次每秒是一个内存短缺的强烈信号. 你必须小心的查看这些计数器来理解他们告诉你的信息. 这个计数器又一次阐述了从硬盘读取数据来解决页面错误的次数. 每次系统到磁盘进行页面读取的量可能实际有不小的差异. 这是应用程序一个功能, 并且接近硬盘驱动器上的数据的量. 与此事实无关的是, 这个值持续地超过5, 那就是一个内存问题的强烈信号. 记住这里的形容词"持续"的重要性. 系统操作经常有起伏, 有时候还是大幅度的起伏. 所以, 仅仅靠系统在几秒内Page Reads/sec达到24, 并不意味着你有内存不足的问题.

    Memory : Page Writes/sec.

    -----------------------------------------

    与Page Reads/sec相像, 这个计数器表明为了清除内存中不用的item, 磁盘被写入的次数. 再次说明, 每次读取的页面的数据可能会变化. 这个计数器值的增加经常标示正在形成的内存资源的紧张.

    Memory : Available Memory.

    -----------------------------------------

    This counter indicates the amount of memory that is left after nonpaged pool allocations, paged pool allocations, process' working sets, and the file system cache have all taken their piece. In general, NT attempts to keep this value around 4 MB. Should it drop below this for a sustained period, on the order of minutes at a time, there may be a memory shortage. Of course, you must always keep an eye out for those times when you are simply attempting to perform memory intensive tasks or large file transfers.

    Memory : Nonpageable memory pool bytes.

    -----------------------------------------

    This counter provides an indication of how NT has divided up the physical memory resource. An uncontrolled increase in this value would be indicative of a memory leak in a Kernel level service or driver.

    Memory : Pageable memory pool bytes.

    -----------------------------------------

    An uncontrolled increase in this counter, with the corresponding decrease in the available memory, would be indicative of a process taking more memory than it should and not giving it back.

    Memory : Committed Bytes.

    -----------------------------------------

    This counter indicates the total amount of memory that has been committed for the exclusive use of any of the services or processes on Windows NT. Should this value approach the committed limit, you will be facing a memory shortage of unknown cause, but of certain severe consequence.

    Process : Page Faults/sec.

    -----------------------------------------

    This is an indication of the number of page faults that occurred due to requests from this particular process. Excessive page faults from a particular process are an indication usually of bad coding practices. Either the functions and DLLs are not organized correctly, or the data set that the application is using is being called in a less than efficient manner.

    Process : Pool Paged Bytes.

    -----------------------------------------

    This is the amount of memory that the process is using in the pageable memory region. This information can be paged out from physical RAM to the pagefile on the hard drive.

    Process : Pool NonPaged Bytes.

    -----------------------------------------

    This is the amount of memory that the process is using that cannot be moved out to the pagefile and thus will remain in physical RAM. Most processes do not use this, however, some real-time applications may find it necessary to keep some DLLs and functions readily available in order to function at the real-time mode.

    Process : Working Set.

    -----------------------------------------

    This is the current size of the memory area that the process is utilizing for code, threads, and data. The size of the working set will grow and shrink as the VMM can permit. When memory is becoming scarce the working sets of the applications will be trimmed. When memory is plentiful the working sets are allowed to grow. Larger working sets mean more code and data in memory making the overall performance of the applications increase. However, a large working set that does not shrink appropriately is usually an indication of a memory leak.

    本文出自 小古Blog,转载时请注明出处及相应链接。

    本文永久链接: http://blog.chdz1.com/?post=123

    |

    发表评论:

    电子邮件地址不会被公开。 必填项已用*标注

    Ɣ回顶部
    sitemap