Scenario: System monitor

See an example system monitor that alerts you if the CPU utilization gets too high and temporarily holds any lower priority jobs until more resources become available.

Situation

As a system administrator, you need to ensure that the iSeries™ system has enough resources to meet the current demands of your users and business requirements. For your system, CPU utilization is a particularly important concern. You would like the system to alert you if the CPU utilization gets too high and to temporarily hold any lower priority jobs until more resources become available.

To accomplish this, you can set up a system monitor that sends you a message if CPU utilization exceeds 80%. Moreover, it can also hold all the jobs in the QBATCH job queue until CPU utilization drops to 60%, at which point the jobs are released, and normal operations resume.

Configuration example

To set up a system monitor, you need to define what metrics you want to track and what you want the monitor to do when the metrics reach specified levels. To define a system monitor that accomplishes this goal, complete the following steps:

  1. In iSeries Navigator, expand Management Central > Monitors, right-click System Monitor, and select New Monitor...
  2. On the General page, enter a name and description for this monitor.
  3. Click the Metrics tab, and enter the following values:
    1. Select the CPU Utilization Basic (Average), from the list of Available Metrics, and click Add. CPU Utilization Basic (Average) is now listed under Metrics to monitor, and the bottom portion of the window displays the settings for this metric.
    2. For Collection interval, specify how often you would like to collect this data. This will override the Collection Services setting. For this example, specify 30 seconds.
    3. To change the scale for the vertical axis of the monitor's graph for this metric, change the Maximum graphing value. To change the scale for the horizontal axis of the graph for this metric, change the value for Display time.
    4. Click the Threshold 1 tab for the metrics settings, and enter the following values to send an inquiry message if the CPU Utilization is greater than or equal to 80%:
      1. Select Enable threshold.
      2. For the threshold trigger value, specify >= 80 (greater than or equal to 80 percent busy).
      3. For Duration, specify 1 interval.
      4. For the i5/OS™ command, specify the following:
        SNDMSG MSG('Warning,CPU...') TOUSR(*SYSOPR) MSGTYPE(*INQ)
      5. For the threshold reset value, specify < 60 (less than 60 percent busy). This will reset the monitor when CPU utilization falls below 60%.
    5. Click the Threshold 2 tab, and enter the following values to hold all the jobs in the QBATCH job queue when CPU utilization stays above 80% for five collection intervals:
      1. Select Enable threshold.
      2. For the threshold trigger value, specify >= 80 (greater than or equal to 80 percent busy).
      3. For Duration, specify 5 intervals.
      4. For the i5/OS command, specify the following:
        HLDJOBQ JOBQ(QBATCH)
      5. For the threshold reset value, specify < 60 (less than 60 percent busy). This will reset the monitor when CPU utilization falls below 60%.
      6. For Duration, specify 5 intervals.
      7. For the i5/OS command, specify the following:
        RLSJOBQ JOBQ(QBATCH)

        This command releases the QBATCH job queue when CPU utilization stays below 60% for 5 collection intervals.

  4. Click the Actions tab, and select Log event in both the Trigger and Reset columns. This action creates an entry in the event log when the thresholds are triggered and reset.
  5. Click the Systems and groups tab to specify the systems and groups you want to monitor.
  6. Click OK to save the monitor.
  7. From the list of system monitors, right-click the new monitor and select Start.

Results

The new monitor displays the CPU utilization, with new data points being added every 30 seconds, according to the specified collection interval. The monitor automatically carries out the specified threshold actions, even if your PC is turned off, whenever CPU utilization reaches 80%.

Note: This monitor tracks only CPU utilization. However, you can include any number of the available metrics in the same monitor, and each metric can have its own threshold values and actions. You can also have several system monitors that run at the same time.