CLI Reference Guide 2. Getting Started
Version 6.4 17 January 2012
2.2.4 Common CLI Functions
The following table contains descriptions of common CLI commands.
Table 2-2: Common CLI Commands
Command Description
do
Provides a way to execute commands in other command sets without
taking the time to exit the current command set. The following example
shows the do command, used to view the GigabitEthernet interface
configuration while in the virtual-LAN interface command set:
(config)# interface vlan 1
(conf-if-VLAN 1)# do show interfaces GigabitEthernet
0/0
no Undoes an issued command or disables a feature. Enter no before the
command:
the command is not applied until you enter the activate and exit
commands.
Note: Offline configuration changes require a reset of the device. A reset
can be performed at the end of the configuration changes. A required reset
exit
Leaves the current command-set and returns one level up. If issued on the
top level, the session ends.
For online parameters, if the configuration was changed and no activate
command was entered, the exit command applies the activate command
automatically. If issued on the top level, the session will end:
(config)# exit
# exit
(session closed)
display
Shows the configuration of current configuration set.
help
Shows a short help how-to string.
history
Shows a list of previously run commands.
list
Shows the available command list of the current command-set.
| <filter>
Applied to a command output. The filter should be typed after the
command with a pipe mark (|)
Supported filters:
include <word> – filter (print) lines which contain <word>
exclude <word> – filter lines which does not contain <word>
grep <options> - filter lines according to grep common Unix utility options
egrep <options> - filter lines according to egrep common Unix utility
options
begin <word> – filter (print) lines which begins with <word>
between <word1> <word2> – filter (print) lines which are placed between
<word1> and <word2>
count – show the output’s line count
Example:
# show version | grep Number
;Serial Number: 2239835