342
| Actions and Adaptive CLI
When using the CLI Format, The Adaptive CLI tool will prompt you to create new attributes
based upon your script markup. This lets you quickly create a script and schema to create an ACLI.
If you have attributes that are mainly simple String attributes, this is a very quick and automated
approach.
Using Perl in Adaptive CLI
If you need conditional logic that goes beyond simple scripting, you can use Perl in Adaptive CLI.
The example below checks to see if a String Attribute is empty (null) or not. If the String attribute
(ShowCmdString
) has content, the show command with
ShowCmdString
as a parameter goes
to the device. Otherwise, the Perl script skips or excludes this statement.
Embedded CLI Example:
[IF ShowCmdString]
Show [ShowCmdString]
[ENDIF ShowCmdString]
You could use the CLI format for the above example, but if you need to check attributes of other
types, besides String, then you must switch to Perl. For example:
Boolean
myFlag
equals True:
if ($myFlag)
{
…
}
Integer
myInt
greater than zero:
Example:
if ($myInt > 0)
{
…
}
To check whether a string is a particular value—like from a valid values list entry assigned to the
String attribute—then you must also use Perl. The CLI format only can test if the String exists. It
cannot validate its value when populated. For example: EncapsulationType = “VLAN-CCC”,
“VLAN-TCC”, … You can not do this check with the CLI Format:
[IF EncapsulationType =
“VLAN-TCC”].
Instead, use a Perl script with a statement like this:
If
($EncapsulationType eq “VLAN-TCC”)
{
print “set encapsulation $EncapsulationType\n”;
}
Summary of Contents for OpenManage Network Manager
Page 1: ...Dell OpenManage Network Manager version 5 1 Web Client Guide ...
Page 14: ...14 A Note About Performance Preface ...
Page 98: ...98 Schedules Portal Conventions ...
Page 142: ...142 Vendors Key Portlets ...
Page 232: ...232 File Management File Servers ...
Page 242: ...242 Deploy Configuration ...
Page 290: ...290 Key Metric Editor Monitoring Metrics This panel s display depends on the selected device ...
Page 340: ...340 ...
Page 374: ...374 Adaptive CLI Records Archiving Policy Actions and Adaptive CLI ...
Page 380: ...380 Glossary ...
Page 388: ...388 388 Index ...