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:
-
Click
in the section of the tab. -
On the + icon to create a new tool.
tab, click the -
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.
-
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).
The Alert Type Filter uses a regular expression '.*' to make the tool available for all alerts.