Implement Alert Server Tools

Alert server tools allow you to execute a utility on a remote host. You define the host when you run the tool. You can control which tools are available for different types of alerts.

These tools specify a command that is run using ToolRunner, which is configured to connect to the remote host. The command can be anything that is executable from the Linux command line. For example a ping or cat or a custom bash script. See Configure Tool Runner for more information.

Alert server tools pass arguments to utilities based upon alert attributes. For example, testing the reachability (ping) of hardware using the source attribute of the alert.

Create a new alert server tool

To create a new alert server tool:

  1. Click Alert Server Tools in the Tools section of the Settings tab.

  2. On the Tool tab, click the + icon to create a new tool.

  3. Fill in the available fields to define the tool:

    Field

    Input

    Description

    Name

    String (Required)

    Name for the alert server tool (up to 100 characters).

    Description

    String

    Text description of the alert server tool.

    Alert Type Filter

    String

    Alert Types for which the alert server tool is available.

    Enter .* to make it available for all alert types.

    Filter Using Regex

    Boolean

    If you select this check box, the Alert Type Filter uses regular expression.

    Command

    String (Required)

    The command to carry out on alerts. This command must be an accessible path on the host system. It is defined when you run the tool.

    Arguments

    String

    This is the specific input for the command.

    Run For

    Boolean +Integer

    If you select this check box, you can define the number of seconds the tool runs for. The minimum value for this field is 5 seconds.

  4. Click Save Changes to add the tool to the list of alert server tools in the left hand pane.

Example

The following screenshot shows an alert server tool that tests the reachability of the source alert and returns the results.

The Command ping is used with Arguments$source and -c5 which specify the source, from the alert attribute, and the number of times to ping (five).

AlertServer1.JPG

The Alert Type Filter uses a regular expression '.*' to make the tool available for all alerts.