clicmds package
Information on this package is covered here.
|
Package
|
Description
|
License
|
|
clicmds
|
Command Line Interface (CLI) commands
|
Devicescape Software, Inc.
|
Summary
The clicmds package provides the commands that are used in the Devicescape Wireless Infrastructure Platform command line interface (CLI).
The Devicescape Wireless Infrastructure Platform provides a special-purpose shell, called "splash" (for "simple, pleasant administrative shell"), which is used to call the CLI commands. The splash shell is lightweight, supporting only the features needed for the Devicescape Wireless Infrastructure Platform. At the same time, however, it provides key features that make the CLI easier to use, such as command completion, history, and command editing. (The splash shell is part of the busybox package.)
The commands provided by the clicmds package include the following:
- get
- set
- add
- remove
- save-running
- reboot
- factory-reset
To maintain a small footprint, the CLI commands are implemented in a multicall binary. Instead of each command having its own executable file, a command is called by means of a symbolic link. The clicmds package, therefore, consists of a single binary file (clicmds) and a symbolic link for each of the commands.
For more information on using the CLI, see the "Appendix C. Command Line Interface (CLI) for AP Configuration" and "Classes and Properties Reference" in the Administrator Guide.
Access
The CLI can be accessed through any of the following means:
See also information on how to start/stop services for Serial connection, Telnet, and SSH in Starting/Stopping Related Services.
CLI Schema
The majority of the CLI commands to access and manipulate Device Management Agent's configuration and status data.
The Device Management Agent exposes this data through a standard data model. The CLI commands use a schema file that serves as a bridge between the command line interface and the Device Management Agent's data model. The schema file defines the classes and properties with the CLI that the user can access. The schema file allows you to set permissions for these classes and proprieties, specifying what about what kind of operations (read, write, and so on) can be performed. The schema file also provides metadata about the Device Management Agent classes required to support certain CLI features.
For example, the CLI provides features that make it easier for user to view data in a command line environment. When viewing the data contained in the instance of a class, you have the option of viewing all the properties that make up the class, or just the most common properties. The schema file is used to indicate which properties of a class are common.
Usage
Starting/Stopping Related Services
Use the command line interface (CLI) to get status and stop/start the following services, which support access to the CLI.
|
Related Service
|
Command
|
Description
|
|
Serial
|
get serial status
|
Returns status of the serial service (up is on, down is off).
|
|
set serial status down
|
Stops the serial service.
|
|
set serial status up
|
Starts the serial service.
|
|
Telnet
|
get telnet status
|
Returns status of the telnet service (up is on, down is off).
|
|
set telnet status down
|
Stops the telnet service.
|
|
set telnet status up
|
Starts the telnet service.
|
|
SSH
|
get ssh status
|
Returns status of the ssh service (up is on, down is off).
|
|
set ssh status down
|
Stops the ssh service.
|
|
set ssh status up
|
Starts the ssh service.
|
CLI Commands
The following table shows how to use the CLI commands that ship with the Devicescape Wireless Infrastructure Platform.
|
Notes
|
named_class is a class of an object from the configuration whose instances are individually named. Named classes have two types: unique-named and group-named. All the instances of a unique named class must be assigned unique names. In a group named class, instances that have the same name form a group.
instance is a name of an instance of class.
- property values cannot contain spaces unless the value is in quotes
|
|
get
|
The "get" command allows you to get the property values of existing instances of a class.
Classes can be "named" or "unnamed". The command syntax is:
get unnamed-class [ property ... | detail ]
get named-class [ instance | all [ property ... | name | detail ] ]
The rest of the command line is optional. If provided, it is either a list of one or more properties, or the keyword detail.
An example of using the "get" command on an unnamed class with a single instance is: get log
(There is only one log on the AP. This command returns information on the log file.)
An example of using the "get" command on an unnamed class with multiple instances is: get log-entry (There are multiple log entries but they are not named. This command returns all log entries.)
An example of using the "get" command on a named class with multiple instances is:
get bss wlan0bssInternal (There are multiple bss's and they are named. This command returns information on the BSS named "wlan0bssInternal".)
Examples of using the "get" command on a named class to get all instances:
get radius-user all name get radius-user all
|
|
set
|
The "set" command allows you to set the property values of existing instances of a class.
set unnamed-class [ with qualifier-property qualifier-value ... to ] property value . . .
The first argument is an unnamed class in the configuration.
After this is an optional qualifier that restricts the set to only some instances. For singleton classes (with only one instance) no qualifier is needed. If there is a qualifier, it starts with the keyword with, then has a sequence of one or more qualifier-property qualifier-value pairs, and ends with the keyword to. If these are included, then only instances whose present value of qualifier-property is qualifier-value will be set. The qualfier-value arguments cannot contain spaces. Therefore, you cannot select instances whose desired qualifier-value has a space in it.
The rest of the command line contains property-value pairs.
set named-class instance | all [ with qualifier-property qualifier-value ... to ] property value . . .
The first argument is a named class in the configuration.
The next argument is either the name of the instance to set, or the keyword all, which indicates that all instances should be set. Classes with multiple instances can be set consecutively in the same command line as shown in Example 4 below. The qualfier-value arguments cannot contain spaces.
Here are some examples. (Bold text indicates class names, property names or keywords; the unbold text are values to which the properties are being set.)
1. set interface wlan0 ssid "Vicky's AP"
2. set radio all beacon-interval 200
3. set tx-queue wlan0 with queue data0 to aifs 3
4. set tx-queue wlan0 with queue data0 to aifs 7 cwmin 15 cwmax 1024 burst 0 5. set bridge-port br0 with interface eth0 to path-cost 200
|
|
add
|
The "add" command allows you to add a new instance of a class.
add unique-named-class instance [ property value ... ]
add group-named-class instance [ property value ... ]
add anonymous-class [ property value ... ]
For example:
add radius-user wally
Note: If you're adding an instance to a unique-named class, you must assign the instance a name not already in use by any other instance of that class. If you add instances to group-named classes, you can form groups by creating instances and assigning them identical names. All instances of a group-named class that have the same name form a group of instances.
|
|
remove
|
The "remove" command allows you to remove an existing instance of a class.
remove unnamed-class [ property value . . . ]
remove named-class instance | all [ property value . . .]
For example:
remove radius-user wally
|
|
save-running
|
The save-running command saves the running configuration as the startup configuration.
|
|
reboot
|
The reboot command restarts the access point (a "soft" reboot).
|
|
factory-reset
|
he factory-reset command resets the AP to factory defaults and reboots.
|
Getting Help on Commands at the CLI
The clicmds offer help by providing command-line completion. The user requests command line completion options by using the TAB key.
Hitting TAB once will attempt to complete the current command.
If multiple completions exist, a beep will sound and no results will be displayed. Enter TAB again to display all available completions.
- Example 1: At a blank command line, hit TAB twice to get a list of all commands.
add Add an instance to the running configuration
factory-reset Reset the system to factory defaults
get Get property values of the running configuration
remove Remove instances in the running configuration
save-running Save the running configuration
set Set property values of the running configuration
- Example 2: Type "get " TAB TAB (including a space after get) to see a list of all property options for the get command.
association Associated station
basic-rate Basic rates of radios
bridge-port Bridge ports of bridge interfaces
bss Basic Service Set of radios
cluster Clustering-based configuration settings
cluster-member Member of a cluster of like-configured access points
config Configuration settings
detected-ap Detected access point
dhcp-client DHCP client settings
dot11 IEEE 802.11 (all radios)
host Internet host settings
interface Network interface
mac-acl MAC address access list item
ntp Network Time Protocol client
portal Guest captive portal
serial Serial access to the command line interface
snmp SNMP (Simple Network Management Protocol)
ssh SSH access to the command line interface
static-ip-route Static IP route entry - used when DHCP is off
supported-rate Supported rates of radios
telnet Telnet access to the command line interface
traphost Destination host for SNMP traps
tx-queue Transmission queue parameters
wme-queue Transmission queue parameters for stations
- Example 3: Type "get system v" TAB. This will result in completion with the only matching property, "get system version". Hit ENTER to display the output results of the command.
Start/Stop Options
The clicmds binary is called each time the user runs a CLI command. It is not a service that needs to be stopped or started, though the access methods for the CLI do.
Command Line Options
To support command completion, a CLI command must respond to the --complete option with the appropriate data to provide the next step in the command line sequence. It must also support --summary to give a summary of what each completion means.
Building the Package
Follow standard instructions for building userspace packages in the Devicescape Developer Guide topic on "Building the Packages", see subtopic: "Building a Userspace Package from a Source RPM"
Licensing
Devicescape Software, Inc.
Related Packages
Required
BusyBox package
Related
dropbear package
device-mgmt-agent package