Table Of Contents
Using the CLI
Setting Up the Director
Starting a CLI Session
Command Modes
Using User Exec Mode
Using Global Configuration Mode
Using Ethernet Interface Configuration Mode
Entering and Exiting Modes
Command Help
Correcting Commands
Editing the CLI
Exiting the CLI Session
Using the Documentation
Text Conventions
Command Description
Syntax Description
Defaults
Command Modes
Usage Guidelines
Command History
Examples
Related Commands
Using the CLI
This chapter provides a general overview of the Cisco VFrame Data Center command-line interface (CLI). It describes how to start a CLI session, how to enter commands, and how to view CLI online help. Details about individual commands appear later in this guide.
This chapter includes the following sections:
•
Setting Up the Director
•
Starting a CLI Session
•
Command Modes
•
Entering and Exiting Modes
•
Command Help
•
Correcting Commands
•
Editing the CLI
•
Exiting the CLI Session
•
Using the Documentation
Setting Up the Director
This guide assumes that your Director has already been set up. If this is not the case, then set up your Director by connecting to the management port and running the VFrame Data Center setup command from the command line. See the Cisco VFrame Data Center Installation and Configuration Guide for complete information about how to set up a Director.
Starting a CLI Session
To start a CLI session, perform the following steps:
Step 1
Start an SSH client.
Step 2
Create a connection to the Director.
Step 3
Log in to the Director using admin as your username.
Note
admin and macrouser are two types of accounts that you use on a Director. The admin account provides all of the CLI commands. The macrouser account provides a document named LOM_INVENTORY_REFERENCE.TXT. This document is a LOM inventory reference used for building LOM inventory files. See the Cisco VFrame Data Center Administration Guide for complete information about the admin and macrouser accounts.
When you are connected, you will see the command line. Example 1-1 shows an example of what you see when you log in:
Example 1-1 VFrame Data Center Director Command Line
SSH Secure Shell 3.2.0 (Build 267)
Copyright (c) 2000-2002 SSH Communications Security Corp - http://www.ssh.com/
This copy of SSH Secure Shell is a commercial version
licensed to CD-ROM customer, N/A.
Last login: Tue Nov 13 16:34:06 2007
Copyright 2007, Cisco Systems,Inc.
Command Modes
Table 1-1 lists the command modes and command prompts.
Table 1-1 Command Modes
Mode
|
Command Prompt
|
User EXEC
|
|
Global configuration
|
|
Ethernet interface configuration
|
|
You enter a question mark (?) at the CLI prompt to list the commands available in the current mode.
Using User Exec Mode
All CLI sessions begin in user EXEC mode. This mode provides system commands and commands for viewing the system configuration. In user EXEC mode, you can perform the following tasks:
•
Ethernet interface configuration
•
File management
•
Database management
•
Debugging
•
Installations and upgrades
•
System configuration
•
System information management
•
Remote connection configuration
Following is a list of the commands available in user EXEC mode:
config Enter configuration mode
db Manage Database Server
install Install and upgrade commands
no Disable debugging functions
ping Ping a remote ip address
setup Configure the system
show Show running system information
shutdown Shutdown the system
ssh Ssh to a remote ip address
telnet Telnet to a remote ip address
traceroute Trace the route to a remote ip address
In user EXEC mode, you access global configuration mode.
Using Global Configuration Mode
When you enter the config command in user EXEC mode, you enter global configuration mode. In global configuration mode, you can perform the following tasks:
•
Clock management
•
GIR management
•
IP configuration
•
License configuration
•
NTP configuration
•
HA configuration
•
Password management
•
VHA configuration
Following is a list of the commands available in global configuration mode:
Enter configuration commands, one per line. End with CNTL/Z.
clock Hardware clock Configuration
end Exit from configure mode
exit Exit from configure mode
gir Golden Image Repository configuration
interface Configure interface
license License configuration
no Negate a command or set its defaults
redundancy Redundancy Configuration
user Configure user details
vha VFrame Host Agent configuration
From the global configuration mode, you access the Ethernet interface configuration mode.
Using Ethernet Interface Configuration Mode
When you enter the interface eth <0-2> command in global configuration mode, you enter ethernet interface configuration mode. In ethernet interface configuration mode, you enable or disable Ethernet interfaces 0, 1 and 2. Following is a list of the commands in ethernet interface configuration mode:
Enter configuration commands, one per line. End with CNTL/Z.
test-100(config)# interface eth 0
Configure ethernet interface:
exit Exit from this submode
no Negate a command or set its defaults
shutdown Shutdown the interface
Entering and Exiting Modes
Most commands are mode-dependent. For example, you can configure clock settings in global configuration mode only. To use the various commands, you must enter and exit CLI modes. Use the exit and end commands to exit modes.
The following example shows you how to enter and exit the global configuration mode:
Enter configuration commands, one per line. End with CNTL/Z.
The following example shows you how to enter and exit ethernet interface configuration mode:
Enter configuration commands, one per line. End with CNTL/Z.
test-100(config)# interface eth 0
test-100(config-eth)# exit
The following example shows you how to exit ethernet interface configuration mode to the user EXEC mode using the end command:
test-100(config-eth)# end
The following example shows you how to exit global configuration mode to the user EXEC mode using the end command:
Note
If you enter the exit command in user EXEC mode, your SSH session ends.
Command Help
Enter part of a command string, and end it with a question mark (?) to display options that you can use to complete the string:
To facilitate command entry, you do not need to enter CLI commands in their entirety. You can enter just enough of each command or argument to make it uniquely identifiable.
backup Make a local backup
file Copy a file to a remote URL.
logs Dump logs to a remote URL.
setup Copy the setup config to a remote site
When enough characters have been entered to uniquely identify a command or keyword in a command string, you can leave the partially-typed command or keyword, enter a space, and then add additional keywords or arguments, or you can press the Tab key to complete the commands or keywords to improve readability.
Correcting Commands
The CLI responds to invalid command input by identifying the first letter of the input with an carat immediately below the error, followed by text describing the error. The first example shows a misspelled command.
% invalid command detected at '^' marker.
In the next example, part of the command is incorrect. The carat indicates that the file keyword cannot immediately follow the backup keyword in this command.
test-100# copy backup file
% invalid command detected at '^' marker.
The system response to command-line errors is different when you use the question mark (?) to obtain help for a command. In this case, the system repeats your input following the subsequent prompt, as shown in the following example.
test-100# show interfce ?
Editing the CLI
Command-line editing lets you modify a command-line command that you have just entered or a command line that you entered previously in the CLI session. The CLI supports a variety of ways to edit the currently displayed command line. Table 1-2 lists and describes these options.
Table 1-2 Key Stroke Shortcuts
Key Strokes
|
Description
|
Ctrl-A
|
Moves the cursor to the beginning of the line.
|
Ctrl-B
|
Moves the cursor left (back) one character.
|
Ctrl-D
|
Deletes the current character.
|
Ctrl-E
|
Moves the cursor to the end of the line.
|
Ctrl-F
|
Moves the cursor to the right (forward) one character.
|
Ctrl-K
|
Deletes text from cursor to the end of the line.
|
Ctrl-L
|
Refreshes the input line.
|
Ctrl-N
|
Displays the next command in the history queue.
|
Ctrl-P
|
Displays the previous command in the history queue.
|
Ctrl-Q
|
Returns to user EXEC mode.
Note If a command is entered on the command line, execute the command before returning to user EXEC mode.
|
Ctrl-T
|
Transposes the current and previous characters.
|
Ctrl-U
|
Deletes all text to the left of the cursor.
|
Ctrl-W
|
Deletes the text of a word up to cursor.
|
Ctrl-Z
|
Returns you to privileged EXEC mode.
|
Esc-B
|
Moves the cursor left (back) one word.
|
Esc-C
|
Converts characters, from the cursor to the end of the word, to upper case.
|
Esc-D
|
Deletes characters from the cursor through remainder of the word.
|
Esc-F
|
Moves the cursor right (forward) one word.
|
Esc-L
|
Converts characters, from the cursor to the end of the word, to lower case.
|
down-arrow
|
Displays the next command in the history queue.
|
up-arrow
|
Displays the previous command in the history queue.
|
left-arrow
|
Moves the cursor left (back) one character.
|
right-arrow
|
Moves the cursor right (forward) one character.
|
Exiting the CLI Session
To exit a CLI session, return to user EXEC mode and enter the exit command.
The CLI session ends.
Using the Documentation
The command pages in this guide provide information about each command. Each command page is divided into subsections, providing easy access to information. Each command page begins with a brief, high-level description of the command, followed by the command syntax.
Text Conventions
The following text conventions indicate how the command is entered on the command line:
•
Text in bold font represents text that you enter exactly as it appears.
•
Text in italicized font represents variables that you replace with actual values when you enter a command at the command line.
•
Square brackets [ ] enclose optional syntax. Do not enter square brackets in the CLI.
•
Braces { } enclose required syntax. Do not enter braces in the CLI.
•
The pipe character | delineates between selections in syntax. If command X requires argument Y or argument Z, but not both at the same time, the syntax will appears as follows:
X {Y | Z}
The following sections describe the subsections in the command descriptions.
Command Description
The Command Description subsection provides a brief, high-level description of the command.
Syntax Description
The Syntax Description subsection provides a table that describes all syntax arguments.
Defaults
The Defaults subsection provides any defaults that are built into the command.
Command Modes
The Command Modes subsection indicates the command mode that you must be in to execute the command.
Usage Guidelines
The Usage Guidelines subsection provides additional information and details to help you use a command to its full potential.
Command History
The Command History subsection lists when the command was added to the CLI and any changes that were made to the command.
Examples
The Examples subsection provides command examples and output.
Related Commands
The Related Commands subsection provides related CLI commands.