User Guide

User Guide
Using the CLI: Dell PowerConnect Switch Command Reference

Back to Contents Page

Using the CLI:
Dell PowerConnect Switch Command Reference

Accessing the CLI 

Setting Passwords

Setting an IP Address

Entering Commands

Getting Help on Commands

Negating the Effect of Commands

Using Command History

Understanding Command Modes

Command Line Processing 


Accessing the CLI

When accessing the management interface for the switch over a direct connection to the switch's console port, or via a Telnet connection, the switch can be managed by entering command keywords and parameters at the prompt. Using the switch's command-line interface (CLI) is very similar to entering commands on a UNIX system.

Console Connection

To access the switch through the console port, perform these steps:

  1. At the console prompt, enter the user name and password. (The default user names are "admin" and "guest" with corresponding passwords of "admin" and "guest.") When the administrator user name and password is entered, the CLI displays the "Console#" prompt and enters privileged access mode (i.e., Privileged Exec). But when the guest user name and password is entered, the CLI displays the "Console>" prompt and enters normal access mode (i.e., Normal Exec).
  2. Enter the necessary commands to complete your desired tasks.
  3. When finished, exit the session with the “quit” or "exit" command.

After connecting to the system through the console port, the login screen displays:

User Access Verification

Username: admin
Password:

CLI session with the PowerConnect is opened.
To end the CLI session, enter [Exit].

Console#

Telnet Connection

Telnet operates over the IP transport protocol. In this environment, your management station and any network device you want to manage over the network must have a valid IP address.

To access the switch through a Telnet session, you must first set the IP address for the switch, and set the default gateway if you are managing the switch from a different IP subnet. For example,

Console(config)#interface vlan 1
Console(config-if)#ip address 10.1.0.1 255.255.255.0
Console(config-if)#exit
Console(config)#ip default-gateway 10.1.0.254

If your corporate network is connected to another network outside your office or to the Internet, you need to apply for a registered IP address. However, if you are attached to an isolated network, then you can use any IP address that matches the network segment to which you are attached.

After you configure the switch with an IP address, you can open a Telnet session by performing these steps.

  1. From the remote host, enter the Telnet command and the IP address of the device you want to access.
  2. At the prompt, enter the user name and system password. The CLI will display the "Vty-0#" prompt for the administrator to show that you are using privileged access mode (i.e., Privileged Exec), or "Vty-0>" for the guest to show that you are using normal access mode (i.e., Normal Exec).
  3. Enter the necessary commands to complete your desired tasks.
  4. When finished, exit the session with the "quit" or "exit" command.

After entering the Telnet command, the login screen displays:

User Access Verification

Username: admin
Password:

CLI session with the PowerConnect is opened.
To end the CLI session, enter [Exit].

Vty-0#

note.gif (1135 bytes) NOTE: You can open up to four sessions to the device via Telnet.


Setting Passwords

note.gif (1135 bytes) NOTE: If this is your first time to log into the configuration program, you should define a new password using the "username" command, record it and put it in a safe place.

Passwords can consist of up to 8 alphanumeric characters and are case sensitive. To prevent unauthorized access to the switch, set the passwords as follows:

  1. Open the console interface with the default user name and password "admin" to access Privileged Exec mode.
  2. Type "configure" and press <Enter>.
  3. Type "username guest password 0 password," for the Normal Exec level, where password is your new password. Press <Enter>.
  4. Type "username admin password 0 password," for the Privileged Exec level, where password is your new password. Press <Enter>.
  5. Save your configuration changes by typing "copy running-config startup-config." Press <Enter>.
note.gif (1135 bytes) NOTE: CLI configuration commands only modify the running configuration file and are not saved when the switch is rebooted. To save all your configuration changes in nonvolatile storage, you must copy the running configuration file to the startup configuration file using the copy command.


Setting an IP Address

You must assign an IP address to this device to gain management access over your network. You may also need to a establish a default gateway between this device and management stations that exist on another network segment. You can manually configure a specific IP address, or direct the device to obtain an address from a BOOTP or DHCP server when it is powered on. Valid IP addresses consist of four decimal numbers, 0 to 255, separated by periods. Anything outside this format will not be accepted by the CLI program.

note.gif (1135 bytes) NOTE: The IP address for this switch is assigned via DHCP by default. The default management interface is VLAN 1.


If you select the "bootp" or "dhcp" option, IP is enabled but will not function until a BOOTP or DHCP reply has been received. Requests will be broadcast periodically by this device in an effort to learn its IP address. (BOOTP and DHCP values can include the IP address, default gateway, and subnet mask).

Console#config
Console(config)#interface vlan 1
Console(config-if)#ip address 192.168.1.5 255.255.255.0
Console(config-if)#exit
Console(config)#ip default-gateway 192.168.1.254
Console(config)#

Before you can assign an IP address to the switch, you must obtain the following information from your network administrator:

  • IP address for the switch
  • Default gateway for the network
  • Network mask for this network

To assign an IP address to the switch, complete the following steps:

  1. From the Privileged Exec level global configuration mode prompt, type "interface vlan 1" to access the interface-configuration mode. Press <Enter>.
  2. Type "ip address ip-address netmask," where "ip-address" is the switch IP address and "netmask" the network mask for the network.
  3. Type "exit" to return to the global configuration mode prompt. Press <Enter>.
  4. To set the IP address of the default gateway for the network to which the switch belongs, type "ip default-gateway gateway," where "gateway" is the IP address of the default gateway. Press <Enter>.
  5. Save your configuration changes by typing "copy running-config startup-config." Press <Enter>.

At this point, you are ready to use appropriate network cabling to connect devices to the switch’s external RJ-45 connectors.


Entering Commands

This section describes how to enter CLI commands.

Keywords and Arguments

A CLI command is a series of keywords and arguments. Keywords identify a command, and arguments specify configuration parameters. For example, in the command "show interfaces status ethernet 1/5," show, interfaces and status are keywords, ethernet is an argument that specifies the interface type, and 1/5 specifies the unit/port.

note.gif (1135 bytes) NOTE: This switch is a standalone unit, so the interface or unit number is always "1." For example, you should enter "1/5" for port 5.

You can enter commands as follows:

  • To enter a simple command, enter the command keyword.
  • To enter multiple commands, enter each command in the required order. For example, to enable Privileged Exec command mode, and display the startup configuration, enter:
    Console>enable
    Console# show startup-config
  • To enter commands that require parameters, enter the required parameters after the command keyword. For example, to set a password for the administrator, enter:
    Console(config)# username admin password 0 smith

Minimum Abbreviation

The CLI will accept a minimum number of characters that uniquely identify a command. For example, the command "configure" can be entered as con. If an entry is ambiguous, the system will prompt for further input.

Command Completion

If you terminate input with a Tab key, the CLI will print remaining characters of a partial keyword up to the point of ambiguity. In the "configure" example, typing con followed by a tab will result in printing the command up to "configure."

Getting Help on Commands

You can display a brief description of the help system by entering the help command. You can also display command syntax by using the "?" character to list keywords or parameters.

Showing Commands

If you enter a "?" at the command prompt, the system will display the first level of keywords for the current command class (Normal Exec or Privileged Exec) or configuration class (Global, Interface, Line, or VLAN Database). You can also display a list of valid keywords for a specific command. For example, the command "show ?" displays a list of possible show commands:

Console#show ?
  bridge-ext         Bridge extend information
  garp               Garp property
  gvrp               Show gvrp information of interface
  history            Information of history
  interfaces         Information of interfaces
  ip                 IP information
  line               TTY line information
  logging            Show the contents of logging buffers
  mac-address-table  Set configuration of the address table
  map                Map priority
  port               Characteristics of the port
  queue              Information of priority queue
  radius-server      Radius server information
  running-config     The system configuration of running
  snmp               SNMP statistics
  spanning-tree      Specify spanning-tree
  ssh                Secure shell
  startup-config     The system configuration of starting up
  system             Information of system
  tacacs-server      Login by tacacs server
  users              Display information about terminal lines
  version            System hardware and software status
  vlan               Switch VLAN Virtual Interface
Console#show

The command "show interfaces ?" will display the following information:

Partial Keyword Lookup

If you terminate a partial keyword with a question mark, alternatives that match the initial letters are provided. (Remember not to leave a space between the command and question mark.) For example "s?" shows all the keywords starting with "s."

Console#show s?
snmp            spanning-tree   ssh             startup-config   system
Console#show s

Negating the Effect of Commands

For many configuration commands you can enter the prefix keyword "no" to cancel the effect of a command or reset the configuration to the default value. For example, the logging command will log system messages to a host server. To disable logging, specify the no logging command. This guide describes the negation effect for all applicable commands.

Using Command History

The CLI maintains a history of commands that have been entered. You can scroll back through the history of commands by pressing the up arrow key. Any command displayed in the history list can be executed again, or first modified and then executed.

Using the show history command displays a longer list of recently executed commands.

Understanding Command Modes

The command set is divided into Exec and Configuration classes. Exec commands generally display information on system status or clear statistical counters. Configuration commands, on the other hand, modify interface parameters or enable certain switching functions. These classes are further divided into different modes. Available commands depend on the selected mode. You can always enter a question mark "?" at the prompt to display a list of the commands available for the current mode. The command classes and associated modes are displayed in the following table:

Class Mode
Exec

Normal
Privileged

Configuration*

Global
Interface
Line
VLAN

*You must be in Privileged Exec mode to access any of the configuration modes.

Exec Commands

When you open a new console session on switch with the user name "guest," the system enters Normal Exec command mode (or guest mode). Only a limited number of the commands are available in this mode. You can access all the commands only in Privileged Exec command mode (or administrator mode). To access Privilege Exec mode, open a new console session with the user name "admin," or enter the enable command (followed by the privileged level password if so configured). The command prompt displays as "Console>" for Normal Exec mode and "Console#" for Privileged Exec mode.

To enter Privileged Exec mode, enter the following commands and passwords:

Username: admin
Password: [system login password]

CLI session with the PowerConnect is opened.
To end the CLI session, enter [Exit].

Console#


Username: guest
Password: [system login password]

CLI session with the PowerConnect is opened.
To end the CLI session, enter [Exit].

Console>enable
Password: [privileged level password if so configured]
Console#

Configuration Commands

Configuration commands are privileged level commands used to modify switch settings. These commands modify the running configuration only and are not saved when the switch is rebooted. To store the running configuration in nonvolatile storage, use the copy running-config startup-config command.

The configuration commands are organized into three different modes:

  • Global Configuration - These commands modify the system level configuration, and include commands such as hostname and snmp-server community.
  • Interface Configuration - These commands modify the port configuration such as speed-duplex and negotiation.
  • Line Configuration - These commands modify the console port configuration, and include command such as parity and databits.

To enter the Global Configuration mode, enter the command configure in Privileged Exec mode. The system prompt will change to "Console(config)# " which gives you access privilege to all Global Configuration commands.

Console#configure
Console(config)#

To enter Interface, Line Configuration, or VLAN mode, you must enter the "interface …," "line …" or "vlan database" command while in Global Configuration mode. The system prompt will change to "Console(config-if)#," "Console(config-line)#" or "Console(config-vlan)" indicating that you have access privileges to the associated commands. You can use the end command to return to the Privileged Exec mode.

Console(config)#interface ethernet 1/5
Console(config-if)#exit
Console(config)#line console
Console(config-line)#

Command Line Processing

Commands are not case sensitive. You can abbreviate commands and parameters as long as they contain enough letters to differentiate them from any other currently available commands or parameters. You can use the Tab key to complete partial commands, or enter a partial command followed by the "?" character to display a list of possible matches. You can also use the following editing keystrokes for command-line processing:

Keystroke Function
Ctrl-A Shifts cursor to start of command line.
Ctrl-B Shifts cursor to the left one character.
Ctrl-E Shifts cursor to end of command line.
Ctrl-F Shifts cursor to the right one character.
Ctrl-P Shows the last command.
Ctrl-U Deletes the entire line.
Ctrl-W Deletes the last word typed.
Delete key or backspace key

Erases a mistake when entering a command.



Please read all restrictions and disclaimers.


 Back to Contents Page

© 2012 Dell | Terms of Sale | Unresolved Issues | Privacy | Site Map | Feedback

snWEB4