Users Guide
External Executable | Actions and Adaptive CLI
586 OMNM 6.5.3 User Guide
peping_test.pl
—Check if a target is pingable from the specified remote host.
pop3_test.pl
—Check if the POP3 service is running on a specified host.
smtp_test.pl
—Check if the SMTP service is running on a specified host.
telnet_test.pl
—Check if the TELNET service is running on a specified host.
See
Create a Monitor for an External Script
on page 394 for more specifics about monitoring
these.
If you have a clustered installation, then every server in the cluster must have scripts installed to
the paths Adaptive CLIs using them specify.
How To:
Make an Adaptive CLI Run an External Script
The following demonstrates Adaptive CLI running an example Windows external batch file
(script) that includes command line parameters. Follow these steps to create this training example:
1
Right-click in the
Actions
portlet to create a new Adaptive CLI.
2
In the editor’s
General
tab, enter a name (here: Test HelloWorld.bat), and select
External
Command
as the type.
3
Click the
Attributes
tab, and create Hello World Schema with two string attributes (in the
Attribute Settings
sub-tab). Here, we make
Command1
and
Command2.
4
In the
Script
tab, make the Hello World Batch File command (the example name), whose
contents are:
c:\HelloWorld.bat [Command1] [Command2]
Both command line parameters are optional in this example, but you can create such scripts
where parameters are required before the script will run. Select a parameter and click the
Tokens at the bottom of the screen to arrange that.
5
After you have finished configuring the script, click
Apply
and
Save.
6
Before running this Adaptive CLI example, you must create a batch file called
c:\HelloWorld.bat
. Here are its contents:
@ECHO OFF
ECHO -------------------------
ECHO * Hello World! *
ECHO -------------------------
ECHO ...then display the appended command(s)
ECHO ...
ECHO %1
ECHO ...
ECHO %2
7
After creating and saving
c:\HelloWorld.bat
, right-click Test HelloWorld.bat in the
Actions portlet, and select
Execute.
8
You must select a target device before going further, even though this script does not require
one. Select any device.
9
A screen offering to let you specify Command1 and Command2 appears. For the sake of this
example, any string you enter works. We’ll enter XXX and YYY.