Lesson 1: Using Task Manager Task Manager Provides Information About the Programs and Processes Running on Your Computer and the Performance of Your Computer
Total Page:16
File Type:pdf, Size:1020Kb
19-2 Chapter 19 Monitoring and Optimizing System Performance Lesson 1: Using Task Manager Task Manager provides information about the programs and processes running on your computer and the performance of your computer. You can use Task Manager to start programs, to stop programs and processes, and to see a current view of your com- puter’s performance. After this lesson, you will be able to ■ Monitor programs by using Task Manager ■ Monitor processes by using Task Manager ■ Monitor system performance by using Task Manager ■ Monitor networking by using Task Manager Estimated lesson time: 25 minutes How to Monitor Programs Task Manager allows you to monitor applications and processes that are currently run- ning on your computer. It also provides information about the processes, including the memory usage of each one. It provides statistics about the memory and processor per- formance and network usage. You start Task Manager in any of the following ways: ■ Press CTRL+SHIFT+ESC ■ Right-click the Windows taskbar, and then click Task Manager ■ Press CTRL+ALT+DELETE Note Provided your computer running Windows XP Professional is in a domain environment, you can start Task Manager by pressing CTRL+ALT+DELETE. However, if your computer is in a workgroup environment, you might need to start Task Manager by selecting it, depending on how the logon and logoff options are configured. The Task Manager dialog box shown in Figure 19-1 has four tabs: Applications, Pro- cesses, Performance, and Networking. Lesson 1 Using Task Manager 19-3 F19us01 Figure 19-1 The Applications tab shows running applications and lets you terminate them. You can use the buttons on the Applications tab of the Task Manager dialog box to stop a program from running (End Task), to switch to a program and bring the pro- gram into the foreground (Switch To), and to start a program (New Task). At the bot- tom of the display, Task Manager shows you the number of processes that are currently running, the CPU usage, and the memory usage. How to Monitor Processes The Processes tab in the Task Manager dialog box (see Figure 19-2) lists each process that is currently running on your computer that runs in its own address space, including all applications and system services. Task Manager also allows you to end processes. F19us02 Figure 19-2 You can select the columns that appear on the Processes tab. 19-4 Chapter 19 Monitoring and Optimizing System Performance By default, the Processes tab shows you the processes, the users running each process, and the CPU and memory usage for each process that is running. You can add addi- tional performance measures to those that are shown by default on the Processes tab. To add performance measures, on the View menu, click Select Columns (refer to Fig- ure 19-2). Table 19-1 describes the columns that are displayed in Task Manager by default and some of the columns that can be added to the Processes tab. Table 19-1 Processes Tab Columns Column Description Image Name The name of the process, displayed by default. PID (Process Identifier) The numeric identifier assigned to the process while it is running. User Name The name of the user that the process is running under, displayed by default. CPU Usage The percentage of time the threads of the process used the processor since the last update, displayed by default. If a process is consuming a large amount of processor time over a long period (other than when an application is first starting or is performing a particularly intensive task), the process might be having trouble. Try closing the application (by using the Applications tab). CPU Time The total processor time (in seconds) used by the process since it was started. Memory Usage The amount of memory (in kilobytes) used by the process, displayed by default. This column is particularly useful for determining which applications are using memory because it displays the total amount of physical and virtual memory used by an application. If an application seems to be using too much memory, there might be a problem with the application. Try closing the application and restarting it (or restarting your computer and then restarting the application). Base Priority The order in which threads are scheduled for the processor. The base priority is not set by the operating system; it is set by the code. You can use Task Manager to change the base priority of processes. To change the base priority of a process, right-click the process and click Set Priority. Non-paged Pool The amount of memory (in kilobytes) that is used by a process; oper- ating system memory that is never paged (moved from memory) to disk. Paged Pool The amount of system-allocated virtual memory (in kilobytes) used by a process; virtual memory that can be paged to disk. Paging is the moving of infrequently used data from RAM to the paging file on the hard disk. Lesson 1 Using Task Manager 19-5 Table 19-1 Processes Tab Columns Column Description Page Faults The number of times that data had to be retrieved from the page file on the hard disk for this process because it had been paged out of physical memory. Windows XP Professional uses a page file stored on the hard disk to augment physical memory. When the physical memory is full, Windows swaps older information in physical mem- ory to the swap file to make room for newer information. Too many page faults often indicate that you need more physical memory. Peak Memory Usage The maximum amount of physical memory resident in a process since it started. Thread Count The number of threads running in the process. This column can be useful for troubleshooting multithreaded applications. ! Exam Tip For the exam, remember that Task Manager can show real-time information about the CPU, RAM, and virtual memory, but the measurements are fairly limited. To collect more detailed information, use the Performance console. The Performance console also allows you to collect performance data over a longer period. How to Change the Base Priority of a Running Process Changing the base priority of a process determines how much processor time Win- dows XP Professional devotes to the process compared with other processes. By default, most processes run at a base priority of Normal. However, you can change the base priority for a process by using the following steps: 1. In Task Manager, on the Processes tab, click the View menu and then click Select Columns. 2. In the Select Columns dialog box, select Base Priority and then click OK. The Base Priority column now appears in the Task Manager window. 3. Right-click the process for which you would like to change the base priority. 4. On the shortcut menu that appears, point to Set Priority, and then select one of the following commands: ❑ Realtime ❑ High ❑ AboveNormal ❑ Normal ❑ BelowNormal ❑ Low 19-6 Chapter 19 Monitoring and Optimizing System Performance Caution You should change the priority of processes only when there is a process that needs priority over (or is less important than) other running processes; even then, you should try to use only the AboveNormal, Normal, and BelowNormal levels. Setting a process at too high a base priority (such as RealTime) can consume enough system resources that other vital processes cannot function properly. How to Set Processor Affinity Windows XP Professional can support two processors running on the same computer. When two processors are installed, Windows XP Professional does a good job of assigning processes to processors based on need. However, you can assign a particular process to a specific processor. (This is referred to as assigning processor affinity to a process; of course, it is available only on computers with two processors or on com- puters with a hyperthreaded processor in which multiple processes can run simulta- neously on one processor.) To assign a process to a processor, use the following steps: 1. In Task Manager, on the Processes tab, right-click a process and then click Set Affinity. 2. In the Processor Affinity dialog box, select the processors on which the process should be allowed to run. By default, both processors (CPU 0 and CPU 1) are selected for a processor. Caution Controlling processor affinity can improve performance by reducing the number of processor cache flushes that occur as threads move from one processor to another. This might be a good option for dedicated file servers. However, be aware that dedicating a pro- gram to a particular processor might not allow other program threads to migrate to the least- busy processor. How to Monitor System Performance You can use the Performance tab in the Task Manager dialog box (see Figure 19-3) to see a current overview of system performance that includes information about the CPU (or CPUs on a computer with two processors), physical memory, and virtual memory. Lesson 1 Using Task Manager 19-7 F19us03 Figure 19-3 The Performance tab provides real-time performance data about the CPU, RAM, and virtual memory. Table 19-2 describes the fields that are displayed by default on the Performance tab in Task Manager. Table 19-2 Performance Tab Fields Field Description CPU Usage The percentage of time that the processor is busy. If this graph displays a high percentage continuously (and not when there is an obvious reason, such as a big application), your processor might be overloaded. If your computer has two processors, two graphs are shown. If this value runs continuously over 80 percent, you probably see a noticeable improve- ment in performance if you upgrade your processor.