4-2 Optimizing System Performance Part 2
> System Monitor
With System Monitor, you can measure the performance of your computer or other computers on a network:
- Collect and view real-time performance data on a local computer or from several remote computers.
- View data collected either currently or previously in a counter log.
- Present data in a printable graph, histogram, or report view.
- Create reusable monitoring configurations that can be installed on other computers using Microsoft Management Console.
System Monitor, can also collect and view data about the usage of hardware resources and the activity of system services on computers.
System Monitor and Performance Logs Alerts can be accessed from Start / Admistration Tools / Performance.

Performance Logs and Alerts
Performance Logs and Alerts can collect performance data automatically from local or remote computers. You can view logged counter data using System Monitor or export the data to spreadsheet programs or databases for analysis and report generation.
Capabilities:
- Performance Logs and Alerts collects data in a comma-separated or tab-separated format for easy import to spreadsheet programs.
- Counter data collected by Performance Logs and Alerts can be viewed during collection as well as after collection has stopped.
- Because logging runs as a service, data collection occurs regardless of whether any user is logged on to the computer being monitored.
- You can define start and stop times, file names, file sizes, and other parameters for automatic log generation.
- You can manage multiple logging sessions from a single console window.
- You can set an alert on a counter, thereby defining that a message be sent, a program be run, or a log be started when the selected counter's value exceeds or falls below a specified setting.
> Determining acceptable values for counters
The following table containing threshold values for specific counters that can help you determine whether values reported by your computer indicate a problem. If System Monitor consistently reports these values, it is likely that bottlenecks exist on your system and you should take action to tune or upgrade the affected resource.
|
Resource
|
Object\ Counter
|
Suggested threshold
|
Comments
|
| Disk | PhysicalDisk\ % Disk Time |
90%
|
|
| Disk | PhysicalDisk\ Disk Reads/sec, PhysicalDisk\ Disk Writes/sec | Depends on manufacturer's specifications | Check the specified transfer rate for your disks to verify that this rate doesn't exceed the specifications. In general, Ultra Wide SCSI disks can handle 50 I/O operations per second. |
| Disk | Physical Disk\ Current Disk Queue Length | This is an instantaneous counter; observe its value over several intervals. For an average over time, use Physical Disk\ Avg. Disk Queue Length. | |
| Memory | Memory\ Available Bytes | Less than 4 MB | Research memory usage and add memory if needed. |
| Memory | Memory\ Pages/sec | 20 | Research paging activity. |
| Network | Network Segment\ % Net Utilization | Depends on type of network | You must determine the threshold based on the type of network you are running. For Ethernet networks, for example, 30% is the recommended threshold. |
| Paging File | Paging File\ % Usage | 99% | Review this value in conjunction with Available Bytes and Pages/sec to understand paging activity on your computer. |
| Processor | Processor\ % Processor Time | 85% | Find the process that is using a high percentage of processor time. Upgrade to a faster processor or install an additional processor. |
| Processor | Processor\ Interrupts/sec | Depends on processor. | A dramatic increase in this counter value without a corresponding increase in system activity indicates a hardware problem. Identify the network adapter causing the interrupts. |
| Server | Server\ Bytes Total/sec |
If the sum of Bytes Total/sec for all servers is roughly equal to the maximum transfer rates of your network, you may need to segment the network.
|
|
| Server | Server\ Work Item Shortages | 3 |
If the value reaches this threshold, consider tuning InitWorkItems or MaxWorkItems in the registry (under HKEY_LOCAL_MACHINE\SYSTEM\ |
| Server | Server\ Pool Paged Peak | Amount of physical RAM | This value is an indicator of the maximum paging file size and the amount of physical memory. |
| Server | Server Work Queues\ Queue Length | 4 | If the value reaches this threshold, there may be a processor bottleneck. This is an instantaneous counter; observe its value over several intervals. |
Optimize and troubleshoot memory performance.
Memory usage is one of the most important factors in system performance. If your system is paging frequently you may have a memory shortage. Paging is the process of moving fixed size blocks of code and data from RAM to disk using units called pages in order to free memory for other uses. Although some paging is acceptable because it enables Windows 2000 to use more memory than actually exists, constant paging is a drain on system performance. Reducing paging will significantly improve system responsiveness.
Checking your configuration
- Make sure your system has the recommended amount of memory not only for running Windows 2000 but also for the programs or services you are running. Check the amount of memory on your system against requirements of the operating system and your programs. Consult product documentation for programs or services that you are running to verify that memory is adequate.
- Number of users multiplied by the average size of the open data files per user
To monitor for a low-memory condition, start with the following object counters: ( see table above )
Memory\ Available Bytes
- Available Bytes indicates how many bytes of memory are currently available for use by processes.
- 4 MB or less may indicate there is an overall shortage of memory on your computer or that a program is not releasing memory.
Memory\ Pages/sec
- Pages/sec provides the number of pages that were either retrieved from disk due to hard page faults or written to disk to free space in the working set due to page faults.
- If the value of Pages/sec is 20 or more, you should research the paging activity further.
- A high rate for Pages/sec may not indicate a memory problem but may instead be the result of running a program that uses a memory-mapped file.
If you suspect a memory leak, monitor Memory\Available Bytes and Memory\ Committed Bytes to observe memory behavior and monitor Process\ Private Bytes, Process\ Working Set, and Process\ Handle Count for processes you think may be leaking memory.
Optimize and troubleshoot disk performance.
It is possible to confuse a memory shortage that causes paging with a disk bottleneck that results in paging. As a result, when you investigate the causes of paging, where a memory shortage is not apparent, make sure to track disk usage counters such as the following along with memory counters:
Physical Disk\ % Disk Time
Physical Disk\ Avg. Disk Queue Length
Page Reads/sec with % Disk Time and Avg. Disk Queue Length. If a low rate of page-read operations coincides with high values for % Disk Time and Avg. Disk Queue Length, there could be a disk bottleneck. If an increase in queue length is not accompanied by a decrease in the pages-read rate, then a memory shortage exists.
To determine the impact of excessive paging on disk activity, multiply the values of the Physical Disk\ Avg. Disk sec/Transfer and Memory\ Pages/sec counters. If the product of these counters exceeds 0.1, paging is taking more than 10 percent of disk access time. If this occurs over a long period, you probably need more memory.
To check for excessive paging due to programs that are running.
- Stop the program with the highest working set value and see whether that dramatically changes the paging rate.
- If you suspect excessive paging, check the Memory\ Pages/sec counter. This counter shows the number of pages that needed to be read from disk because they were not in physical memory.
Manage your paging file for better performance:
- Place a paging file on other disk drives. If you have multiple hard disks, splitting up the paging file will speed up the access time. If you have two hard disks and you split the paging file, both hard disks can be accessing information simultaneously, greatly increasing the throughput.
- Increase the size of the paging file. The recommended size for the paging file is 1.5 times the amount of RAM available on your system.
> Manage hardware profiles.
A hardware profile is a set of instructions that tells Windows 2000 which devices to start when you start your computer or what settings to use for each device. When you first install Windows 2000, a hardware profile called Profile 1 (for laptops, the profiles would be Docked Profile or Undocked Profile) is created. By default, every device that is installed on your computer at the time you install Windows 2000 is enabled in the Profile 1 hardware profile.
Hardware profiles are especially useful if you have a portable computer. Most portable computers are used in a variety of locations, and hardware profiles will let you change which devices your computer uses when you move it from location to location. For example, you may have one profile named Docking Station Configuration for using your portable computer at a docking station with hardware components such as a CD-ROM drive and a network adapter. And you may have a second profile named Undocked Configuration for using your portable computer in a hotel or on an airplane, when you are not using a network adapter or a CD-ROM but you are using a modem and a portable printer.

To create a hardware profile:
- Open System in Control Panel.
- On the Hardware tab, click Hardware Profiles.
- Under Available hardware profiles, click Profile 1 (Current).
- Click Copy, type a name for the new hardware profile, and then click OK. You can then customize your new profile by enabling or disabling devices for that profile in Device Manager.
> Recover system state data and user data.
You can access Backup and Recovery Tools by typing ntbackup.exe in the run box.

Recover system state data and user data by using Windows Backup.
Creating emergency repair disk (ERD)
Open Backup On the Tools menu, click Create an Emergency Repair Disk Follow the instructions that appear on your screen
To restore your settings from the ERD, you need your Windows 2000 CD, the Windows 2000 Setup disks, and the ERD, during the restoration process.
Troubleshoot system restoration by using Safe Mode.
Safe Mode Options
Safe Mode - Starts Windows 2000 using only basic files and drivers (mouse, except serial mice; monitor; keyboard; mass storage; base video; default system services; and no network connections). Safe mode with Networking - Starts Windows 2000 using only basic files and drivers, plus network connections. Safe Mode with Command Prompt - Starts Windows 2000 using only basic files and drivers. After logging on, the command prompt is displayed instead of the Windows desktop. Enable Boot Logging - Starts Windows 2000 while logging all the drivers and services that were loaded (or not loaded) by the system to a file. This file is called ntbtlog.txt and it is located in the windir directory. Safe Mode, Safe Mode with Networking, and Safe Mode with Command Prompt add to the boot log a list of all the drivers and services that are loaded. The boot log is useful in determining the exact cause of system startup problems. Enable VGA Mode - Starts Windows 2000 using the basic VGA driver. The basic video driver is always used when you start Windows 2000 in Safe Mode (either Safe Mode, Safe Mode with Networking, or Safe Mode with Command Prompt). Last Known Good Configuration - Starts Windows 2000 using the registry information that Windows saved at the last shutdown. Use only in cases of incorrect configuration. Last known good configuration does not solve problems caused by corrupted or missing drivers or files. Also, any changes made since the last successful startup will be lost. Debugging Mode - Starts Windows 2000 while sending debug information through a serial cable to another computer.
Users can use the Recovery Console to repair Windows. This command-line utility can be used to copy system files, disable and enable services or drivers, repairing the Master Boot Record, etc. Only administrators have access to the Recovery Console.
There are two ways to start the Recovery Console: If you are unable to start your computer, you can run the Recovery Console from your Windows 2000 Setup disks. Or, you can install the Recovery Console on your computer to make it available in case you are unable to restart Windows 2000. You can then choose the Windows 2000 Recovery Console option from the boot menu.
To install Recovery Console as a startup option:
- Log on to Windows 2000 with administrator rights.
- Insert the Windows 2000 Professional CD into your CD-ROM drive. If you're prompted to upgrade to Windows 2000, click No. From the command prompt or from the Run command in Windows 2000 type the path to the appropriate Winnt32.exe file (on your Windows 2000 CD), followed by a space and the /cmdcons switch. For example: e:\\i386\winnt32.exe /cmdcons
- Follow the instructions that appear.
To run Recovery Console on a system that does not start:
- Restart your computer, and then click Windows 2000 Recovery Console from the list of operating systems.
- Follow the instructions that appear.
- Recovery Console displays a command prompt.
- To see the commands available on the Recovery Console, type help at the command promp.