Subscribe to Windows IT Pro
July 31, 2001 12:00 AM

Monitoring CPU Performance Counters

Windows IT Pro
InstantDoc ID #21990
Rating: (0)

The age-old question in IIS performance (and Windows server performance, for that matter) is "What makes IIS run faster—memory or the CPU?" The answer to this question is complex and depends on many factors. But if you're experiencing IIS latency or performance problems, some simple monitoring can help you diagnose whether the CPU is the problem.

CPU performance latency occurs when one or more processes consume a majority of the processor time. Threads that are ready to be executed have to wait in a queue for the processor to become available. Trying to overcome a processor bottleneck by throwing hardware (e.g., more memory, faster disks, more network connections) at the problem won't help. In fact, in most cases, doing so often makes matters worse.

Monitoring CPU performance counters in IIS can yield interesting results on your sites. To run performance monitoring on Windows 2000 Server, click Start, Programs, Administrative Tools, Performance. To add performance monitors, simply right-click on the graph surface and select Add Counters. The Performance Monitor tool groups counters logically within performance objects (e.g., the processor-related counters are grouped within a performance object called Processor). Choose the performance object group you want, then choose the counter from the list. Each counter has an Explain button that you can click for more information about its function.

Here's a description of some CPU performance monitors and why you should track them:

  • System, Counter: Processor Queue Length. This Performance Monitor counter displays the number of threads waiting to be executed in the queue, which all the processors on your system share. If this counter has a sustained value of two or more threads, you have a processor bottleneck on your hands. The problem could be a renegade component or a poorly written application, but it might just be that your system is overloaded.
  • Processor, Counter: % Processor Time. If Processor Time numbers are high and the NIC and disk I/O remaining numbers are well below capacity, you're experiencing a CPU bottleneck. On a multiprocessor computer, I recommend that you monitor the Processor: % Processor Time counter to determine whether the system is imbalanced.
  • Processor, Counter: Interrupts/sec and Performance Object; Processor, Counter: % DPC Time. You can use these Performance Monitor counters to determine how much time the processor spends on interrupts and deferred procedure calls (DPCs). Both interrupts and DPCs can be huge sources of load on your servers' CPUs. Client requests can drive these problems. Some new NICs include interrupt moderation, which accumulates interrupts in a buffer when the level of interrupts becomes too high. Interrupt moderation alleviates the interrupt problem, but you won't find this feature on most network boards that have been in production a while.

A wealth of performance-monitoring information is available, yet most IIS administrators don't take advantage of these capabilities. Let's hope that this information gets you well on your way to successful performance monitoring of the processors in your servers.

Related Content:

ARTICLE TOOLS

Comments
  • gaurang
    8 years ago
    Apr 19, 2004

    i want to know source code of cpu performance in either java or vc++. so can you please find and mail me on this email address - gmshastri@yahoo.com.

You must log on before posting a comment.

Are you a new visitor? Register Here

advertisement

advertisement

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.