Batch Script Syntax; Interface Script Syntax - Lantronix 100-120 VAC SLB User Manual

Branch office manager
Table of Contents

Advertisement

command. This action requires that a SLB user running the runcli command belong to a
group that is the same or greater than the group assigned to the script (e.g., if the script is
assigned to the Power group, the user running the runcli command must belong to the Power
or Admin group). For Batch Scripts, if this minimum group requirement is met, the SLB user
will temporarily be granted all of the individual rights assigned to the script while the Batch
Script is running. It is recommended that scripts that spawn clisession only be used with the
set script runcli command (and not the connect script command), and that scripts
that spawn portsession only be used with the connect script command (and not the set
script runcli command).
Note:
Custom Scripts have a debug enable option that supports printing Expect
debug information to aid in creating an Expect script.The debug option is not
supported for Tcl and Python scripts.

Batch Script Syntax

The syntax for Batch Scripts is exactly the same as the commands that can be typed at the CLI,
with the additions described in this section.
The sleep command suspends execution of the script (puts it to 'sleep') for the specified number
of seconds. Syntax:
sleep <value>
The while command allows a loop containing CLI commands to be executed. Syntax:
while {<Boolean expression>} {
CLI command 1
CLI command 2
...
CLI command n
}
Note:
The closing left brace '}' must be on a line without any other characters. To
support a while command, the set command, variables, and secondary commands are
also supported.

Interface Script Syntax

This section describes the abbreviated scripting syntax for Interface Scripts. This limited syntax
was created to prevent the creation of scripts containing potentially harmful commands. Script
commands are divided into three groups: Primary, Secondary and Control Flow. Primary
commands provide the basic functionality of a script and are generally the first element on a line of
a script, as in:
send_user "Password:"
Secondary commands provide support for the primary commands and are generally not useful by
themselves. For example, the expr command can be used to generate a value for a set
command.
set <my_var> [expr 1 + 1]
Control Flow commands allow conditional execution of other commands based on the results
of the evaluation of a Boolean expression.
SLB™ Branch Office Manager User Guide
8: Device Ports
142

Advertisement

Table of Contents
loading

This manual is also suitable for:

200-240 vac slb

Table of Contents