A Quick Tour of Deployment Shell
The following topics can help you get started with the Deployment Shell CLI to perform configuration changes, switch between operational mode and configuration mode, create a user account, and execute some of the basic commands.
CLI Modes
The CLI has two modes:
-
Operational mode—Use this mode to display the status of and information on the Routing Director cluster including the version of the software installed. In operational mode, you enter commands to monitor and to troubleshoot the Routing Director application. When you log in to a node VM, you are placed in operational mode by default.
If you are in the Linux root shell, type
clito enter Deployment Shell operational mode.user@node>
-
Configuration mode—Use this mode to configure the cluster, SMTP, monitoring, user access, and several application properties. Type
configureto enter configuration mode. To implement all configured changes, you must commit the changes.user@node> configure Entering configuration mode [edit] user@node#
The CLI prompt changes from
user@node>touser@node#, showing that you are in configuration mode, and a banner appears to indicate the hierarchy level. You can exit configuration mode and return to operational mode in one of the following ways:-
To commit the configuration and exit:
[edit] user@node#
commit and-quitcommit complete Exiting configuration mode user@node> -
To exit without committing:
[edit] user@node#
exitExiting configuration mode user@node>
When you exit configuration mode, the CLI prompt changes from
user@node#touser@node>, and the banner no longer appears. You can enter or exit configuration mode as many times as you wish without committing your changes. -
You can view and execute the commands that are available corresponding to your role
and privileges. Currently, we have the super-user and
read-only privileges. A superuser, or root user like the system
administrator, can view and execute all the supported commands available in
Deployment
Shell. A user with read-only privileges can execute a limited set
of commands. To view the commands available for your user role, type
? and press enter. Table 1
describes the commands you can use to navigate the CLI.
|
Command |
Description |
|---|---|
? |
Type ? to view the entire list of supported
commands available to you. Append ? at the end of a
command to view a list of possible options you can use to complete
and execute the command. For example, You can also press tab to auto-complete a command or show the available options for that command. |
cli |
Type this command in the Linux root shell to enter Deployment Shell. |
|
|
Exit
Deployment
Shell or exit from configuration mode. The
|
exit |
Type this command to exit from the
Deployment
Shell CLI or configuration mode. If you are in
the configuration mode, type |
configure |
Type this command to enter the configuration mode in Deployment Shell. |
|
Configuration Mode Commands |
|
commit |
Type this command to commit any configuration updates you make in the configuration mode. |
commit and quit |
Type this command to commit any configuration updates you make and exit the configuration mode. |
set |
Add or edit a configuration. |
show show statement-path |
Display the current configuration. |
delete |
Delete a configuration. |
Display set Commands from the Configuration
In configuration mode, you can display the configuration as a series of configuration mode commands required to re-create the configuration. This is useful if you are not familiar with how to use configuration mode commands or if you want to cut, paste, and edit the displayed configuration.
To display the configuration as a series of configuration mode commands, which are
required to re-create the configuration from the top level of the hierarchy as
set commands, issue the show configuration
mode command with the display set option:
user@node# show | display set
For example:
user@node# show | display setset version "20240723.110451__cd-builder.r1435036 [_cd-builder]" set system scripts action max-datasize 2g set system services ssh port 2222 set deployment monitoring source audit cluster kafka bootstrap_servers kafka.common:9092 set deployment monitoring source audit cluster kafka group_id vector-kafka-consumer set deployment monitoring source audit cluster kafka topics audits-dev set deployment monitoring source ksm cluster prometheus_scrape endpoints http://kube-state-metrics.kube-system:8080/metrics set deployment monitoring source ksm cluster prometheus_scrape scrape_interval_secs 60 set deployment monitoring source host node host_metrics scrape_interval_secs 60 set deployment cluster nodes kubernetes 1 address 10.1.2.3 set deployment cluster nodes kubernetes 2 address 10.1.2.4 set deployment cluster nodes kubernetes 3 address 10.1.2.5 set deployment cluster nodes kubernetes 4 address 10.1.2.6 set deployment cluster ntp ntp-servers pool.ntp.org set deployment cluster common-services ingress ingress-vip 10.1.2.7 set deployment cluster applications active-assurance test-agent-gateway-vip 10.1.2.8 set deployment cluster applications active-assurance test-agent-gateway-vip-ipv6 ::1 set deployment cluster applications active-assurance test-agent-gateway-hostname test.local set deployment cluster applications web-ui web-admin-user "test@test.com" set deployment cluster applications web-ui web-admin-password ENC:U2FsdGTkX19P9H1ZBcxssLwEwyPNfummGXHh7mi/O/o= <output snipped>
To display the configuration as set commands and search for text
matching a regular expression by filtering output, specify the
match option after the pipe ( | ):
user@node# show | display set | match regular-expression
For example:
user@node# show | display set | match address set deployment cluster nodes kubernetes 1 address 10.1.2.3 set deployment cluster nodes kubernetes 2 address 10.1.2.4 set deployment cluster nodes kubernetes 3 address 10.1.2.5 set deployment cluster nodes kubernetes 4 address 10.1.2.6 [edit]
Getting Help About Commands
CLI commands and options can vary by software release, your role, and privileges.
Each level of the CLI command hierarchy provides information about available
commands. You can type a question mark (?) to get context-relevant
help about commands.
If you type the question mark at the command-line prompt, the CLI lists the available commands and options. For example, to view a list of top-level operational mode commands, this is the result:
user@node> ? Possible completions: clear Clear information in the system configure Manipulate software configuration information file Perform file operations monitor Show real-time debugging information quit Exit the management session request Make system-level requests set Set CLI properties, date/time, craft interface message show Show system information ssh Start secure shell on another host user@node>
If you type the question mark after entering the complete name of a command or command option, the CLI lists the available commands and options and then re-displays the command names and options you typed.
user@node> request ? Possible completions: deployment system Perform system-level operations
If you type the question mark in the middle of a command name, the CLI lists possible command completions that match the letters you have entered so far. It then re-displays the letters that you typed. For example, to list all operational mode commands that start with the letter s, type the following:
user@node> s? Possible completions: set Set CLI properties, date/time, craft interface message show Show system information ssh Start secure shell on another host