Download (direct link):
Figure 14-2: A proper Properties sheet.
Performance logs and alerts
If you have a heart problem, the doctor may put you on a heart monitor that tracks cardiac activity for a 24-hour period or longer. That monitoring device may also have an alarm that sounds when the patient's heart rate strays outside safe limits, for example, when watching Baywatch.
The Performance console's Performance Logs and Alerts snap-in can generate log files that you can collect over a reasonable time period and then view at your leisure later, using the same System Monitor display that you use to watch real-time data. (Click the View Log Data toolbar icon and specify the log filename on the Source tab.) You can also configure performance alerts that trigger events or messages when certain threshold levels are violated.
Time Shaver Here's what you must know about the Performance Logs and Alerts snap-in:
* Counter logs let you create disk files that record the state of object counters you specify, at a frequency you specify. The default format is *.BLG, for Binary LoG.
* Trace logs monitor a particular value continuously, rather than at sampling intervals. You can't trace every object counter that you can run counter logs for.
* Alerts can specify a minimum or maximum threshold for any counter, and can generate an application log entry, send a message to any computer on the network (see Figure 14-3), start a log file, and/or run any program you specify.
Figure 14-3: An alert message stating that lots of disk paging is going on.
* Create a new log or alert by selecting the appropriate branch under the Performance Logs and Alerts snap-in in the left window pane, and by right-clicking the right (details) window pane and choosing New Log Settings or New Alert Settings. Give the log or alert a name and set its properties.
* All logs go by default to the C:\PERFLOGS folder.
* You need to be an Administrator to set logs and alerts.
* If you set the sampling frequency or number of counters too high, you can run out of disk space in a major hurry.
* You can use the Schedule tab on the property sheets of logs and alerts to set begin and end times, or you can start and stop logs and alerts manually by right-clicking the icon in the details pane and choosing Start or Stop.
If the Performance console is like a $500 oscilloscope, Task Manager is like a $50 handheld voltmeter. Less complete than the Performance console, but also easier to understand and use, Task Manager comes in handy for taking a quick look at key system performance variables. Activate Task Manager by pressing Ctrl+Alt+Del and clicking the Task Manager button. (I know, it seems like a weird way to get to a program. A faster way is to choose Start?Run and type TASKMGR.) You should see a screen similar to the one shown in Figure 14-4, with (at minimum) the three tabs Applications, Processes, and Performance, and (if you're networked) Networking.
Figure 14-4: The Task Manager Processes display.
The Applications tab has the simplest display and shows a list of running programs and their status (usually either 'running' or 'not responding'). The Processes tab shows not only programs but also services and operating system executables, along with CPU and memory usage by process. The Performance tab (see Figure 14-5) shows overall figures for CPU and memory usage, along with rolling line graphs. I'll have more to say about the Performance tab later in this chapter in the section 'Determining the right amount of RAM.' Finally, the Networking tab shows network card traffic as a percentage of available bandwidth; the scale adjusts automatically.
Figure 14-5: The Task Manager Performance display.
Windows 2002 and 2000 Server come with a tool named Network Monitor, which permits analysis of frames (network packets) sent and received by using the server's network interface card(s). The BackOffice product Systems Management Server comes with an industrial strength version of Network Monitor that can monitor packet traffic at client workstations as well as servers. Windows XP Professional doesn't come with either version of Network Monitor, but it does come with a Network Monitor driver that permits SMS to watch traffic on a Windows XP Professional PC. Install the Network Monitor driver as you would any network protocol.
Processor tuning falls into three categories: monitoring existing CPU usage, adjusting the foreground-to-background CPU time split, and adding a second CPU. The next sections deal with each topic in turn.
Tip Microsoft specifies a Pentium 233 CPU for running Windows XP Professional. As a practical matter, you want a more powerful CPU than that. A Pentium II class processor running at 300 megahertz is a more realistic minimum level. Windows XP is, shall we say, not the most efficient operating system in terms of processor requirements!
You can perform some quick-and-dirty CPU monitoring in Task Manager. The Applications and Processes tabs let you see which applications and processes are using the most CPU time while the Performance tab lets you watch total CPU usage via a graphical display. You can keep an eye on the Performance tab while opening and running typical applications on the system to get a sense of whether the CPU may be a bottleneck. You may find that one application in particular is a CPU hog and you may be able to modify its default settings to reduce the performance drain it causes.