The system monitor (performance monitor) integrated in the Windows operating system is designed to detect resource bottlenecks in the system. The system monitor supports detailed monitoring of the operating system resources used. It provides the option of cyclically recording the system resources and saving them in a file. The data gathered can be shown as a graph in relation to time. Detailed information is available in Microsoft's Online Help.
In this entry we describe how you can use the system monitor integrated in the Windows XP operating system.
||Start the system monitor|
Start the Windows system monitor with "Start > Settings > Control Panel > Administrative Tools > Performance". The System Monitor (also called Performance Monitor) opens.
||Create new performance indicator log|
In the tree structure in the left window you select "Console Root > Performance Logs and Alerts > Counter Logs". Right-click to open the pop-up menu in the working area (right window) and select the entry "New Log Settings...". The "New Log Settings..." dialog opens. In the "Name" field you enter the name of the log and acknowledge with the "OK" button.
The newly created performance indicator log is displayed in the working area.
||Parameterize the performance indicator log|
In the working area you double-click the counter log to be parameterized. The dialog for parameterizing the performance indicator log opens.
- "General" tab
In the"General" tab, in the "Sample data every:" area you define the interval with which the data is to be written cyclically to the file.
In the "General" tab you add the required performance indicators. For this you use the "Add Objects..." and/or "Add Counters..." buttons.
In the "General" tab you click the "Add Objects..." button. The "Add Objects" dialog opens.
If data objects from other computers in the network are to be logged, you select the "Select counter objects from computer" and in the associated selection field you enter the name(s) of the computer(s) concerned. If data objects of your own computer are to be logged, you can select "Use local computer counter objects".
For example, you select the entries "Process", "Processor", "Memory" and "LogicalDisk" in the "Performance objects" selection list and click the "Add" button. Press and hold the "CTRL" or "SHIFT" key when selecting with the mouse to select multiple entries in the list. Close the dialog "Add Objects" dialog. The indicators selected for logging are shown in the "Counters" list.
- "Log Files" tab
In the "Log Files" tab you can make the settings for the log file (e.g. file type, name, storage location, maximum file size).
- "Schedule" tab
In the "Schedule" tab you can define when logging is to be started and stopped.
For this example we have selected manual starting and stopping of the log file.
Click the "OK" button to close the dialog window.
||Configure the System Monitor for displaying the logged performance indicators|
In the left window you select the "System Monitor" entry in the tree structure. A graph window is shown in the working area for displaying the performance indicators. Right-click to open the pop-up menu in the graph area (working area of the system monitor). You select the "Properties..." item.
The "System Monitor Properties" dialog opens.
- "Source" tab
Switch to the "Source" tab. In the "Data source" area you select "Log files". Then click the "Add..." button and in the "Select log file" dialog you select the log file required.
- "Data" tab
Switch to the "Data" tab. Add the performance indicators that you wish to have displayed.
- The only performance indicators available are those used in the performance indicator log used. If performance indicators of specific processes and programs (e.g. script.exe) are to be displayed, then these processes and programs must be started so that their indicators can be selected for display.
- If necessary, change the value range of the y axis (vertical scaling), the factor for displaying the individual performance indicators.
||Save the system monitor settings|
With the menu command "File > Save as..." you save the current settings of the system monitor. The settings are saved as an *.msc file (Microsoft Management Console File).
||Start/Stop and display of the log|
In the tree structure in the left window you select "Console Root > Performance Logs and Alerts > Counter Logs". Open the pop-up menu for a performance indicator (counter) log in the working area. Select the Start Item or Stop Item.
Recording of a performance indicator log can only be started or stopped by the user. Whether a performance indicator has been started or stopped is indicated by the color of the icon next to the name of the log.
- Red means that the performance indicator log has been stopped.
- Green means that the performance indicator log has been started.
Once a performance indicator log has been started you can close the system monitor (performance monitor). The data for the performance indicator log started continues to be acquired even when the system monitor is closed. If the data is to be displayed, you can start the system monitor again and select the configuration file saved in Step 4 using the menu item "File > Open...".
When you open the Microsoft Management Console file, you should update the time range of the display, because new data might have been written to the log file since the last configuration.
- Display the current performance indicators even when recording in the file has been stopped
Even when a performance indicator log has just been stopped (i.e. there is currently no data acquisition in the log file), you can have the current values of the performance indicators configured displayed graphically in the system monitor. For this you open the "System Monitor Properties" dialog (as described in Step 4) and switch to the "General" tab. Set the option box "Sample automatically every: 1 seconds". In the associated input field you can change the update time.
- Rapid access to control functions via the menu bar in the system monitor's working area
You can have a menu bar displayed in the working area of the system monitor. Using this menu bar you can rapidly access the control functions of the system monitor.
- Control logging via the Windows command line
You can also create, configure, start and stop the performance indicator logs via the Windows command line. Detailed information on this is available in the Microsoft Online Help or by entering the command "logman /?" in the DOS prompt to obtain a description of the possible commands.
You can call the command line commands of the performance indicator logs in the script in a WinCC picture in order to be able configure, start and stop performance indicator logs from a WinCC picture during WinCC Runtime.
- Define the acquisition cycle
You must adapt the acquisition cycle to each individual application case. You should set the acquisition cycle as short as required not to unnecessarily load the system resources.
- Log file size
Make sure that the log file does not exceed the memory available. For this reason you should save the recorded data at sufficiently short intervals and then delete the log file to free up memory again. Entry ID: 23757729 describes how to determine the memory requirement of a log file. Note that short acquisition cycles cause rapid growth of file size.
- Diagnostics via the network
Since diagnostics with the system monitor can cause additional load to the system, it might be useful to run diagnostics from a different computer in the network. For this see the instruction in Step 3.
- Performance indicators of processes
If you wish to log performance indicators of specific processes, those processes must be started when the log is created. The processes and their performance indicators will then be offered for selection when configuring the log.