Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Panel

...

borderColorgreen
bgColortransparent
borderWidth2

...

Back to Table of Contents

...

In this section:

Table of Contents
maxLevel3

 

A CLI command is composed of the following elements:

Code Block
languagenone
 <operation> <object> <keyword> <parameter1> <attribute/argument> <parameter2> <attribute/argument>

 Where:

<operation> is the operation to be performed.

<container> represents an interior data node in the data tree. A container has no value, but rather a set of child nodes that can be containers, lists, or leafs.

<list> represents an interior data node in the data tree. The <list> statement takes one or more keys depending on the list definition. A list entry contains a set of child nodes that can be containers, lists, or leafs.

<key> is a space-separated list of identifiers that uniquely identify an entry in a list. One or more (*m) key statements may be used.

<leaf> represents an exterior or final data node in the data tree. A leaf is a configuration parameter that that can be set to a value.

<value> represents the leaf's value.

As an example, to enable a SIP trunk group named "STG-1" in the zone named "defaultSigZone" for the default address context, the following command applies (refer to Figure 1):

 

Code Block
languagenone
% set addressContext default zone defaultSigZone sipTrunkGroup STG-1 state enabled
Caption
0Figure
1 CLI Command Line Structure

Image Modified

Uppercase and Lowercase Usage

Div
classexcerptdiv
Excerpt

CLI commands are case-sensitive and must be entered exactly as shown in this guide. Objects and profiles with names that differ only in case are considered distinct objects.

For example, the following trunk groups are three distinct trunk group entities: trunkgroup1, TRUNKGROUP1, TrunkGroup1. It is strongly recommended to avoid such naming conventions, and to also adopt a standard naming convention when initially defining your configuration.

Note
As a best practice, always use UPPERCASE for trunk group names.

Space-Completion Functionality

The CLI includes space-completion behavior which automatically displays a list of possible arguments when the user types more than one space after a keyword or parameter (same action as pressing Tab). This default setting is generally desired behavior when entering commands from an interactive session (complete-on-space is set to "true").
The commands to turn on/off space-completion are:

Code Block
languagenone
> set complete-on-space true
> set complete-on-space false

Here is an example of entering "show" command plus two spaces when space-completion is set to "true". The result is a "Possible completions" list that automatically displays as shown:

Code Block
languagenone
admin@sbx131> show..
Possible completions:
cli - Display cli settings
configuration - Display current configuration
notification - Display notifications
status - Display current system status
table - Display current configuration and status as a table
users - Display currently logged on users
utils - System utilities

On the other hand, when copy-pasting multiple commands to the command line this feature is not desirable. Extra spaces may prevent the commands from running as expected due to the automatic space-completion feature. To avoid this, turn this feature off using the following command:

Code Block
languagenone
admin@sbx131> set complete-on-space false
[ok][2012-07-03 14:13:47]

 

Pagebreak