ConfD is a powerful solution for building on-device management systems for all kinds of networking equipment. ConfD can auto-render a powerful command line interface (CLI) in the style of a Juniper or Cisco CLI significantly reducing development time and costs.
ConfD CLI Functionality
ConfD CLI provides various commands for configuring and monitoring software, hardware, and network connectivity of target devices. The CLI supports operational mode for monitoring the state of the device and configuration mode for changing the state of the device.
Operational mode is the initial mode after successful login to the CLI. It is primarily used for viewing the system status, controlling the CLI environment, monitoring and troubleshooting network connectivity, and initiating the configuration mode. Configuration mode can be initiated by entering the configure command in operational mode.
All changes to the device’s configuration are done to a copy of the active configuration called a candidate configuration. These changes do not take effect until a successful commit or confirmed commit command is entered. When a candidate configuration is committed, the system verifies that nothing of relevance to the update has changed in the active configuration of the device. In the event relevant changes have occurred, the system displays them for the user and asks if the commit should proceed and overwrite the changed active configuration. The system saves multiple past configurations. Users may use the default command name or specify another name. Past configurations can be reinstated by using the rollback command.
Device developers use the YANG data modeling language (RFC 6020) for describing configuration data. ConfD NETCONF and ConfD Web Interface use the same data model. From this data model, ConfD automatically generates a fully functional CLI with the following features:
- Support for choice of Juniper/JUNOS, Cisco/IOS XR, or Cisco/legacy IOS style CLIs
- Rich editing with tab-completion for commands, static elements and dynamic instances
- Support for running commands in batch mode and for scripting new commands which may invoke several built-in commands
- Command line history and command line editor
Extending and Customizing the CLI
The ConfD CLI can be extended or customized in the following ways:
- Internationalization (I18n). Help texts can be translated if developers supply translation files
- Help – Users may choose from three options for command display: short descriptions, longer documentations, or short descriptions of arguments.
- Transformation – The Transformation offers a translation between internal names, such as commands, and the strings displayed in the CLI.
- Wizards – For more complicated configurations, or for bringing up the system initially, wizards can pose questions to the user and then configure relevant parameters.
- Move/Delete/Mount – Helps restructure an existing CLI without changing the data model.
- Advanced Command Completion – The auto-generated CLI performs command completion with respect to values at the current position of the configuration tree.
- Hidden Commands/Settings – This is very useful when adding experimental features, debugging functionality, or customer-specials to a CLI.
ConfD CLI Commands
ConfD CLI provides three types of commands: built-in commands, built-in commands that can be extended by CLI developers, and commands defined by CLI developers. The built-in commands in operational mode are configure, file, help, quit, and set.
Built-in commands in operational mode that can be extended by CLI developers are: monitor, request, and show. For example, some show commands are built-in, such as “show configuration,” which displays the current configuration. Other show commands must be supplied by the CLI developer (show interfaces, corresponding to “ifconfig -a” in Linux).
The built-in commands in configuration mode are: commit, copy, delete, edit, exit, help, load, quit, rollback, run, save, set, show, status, top, and up. Of these, help can be extended by CLI developers. Examples of typical commands defined by CLI developers are: restart, mtrace, and test.
ConfD CLI also provides a mechanism for CLI developers to invoke, as CLI commands, arbitrary programs from the CLI. For example, a ping command that invokes the ping utility can easily be defined.
ConfD supports most versions of Linux and is implemented as a lean daemon with few library dependencies and efficient use of RAM, and disk footprint.