D-link DES-1228 User Manual [ru]

DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Information in this document is subje c t to change without notice. © 2012 D-Link Corporation. All rights reserved. Reproduct ion in any ma nner whatsoever without the written permission of D-Link Corporation is strictly forbidden. Trademarks us ed in thi s text: D-Link and the D-LINK logo are trademarks of D-Link Corporation; Microsoft and Windows are
registered trademarks of Microsoft Corporation. Other trademarks and trade names may be used in this document to refer to either the entities claiming the marks and names o r
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
TABLE OF CONTENTS
INTRODUCTION ................................................................................................................................................................ 1
USING THE CONSOLE CLI .............................................................................................................................................. 3
COMMAND SYNTAX ......................................................................................................................................................... 7
BASIC SWITCH COMMANDS ........................................................................................................................................ 10
MODIFY BANNER AND PROMPT COMMANDS ......................................................................................................... 34
SWITCH PORT COMMANDS ......................................................................................................................................... 37
PORT SECURITY COMMANDS ..................................................................................................................................... 41
NETWORK MANAGEMENT (SNMP) COMMANDS .................................................................................................... 47
SWITCH UTILITY COMMANDS .................................................................................................................................... 73
NETWORK M ONITORING COMMANDS ..................................................................................................................... 88
MULTIPLE SPAN NING TREE PROTOCOL (MSTP ) COMMANDS ......................................................................... 105
FORWARDING DATABASE COMMANDS .................................................................................................................. 121
PACKET STORM CONTROL COMMANDS ................................................................................................................ 129
QOS COMMANDS .......................................................................................................................................................... 133
PORT MIRRORING COMMANDS ............................................................................................................................... 148
VLAN COMMANDS ........................................................................................................................................................ 151
LINK AGGREGATION COMMANDS .......................................................................................................................... 160
BASIC IP COMMANDS .................................................................................................................................................. 165
IGMP SNOOPING COMMANDS ................................................................................................................................... 172
DHCP RELAY COMMANDS ......................................................................................................................................... 185
802.1X COMMANDS ....................................................................................................................................................... 192
ACCESS CONTROL LIST (ACL) COMMANDS .......................................................................................................... 213
CPU FILTERING COMMANDS .................................................................................................................................... 228
SAFEGUARD ENGINE COMMANDS ........................................................................................................................... 230
TRAFFIC SEGMEN TA TIO N COMMANDS ................................................................................................................. 233
TIME AND SNTP COMMANDS .................................................................................................................................... 235
ARP COMMANDS........................................................................................................................................................... 241
ROUTING TABLE COMMANDS .................................................................................................................................. 245
MAC NOTIFICATION COMMANDS ............................................................................................................................ 249
ACCESS AUTHENTICATION CONTROL COMMANDS ........................................................................................... 253
SSH COMMANDS ........................................................................................................................................................... 277
SMTP COMMANDS ........................................................................................................................................................ 285
CABLE DIAGNO STICS COMMANDS .......................................................................................................................... 290
DHCP LOCAL RELAY COMMANDS ........................................................................................................................... 292
GRATUITOUS ARP COMMANDS ................................................................................................................................ 296
VLAN TRUNKING COMMANDS .................................................................................................................................. 301
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
ASYMMETRIC VLAN COMMANDS ............................................................................................................................ 305
IGMP SNOOPING MULTICAST VLAN COMM ANDS ............................................................................................... 307
LLDP COMMANDS ........................................................................................................................................................ 313
DOS PREVENTION COMMANDS ................................................................................................................................ 334
IP-MAC-PORT BINDING COMM ANDS ....................................................................................................................... 340
LOOPBACK DETECTION COMMANDS ..................................................................................................................... 347
FLOW METER COMMANDS ........................................................................................................................................ 354
ARP SPOOFING PREVENTION COMMANDS ............................................................................................................ 357
TECHNICAL SUP PORT COMMANDS ......................................................................................................................... 360
COMMAND HISTORY COMMANDS ........................................................................................................................... 363
BPDU ATTACK PROTECTION COMMANDS ............................................................................................................ 367
PPPOE CIRCUIT ID INSERTION COMMANDS ......................................................................................................... 374
DHCP SERVER SCREENING SETTINGS .................................................................................................................... 377
IPV6 NEIGHBOUR DISCOVERY COMMANDS .......................................................................................................... 380
DEBUG SOFTWARE COMMANDS .............................................................................................................................. 384
BPDU TUNNEL COMMANDS ....................................................................................................................................... 395
APPENDIX A – PASSWORD RECOVERY PROCEDURE .......................................................................................... 398
APPENDIX B – SYSTEM LOG ENTRIES ..................................................................................................................... 399
APPENDIX C – TRAP ENTR IES ................................................................................................................................... 406
APPENDIX D - RADIUS ATTRIBUTES ASSIGNMENT .............................................................................................. 408
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
1

INTRODUCTION

The Switch can be managed through the Switch’s serial port, Telnet, or the Web-based management age nt. The Co mmand Line Interface (CLI) can be used to configure and manage the Switch via the serial port or Telnet interfaces.
This manual p ro vides a re fere nce fo r al l of t he co mma nds co ntaine d i n the CLI. Con figur at ion a nd ma nage ment of t he S witc h via the Web-based manage ment agent is d iscussed in the Manual. Configuration and management of the Switch via the Web-based management agent is di s cussed in the User’s Guide.

Accessing the Switch via the Serial Port

The Switch’s serial port’s default set tings are as follows:
9600 baud
no parity
8 data bits
1 stop bit
A computer running a terminal emulation program capable of emulating a VT-100 terminal and a serial port configured as above are then connected to the Switch’s serial port via an RJ-45 console cable.
With the serial port properly connected to a management computer, the following screen should be visible. If this screen does not appear, try pressing Ctrl+R to refresh the console screen.
DES-1228/ME Metro Ethernet Switch Command Line Interface
Firmware: Build 2.01.001 Copyright(C) 2012 D-Link Corporation. All rights reserved. UserName: PassWord:
Figure 1 - 1. Initial CLI screen
There is no initial username or password. Just press the Enter key twice to display the CL I inp ut cur sor − DES-1228/ME:5#. This is the command line where all commands are input.

Setting the Switch’s IP Address

Each Switch must be assigned its own IP Address, which is used for communication with an SNMP network manager or other TCP/IP application (for example BOOTP, TFTP). The Switch’s default IP address is 10.90.90.90. Users can change the default Switch IP address to meet the specification of your networking address scheme.
The Switch is also assigned a unique MAC address by the factory. This MAC address cannot be changed, and can be found on the initial boot console screen – shown below.
Boot Procedure V2.00.001
-------------------------------------------------------------------------------
Power On Self Test ........................................ 100%
MAC Address : 00-12-28-8E-77-00 H/W Version : B1
Please wait, loading V2.01.001 Runtime image .............. 100%
Figure 1 - 2. Boot screen
The Switch’s MAC address can also be found in the Web management program on the Switch Information (Basic Settings) window in the Configuration folder.
The IP address for the Switch must be set before it can be managed with the Web-based manager. The Switch IP address can be automatically set using BOOTP or DHCP protocols, in which case the actual address assigned to the Switch must be known.
The IP address may be set using the Command Line Interface (CLI) over the console serial port as follows:
1
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config ipif System ipaddress 10.73.21.11/8
Starting at the command line prompt, enter the command config ipif System ipaddress xxx.xxx.xxx.xxx/yyy.yyy.yyy.yyy. Where the x’s represent the IP address to be assigned to the IP interface named System and the y’s represent the corresponding subnet mask.
Alternatively, users can enter config ipif System ipaddress xxx.xxx.xxx.xxx/z. Where the x’s represent the IP address to be assigned to the IP interface named System and the z represents the corresponding number of subnets in CIDR notation.
The IP interface named System on the Switch can be assigne d a n I P ad d r ess a nd sub ne t ma sk which can the n be u sed to c o nnec t a management station to the Switc h’s Telnet or Web-based management agent.
Command: config ipif System ipaddress 10.73.21.11/8
Success.
DES-1228/ME:5#
Figure 1 - 3. Assigning an IP Address
In the above example, the Switch was assigned an IP address of 10.73.21.11 with a subnet mask of 255.0.0.0. The system message Success indicates that the command was executed successfully. The Switch can now be configured and managed via Telnet, SNMP MIB browser and the CLI or via the Web-based management agent using the above IP address to connect to the Switch.
2
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME Metro Ethernet Switch
2

USING THE CONSOLE CLI

The Switch supports a console management in terface that allows the user to connect to the Switch’s management agent via a serial port and a terminal or a computer running a terminal emulation program. The console can also be used over the network using the TCP/IP Telnet protocol. The console program can be used to configure the Switch to use an SNMP-based net work ma nagement application over the network.
This chapter describes how to use the console interface to access the Switch, change its settings, and monitor its operation.
Note: Switch configuration settings are saved to non-volatile RAM using the s ave command . The curr ent configuration will then be retained in the Switch’s NV-RAM, and reloaded when the Switch is reboote d. If the Switch is rebooted without using the save command, the last configuration s aved to NV-RAM will be loaded.

Connecting to the Switch

The console interface is used by connecting the Switch to a VT100-compatible terminal or a computer running an ordinary terminal emulator program (e.g., the HyperTerminal program included with the Windows operating system) using an RJ-45 console cable. Your terminal parameters will need to be set to:
VT-100 compatible
9600 baud
8 data bits
No parity
One stop bit
No flow control
Users can also access the same functions over a Telnet interface. Once users have set an IP address for your Switch, users can use a Telnet program (in VT-100 compatible terminal mode) to access and control the Switch. All of the screens are identical, whether accessed from the console port or from a Telnet interface.
After the Switch reboots and users have logged in, the console loo ks like this:
Command Line Interface
Firmware: Build 2.01.001 Copyright(C) 2012 D-Link Corporation. All rights reserved. UserName: PassWord:
Figure 2 - 1. Initial Console Screen after logging in
Commands are entered at the command prompt, DES-1228/ME:5#. There are a number of helpful features included in the CLI. Entering the ? command will display a list of all of the top-level
commands.
3
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
..
CTRL+C ESC q Quit SPACE n Next Page ENTER Next Entry a All
? cable_diag ports clear clear arptable clear counters clear dos_prevention counters clear fdb clear flood_fdb clear igmp_snooping data_driven_group clear log clear port_security_entry port config 802.1p default_priority config 802.1p user_priority config 802.1x auth_mode config 802.1x auth_parameter ports config 802.1x auth_protocol config 802.1x capability ports config 802.1x guest_vlan ports config 802.1x init config 802.1x reauth config access_profile profile_id
Figure 2 - 2. The ? Command
When users enter a command without its required parameters, the CLI will prompt users with Next possible completions: message.
DES-1228/ME:5#config account Command: config account
Next possible completions: <username>
DES-1228/ME:5#
Figure 2 - 3. Example Command Parameter Help
In this case, the command config account was entered without the parameter <username>. The CLI will then prompt user s to enter the <username> with the message, Next possible completions:. Every command in the CLI has this feature, and complex commands have several layers of parameter prompting.
In additio n, after typin g any give n command p lus one spa ce, users can see all of the next possible sub-co mmands, in sequential order, by repeatedly pressing the Tab key.
To re-enter the previous command at the command prompt, press the up arrow cursor key. The previous command will appear at the command prompt.
4
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config account
DES-1228/ME:5#
DES-1228/ME:5#the
DES-1228/ME:5#
Command: config account
Next possible completions: <username>
DES-1228/ME:5#config account Command: config account
Next possible completions: <username>
Figure 2 - 4. Using the Up Arrow to Re-enter a Command
In the above example, the command config account was entered without the required parameter <username>, the CLI returned the Next possible completions: <username> prompt. The up arrow cursor control key was pressed to re-enter the pr evious command (config account) at the command prompt. Now the appropriate username can be entered and the config account command re­executed.
All comma nds in the CLI function in this way. In additio n, the syn t ax of the help prompts are the sa me as present ed in this manual
angle brackets < > indicate a numerical value or character string, braces { } indicate optional parameters or a choice of parameters, and brackets [ ] indicate required parameters.
If a command is entered that is unrecognized by the CLI, the top-level commands will be displayed under the Available commands: prompt.
Available commands: .. ? cable_diag clear config create delete dir disable download enable login logout ping reboot reset save show smtp telnet traceroute upload
The top-level commands consist of commands such as show or config. Most of these commands require one or more parameters to narrow the top-level command. This is equivalent to show what? or config what? Where the what? is the next parameter.
For example, if users enter the show command with no additional parameters, the CLI will then display all of the possible next parameters.
Figure 2 - 5. The Next Available Commands Prompt
5
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show
Command: show
Next possible completions:
802.1p 802.1x access_profile account acct_client address_binding arp_spoofing_prevention arpentry asymmetric_vlan auth_client auth_diagnostics auth_session_statistics auth_statistics authen authen_enable authen_login authen_policy auto_fdb autoconfig bandwidth_control bpdu_protection bpdu_tunnel command command_history config cos cpu_access_profile cpu_filter dhcp_local_relay dhcp_relay dos_prevention dscp_mapping error fdb filter firmware flood_fdb flow_meter gratuitous_arp greeting_message gvrp igmp igmp_snooping ipif iproute jumbo_frame lacp_ports link_aggregation lldp log log_save_timing loopdetect mac_notification mirror multicast multicast_fdb packet per_queue port_security ports pppoe pvid radius router_ports safeguard_engine scheduling scheduling_mechanism serial_port session smtp snmp sntp ssh stp switch syslog tech_support terminal_line time traffic traffic_segmentation trusted_host utilization vlan vlan_trunk
DES-1228/ME:5#
In the above example, all of the possible next parameters for the show command are displayed. At the next command prompt, the up arrow was used to re-enter the show command, followed by the account parameter. The CLI then displays t he user a ccounts configured on the Switch.
Figure 2 - 6. Next possible completions: Show Command
6
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
3

COMMAND SYNTAX

The following symbols are used to describe how command entries are made and values and arguments are specified in this manual.
Note: All commands are case-sensitive. Be sure to disable Caps Loc k or any other unwanted function that changes text case.
<angle brackets>
Purpose Syntax
Description
Example Command
Encloses a variable or value that must be specified. config ipif <System> [{ipaddress <network_address> | vlan <vlan_name
32> | state [enable | disable}] | bootp | dhcp] In the above syntax example, users must supply an IP interface name in the
<System> space, a VLAN name in the <vlan_name 32> space, and the network address in the <network_address> space. Do not type the angle brackets.
config ipif System ipaddress 10.24.22.5/8 vlan Design state enable
[square brackets]
Purpose
Syntax Description
Example Command
Encloses a required value or set of required arguments. One value or argument can be specified.
create account [admin | operator| Power User|user] <username 15> In the above syntax example, users must specify either an admin or a user
level account to be created. Do not type the square brackets. create account admin ctsnow
| vertical bar
Purpose
Syntax Description
Example Command
Separates two or more mutually exclusive items in a list, one of which must be entered.
create account [admin | operator| Power User|user] <username 15> In the above syntax example, users must specify either admin, or user. Do
not type the vertical bar. create account admin ctsnow
7
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
{braces}
Purpose Syntax Description
Example command
Encloses an optional value or set of option al arguments. reset {[config | system]} {force_agree} In the first part of the above syntax example, users have the option to
specify config or system. It is not necessary to specify either optional value, however the effect of the system reset is dependent on which, if any, value is specified. Therefore, with this example there are three possible outcomes of performing a system reset. Do not type the braces.
reset config
(parentheses)
Purpose
Syntax Description
Example command
Indicates at least one or more of the values or arguments in the preceding syntax enclosed by braces must be specified.
config dhcp_relay {hops <value 1-16> | time <sec 0-65535>}(1) In the above syntax example, users have the option to specify hops or time or
both of them. The "(1)" following the set of braces indicates at least one argument or value within the braces must be specified. Do not type the parentheses.
config dhcp_relay hops 3
Line Editing Key Usage
Delete
Backspace
Insert or Ctrl+R
Left Arrow Right Arrow Up Arrow
Down Arrow
Deletes the character under the cursor and then shifts the remaining characters in the line to the left.
Deletes the character to the left of the cursor and then shifts the remaining characters in the line to the left.
Toggle on and off. When toggled on, inserts text and shifts previous text to the right.
Moves the cursor to the left. Moves the cursor to the right. Repeats the previously entered command. Each time the up arrow is
pressed, the command previous to that displayed appears. This way it is possible to review the command history for the current session. Use the down arrow to progress sequentially forward through the command history list.
The down arrow will display the next command in the command history entered in the current session. This displays each command sequentially as it was entered. Use the up arrow to review previous commands.
Tab
Shifts the cursor to the next field to the left.
8
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Multiple Page Displa y Control Keys
Space CTRL+c
ESC
n p q
r a Enter
Displays the next page. Stops the display of remaining pages when multiple pages are to be
displayed. Stops the display of remaining pages when multiple pages are to be
displayed. Displays the next page. Displays the previous page. Stops the display of remaining pages when multiple pages are to be
displayed. Refreshes the pages currently displayed. Displays the remaini ng pag es without pausing between pages. Displays the next line or table entry.
9
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
[<ipaddr> | <domain_name 255>] {times <value 1-255> | timeout <sec 1-99 > |
4

BASIC SWITCH COMMANDS

The Basic Switch commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
enable password encryption disable password encryption create account [admin|operator|Power User|user] <username 15> config account <username> {encrypt [plain_text|sha_1] <password>} show account delete account <username> show session show switch show serial_port config serial_port {baud_rate [9600 | 19200 | 38400 | 115200] | auto_ log out [ne ver | 2_m inutes |
5_minutes | 10_minutes | 15_m inutes ]} (1) enable clipaging disable clipaging enable telnet {<tcp_port_number 1-65535>} disable telnet telnet <ipaddr> {tcp_port <value 0 -65535>} ping
source_ip <ipaddr>} enable web {<tcp_port_number 1-65535>}
disable web save { [config {config_id <value 1-2>} | log | all]} reboot {force_agree} reset {[config | system ]} { force_agree} login logout show config [ current_config | config_in _nvram <conf ig_id 1-2> ] {[include | exclude | begin]
<filter_string 80> {<filter_string 80> {<filter_string 80>}} {[include | exclude |
begin] <filter_string 80> {<filter_string 80> {<filter_string 80>}}
{[include | exclude | begin] <filter_str ing 80 > {<filter _string 80> {<filter_string
80>}}}}} config terminal_line [default | <value 20-80>] show terminal_line enable jumbo_frame disable jumbo_frame
10
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#
Command Parameters
show jumbo_frame clear config configuration config_id config configuration trap { save [ enable | disable ] | upload [ enable | disable ] | download [ enable |
disable ] }(1) show config information
Each command is listed, in detail, in the following sections:
enable password encryption
Purpose Syntax Description
Parameters Restrictions
Example usage : To enable password encryption on the Switch.
DES-1228/ME:5#enable password encryption Command: enable password encryption
Success.
Used to enable password encryption on a user account. enable password encryption The user account configuration information will be stored in the
configuration file, and can be applied to the system at a time in the future. If the password encryption is enabled, the password will be in encrypted form. If password encryption is disabled and the user specifies the password in encrypted form, or if the password has been converted to encrypted form by the last enabled password encryption command, the password will still be in encrypted form. It can not revert back to plain text.
None. Only Administrator level users can issue this command.
Example usage : To disable password encryption on the Switch.
disable password encryption
Purpose Syntax Description
Parameters Restrictions
Used to disable password encryption on a user account. disable password encryption The user account configuration information will be stored in the
configuration file, and can be applied to the system at a time in the future. If the password encryption is enabled, the password will be in encrypted form. If password encryption is disabled and the user specifies the password in encrypted form, or if the password has been converted to encrypted form by the last enabled password encryption command, the password will still be in encrypted form. It can not revert back to plain text.
None. Only Administrator level users can issue this command.
11
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#disable password encryption
Command: disable password encryption
Success.
DES-1228/ME:5#
12
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
create account
Purpose Syntax Description
Used to create user accounts. create [admin|operator|Power User|user] <usernam e 15> This command is used to create user accounts that consist of a
username of 1 to 15 characters and a password of 0 to 15 characters. Up to eight user accounts can be created.
Parameters
admin <username> – Name of the administrator account. operator <username>- Specify an operator level account. Power User <username> - Specify a power user level account, The
power user level is lower than the operator level and higher than the user level.
user <username> – Name of the user account. username - The user name, with a minimum of 1 character and a
maximum of 15 characters
Restrictions
Only Administrator level users can issue this command. Usernames can be between 1 and 15 characters. Passwords can be between 0 and 15 characters.
Example usage : To create an operator-level user account with the username “dlink”.
DES-1228/ME:5#create account operator dlink Command: create account operator dlink
Enter a case-sensitive new password:***** Enter the new password again for confirmation:***** Success.
DES-1228/ME:5#
NOTICE: In the case of lost passwords or password corruption, please refer to Appendix C Pass word Recover y Proced ure, at t he end of this m anual which will guide you through the steps necessary to resolve this issue.
13
DES-1228/ME:5#config account dlink
config account
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax Description
Used to configure user accounts. config account <username> {encrypt [plain_text|sha_1] <password>} This command is used to configure a user account that has been created using the
create account command. When the password information is not specified in the command, the system will prompt the user to input the password interactively. For this case, the user can only input the plain text password.
If the password is present in the command, the user can select to input the password in the plain text form or in the encrypted form. The encryption algorithm is based on SHA-1.
Parameters
<username> – The name of the account. The account must already be defined. plain_text – Select to specify the password in plain text form. sha_1 – Select to specify the password in the SHA-1 encrypted form. password – The password for the usefr account. The length of the password in plain
text form and in encrypted form are different. For the plain text form, passwords must have a minimum of 0 character and can have a maximum of 15 characters. For the encrypted form password, the length is fixed to 35 bytes long. The password is case­sensitive.
Restrictions
Only Administrator level users can issue this command. Usernames can be between 1 and 15 characters. Passwords can be between 0 and 15 characters.
Example usage : To configure the user password of “dlink” account:
Command: config account dlink
Enter a old password:**** Enter a case-sensitive new password:***** Enter the new password again for confirmation:***** Success.
DES-1228/ME:5#
14
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show account
show account
Purpose Syntax Description
Used to display user accounts. show account This command is used to display all user accounts created on the
Switch. Up to eight user accounts can exist at one time.
Parameters Restrictions
None. Only Administrator level users can issue this command.
Example usage : To display the accounts that have been created:
Command: show account
Current Accounts: Username Access Level
------------------ -----------­admin Admin dlink Operator beta Power User guest User
Total Entries : 4
DES-1228/ME:5#
delete account
Purpose Syntax Description
Parameters Restrictions
Example usage : To delete the user account “dlink”:
DES-1228/ME:5#delete account dlink Command: delete account dlink
Success.
DES-1228/ME:5#
Used to delete an existing user account. delete account <usernam e> This command is used to delete a user account that has been
created using the create account command. <username> – The name of the account to be deleted. Only Administrator level users can issue this command.
15
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show session
show session
Purpose Syntax Description
Used to display a list of currently logged-in users. show session This command is used to display a list of all the users that are
logged-in at the time the command is issued.
Parameters Restrictions
None. None.
Example usage : To display the way that t he users lo gged in:
Command: show session
ID Live Time From Level Name
-- ------------ --------------------------------------- ----- --------------­8 0:2:27.60 Serial Port 5 dlink
Total Entries: 1
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
16
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show switch
DES-1228/ME:5#
show switch
Purpose Syntax Description Parameters Restrictions
Example usage : To display the Switch’s information:
Command: show switch
Device Type : DES-1228/ME Metro Ethernet Switch MAC Address : 00-12-28-8E-77-00 IP Address : 10.90.90.90 (Manual) VLAN Name : default Subnet Mask : 255.0.0.0 Default Gateway : 0.0.0.0 Boot PROM Version : Build 2.00.001 Firmware Version : Build 2.01.001 Hardware Version : B1 System Name : System Location : System Uptime : 0 days, 1 hours, 46 minutes, 17 seconds System Contact : Spanning Tree : Disabled GVRP : Disabled IGMP Snooping : Disabled VLAN Trunk : Disabled
802.1X : Disabled Telnet : Enabled (TCP 23) Web : Enabled (TCP 80) RMON : Disabled SSH : Disabled CLI Paging : Enabled Syslog Global State: Disabled Dual Image : Supported Password Encryption Status : Disabled
Used to display general information about the Switch. show switch This command is used to display information about the Switch. None. None.
17
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show serial_port
DES-1228/ME:5#
show serial_port
Purpose Syntax Description Parameters Restrictions
Example usage : To display the serial port setting:
Command: show serial_port
Baud Rate : 9600 Data Bits : 8 Parity Bits : None Stop Bits : 1 Auto-Logout : 10 mins
Used to display the current serial port settings. show serial_port This command is used to display the current serial port settings. None. None
18
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config serial_port baud_rate 115200
config serial_port
Purpose Syntax
Description
Parameters
Restriction s
Example usage : To configure the baud rate:
Used to configure the serial port. config serial_port { baud_rate [9600 | 19200 | 38400 | 115200] | auto_logout [never |
2_minutes | 5_minutes | 10_minutes | 15_minutes] } (1) This command is used to configure the serial port’s baud rate and auto logout
settings. baud_rate [9600 | 19200 | 38400 | 115200] The serial bit rate that will be used to
communicate with the management host. There are four options: 9600, 19200, 38400, and 115200.
never No time limit on the length of time the console can be open with no user input.
2_minutes The console will log out the current user if there is no user input for 2 minutes.
5_minutes The console will log out the current user if there is no user input for 5 minutes.
10_minutes The console will log out the current user if there is no user input for 10 minutes.
15_minutes The console will log out the current user if there is no user input for 15 minutes.
Only Administrator level and Operator level users can issue this command.
Command: config serial_port baud_rate 115200
Success.
DES-1228/ME:5#
19
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#enable clipaging
DES-1228/ME:5#disable clipaging
DES-1228/ME:5#
enable clipaging
Purpose
Used to pause the scrolling of the console screen when a command displays more than one page.
Syntax Description
enable clipaging This command is used when issuing a command which causes the
console screen to rapidly scroll through several pages. This command will cause the console to pause at the end of each page. The default setting is enabled.
Parameters Restrictions
None. Only Administrator level users, Operator level and Power User level
users can issue this command.
Example usage : To enable pausing of the s creen display when the show command output reaches the end of the pa ge:
Command: enable clipaging
Success.
DES-1228/ME:5#
disable clipaging
Purpose
Syntax Description
Parameters Restrictions
Example usage : To disable pausing of the screen display when s how command output reaches the end of the page:
Command: disable clipaging
Success.
Used to disable the pausing of the console screen scrolling at the end of each page when a command displays more than one screen of information.
disable clipaging This command is used to disable the pausing of the console screen
at the end of each page when a command would display more than one screen of information.
None. Only Administrator level users, Operator level and Power User level
users can issue this command.
20
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
ES-1228/ME:5#enable telnet
DES-1228/ME:5#
DES-1228/ME:5#disable telnet
DES-1228/ME:5#
enable telnet
Purpose
Used to enable communication with and management of the Switch using the Telnet protocol.
Syntax Description
enable telnet {<tcp_port_number 1-65535>} This command is used to enable the Telnet protocol on the Switch.
The user can specify the TCP port number the Switch will use to listen for Telnet requests.
Parameters
<tcp_port_number 1-65535> The TCP port number. TCP ports are numbered between 1 and 65535. The “well-known” TCP port for the Telnet protocol is 23.
Restrictions
Only Administrator level and Operator level users can issue this command.
Example usage : To enable Telnet and configure port number:
Command: enable telnet
Success.
disable telnet
Purpose Syntax Description Parameters Restrictions
Example usage : To disable the Telnet proto col on the Switc h:
Command: disable telnet
Success.
Used to disable the Telnet protocol on the Switch. disable telnet This command is used to disable the Telnet protocol on the Switch. None. Only Administrator level and Operator level users can issue this
command.
21
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#telnet 10.53.13.99 tcp_port 23
ping [<ipaddr> | <domain_name 255>] {times <value 1-255 > |
telnet
Purpose Syntax Description
Parameters
Restrictions
Example usage : To connect to a device through telnet with an IP address of 10.53.13.99:
Command: telnet 10.53.13.99 tcp_port 23
Used to Telnet another device on the network. telnet <ipaddr> {tcp_port <value 0-65535>} This command is used to connect to another device’s managem ent
through Telnet. <ipaddr> Enter the IP address of the device to connect through,
using Telnet. tcp_port <value 0-65535> Enter the TCP port number used to
connect through. The common TCP port number for telnet is 23. Only Administrator level, Operator level and Power User level users
can issue this command.
ping
Purpose Syntax
Used to ping a remote IP address on the network.
timeout <sec 1-99> | source_ip <ipaddr>}
Description
Parameters
Restrictions
This command is used to send Internet Control Message Protocol (ICMP) echo messages to a remote IP address. The remote IP address will then “echo” or return the message. This is used to confirm connectivity between the switch and the remote device.
<ipaddr> Specifies the IP address of the host. <domain_name 255> - Specifies the domain name of the host. This
name can be up to 255 characters long. times - (Optional) Specify the number of individual ICMP echo
messages to be sent. value 1-255 - Specify the number of individual ICMP echo
messages to be sent. A value of 0 will send an infinite ICMP echo messages. The maximum value is 255. The default is 0.
timeout – Specify the timeout period while waiting for a response from the remote device. A value of 1 to 99 seconds can be specified. The default is 1 second.
<sec 1-99> - Specify the time-out period while waiting for a response from the remote device. A value of 1 to 99 seconds can be specified. The default is 1 second.
source_ip - Specifies the source IP address of the ping packets. If specified, the IP address will be used as the packets’ source IP address that ping send to remote host.
<ipaddr> - Enter the source IP address used here. None.
22
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#ping 10.51.17.1 times 4
DES-1228/ME:5#
DES-1228/ME:5#enable web 80
DES-1228/ME:5#
To send ICMP echo message to “10.51.17.1” for 4 times:
Command: ping 10.51.17.1 times 4
Reply from 10.51.17.1, time<10ms Reply from 10.51.17.1, time<10ms Reply from 10.51.17.1, time<10ms Reply from 10.51.17.1, time<10ms
Ping Statistics for 10.51.17.1 Packets: Sent =4, Received =4, Lost =0
enable web
Purpose
Used to enable the HTTP-based management software on the Switch.
Syntax Description
enable web {<tcp_port_number 1-65535>} This command is used to enable the Web-based management
software on the Switch. The user can specify the TCP port number the Switch will use to listen for Telnet requests.
Parameters
<tcp_port_number 1-65535> The TCP port number. TCP ports are numbered between 1 and 65535. The “well-known” port for the Web­based management software is 80.
Restrictions
Only Administrator level and Operator level users can issue this command.
Example usage : To enable HTTP and configure port number:
Command: enable web 80
Success.
disable web
Purpose
Syntax Description
Parameters Restrictions
Used to disable the HTTP-based management software on the Switch.
disable web This command disables the Web-based management software on
the Switch. None. Only Administrator level and Operator level users can issue this
command.
23
DES-1228/ME:5#disable web
DES-1228/ME:5#save log
DES-1228/ME:5#
Example usage : To disable HTTP:
Command: disable web
Success.
DES-1228/ME:5#
save
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose
Used to save changes in the Switch’s configuration to non-volatile RAM.
Syntax Description
save {[config {config_id < value 1-2>} | log | all]} This command is used to enter the current switch configuration into
non-volatile RAM. The saved switch configuration will be loaded into the Switch’s memory each time the Switch is restarted.
Parameters
config – Used to save the current configuration to a file. config_id - Specifies which cfg file ID. if cfg ID is not specified, it
refers to the boot_up CFG file. log – Used to save the current log to a file. The log file cannot be
deleted. all – Save changes to currently activated configurations and save
log. If no keywords are specified, save the changes to the configuration. If there are no keywords specified, the changes will be saved to the configuration.
Restrictions
Only Administrator level,Operator level or Power User level users can issue this command.
Example usage : To save the Switch’s current configuration to non-volatile RAM:
DES-1228/ME:5#save config Command: save config
Saving all configurations to NV-RAM...... Done.
Success.
DES-1228/ME:5#
To save the Switch’s current log to non-volatile RAM:
Command: save log
Saving all log information to NV-RAM...... Done.
Success.
24
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#save all
DES-1228/ME:5#reboot
Please wait, the switch is rebooting...
DES-1228/ME:5#reboot force_agree
To save the Switch’s the current configuration and log to non-volatile RAM:
Command: save all
Saving all configurations and log information to NV-RAM...... Done.
Success.
DES-1228/ME:5#
reboot
Purpose Syntax Description Parameters
Restrictions
Example usage : To restart the Switch:
Command: reboot
Are you sure you want to proceed with the system reboot?(y/n) y
To force the Switch to restart:
Command: reboot force_agree
Please wait, the switch is rebooting...
Used to restart the Switch. reboot {force_agree} This command is used to restart the Switch. force_agree – When force_agree is specified, the Switch will be
forced to restart immediately without further confirmation. Only Administrator level users can issue this command.
25
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#reset
DES-1228/ME:5#
reset
Purpose Syntax Description
Used to reset the Switch to the factory default settings. reset {[config | system]} {force_agree} This command is used to restore the Switch’s configuration to the
default settings assigned from the factory.
Parameters
config If the keyword ‘config’ is specified, all of the factory default settings are restored on the Switch including the IP address, user accounts, and the switch history log. The Switch will not save or reboot.
system − If the keyword ‘system’ is specified all of the factory default settings are restored on the Switch. The Switch will save and reboot after the settings are changed to default. Rebooting will clear all entries in the Forwarding Data Base.
force_agree – When force_agree is specified, the reset command will be executed immediately without further confirmation.
If no parameter is specified, the Switch’s current IP address, user accounts, and the switch history log are not changed. All other parameters are restored to the factory default settings. The Switch will not save or reboot.
Restrictions
Only Administrator level users can issue this command.
Example usage : To restore all of the Switch’s parameters to their default values except the IP address, user accounts, and Switch logs:
Command: reset
Are you sure you want to proceed with system reset except IP address, log and user account?(y/n) y Success.
To restore all of the Switch’s pa r a meters to their default values:
DES-1228/ME:5#reset config Command: reset config
Are you sure you want to proceed with system reset?(y/n) y Success.
DES-1228/ME:5#
26
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#reset system
Please wait, the switch is rebooting...
DES-1228/ME:5#login
To restore all of the Switch’s parameters to their default values and have the Switch save and reboot:
Command: reset system
Are you sure you want to proceed with system reset, save and reboot?(y/n) y
Load Factory Default Configuration... Done. Saving all configurations to NV-RAM... Done.
login
Purpose Syntax Description
Parameters Restrictions
Example usage : To initiate the login procedure:
Command: login
UserName:
logout
Purpose Syntax Description
Used to log in a user to the Switch’s console. login This command is used to initiate the login procedure. The user will be
prompted for a Username and Password. None. None.
Used to log out a user from the Switch’s console. logout This command terminates the current user’s session on the Switch’s
console.
Parameters Restrictions
None. None.
Example usage : To terminate the current user’s console session:
DES-1228/ME:5#logout
27
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
exclude | begin] <filter_string 80> {<filter_string 80>
{[include | exclude | begin] <filter_string 80>
{[include | exclude | begin] <filter_string 80> {<filter_string 80>
show config
Purpose
Syntax
Description
Display the content of the current configuration, or the configuration file in flash.
show config [ current_config | config_in_nvram <config_id 1-2> ] {[include | {<filter_string 80>}} {<filter_string 80> {<filter_string 80>}}
{<filter_string 80>}}}}} This command is used to display the content of the current
configuration, or the configuration file in flash. The output stream of the configuration data can be filtered by the
expression specified at the end of the command. The expression can contain up to three multiple filter evaluations. A filter evaluation begins with a filter type (include, exclude, and begin), followed by up to three filter strings (ex: “stp”). A filter string is enclosed by symbol ".
The following describes the meaning of the each filter type. include: includes lines that contain the specified filter string. exclude: excludes lines that contain the specified filter string begin: The first lin e that contai ns the spec ified filter st ring will be the
first line of the output. The relationship of m ultiple f ilter str ings f ollo wing t he s am e filter t ype
is OR. That is, one line is qua lified if one of specified f ilter strings is matched.
If more than one filter eva luation is spec ified; the output is filtered by the former evaluation and will be used as the input of the latter evaluation.
For example, if the following expression is specified, Include “stp” exclude “port”
The result of the above example is all lines that include the “stp” string but exclude the “port” string.
Parameters
Restrictions
current_config – Display system configuration from the DRAM database, i.e. the current system setting.
config_in_nvram – Display the system configuration from NV-RAM i.e. the configuration filein flash.
config_id - Specifies whic h c f g file ID. if cfg ID is not specified, it refers to the boot_up CFG file.
include – includes lines that contain the specified filter string. exclude – excludes lines that contain the specified filter string. begin – the first line that contains the specified filter string wi ll be the
first line of the output. filter_string - A filter string is enclosed by symbol ". Thus, the filter
string itself cannot contain the “character. The filter string is case sensitive.
Only Administrator level users can issue this command.
28
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show config current_config include "stp"
DES-1228/ME:5#config terminal_line 30
DES-1228/ME:5#
Example usage : To display the current spanning tree configurations:
Command: show config current_config include "stp" disable stp config stp version rstp config stp maxage 20 maxhops 20 forwarddelay 15 txholdcount 6 fbpdu
enable hello time 2 config stp priority 32768 instance_id 0 config stp mst_config_id name 00:71:39:00:00:01 revision_level 0 config stp ports 1-26 externalCost auto edge auto p2p auto state
enable config stp mst_ports 1-26 instance_id 0 internalCost auto priority
128 config stp ports 1-26 fbpdu enable config stp ports 1-26 restricted_role false config stp ports 1-26 restricted_tcn false
DES-1228/ME:5#
Note: If the downlo aded conf iguratio n file has been m odified and sav ed, the “ From ” item wi ll display “local save.”
config terminal_line
Purpose
Syntax Description
Parameters Restrictions
Example usage : To configure the termi na l line to display 30 rows:
Used to configure the number of rows which can be displayed on a screen.
config terminal_line [ defaul t | <value 20-80>] This command is used to configure the number of rows which can be
displayed on a screen. The default value is 24. None. Only Administrator level, Operator level or Power User level users
can issue this command.
Command: config terminal_line 30
Success.
29
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show terminal_line
DES-1228/ME:5#
DES-1228/ME:5#enable jumbo_frame
DES-1228/ME:5#
show terminal_line
Purpose
Syntax Description
Parameters Restrictions
Example usage : To show the current number of rows that can be displayed:
Command: show terminal_line
Terminal Line : 30
Used to show the number of rows which can be displayed on the screen.
show terminal_line This command is used to show the number of rows which can be
displayed on the screen. None. None.
enable jumbo_frame
Purpose Syntax Description
Parameters Restrictions
Example usage : To enable jumbo frame:
Command: enable jumbo_frame
Success.
disable jumbo_frame
Purpose Syntax
Used to enable jumbo frame. enable jumbo_frame This command is used to configure the jumbo frame setting as
enable. None. Only Administrator level, Operator level or Power User level users
can issue this command.
Used to disable jumbo frame. disable jumbo_frame
Description
Parameters Restrictions
This command is used to configure the jumbo frame setting as disable.
None. Only Administrator level, Operator level or Power User level users
can issue this command.
30
DES-1228/ME:5#disable jumbo_frame
Example usage: To disable jumbo frame:
Command: disable jumbo_frame
Success.
DES-1228/ME:5#
show jumbo_frame
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax Description
Parameters Restrictions
Example usage : To display jumbo frame:
DES-1228/ME:5#show jumbo_frame Command: show jumbo_frame
Jumbo Frame State : Disabled Maximum Jumbo Frame Size : 2048 Bytes
DES-1228/ME:5#
clear
Purpose
Used to display the current configuration of jumbo frame. show jumbo_frame This command is used to display the current configuration of the
jumbo frame setting. None. None.
This command is used to clear the terminal screen.
Syntax Description Parameters Restrictions
Example usage : To clear the terminal screen:
DES-1228/ME:5#clear Command: clear
clear This command is used to clear the terminal screen. None. None.
31
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config configuration config_id 1 boot_up
config configuration config_id
Purpose
This command is used to select a configuration file as the next boot up configuration or to apply a specific configuration to the system. This command is required when multiple configuration files are supported.
Syntax Description
config configuration config_id <int 1-n> {del ete | boot _u p | active} Used to select a configuration file as the next boot up configuration
or to apply a specific configuration to the system. This command is required when multiple configuration files are supported.
Parameters
delete – Specifies to delete the configuration file. boot_up – Specifies the configuration file as a boot up file. active – Specifies to apply the configuration.
Restrictions
Only Administrator level users can issue this command.
Example usage : To set configuration file 1 to be a boot up file:
Command: config configuration config_id 1 boot_up
Success.
DES-1228/ME:5#
32
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config configuration trap save enable
DES-1228/ME:5#
Only Administrator level users can issue this command.
DES-1228/ME:5#show config information
config configuration tr a p
Purpose
Used to configure the trap status of configuration saving completed, configuration uploading completed and configuration downloading completed.
Syntax
config configuration trap { save [ enable | disable ] | upload [ enable | disable ] | download [ enable | disable ] }(1)
Description
When set to enabled, the SNMP Agent will send a trap while the related operation (save / upload / download the configuration) is successfully completed.
Parameters
save – Enable: the SNMP agent will send trap while successfully save the configuration to NVRAM
Disable: No trap will be sent. upload – Enable: the SNMP agent will send trap while successfully
complete upload configuration. Disable: No trap will be sent. download – Enable: the SN MP agent will send trap while
successfully complete download the configuration. Disable: No trap will be sent.
Restrictions
Only Administrator level users can issue this command.
Example usage : To enable the trap of a configuration saving completed:
Command: config configuration trap save enable Success.
show config information
Purpose Syntax Description Parameters Restrictions
Example usage : To display the contents of the config file
Command: show config information
Save Configuration Trap : Enabled Upload Configuration Trap : Enabled Download Configuration Trap : Enabled
ID Version Size(B) Update Time From User
-- -------- ------- ------------------- --------------------
------------­*1 2.00.007 14330 0000/00/00 19:51:51 0.0.0.0(CONSOLE) Anonymous 2 2.00.007 14330 0000/00/00 19:51:51 0.0.0.0(CONSOLE) Anonymous
DES-1228/ME:5#
Used to display the content of the configuration file information. show config information Used to display the content of the configuration file information. None.
33
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
5

MODIFY BAN NE R AND PROMPT COMMANDS

The Modify Banner and Prompt commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
config command_ prompt [<string 32> | username | default] config greeting_message {default} show greeting_message
Administrator level users can modify the login banner (greeting message) and command prompt by u sing the co mmands described below:
config command prompt
Purpose Syntax Description
Parameters
Restrictions
Example usage To modify the command prompt to “AtYourService”:
DES-1228/ME:5#config command_prompt AtYourService Command: config command_prompt AtYourService
Success.
AtYourService:5#
Used to configure the command prompt. config command_prompt [<string 32> | username | default] Administrator level users can use this command to change the
command prompt. string 32 The command prompt can be changed by entering a
new name of no more that 32 characters. username The command prompt will be changed to the login
username. default – The command prompt will reset to factory default
command prompt. Default = the name of the Switch model, for example “DES-1288/ME”.
Only Administrator level users can issue this command. Other restrictions include:
If the “reset” command is executed, the modified command prompt will remain modified. However, the “reset config/reset system” command will reset the command prompt to the original factory banner.
34
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
-------------------------------------------------------------------------------
config greeting _messa ge
Purpose Syntax Description Parameters
Restrictions
Used to configure the login banner (greeting message). config greeting _message {default} Users can use this command to modify the login banner (greeting message). default – If the user enters default to the modify banner command, then the banner will be
reset to the original factory banner. To open the Banner Editor, click Enter after typing the config greeting_message command.
Type the information to be displayed on the banner by using the commands described on the Banner Editor:
Quit without save: Ctrl+C Save and quit: Ctrl+W Move cursor: Left/Right/Up/Down Delete line: Ctrl+D Erase all setting: Ctrl+X Reload original setting: Ctrl+L
Only Administrator level users can issue this command. Other restrictions include: If the “reset” command is executed, the modified banner will remain modified. However, the
“reset config/reset system” command will reset the modified banner to the original factory banner.
The capacity of the banner is 24*80. 24 Lines and 80 characters per line. Ctrl+W will only save the modified banner in the DRAM. Users need to type the “save
config/save all” command to save it into Flash. Only valid in threshold level.
Example usage : To modify the banner:
DES-1228/ME:5#config greeting_message Command: config greeting_message
Greeting Messages Editor ================================================================================
DES-1228/ME Metro Ethernet Switch Command Line Interface
Firmware: Build 2.01.001 Copyright(C) 2012 D-Link Corporation. All rights reserved.
================================================================================
<Function Key> <Control Key> Ctrl+C Quit without save left/right/ Ctrl+W Save and quit up/down Move cursor Ctrl+D Delete line Ctrl+X Erase all setting Ctrl+L Reload original setting
35
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show greeting_message
show greeting_message
Purpose
Used to view the currently configured greeting message configured on the Switch.
Syntax Description
show greeting_message This command is used to view the currently configured greeting
message on the Switch.
Parameters Restrictions
None. None.
Example usage: To view the currently configured greeting me ss age:
Command: show greeting_message
================================================================================
DES-1228/ME Metro Ethernet Switch Command Line Interface
Firmware: Build 2.01.001 Copyright(C) 2012 D-Link Corporation. All rights reserved.
================================================================================
36
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
6

SWITCH PORT COMMANDS

The Switch Port commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
config ports [<portlist> | all] {medium_type [fiber | copper]} {speed [auto | 10_half | 10_full | 100_half
| 100_full | 1000_full {[master | slave]}] | flow_control [enable | disable] | state [enable | disable] | learning [enable | disable] | [descr ipt ion <des c 32> | clear_des c ripti on] | mdix [auto | normal | cross]} (1)
show ports {<portlist>} { [description | err_disabled] }
Each command is listed, in detail, in the following sections:
37
DES-1228/ME:5#config ports 20-24 speed 10_full state enable
DES-1228/ME:5#
config ports
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax
Description
Parameters
Used to configure the Switch’s Ethernet port settings. [<portlist> | all] {medium_type [fiber | copper]} {spe ed [auto | 10_ half | 10_f ull | 100_ha lf |
100_full | 1000_full {[master | slave]}] | flow_control [enable | disable] | state [enable | disable] | learning [enable | disable] | [description <desc 32> | clear_description] | mdix [auto | normal | cross]} (1)
This command is used to configure the Switch’s Ethernet ports. Only the ports listed in the <portlist> will be affected.
all − Configure all ports on the Switch. <portlist> − Specifies a port or range of ports to be configured. medium_type [fiber | copper ] – If configuring the Combo ports, this defines the type of medium
being configured. speed – Allows the user to adjust the speed for a port or range of ports. The user has a choice
of the following:
auto Enables auto-negotiation for the specified range of ports. [10 | 100 | 1000] Configures the speed in Mbps for the specified range of ports. Gigabit
ports are statically set to 1000 but can be set to slower speeds. [half | full] − Configures the specified range of ports as either full-duplex or half-duplex. [master | slave] − The master setting (1000M/Full_M) will allow the port to advertise
capabilities related to duplex, speed and physical layer type. The master setting will
also determine the master and slave relationship between the two connected physical
layers. This relationship is necessary for establishing the timing control between the
two physical layers. The timing control is set on a master physical layer by a local
source. The slave setting (1000M/Full_S) uses loop timing, where the timing comes
from a data stream received from the master. If one connection is set for
1000M/Full_M, the other side of the connection must be set for 1000M/Full_S. Any
other configuration will result in a link down status for both ports.
flow_control [enable | disable] – Enable or disable flow control for the specified ports. state [enable | disable] Enables or disables the specified range of ports. learning [enable | disable] Enables or disables the MAC address learning on the specified
range of ports. description <desc 32> Enter an alphanumeric string of no more than 32 characters to
describe a selected port interf ace. clear_description Enter this command to clear the port description of the selected port(s). mdix – Specifies the MDIX setting of the port. The MDIX setting can be auto, normal or cross. If set to normal state, the port in MDIX mode, can be connected to PC NIC using a straight
cable. If set to cross state, the port in mdi mode, can be connected to a port (in mdix mode) on another switch through a straight cable.
Restrictions
Only Administrator level or Operator le vel users can issue this command.
Example usage : To configure the speed of ports 20 to 24 to be 10 Mbps, full duplex, with state enabled:
Command: config ports 20-24 speed 10_full state enable
Success.
38
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show ports
CTRL+C ESC q Quit SPACE n Next Page ENTER Next Entry a All
show ports
Purpose Syntax Description
Parameters
Restrictions
Example usage : To display the configuration of all po rts on a standalone switch:
Command: show ports
Port State/ Settings Connection Address MDI Speed/Duplex/FlowCtrl Speed/Duplex/FlowCtrl Learning
----- -------- --------------------- --------------------- -------­ 1 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 2 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 3 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 4 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 5 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 6 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled 7 Enabled Auto/Disabled LinkDown Enabled Auto Auto/Disabled LinkDown Enabled
Used to display the current configuration of a range of ports. show ports {<portlist >} {[de s cr iption | err_dis a bl ed]} This command is used to display the current configurations of a range of ports. No
parameters will show all ports. <portlist> − Specifies a port or range of ports to be displayed.
description – Adding this parameter to the show ports command indicates that a previously entered port description will be included in the display.
err_disabled – Use this to list disabled ports including connection status and reason for being disabled.
None.
39
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show ports description
Example usage : To display the configuration of all po rts on a standalone switch, with description:
Command: show ports description
Port State/ Settings Connection Address MDI Speed/Duplex/FlowCtrl Speed/Duplex/FlowCtrl Learning
----- -------- --------------------- --------------------- -------­ 1 Enabled Auto/Disabled LinkDown Enabled Auto Desc: 2 Enabled Auto/Disabled LinkDown Enabled Auto Desc: 3 Enabled Auto/Disabled LinkDown Enabled Auto Desc: 4 Enabled Auto/Disabled LinkDown Enabled Auto Desc: 5 Enabled Auto/Disabled LinkDown Enabled Auto Desc: 6 Enabled Auto/Disabled LinkDown Enabled Auto Desc:
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
40
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
7

PORT SECURITY COMMANDS

The Port Security commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
config port_security ports [<auth_portlist> | all] {admin_state [enable | disable] |
max_learning_addr <max_lock_no 0-64> | lock _address_mode [DeleteOnTimeout | DeleteOnReset | Permanent]} (1)
delete port_security_en tr y vlan_name <vlan_name 32> mac_address <macaddr> port
<auth_port> clear port_security_entry port <auth_portlist> show port_security {ports <auth_portlist>} enable port_security trap_log disable port_security trap_ log
Each command is listed, in detail, in the following sections:
41
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
5 admin_state enable
5 admin_state enable
config port_security ports
Purpose Syntax
Used to configure port security settings. config port_security ports [<auth_portlist> | all ] {admin_state [enable | disab le] |
max_learning_addr <max_lock_no 0-64> | lock _address_mode [ DeleteOnTimeout | DeleteOnReset | Permanent]} (1)
Description
This command is used to configure the port security feature. Only the ports listed in the <auth_portlist> are affected.
Parameters
<auth_portlist> Specifies a port or range of ports to be configured. all − Configure port security for all ports on the Switch. admin_state [enable | disable] Enable or disable port security for the listed ports. max_learning_addr <max_lock_no 0-64> Use this to limit the number of MAC addresses
dynamically listed in the FDB for the ports. lock_address_m ode [Delet eO nT im out | DeleteO nR es et | Perm anent] Indicates the method
of locking addresses. The user has three choices: DeleteOnTimeout – The locked addresses will age out after the aging timer expires (Aging
Time is set using the FDB command). DeleteOnReset – The locked addresses will not age out until the Switch has been reset. Permanent – The lock ed address es will not age out.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To configure the port security:
DES-1228/ME:5#config port_security ports 1­max_learning_addr 5 lock_address_mode DeleteOnReset
Command: config port_security ports 1­max_learning_addr 5 lock_address_mode DeleteOnReset
Success.
DES-1228/ME:5#
42
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
delete port_security_entry
Purpose
Syntax
Description
Parameters
Restrictions
Example usage : To delete a port security entry:
DES-1228/ME:4#delete port_security_entry vlan_name default mac_address 00-01-30-10-2C-C7 port 3
Command: delete port_security_entry vlan_name default mac_address 00-01­30-10-2C-C7 port 3
Success.
DES-1228/ME:4#
Used to delete a port security entry by MAC address, port number and VLAN ID.
delete port_security_entry vlan_name <vlan_name 32> mac_address <macaddr> port <auth_port>
This command is used to delete a single, previously learned port security entry by port, VLAN name, and MAC address.
vlan name <vlan_name 32> Enter the corresponding VLAN name of the port to delete.
mac_address <macaddr> Enter the corresponding MAC address, previously learned by the port, to delete.
port <auth_port> Enter the port number which has learned the previously entered MAC address.
Only Administrator level, Operator level or Power User level users can issue this command.
43
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
clear port_security_entry
Purpose
Used to clear MAC address entries learned from a specified port for the port security function.
Syntax Description
clear port_security_entry ports <auth_portlist> This command is used to clear MAC address entries which were
learned by the Switch by a specified port. This command only relates to the port security function.
Parameters Restrictions
<auth_portlist> Specifies a port or port range to clear. Only Administrator level, Operator level or Power User level users
can issue this command.
Example usage : To clear a port security entry by port:
DES-1228/ME:5#clear port_security_entry port 3 Command: clear port_security_entry port 3
Success.
DES-1228/ME:5#
44
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#
show port_security
Purpose Syntax Description
Used to display the current port security configuration. show port_security {ports <auth_portlist>} This command is used to display port security information of the
Switch’s ports. The information displayed includes port security, admin state, maximum number of learning address and lock mode.
Parameters Restrictions
<auth_portlist> Specifies a port or range of ports to be viewed. None.
Example usage : To display the port security configura tion:
DES-1228/ME:5#show port_security ports 1-5 Command: show port_security ports 1-5
Port_security Trap/Log : Disabled
Port Admin State Max. Learning Addr. Lock Address Mode
---- ----------- ------------------ ----------------­1 Enabled 5 DeleteOnReset 2 Enabled 5 DeleteOnReset 3 Enabled 5 DeleteOnReset 4 Enabled 5 DeleteOnReset 5 Enabled 5 DeleteOnReset
45
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#enable port_security trap_log
DES-1228/ME:5#
DES-1228/ME:5#disable port_security trap_log
enable port_security trap_log
Purpose Syntax Description
Used to enable the trap log for port security. enable port_security trap_log This command, along with the disable port_security trap_log, will
enable the sending of log messages to the Switch’s log and SNMP agent when the port security of the Switch has been triggered.
Parameters Restrictions
None. Only Administrator level, Operator level or Power User level users
can issue this command.
Example usage : To enable the port security trap log setting:
Command: enable port_security trap_log
Success.
disable port_security trap_log
Purpose
Used to disable the trap log for port security.
Syntax Description
disable port_security trap_ log This command, along with the enable port_security trap_log, will
disable the sending of log messages to the Switch’s log and SNMP agent when the port security of the Switch has been triggered.
Parameters Restrictions
None. Only Administrator level, Operator level or Power User level users
can issue this command.
Example usage : To disable the port security trap log setting:
Command: disable port_security trap_log
Success.
DES-1228/ME:5#
46
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
8

NETWORK MANAGEMENT (SNMP) COMMANDS

The Switch supports the Simple Network Management Protocol (SNMP) versions 1, 2c, and 3. Users can specify which version of the SNMP use rs want to use t o monit or a nd c o n tr ol the S wi t ch. T he thr ee ve r sio n s o f S N M P vary in the level o f se c ur it y p r ovi d ed between the management station and the network device. The following table lists the security features of the three SNMP versions:
SNMP Version
v1 Community String v2c Community String v3 Username v3 MD5 or SHA
v3 MD5 DES or SHA DES
The Network Management commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Authentication Method Description
Community String is used for authe ntication − NoAuthNoPriv Community String is used for authe ntication − NoAuthNoPriv Username is used for authentication − NoAuthNoPriv Authentication is based on the HMAC-MD5 or HMAC-SHA algorithms
AuthNoPriv Authentication is based on the HMAC-MD5 or HMAC-SHA algorithms AuthPriv.
DES 56-bit encryption is added based on the CBC-DES (DES-56) standard
47
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Command Parameters
create snmp user <SNMP_name 32> <groupname 32> {encrypted [by_password auth [md5
<auth_password 8-16 > | sha <auth_p as s word 8-2 0> ] pr iv [none | des <priv_password 8-16>] | by_key auth [md5 <auth_key 32-32 > | sha <auth _k ey
40-40>] priv [none | des <priv_key 32-32>]]} delete snmp user <SNMP_name 32> show snmp user create snmp view <view_name 32> <oid> view_type [included | excluded] delete snmp view <view_name 32> [all | oid] show snmp view {<view_name 32>} create snmp community <community_string 32> view <view_name 32> [read_only | read_write] delete snmp community <community_string 32> show snmp community {<community_string 32>} config snmp engineID <snmp_engineID 10-64> show snmp engineID create snmp group <groupname 32> [v1 | v2c | v3 [noauth_nopriv | auth_nopriv | auth_priv]]
{read_view <view_nam e 32> | write_ view < vie w_name 32> | notify_view
<view_name 32>} (1) delete snmp group <groupname 32> show snmp groups create snmp [host <ipaddr> [v1 | v2c | v3 [noauth_nopri v | auth_nopriv | auth_priv]]
<auth_string 32> delete snmp [host <ip addr >] show snmp host {<ipaddr>} create trusted_host [<ipaddr> | network<network_address>] delete trusted_host [ipaddr < ipaddr> | network<network_addres s > | all] show trusted_host enable snmp traps enable snmp authenticate_traps enable snmp linkchange_traps disable snmp traps disable snmp authenticate_traps disable snmp linkchange_traps config snmp linkchange_traps
ports show snmp traps {linkchange_traps { ports <portlist>} } config snmp system_contact {<sw_contact>} config snmp system_location {<sw_location>} config snmp system_name {<sw_name>} enable rmon
[all | <portlist>] [enable | disable]
48
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
<priv_key 32-32> − Enter an alphanumeric key string of exactly 32 characters, in hex
Command Parameters
disable rmon config snmp coldstart_traps [enable | disable] config snmp warmstart_traps [enable | disable]
Each command is listed, in detail, in the following sections:
create snmp user
Purpose
Syntax
Description
Parameters
Used to create a new SNMP user and adds the user to an SNMP group that is also created by this command.
create snmp user <SNMP_name 32> <groupname 32> {encrypted [by_password auth [md5 <auth_password 8-16> | sha <auth_password 8-20>] priv [none | des <priv_password 8-16>] | by_key auth [md5 <auth_key 32-32 > | sha <auth _k ey 40-40>] priv [none | des <priv_key 32-32>]]}
This command is used to create a new SNMP user and adds the user to an SNMP group that is also created by this command. SNMP ensures:
Message integrity Ensures that packets have not been tampered with during transit. Authentication Determines if an SNMP message is from a valid source. Encryption Scrambles the contents of messages to prevent it from being viewed by an
unauthorized source. <SNMP_name 32> An alphanumeric name of up to 32 characters that will identify the
new SNMP user. <groupname 32> An alphanumeric name of up to 32 characters that will identify the
SNMP group the new SNMP user will be associated with. encrypted – Allows the user to choose a type of authorization for authentication using
SNMP. The user may choose:
by_password – Requires the SNMP user to enter a password for authentication and
privacy. The password is defined by specifying the auth_password below. This method is recommended.
by_key – Requires the SNMP user to enter an encryption key for authentication and
privacy. The key is defined by specifying the key in hex form. This method is not recommended.
auth The user may also choose the type of authentication algorithms used to authenticate the snmp user. The choices are:
md5 Specifies that the HMAC-MD5-96 authentication level will be used. md5 may be
utilized by entering one of the following:
<auth password 8-16> An alphanumeric string of between 8 and 16 characters that will be used to authorize the agent to receive packets for the host.
<auth_key 32-32> Enter an alphanumeric string of exactly 32 characters, in hex form, to define the key that will be used to authorize the agent to receive packets for the host.
sha Specifies that the HMAC-SHA-96 authentication level will be used.
<auth password 8-20> An alphanumeric string of between 8 and 20 characters that will be used to authorize the agent to receive packets for the host.
<auth_key 40-40> Enter an alphanumeric string of exactly 40 characters, in hex form, to define the key that will be used to authorize the agent to receive packets for the host.
priv – Adding the priv (privacy) parameter will allow for encryption in addition to the authentication algorithm for higher security. The user may choose:
des – Adding this parameter will allow for a 56-bit encryption to be added using the
DES-56 standard using:
<priv_password 8-16> An alphanumeric string of between 8 and 16 characters that will be used to encrypt the contents of messages the host sends to the agent.
49
form, that will be used to encrypt the contents of messages the host sends to the agent.
DES-1228/ME:5#create snmp user dlinkuser dlink encrypted by_password auth
Command: create snmp user dlinkuser dlink encrypted by_password auth md5
DES-1228/ME:5#
DES-1228/ME:5#delete snmp user dlinkuser
create snmp user
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
none – Adding this parameter will add no encryption.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To create an SNMP user on the Switch:
md5 knickerbockers priv none
knickerbockers priv none
Success.
delete snmp user
Purpose
Used to remove an SNMP user from an SNMP group and also to delete the associated SNMP group.
Syntax Description
delete snmp user <SNMP_name 32> This command is used to remove an SNMP user from its SNMP
group and then delete the associated SNMP group.
Parameters
<SNMP_name 32> An alphanumeric string of up to 32 characters that identifies the SNMP user that will be delete d.
Restrictions
Only Administrator level users can issue this command.
Example usage : To delete a previously entered SNMP user on the Switch:
Command: delete snmp user dlinkuser
Success.
DES-1228/ME:5#
50
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp user
show snmp user
Purpose
Used to display information about each SNMP username in the SNMP group username table.
Syntax Description
show snmp user This command is used to display information about each SNMP
username in the SNMP group username table.
Parameters Restrictions
None. None.
Example usage : To display the SNMP users currently configured on the Switch:
Command: show snmp user
Username Group Name SNMP Version Auth-Protocol PrivProtocol
--------------- --------------- ------------ ------------- -----------­initial initial V3 None None dlinkuser dlink V3 MD5 None
Total Entries : 2
DES-1228/ME:5#
51
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#create snmp view dlinkview 1.3.6 view_type included
create snmp view
Purpose
Syntax
Description
Parameters
Restrictions
Example usage : To create an SNMP view:
Command: create snmp view dlinkview 1.3.6 view_type included
Success.
DES-1228/ME:5#
Used to assign views to community strings to limit which MIB objects and SNMP manager can access.
create snmp view <view_name 32> <oid> view_type [included | excluded]
This command is used to assign views to community strings to limit which MIB objects an SNMP manager can access.
<view_name 32> An alphanumeric string of up to 32 characters that identifies the SNMP view that will be created.
<oid> − The object ID that identifies an object tree (MIB tree) that will be included or excluded from access by an SNMP manager.
view typ e – Sets the view type to be: included Include this object in the list of objects that an SNMP
manager can access. excluded Exclude this object from the list of objects that an SNMP
manager can access. Only Administrator level, Operator level or Power User level users
can issue this command.
52
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#delete snmp view dlinkview all
DES-1228/ME:5#
delete snmp view
Purpose
Syntax Description
Parameters
Restrictions
Example usage : To delete a previously configured SNMP view from the Switch:
Command: delete snmp view dlinkview all
Success.
Used to remove an SNMP view entry previously created on the Switch.
delete snmp view <view_name 32> [all | <oid>] This command is used to remove an SNMP view previously created
on the Switch. <view_name 32> An alphanumeric string of up to 32 characters
that identifies the SN M P vie w to be deleted. all − Specifies that all of the SNMP views on the Switch will be
deleted. <oid> − The object ID that identifies an object tree (MIB tree) that
will be deleted from the Switch. Only Administrator level, Operator level or Power User level users
can issue this command.
show snmp view
Purpose Syntax Description
Parameters
Restrictions
Used to display an SNMP view previously created on the Switch. show snmp view {<view_name 32>} This command is used to display an SNMP view previously created
on the Switch. <view_name 32> An alphanumeric string of up to 32 characters
that identifies the SNMP view that will be displayed. None.
53
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp view
DES-1228/ME:5#
Example usage : To display SNMP view configuration:
Command: show snmp view
Vacm View Table Settings View Name Subtree View Type
-------------------- ------------------------- ---------­dlinkview 1.3.6 Included restricted 1.3.6.1.2.1.1 Included restricted 1.3.6.1.2.1.11 Included restricted 1.3.6.1.6.3.10.2.1 Included restricted 1.3.6.1.6.3.11.2.1 Included restricted 1.3.6.1.6.3.15.1.1 Included CommunityView 1 Included CommunityView 1.3.6.1.6.3 Excluded CommunityView 1.3.6.1.6.3.1 Included Total Entries : 9
create snmp communit y
Purpose
Syntax
Description
Parameters
Used to create an SNMP community string to define the relationship between the SNMP manager and an agent. The community string acts like a password to permit access to the agent on the Switch. One or more of the following characteristics can be associated with the community string:
An MIB view that defines the subset of all MIB objects that will be accessible to the SNMP community.
read_write or read_only level permission for the MIB objects accessible to the SNMP community.
create snmp community <community_string 32> view <view_name 32> [read_only | read_write]
This command is used to create an SNMP community string and to assign access-limiting characteristics to this community string.
<community_string 32> An alphanumeric string of up to 32 characters that is used to identify members of an SNMP community. This string is used like a password to give remote SNMP managers access to MIB objects in the Switch’s SNMP agent.
view <view_name 32> An alphanumeric string of up to 32 characters that is used to identify the group of MIB objects that a remote SNMP manager is allowed to access on the Switch.
read_only Specifies that SNMP community members using the community string created with this command can only read the contents of the MIBs on the Switch.
read_write Specifies that SNMP community members using the community string created with this command can read from and write to the contents of the MIBs on the Switch.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
54
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#create snmp community dlinkcomm view dlinkview read_write DES-1228/ME:5#delete snmp community dlinkcomm
DES-1228/ME:5#
Example usage : To create the SNMP community string “dlinkcomm”:
Command: create snmp community dlinkcomm view dlinkview read_write
Success.
DES-1228/ME:5#
delete snmp community
Purpose Syntax Description
Used to remove a specific SNMP community string from the Switch. delete snmp community <community_string 32> This command is used to remove a previously defined SNMP
community string from the Switch.
Parameters
<community_string 32> An alphanumeric string of up to 32 characters that is used to identify members of an SNMP community. This string is used like a password to give remote SNMP managers access to MIB objects in the Switch’s SNMP agent.
Restrictions
Only Administrator level users can issue this command.
Example usage : To delete the SNMP community string “dlinkcomm”:
Command: delete snmp community dlinkcomm
Success.
show snmp community
Purpose Syntax Description
Used to display SNMP community strings configured on the Switch. show snmp community {<community_string 32>} This command is used to display SNMP community strings that are
configured on the Switch.
Parameters
<community_string 32> An alphanumeric string of up to 32 characters that is used to identify members of an SNMP community. This string is used like a password to give remote SNMP managers access to MIB objects in the Switch’s SNMP agent.
Restrictions
None.
55
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp community
DES-1228/ME:5#
DES-1228/ME:5#
Example usage : To display the currently entered SNMP community strings:
Command: show snmp community
SNMP Community Table
Community Name View Name Access Right
--------------------- --------------------- -----------­dlinkcomm dlinkview read_write private CommunityView read_write public CommunityView read_only
Total Entries: 3
config snmp engineID
Purpose Syntax Description
Used to configure an identifier for the SNMP engine on the Switch. config snmp engineID <snmp_engineID 10-64> This command is used to configure an identifier for the SNMP
engine on the Switch.
Parameters
<snmp_engineID 10-64> An alphanumeric string that will be used to identify the SNMP engine on the Switch.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To give the SNMP agent o n the Switch the name “0035636666”:
DES-1228/ME:5#config snmp engineID 0035636666 Command: config snmp engineID 0035636666
Success.
56
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp engineID
DES-1228/ME:5#
show snmp engineID
Purpose Syntax Description
Used to display the identification of the SNMP engine on the Switch. show snmp engineID This command is used to display the identification of the SNMP
engine on the Switch.
Parameters Restrictions
None. None.
Example usage : To display the current name of the SNMP engine on the Switch:
Command: show snmp engineID
SNMP Engine ID : 0035636666
57
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Scrambles the contents of messages to prevent it being viewed by an
create snmp group
Purpose
Syntax
Description
Parameters
Used to create a new SNMP group, or a table that maps SNMP users to SNMP views.
create snmp group <groupname 32> [v1 | v2c | v3 [noauth_nopriv | auth_nopriv | auth_priv]] {read_vi e w <view_name 32> | write_view <view_nam e 32> | notify_view <view_name 32>} (1)
This command is used to create a new SNMP group, or a table that maps SNMP users to SNMP views.
<groupname 32> An alphanumeric name of up to 32 character s that wi ll ident ify the SNMP group the new SNMP user will be associate d with.
v1 – Specifies that SNMP version 1 will be used. The Simple Network Management Protocol (SNMP), version 1, is a network management protocol that provides a means to monitor and control network devices.
v2c – Specifies that SNMP version 2c will be used. The SNMP v2c supports both centralized and distributed net work management strategies . It includes improvements in the Structure of Management Information (SMI) and adds some security features.
v3 – Specifies that the SNMP vers io n 3 will be used. SNM P v3 prov ides sec ure access to devices through a combination of authentication and encrypting packets over the network. SNMP v3 adds:
Message integrity − Ensures that packets have no t been tampered with during transit. Authentication − Determines if an SNMP message is from a valid source. Encryption
unauthorized source.
noauth_nopriv Specifies that there will be no authorization and no encryption of packets sent between the Switch and a remote SNMP manager.
auth_nopriv Specifies that authorization will be required, but there will be no encryption of packets sent between the Switch and a remote SNMP manager.
auth_priv Specifies that authorization will be required, and that packets sent between the Switch and a remote SNMP manger will be encrypted.
read_view – Specifies that the SNMP group being created can request SNMP messages.
write_view – Specifies that the SNMP group being cre ated has write pr ivil eges . notify_view − Specifies that the SNMP group being created can receive SNMP
trap messages generated by the Switch’s SNMP agent. <view_name 32> An alphanumeric string of up to 32 characters that is used to
identify the group of MIB objects that a remote SNMP manager is allowed to access on the Switch.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
58
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#create snmp group dlink v3 noauth_nopriv read_view dlinkview
Command: create snmp group dlink v3 noauth_nopriv read_view dlinkview
DES-1228/ME:5#
Example usage : To create an SNMP group named “sg1:”
write_view dlinkview notify_view dlinkview
write_view dlinkview notify_view dlinkview
Success.
delete snmp group
Purpose Syntax Description Parameters
Used to remove an SNMP group from the Switch. delete snmp group <groupname 32> This command is used to remove an SNMP group from the Switch. <groupname 32> An alphanumeric name of up to 32 characters that
will identify the SNMP group the new SNMP user will be associated with.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To delete the SNMP group named “dlink”.
DES-1228/ME:5#delete snmp group dlink Command: delete snmp group dlink
Success.
DES-1228/ME:5#
show snmp groups
Purpose
Used to display the group names of SNMP groups currently configured on the Switch. The security model, level, and status of each group are also displayed.
Syntax Description
show snmp groups This command is used to display the group names of SNMP groups
currently configured on the Switch. The security model, level, and status of each group are also displayed.
Parameters Restrictions
None. None.
59
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp groups
Example usage : To display the currently configured SNMP groups on the Switch:
Command: show snmp groups
Vacm Access Table Settings
Group Name : dlink ReadView Name : dlinkview WriteView Name : dlinkview Notify View Name : dlinkview Securiy Model : SNMPv3 Securiy Level : NoAuthNoPriv
Group Name : public ReadView Name : CommunityView WriteView Name : Notify View Name : CommunityView Securiy Model : SNMPv1 Securiy Level : NoAuthNoPriv
Group Name : public ReadView Name : CommunityView WriteView Name : Notify View Name : CommunityView Securiy Model : SNMPv2 Securiy Level : NoAuthNoPriv
CTRL+C ESC q Quit SPACE n Next Page ENTER Next Entry a All
60
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#create snmp host 10.48.74.100 v3 auth_priv public
DES-1228/ME:5#
create snmp host
Purpose
Syntax
Description
Parameters
Used to create a recipient of SNMP traps generated by the Switch’s SNMP agent.
create snmp [host <ipaddr>] [v1 | v2c | v3 [noauth_nopriv | auth_nopriv | auth_priv] <auth_string 32>
This command is used to create a recipient of SNMP traps generated by the Switch’s SNMP agent.
<ipaddr> – The IP address of the remote management station that will serve as the SNMP host for the Switch.
v1 – Specifies that SNMP ver s ion 1 will be used. The Simple Network Management Protocol (SNMP), version 1, is a network management protocol that provides a means to monitor and control network devices.
v2c – Specifies that SNMP version 2c will be used. The SNMP v2c supports both centralized and distributed network management strategies. It includes improvements in the Structure of Management Information (SMI) and adds some security features.
v3 – Specifies that the SNMP vers io n 3 will be used. SNM P v3 provides secure access to devices through a combination of authentication and encrypting packets over the network. SNMP v3 adds:
Message integrity ensures that packets have not been tampered with during transit.
Authentication determines if an SNMP message is from a valid source.
Encryption scrambles the contents of messages to prevent it being viewed by an unauthorized source.
noauth_nopriv – Specifies that there will be no authorization and no encryption of packets sent between the Switch and a remote SNMP manager.
auth_nopriv – Specifies that authorization will be required, but there will be no encryption of packets sent between the Switch and a remote SNMP manager.
auth_priv – Specifies that authorization will be required, and that packets sent between the Switch and a remote SNMP manger will be encrypted.
<auth_string 32> – An alphanumeric string used to authorize a
remote
SNMP manager to access the Switch’s SNMP agent.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To create an SNMP host to receive SNMP messages:
Command: create snmp host 10.48.74.100 v3 auth_priv public
Success.
61
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#delete snmp host 10.48.74.100
DES-1228/ME:5#
DES-1228/ME:5#show snmp host
SNMPv3 User Name
DES-1228/ME:5#
delete snmp host
Purpose
Syntax Description
Parameters
Restrictions
Example usage : To delete an SNMP host entry:
Command: delete snmp host 10.48.74.100
Success.
show snmp host
Used to remove a recipient of SNMP traps generated by the Switch’s SNMP agent.
delete snmp [host <ipaddr>] This command is used to delete a recipient of SNMP traps generated
by the Switch’s SNMP agent. <ipaddr> – The IP address of a remote SNMP manager that will
receive SNMP traps generated by the Switch’s SNMP agent. Only Administrator level, Operator level or Power User level users
can issue this command.
Purpose
Syntax Description
Parameters
Restrictions
Example usage : To display the currently configured SNMP hosts on the Switch:
Command: show snmp host
SNMP Host Table Host IP Address SNMP Version Community Name /
--------------- --------------- ---------------------------------
10.48.76.23 V3 noauthnopriv initial
10.48.74.100 V2c public
Total Entries : 2
Used to display the recipient of SNMP traps generated by the Switch’s SNMP agent.
show snmp host {<ipaddr>} This command is used to display the IP addresses and configuration
information of remote SNMP managers that are designated as recipients of SNMP traps that are generated by the Switch’s SNMP agent.
<ipaddr> The IP address of a remote SNMP manager that will receive SNMP traps generated by the Switch’s SNMP agent.
None.
62
DES-1228/ME:5#create trusted_host 10.81.17.1
DES-1228/ME:5#
DES-1228/ME:5#create trusted_host network 10.81.0.0/16
create trusted_host
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax Description
Parameters
Restrictions
Example usage : To create a trusted host:
Command: create trusted_host 10.81.17.1
Success.
Used to create a trusted host. create trusted_host [<ipaddr> | network <network_address>] This command is used to create a trusted host. The Switch allows users to specify up
to ten IP addresses that are allowed to manage the Switch via in-band SNMP or Telnet-based management software. These IP addresses must be members of the Management VLAN. If no IP addresses are specified, then there is nothing to prevent any IP address from accessing the Switch, provided the user knows the Username and Password.
<ipaddr> The IP address of the trusted host to be created. <network_address> The IP address and netmask of the trusted host to be created.
Only Administrator level or Operator level users can issue this command.
To create a trusted host network:
Command: create trusted_host network 10.81.0.0/16
Success.
DES-1228/ME:5#
delete trusted_host
Purpose
Syntax
Description
Parameters
Used to delete a trusted host entry made using the create trusted_host command above.
delete trusted _host [ipaddr <ipaddr> | network <network_address> | all]
This command is used to delete a trusted host entry made using the create trusted_host command above.
<ipaddr> The IP address of the trusted host. <network_address> – The network address of the trusted network. all – All trusted hosts will be deleted.
Restrictions
Only Administrator level or Operator level users can issue this command.
63
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#delete trusted_host ipaddr 10.81.17.1
DES-1228/ME:5#delete trusted_host network 10.81.0.0/16 DES-1228/ME:5#delete trusted_host all
DES-1228/ME:5#
Example usage : To delete a trusted host with an IP address 10.48.74.121:
Command: delete trusted_host ipaddr 10.81.17.1
Success.
DES-1228/ME:5#
To delete a trusted host network with a network address 10.62.0.0/16:
Command: delete trusted_host network 10.81.0.0/16
Success.
DES-1228/ME:5#
To delete all trusted host entries:
Command: delete trusted_host all
Success.
show trusted_host
Purpose
Syntax Description
Parameters Restrictions
Used to display a list of trusted hosts entered on the Switch using the create trusted_host command above.
show trusted_host This command is used to display a list of trusted hosts entered on the Switch
using the create trusted_host command above. None. None.
64
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show trusted_host
DES-1228/ME:5#enable snmp traps
DES-1228:5#
DES-1228/ME:5#enable snmp authenticate_traps
Example Usage: To display the list of trust hosts:
Command: show trusted_host
Management Stations
IP Address/Netmask
-----------------------
10.53.13.94/32
Total Entries: 1
DES-1228/ME:5#
enable snmp traps
Purpose Syntax Description Parameters Restrictions
Used to enable SNMP trap support. enable snmp traps
The enable snmp traps command is used to enable SNMP trap support on the switch.
None. Only Administrator level or Operator level users can issue this command.
To enable SNMP trap support:
Command: enable snmp traps
Success.
enable snmp authenticate_traps
Purpose Syntax Description
Used to enable SNMP authentication failure trap support.. enable snmp authenticate_traps This command is us ed to enable snmp authenticate_ traps command enables
SNMP authentication failure trap support.
Parameters Restrictions
None. Only Administrator level or Operator level users can issue this command.
Example usage : To enable SNMP authentication trap support:
Command: enable snmp authenticate_traps
Success.
DES-1228/ME:5#
65
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
enable snmp linkchange_traps
Purpose Syntax Description Parameters Restrictions
Used to configure the sending of linkchange traps. . enable snmp linkchange_traps This command is used to enable/disable snmp link change traps. None. Only Administrator level or Operator level users can issue this command.
To enable SNMP linkchange t rap support on the Switch:
DES-1228/ME:5# enable snmp linkchange_traps Command: enable snmp linkchange_traps Success.
DES-1228/ME:5#
66
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#disable snmp traps
mand disables SNMP
DES-1228/ME:5#disable snmp authenticate_traps
DES-1228/ME:5#
disable snmp traps
Purpose Syntax Description Parameters Restrictions
Used to disable SNMP trap support on the switch. disable snmp traps This command is used to disable SNMP trap support on the Switch. None. Only Administrator level or Operator level users can issue this
command.
Example usage : To disable SNMP authentication trap support:
Command: disable snmp traps
Success.
DES-1228/ME:5#
disable snmp authenticate_traps
Purpose Syntax
Used to disable SNMP trap support on the switch. disable snmp authenticate_traps
Description
The disable snmp authenticate_traps com authentication failure trap support.
Parameters Restrictions
None. Only Administrator level or Operator level users can issue this
command.
To disable SNMP authentication trap support:
Command: disable snmp authenticate_traps
Success.
disable snmp linkchange_traps
Purpose Syntax Description Parameters
Used to disable the sending of linkchange traps. disable snmp linkchange_traps This command is used to disable snmp link change traps.. None.
Restrictions
Only Administrator level or Operator level users can issue this command.
67
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5# disable snmp linkchange_traps
DES-1228/ME:5#config snmp linkchange_traps ports 1-4 enable
To disable SNMP linkchange trap support o n t he Switch::
Command: disable snmp linkchange_traps Success.
DES-1228/ME:5#
config snmp linkchange_traps ports
Purpose
Used to configure the sending of linkchange traps and per port control for sending of change traps.
Syntax Description
config snmp linkchange_traps ports [all | <portlist>] [enable | disable] This command is used to configure the sending of linkchange traps
and per port control for the sending of change traps.
Parameters
all – To specify all ports. <portlist> - To specify a port range. enable – To enable the sending of a link change trap for this port. disable - To disable the sending of a link change trap for this port.
Restrictions
Only Administrator level or Operator level users can issue this command.
Example usage : To configure SNMP linkchange traps for ports 1 to 4:
Command: config snmp linkchange_traps ports 1-4 enable
Success.
DES-1228/ME:5#
show snmp traps
Purpose Syntax Description
Parameters
Restrictions
Example usage : To view the current SNMP trap support:
Used to show SNMP trap support on the Switch. show snmp traps {linkchange_traps { ports <portlist>} } This command is used to view the SNMP trap support status
currently configured on the Switch. linkchange_traps – This displays the current SNMP linkchange trap
status. <portlist> – This specifies a list of ports to display SNMP trap
support. None.
68
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show snmp traps
DES-1228/ME:5#
Command: show snmp traps
SNMP Traps : Enabled Authenticate Traps : Enabled Linkchange Traps : Enabled
69
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#config snmp system_contact MIS Department II
DES-1228/ME:5#config snmp system_location HQ 5F
config snmp system_contact
Purpose
Used to enter the name of a contact person who is responsible for the Switch.
Syntax Description
config snmp system_contact {<sw_contact>} This command is used to enter the name and/or other information to
identify a contact person who is responsible for the Switch. A maximum of 128 characters can be used.
Parameters
<sw_contact> A maximum of 128 characters is allowed. A NULL string is accepted if there is no contact.
Restrictions
Only Administrator level or Operator level users can issue this command..
Example usage : To configure the Switch contact to “MIS Department II”:
Command: config snmp system_contact MIS Department II
Success.
DES-1228/ME:5#
config snmp system_loca ti on
Purpose Syntax Description
Parameters
Restrictions
Example usage : To configure the Switc h location for “HQ 5F”:
Command: config snmp system_location HQ 5F
Success.
DES-1228/ME:5#
Used to enter a description of the location of the Switch. config snmp system_location {<sw_location>} This command is used to enter a description of the location of the
Switch. A maximum of 128 characters can be used. <sw_location> A maximum of 128 characters is allowed. A NULL
string is accepted if there is no location desired. Only Administrator level or Operator level users can issue this
command..
70
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#enable rmon
DES-1228/ME:5#
config snmp system_name
Purpose Syntax Description Parameters
Restrictions
Example usage : To configure the Switc h name for “DES-1228 Switch”:
DES-1228/ME:5#config snmp system_name DES-1228 Switch Command: config snmp system_name DES-1228 Switch
Success.
DES-1228/ME:5#
Used to configure the name for the Switch. config snmp system_name {<sw_name>} This command is used to configure the name of the Switch. <sw_name> A maximum of 128 characters is allowed. A NULL
string is accepted if no name is desired. Only Administrator level or Operator level users can issue this
command..
enable rmon
Purpose
Used to enable RMON on the Switch.
Syntax Description
Parameters Restrictions
Example Usage: To enable RMON:
Command: enable rmon
Success.
disable rmon
Purpose Syntax
enable rmon This command is used, in conjunction w ith the disa bl e rm on
command below, to enable and disable remote monitoring (RMON) on the Switch.
None. Only Administrator level or Operator level users can issue this
command..
Used to disable RMON on the Switch. disable rmon
Description
Parameters Restrictions
This command is used, in conjunction with the enable rmon command above, to enable and disable remote monitoring (RMON) on the Switch.
None. Only Administrator level or Operator level users can issue this
command..
71
DES-1228/ME:5#disable rmon
DES-1228/ME:5#
DES-1228/ME:5# config snmp coldstart_traps enable
Example Usage: To disable RMON:
Command: disable rmon
Success.
config snmp coldstart _ tr a ps
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax Description Parameters
Used to configure the trap for coldstart event. config snmp coldstart_traps [enable | disable] This command is used to configure the trap state for coldstart event enable – enable trap of coldstart event.
disable – disable trap of coldstart event.
Restrictions
Only Administrator level users can issue this command.
Example usage: To enable the trap for coldstart events:
Command: config snmp coldstart_traps enable Success.
DES-1228/ME:5#
config snmp warmstart_traps
Purpose Syntax
Used to configure the trap for warmstart event. config snmp warmstart_traps [enable | disable]
Description Parameters
This command is used to configure the trap state for warmstart event enable – enable trap of warmstart event.
disable – disable trap of warmstart event.
Restrictions
Only Administrator level users can issue this command.
Example usage : To enable the trap for warmstart events:
DES-1228/ME:5# config snmp warmstart_traps enable Command: config snmp warmstart_traps enable Success.
DES-1228/ME:5#
72
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
<ipv6addr>] <path_filename 64>
9

SWITCH UTILITY COMMANDS

The Switch Utility commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
download [ firmware_fromTFT P [<ipaddr> | <ipv6ad dr >] <path _filename
64> image_id <value 1-2> | cfg_fromTFTP [<ipaddr> | <ipv6addr>] <path_filename 64> {config_id <value 1-2> |
increment} ] config firmware image_id <value 1-2> [delete | boot_up] show firmware information show config [current_config | config_in_nvram] upload [cfg_toTFTP [<ipaddr> |
{config_id <value 1-2>} {[in clude | exclude | begin] <filter_string
80> {<filter_string 80 > {<filter_string 80>}} {[includ e | exclude |
begin] <filter_string 80> {<filter_string 80> {<filter_string 80>}}
{[include | exclude | begin] <filter_str ing 80> {<filter_string 80>
{<filter_string 80>}}}}} | log_toTFTP [<ipaddr> | <ipv6addr>]
<path_filename 64>] enable autoconfig disable autoconfig config autoconfig timeout < value 1-65535 > show autoconfig ping <ipaddr> {times <val ue 0-255>} {size <value 1-60000>}
{timeout <sec 1-99>} ping6 <ipv6addr> {times <value 1-255>} {size <value 1-6000>}
{timeout <value 1-10>} traceroute <ipaddr> {ttl <value 1-60>} {port <value 30000-64900>}
{timeout <sec 1-65535>} {probe <value 1-9>} config terminal _line [default | <value 20-80>] show terminal_line
Each command is listed, in detail, in the following sections:
73
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
2> | cfg_fromTFTP [<ipaddr> | <ipv6addr>]
download
Purpose
Syntax
Description
Parameters
Used to download and install new firmware or a Switch configuration file from a TFTP server.
[firmware_fromTFTP [<ipaddr> | <ipv6addr>] <path_filename 64> image_id <value 1­<path_filename 64> {config_id <value 1-2> | increment}]
This command is used to download a new firmware or a Switch configuration file from a TFTP server.
firmware_fromTFTP - Download and install new firmware on the Switch from a TFTP server.
cfg_fromTFTP - Download a switch configuration file from a TFTP server.
<ipaddr> - The IP address of the TFTP server. <ipv6addr> - The IPv6 address of the TFTP server. <path_filename> - The DOS path and filename of the firmware or
switch configuration file on the TFTP server. For example, C:\1228.had.
image_id <value 1-2> - Specify the working section ID. The Switch can hold two firmware versions for the user to select from, which are specified by section ID.
increment - Allows the download of a partial switch configuration file. This allows a file to be downloaded that will change only the switch parameters explicitly stated in the configuration file. All other switch parameters will remain unchanged.
config_id <value 1-2> - Specifies which cfg file ID. if cfg ID is not specified, it refers to the boot_up CFG file.
Restrictions
Example usage : To download a configura t ion file:
The TFTP server must be on the same IP subnet as the Switch. Only Administrator level, Operator level or Power User level users can issue this command.
74
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#download cfg_fromTFTP 10.48.74.121 c:\cfg\setting.txt
Command: download cfg_fromTFTP 10.48.74.121 c:\cfg\setting.txt
Connecting to server................... Done.
Download configuration................. Done.
Success. DES-1228/ME:5# DES-1228/ME:5##------------------------------------------------------------------­DES-1228/ME:5## DES-1228/ME Configuration DES-1228/ME:5## DES-1228/ME:5## Firmware: Build 2.01.001 DES-1228/ME:5## Copyright(C) 2012 D-Link Corporation. All rights reserved. DES-1228/ME:5##------------------------------------------------------------------­DES-1228/ME:5# DES-1228/ME:5# DES-1228/ME:5## BASIC DES-1228/ME:5# DES-1228/ME:5#config serial_port baud_rate 9600 auto_logout 10_minutes Command: config serial_port baud_rate 9600 auto_logout 10_minutes
The downloa d confi guratio n comma nd will initiate t he loading of the various setti ngs in the order listed in the con figuration file. When the file has been successfully loaded the message “End of configuration file for DES-1228/ME” appears followed by the command prompt.
DES-1228/ME:5#disable authen_policy Command: disable authen_policy
Success.
DES-1228/ME:5#
config firmware
Purpose
Syntax Description
Parameters
Used to configure the firmware section image as a boot up section, or to delete the firmware section
config firmware image_id <value 1-2> [delete | boot_up] This command is used to configure the firmware section image. The
user may choose to remove the firmware section or use it as a boot up section.
image_id – Specifies the working section image. The Switch can hold two firmware versions for the user to select from, which are specified by image ID.
delete – Entering this parameter will delete the specified firmware section image.
boot_up – Entering this parameter will specify the firmware image ID as a boot up section image.
Restrictions
Only Administrator level users can issue this command.
Example usage : To configure firmware section image 1 as a boot up section:
75
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5# config firmware image_id 1 boot_up
Command: config firmware image_id 1 boot_up
Success.
DES-1228/ME:5#
76
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show firmware information
show firmware information
Purpose Syntax Description Parameters Restrictions
Used to display the firmware section information. show firmware information This command is used to display the firmware section information. None. None
Example usage : To display the current firmware information on the Switch:
Command: show firmware information
Image ID : 1(Boot up firmware) Version : 2.01.001 Size : 2420752 Bytes Update Time: 0000/00/00 00:03:03 From : 10.10.27.67 User : Anonymous(CONSOLE)
Image ID : 2(Empty)
DES-1228/ME:5#
77
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
ath_filename 64>
upload
Purpose
Syntax
Description
Parameters
Used to upload the current switch settings or the switch history log to a TFTP.
upload [cfg_toTFTP [<ipaddr> | <ipv6addr>] <p {config_id <value 1-2>} {[include | exclude | begin] <filter_string 80> {<filter_string 80> {<filter_string 80>}} {[include | exclude | begin] <filter_string 80> {<filter_string 80> {<filter_string 80>}} {[include | exclude | begin] <filter_string 80> {<filter_string 80> {<filter_string 80>}}}}} | log_toTFTP [<ipaddr> | <ipv 6ad dr>] <p ath _f il ename 64>]
This command is used to upload either the Switch’s current settings or the Switch’s history log to a TFTP server.
The output stream can be filtered by the expression specified at the end of the comm and. The expression can conta in up to three m ultiple filter evaluations. A filter evaluation begins wit h a filter type (include, exclude, and begin), foll owed by up to three filter s trings (ex: “stp”). A filter string is enclosed by the symbol “
The relationship of m ultip le filter strings following th e s ame filter type is OR. That is, one line is qualifie d if one of the specif ied filter strings is matched.
If more than one f ilter evaluation is spec ified; the output is filtered by the former evaluation and will be used as the input of the latter evaluation.
cfg_toTFTP Specifies that the Switch’s current settings will be uploaded to the TFTP server.
log_toTFTP Specifies that the switch history log will be uploaded to the TFTP server.
<ipaddr> The IP address of the TFTP server. The TFTP server must be on the same IP subnet as the Switch.
<ipv6addr> - The IPv6 address of the TFTP server. <path_filename 64> Specifies the location of the Switch
configuration file on the TFTP server. This file will be replaced by the uploaded file from the Switch
config_id - Specifies which cfg file ID. if cfg ID is not specified, it refers to the boot_up CFG file.
include – Includes lines that contain the specified filter string. exclude – Excludes lines that contain the specified filter string begin – The first line that conta ins the specified filter s tring will be the
first line of the output. filter_string: A f ilter string is encl osed by the symbo l ". Thus, the filter
string itself cannot contain the “character. The filter string is case sensitive.
Restrictions
Example usage : To upload the spanning tree configurat ions to TFTP server:
The TFTP server must be on the same IP subnet as the Switch Only Administrator level or Operator level users can issue this command
78
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#
DES-1228/ME:5#upload cfg_toTFTP 10.90.90.1 config_stp.txt include "stp" Command: upload cfg_toTFTP 10.90.90.1 config_stp.txt include "stp"
Connecting to server................... Done.
Upload configuration................... Done.
Success.
79
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
configuration file name and path within the user interface. Alternatively, the DHCP
enable autoconfig
Purpose
Used to activate the auto configuration function for the Switch. This will load a previously saved configuration file for current use.
Syntax Description
enable autoconfig When autoconfig is enabled on the Switch, the DHCP reply will contain a
configuration file and path name. It will then request the file from the TFTP server specified in the reply. When autoconfig is enabled, the ipif settings will automatically become DHCP client.
Parameters Restrictions
None. When autoconfig is enabled, the Switch becomes a DHCP client
automatically (same as: config ipif System dhcp). The DHCP server must have the TFTP server IP address and configuration file name, and be configured to deliver this information in the data field of the DHCP reply packet. The TFTP server must be running and have the requested configuration file in its base directory when the request is received from the Switch. Consult the DHCP server and TFTP server software instructions for information on loading a configuration file.
If the Switch is unable to complete the auto configuration process the previously saved local configuration file present in Switch memory will be loaded.
Only Administrator level or Operator level users can issue this command
Note: Dual-purpose (DHCP/TFTP) server utility software may require entry of the software m ay require c reating a s eparate ex t file with t he configur ation file n ame and
path in a specific directory on the server. Consult the documentation for the DHCP server software if users are unsure.
Example usage : To enable auto configuration on the Switch:
DES-1228/ME:5#enable autoconfig Command: enable autoconfig
Success.
DES-1228/ME:5#
When autoconfig is enabled and the Switch is rebooted, the normal login screen will appear for a few moments while the autoconfig request (i.e. download configuration) is initiated. The console will then displa y the configuration parameters as they are loaded from the configuration file specified in the DHCP or TFTP server. This is exactly the same as using a download configurat ion command. Aft er the entire Swit ch configurat ion is loaded, the Switch will automatically “logout” the s erver. The configuration settings will be saved automatically and become the active configuration.
Upon booting up the autoconfig process is initiated, the console screen will appear similar to the example below. The configuration settings will be loaded in normal order.
80
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME Metro Ethernet Switch
Download configuration................. Done.
: With autoconfig enabled, the Switch ipif settings now define the Switch as a DHCP
Command Line Interface
Firmware: Build 2.01.001 Copyright(C) 2012 D-Link Corporation. All rights reserved. UserName: PassWord:
DES-1228/ME:5#download cfg_fromTFTP 10.41.44.44 c:\cfg\setting.txt Command: download cfg_fromTFTP 10.41.44.44 c:\cfg\setting.txt
Connecting to server................... Done.
The very end of the autoconfig process appears like this:
Success.
DES-1228/ME:5# DES-1228/ME:5## ROUTE DES-1228/ME:5# DES-1228/ME:5# DES-1228/ME:5##--------------------------------------------------­DES-1228/ME:5## End of configuration file for DES-1228/ME DES-1228/ME:5##--------------------------------------------------­DES-1228/ME:5#
DES-1228/ME:5#
Note
client. Use the show switch command to display the new IP settings status.
81
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#disable autoconfig
DES-1228/ME:5#config autoconfig timeout 20
disable autoconfig
Purpose Syntax Description
Use this to deactivate auto configuration from DHCP. disable autoconfig This command is used to instruct the Switch not to accept auto
configuration instruction from the DHCP server. This does not change the IP settings of the Switch. The ipif settings will continue as DHCP client until changed with the config ipif command.
Parameters Restrictions
None. Only Administrator level or Operator level users can issue this
command.
Example usage : To stop the auto configuration function:
Command: disable autoconfig
Success.
DES-1228/ME:5#
config autoconfig timeout
Purpose
This command is used to specify the timeout length in getting of network setting through DHCP.
Syntax Description
config autoconfig timeout < value 1-65 535 > This command is used to configure the timeout value. This timer is used
to limit the length of time in getting configuration setting from the network. When timeout occurs, the auto configuration operation will be stopped and the local configuration file will be used to configure the system.
Parameters
value - Specify the timeout length in seconds. The default setting is 50 seconds.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To configure the auto configuration ti me o ut val ue :
Command: config autoconfig timeout 20
Success.
82
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show autoconfig
DES-1228/ME:5#
show autoconfig
Purpose Syntax Description
Used to display the current autoconfig status of the Switch. show autoconfig This command is used to list the current status of the auto
configuration function.
Parameters Restrictions
None. None.
Example usage : To display the autoconfig status:
Command: show autoconfig
Autoconfig State: Disabled Timeout : 50 sec
83
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#ping 10.48.74.121 times 4
ping
Purpose Syntax
Used to test the connectivity between network devices. ping <ipaddr> {times <value 0-255>} {size <value 1-60000>}
{timeout <sec 1-99>}
Description
The command is used to send Internet Control Message Protocol (ICMP) echo messages to a remote IP address. The remote IP address will then “echo” or return the message. This is used to confirm connectivity between the Switch and the remote device.
Parameters
<ipaddr> Specifies the IP address of the host. times <value 0-255> The number of individual ICMP echo
messages to be sent. A value of 0 will send an infinite ICMP echo messages. The maximum value is 255. The default is 0.
size <value 1-60000> The size of the test packet. The value is between 1 and 60000.
timeout <sec 1-99> Defines the time-out period while waiting for a response from the remote device. A value of 1 to 99 seconds can be specified. The default is 1 second.
Restrictions
None.
Example usage : To ping the IP address 10.48.74.121 four times:
Command: ping 10.48.74.121
Reply from 10.48.74.121, time<10ms Reply from 10.48.74.121, time<10ms Reply from 10.48.74.121, time<10ms Reply from 10.48.74.121, time<10ms
Ping statistics for 10.48.74.121 Packets: Sent =4, Received =4, Lost =0
DES-1228/ME:5#
ping6
Purpose Syntax
Description Parameters
Used to diagnose the IPv6 network. ping6 <ipv6addr> {times <value 1-255>} {size <value 1-6000>}
{timeout <value 1-10>} This command is used to diagnose the IPv6 network. <ipv6addr> Specifies the IPv6 address of the host.
times <value 1-255> The number of individual ICMP echo messages to be sent. T he default is 1.
size <value 1-6000> The size of the test packet. The value is between 1 and 6000.
timeout <value 1-10> Defines the time-out period whil e waiting for a response from the remote devic e. A value of 1 to 10 secon ds can be specified. The default is 1 second.
84
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#ping6 FE80::254:85FF:FE32:1804%System times 6
ping6
Restrictions
None.
Example usage : To ping the IPv6 address “FE80::254:85FF:FE32:1804” six times:
Command: ping6 FE80::254:85FF:FE32:1804%System times 6 Reply from FE80::254:85FF:FE32:1804, bytes=100 time=10 ms Reply from FE80::254:85FF:FE32:1804, bytes=100 time<10 ms Reply from FE80::254:85FF:FE32:1804, bytes=100 time<10 ms Reply from FE80::254:85FF:FE32:1804, bytes=100 time<10 ms Reply from FE80::254:85FF:FE32:1804, bytes=100 time<10 ms Reply from FE80::254:85FF:FE32:1804, bytes=100 time<10 ms Ping Statistics for FE80::254:85FF:FE32:1804 Packets: Sent =6, Received =6, Lost =0 Success. DES-1228/ME:5#
85
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
traceroute
Purpose
Used to trace the routed path between the Switch and a destination endstation.
Syntax
traceroute <ipaddr> {ttl <value 1-60>} {port <value 30000-64900>} {timeout <sec 1-65535>} {probe <value 1-9>}
Description
This command is used to trace the routed path between the Switch and a destination endstation.
Parameters
<ipaddr> - The IP address of the destination endstation. ttl <value 1-60> - The time-to-live value of the trace route request.
This is the maximum number of routers. This command will cross while seeking the networ k path between two devices.
port <value 30000-64900> - The port number. It must be above
1024. The value range is between 30000 and 64900. probe <value 1-9> - The number of probes. The range is from 1 to 9.
Restrictions
Only Administrator level, Operator level or Power User level users can issue this command.
Example usage : To trace the routed path between the Switch and 10.48.74.121:
DES-1228/ME:5#traceroute 10.48.74.121 probe 3 Command: traceroute 10.48.74.121 probe 3
1 <10 ms. 10.48.74.121 1 <10 ms. 10.48.74.121 1 <10 ms. 10.48.74.121
DES-1228/ME:5#
86
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5# config terminal_line 30
DES-1228/ME:5#
config terminal line
Purpose
Syntax Description
Parameters Restrictions
Example usage : To configure the termi nal line:
Command: config terminal_line 30
Success.
show terminal line
Purpose
Used to configure the number of rows which can be displayed at a screen.
config terminal_line [default | <value 20-80>] This command is used to configure the number of rows which can be
displayed on a screen. The default value is 24. None. Only Administrator level, Operator level or Power User level users
can issue this command.
Used to display the number of rows which can be displayed at a screen.
Syntax Description
Parameters Restrictions
Example usage : To show the te rminal line:
DES-1228/ME:5# show terminal_line Command: show terminal_line
Current terminal line number : 30
DES-1228/ME:5#
show terminal_line This command is used to display the number of rows which can be
displayed on a screen. None. None.
87
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
10

NETWORK MONITORING COMMANDS

The Network Monitoring commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table:
Command Parameters
show packet ports <portlist> show error ports <portlist> show utilization [cpu | dram | flash | ports {<portlist>}] clear counters {ports <portlist>} clear log show log {index <value_list X-Y>} enable syslog disable syslog show syslog create syslog host <index 1-4> {severit y [infor mational | warning | all] | facility [local0 |
local1 | local2 | local3 | local4 | local5 | local6 | local7] | udp_port <udp_port_number>| ipaddress [<ipaddr>] | state [enable | disable] }
config syslog {host [all | <index 1-4>]} {severit y [informational | warning | all] |
facility [local0 | local1 | local2 | local3 | local4 | local5 | local6 | local7] | udp_port <udp_por t_number> | ipaddress [<ipaddr>] |
state [enable | disable]} delete syslog host [<index 1-4> | all] show syslog host {<index 1-4>} config log_save_timing [time_interval <min 1-65535> | on_demand | log_trigg er] show log_save_timing enable command
logging disable command
logging show command logging
88
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show packet ports 1
Each command is listed, in detail, in the following sections:
show packet ports
Purpose Syntax Description
Parameters Restrictions
Example usage : To display the packets analysis for port 1:
Command: show packet ports 1
Port Number : 1 Frame Size Frame Counts Frames/sec Frame Type Total Total/sec
------------ ------------ ---------- ---------- ---------- --------­ 64 0 0 RX Bytes 0 0 65-127 0 0 RX Frames 0 0 128-255 0 0 Port Number : 1 0 TX Bytes 0 0 Frame Size Frame Counts Frames/sec Frame Type Total Total/sec
------------ ------------ ---------- ---------- ---------- --------­ 64 0 0 RX Bytes 0 0 65-127 0 0 RX Frames 0 0 128-255 0 0 256-511 0 0 TX Bytes 0 0 512-1023 0 0 TX Frames 0 0 1024-1518 0 0
Unicast RX 0 0 Multicast RX 0 0 Broadcast RX 0 0
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
Used to display stats about packets sent and received by the Switch. show packet ports <portlist> This command is used to display statistics about packets sent and
received by ports specified in the <portlist>. <portlist> − Specifies a port or range of ports to be displayed.
None.
89
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show error ports 1
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
show error ports
Purpose Syntax Description
Parameters Restrictions
Example usage : To display the errors of the port 3:
Command: show error ports 1
Port Number : 1 RX Frames TX Frames
--------- --------­ CRC Error 0 Excessive Deferral 0 Undersize 0 CRC Error 0 Oversize 0 Late Collision 0 Port Number : 1 Excessive Collision 0 RX Frames TX Frames
--------- --------­ CRC Error 0 Excessive Deferral 0 Undersize 0 CRC Error 0 Oversize 0 Late Collision 0 Fragment 0 Excessive Collision 0 Jabber 0 Single Collision 0 Drop Pkts - Collision 0
Used to display the error statistics for a range of ports. show error ports <portlist> This command is used to display all of the packet error statistics
collected and logged by the Switch for a given port list. <portlist> − Specifies a port or range of ports to be displayed.
None.
90
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show utilization cpu
DES-1228/ME:5#show utilization dram
show utilization
Purpose Syntax Description
Parameters
Restrictions
Example usage : To display the current CPU utilization:
Command: show utilization cpu
CPU Utilization :
-----------------------------------------------------------------­Five Seconds - 3% One Minute - 2% Five Minutes - 5%
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
Used to display real-time utilization statistics. show utilization [ cpu | dram | flash | ports {<portlist>}] This command is used to display the real-time utilization statistics for
the Switch. cpu – Entering this parameter will display the current CPU utilization
of the Switch. dram – Entering this parameter will display the current DRAM
utilization of the Switch. flash – Entering this parameter will display the current Flash
utilization of the Switch. ports – Entering this parameter will display the current port utilization
of the Switch. <portlist> – Specifies a range of ports to be displayed.
None.
To display the current DRAM utilization:
Command: show utilization dram
DRAM Utilization :
Total DRAM : 131,072 KB Used DRAM : 65,604 KB Utilization : 50%
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
91
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show utilization flash
DES-1228/ME:5#show utilization ports
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
To display the current Flash memory utilization:
Command: show utilization flash
FLASH Memory Utilization :
Total FLASH : 16,384 KB Used FLASH : 7,371 KB Utilization : 44%
CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
To display the port utilization statistics:
Command: show utilization ports
Port TX/sec RX/sec Util Port TX/sec RX/sec Util
---- ---------- ---------- ---- ---- ---------- ---------- ---­ 1 0 0 0 22 0 0 0 2 0 0 0 23 0 0 0 3 0 0 0 24 0 0 0 4 0 0 0 25 0 0 0 5 0 0 0 26 0 0 0 6 0 0 0 27 0 0 0 7 0 37 1 28 0 0 0 8 0 0 0 9 0 0 0 10 0 0 0 11 36 0 1 12 0 0 0 13 0 0 0 14 0 0 0 15 0 0 0 16 0 0 0 17 0 0 0 18 0 0 0 19 0 0 0 20 0 0 0 21 0 0 0
92
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#clear counters ports 2-9
DES-1228/ME:5#
DES-1228/ME:5#clear log
clear counters
Purpose Syntax Description
Parameters Restrictions
Example usage : To clear the counters:
Command: clear counters ports 2-9
Success.
clear log
Purpose Syntax
Used to clear the Switch’s statistics counters. clear counters {ports <portlist>} This command is used to clear the counters used by the Switch to
compile statistics. <portlist> − Specifies a port or range of ports to be displayed. Only Administrator level or Operator level users can issue this
command.
Used to clear the Switch’s history log. clear log
Description Parameters Restrictions
Example usage : To clear the log information:
Command: clear log
Success.
DES-1228/ME:5#
This command is used to clear the Switch’s history log. None. Only Administrator level or Operator level users can issue this
command.
93
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
00 01:01:09 Successful login through Console (Username: Anonymous)
DES-1228/ME:5#enable syslog
show log
Purpose Syntax Description
Used to display the switch history log. show log {index <value_list X-Y>} This command is used to display the contents of the Switch’s
history log.
Parameters
index <value_list X-Y> This command will display the history log, beginning and ending at the value specified by the user in the <value_list X-Y> field.
If no parameter is specified, all history log entries will be displayed.
Restrictions
None.
Example usage : To display the switch history log:
DES-1228/ME:5#show log index 1-5 Command: show log index 1-5
Index Data Time Log Text
----- -------------------- -----------------------------------------------------­5 00000-00­4 00000-00-00 00:00:14 System warm start 3 00000-00-00 00:00:06 Port 25 link up, 1000Mbps FULL duplex 2 00000-00-00 00:00:01 Port 25 link down 1 00000-00-00 00:06:31 Port 25 link up, 1000Mbps FULL duplex
DES-1228/ME:5#
enable syslog
Purpose Syntax Description
Parameters Restrictions
Example usage : To enable t he syslog function on the Switch:
Command: enable syslog
Success.
DES-1228/ME:5#
Used to enable the system log to be sent to a remote host. enable syslog This command is used to enable the system log to be sent to a
remote host. None. Only Administrator level or Operator level users can issue this
command.
94
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
DES-1228/ME:5#show syslog
DES-1228/ME:5#
disable syslog
Purpose Syntax Description
Used to disable the system log to be sent to a remote host. disable syslog This command is used to disable the system log to be sent to a
remote host.
Parameters Restrictions
None. Only Administrator level or Operator level users can issue this
command.
Example usage : To disable the syslog function on the Switch:
DES-1228/ME:5#disable syslog Command: disable syslog
Success.
DES-1228/ME:5#
show syslog
Purpose Syntax
Used to display the syslog protocol status as enabled or disabled. show syslog
Description
This command is used to display the syslog status as enabled or disabled.
Parameters Restrictions
None. None.
Example usage : To display the current status of t he syslog function:
Command: show syslog
Syslog Global State : Disabled
95
create syslog host
DES-1228/ME Metro Ethernet Managed Switch CLI Reference Guide
Purpose Syntax
Description Parameters
Used to create a new syslog host. create syslog host <index 1-4> {severity [informational | warning | all] | facilit y [local0 | local 1 |
local2 | local3 | local4 | local5 | local6 | local7] | udp_port <udp_p ort_number> | ipaddress [<ipaddr>] | state [enable | disable] }
This command is used to create a new syslog host. <index 1-4> Specifies that the command will be applied to an index of hosts. There are four
available indexes, numbered 1 through 4. severity Severity level indicator. These are described in the following: Bold font indicates that the corresponding severity level is currently supported on the Switch.
Numerical Severity Code
0 Emergency: system is unusable 1 Alert: action must be taken immediately 2 Critical: critical conditions 3 Error: error conditions 4 Warning: warning conditions 5 Notice: normal but significant condition 6 Informational: informational messages 7 Debug: debug-level messages
Numerical Facility Code
96
Loading...