9.46. Configuration for the swap check.

The swap check checks the available swap space on your machine. You can define thresholds for the utilisation.

SWAP

Explanation

SWAP is the enclosing tag for all threshold entries.

Parent

OSAGENT

allowed values

Count

0 or 1. If you don't define SWAP, no swap check will run.

Example
<SWAP>
  <!-- 70% utilisation of your swap is WARNING -->
  <THRESHOLD>
    <MAX>70</MAX>
    <ERRORLEVEL>WARNING</ERRORLEVEL>
  </THRESHOLD>
  <!-- a utilisation of more then 90% is ERROR -->
  <THRESHOLD>
    <MAX>90</MAX>
    <ERRORLEVEL>ERROR</ERRORLEVEL>
    <DESCRIPTION>Increase the swap-space</DESCRIPTION>
  </THRESHOLD>
</SWAP>
        

THRESHOLD

Explanation

define your threshold and error level here

Parent

SWAP

allowed values

Count

As many as you like.

Example

Look at SWAP

MAX

Explanation

threshold (in percent) of utilisation of swap space

Parent

THRESHOLD

allowed values

integer values from 1 till 100 (percent)

Count

1

Example

Look at SWAP

COMMAND

Explanation

Use the COMMAND-tag to do another system call to get swap information (depends on operating system). Currently AIX, HP-UX, Linux and Solaris are supported. You can work with sudo.

the swap check expects for AIX the output of swap -l, for HP-UX the output of swapinfo, free for Linux and swap -l for Solaris

Parent

allowed values

string

Count

0 or 1

If you specify no COMMAND, the default will be used.

Example
<SWAP>
  <!-- here we are on an aix box 
       note: swap -l is the default for aix -->
  <COMMAND>sudo -u root /usr/sbin/swap -l</COMMAND>

  <!-- 70% utilisation of your swap is WARNING -->
  <THRESHOLD>
    <MAX>70</MAX>
    <ERRORLEVEL>WARNING</ERRORLEVEL>
  </THRESHOLD>
  <!-- a utilisation of more then 90% is ERROR -->
  <THRESHOLD>
    <MAX>90</MAX>
    <ERRORLEVEL>ERROR</ERRORLEVEL>
    <DESCRIPTION>Increase the swap-space</DESCRIPTION>
  </THRESHOLD>
</SWAP>