D-link DGS-3212SR User Manual

Page 1
DGS-3212SR
Command Line Interface Reference Manual
First Edition (August 2003)
………….
Page 2
DGS-3212SR Switch CLI Reference
1. Bitte lesen Sie sich diese Hinweise sorgfältig durch.
2. Heben Sie diese Anleitung für den spätern Gebrauch auf.
3. Vor jedem Reinigen ist das Gerät vom Stromnetz zu trennen. Vervenden Sie keine Flüssig­oder Aerosolreiniger. Am besten dient ein angefeuchtetes Tuch zur Reinigung.
4. Um eine Beschädigung des Gerätes zu vermeiden sollten Sie nur Zubehörteile verwenden, die vom Hersteller zugelassen sind.
5. Das Gerät is vor Feuchtigkeit zu schützen.
6. Bei der Aufstellung des Gerätes ist auf sichern Stand zu achten. Ein Kippen oder Fallen könnte Verletzungen hervorrufen. Verwenden Sie nur sichere Standorte und beachten Sie die Aufstellhinweise des Herstellers.
7. Die Belüftungsöffnungen dienen zur Luftzirkulation die das Gerät vor Überhitzung schützt. Sorgen Sie dafür, daß diese Öffnungen nicht abgedeckt werden.
8. Beachten Sie beim Anschluß an das Stromnetz die Anschlußwerte.
9. Die Netzanschlußsteckdose muß aus Gründen der elektrischen Sicherheit einen Schutzleiterkontakt haben.
10. Verlegen Sie die Netzanschlußleitung so, daß niemand darüber fallen kann. Es sollete auch nichts auf der Leitung abgestellt werden.
11. Alle Hinweise und Warnungen die sich am Geräten befinden sind zu beachten.
12. Wird das Gerät über einen längeren Zeitraum nicht benutzt, sollten Sie es vom Stromnetz trennen. Somit wird im Falle einer Überspannung eine Beschädigung vermieden.
13. Durch die Lüftungsöffnungen dürfen niemals Gegenstände oder Flüssigkeiten in das Gerät gelangen. Dies könnte einen Brand bzw. Elektrischen Schlag auslösen.
14. Öffnen Sie niemals das Gerät. Das Gerät darf aus Gründen der elektrischen Sicherheit nur von authorisiertem Servicepersonal geöffnet werden.
15. Wenn folgende Situationen auftreten ist das Gerät vom Stromnetz zu trennen und von einer qualifizierten Servicestelle zu überprüfen:
16. Netzkabel oder Netzstecker sint beschädigt.
17. Flüssigkeit ist in das Gerät eingedrungen.
18. Das Gerät war Feuchtigkeit ausgesetzt.
19. Wenn das Gerät nicht der Bedienungsanleitung ensprechend funktioniert oder Sie mit Hilfe dieser Anleitung keine Verbesserung erzielen.
20. Das Gerät ist gefallen und|oder das Gehäuse ist beschädigt.
21. Wenn das Gerät deutliche Anzeichen eines Defektes aufweist.
22. Bei Reparaturen dürfen nur Orginalersatzteile bzw. den Orginalteilen entsprechende Teile verwendet werden. Der Einsatz von ungeeigneten Ersatzteilen kann eine weitere Beschädigung hervorrufen.
23. Wenden Sie sich mit allen Fragen die Service und Repartur betreffen an Ihren Servicepartner. Somit stellen Sie die Betriebssicherheit des Gerätes sicher.
24. Zum Netzanschluß dieses Gerätes ist eine geprüfte Leitung zu verwenden, Für einen Nennstrom bis 6A und einem Gerätegewicht grőßer 3kg ist eine Leitung nicht leichter als H05VV-F, 3G, 0.75mm2 einzusetzen.
ii
Page 3
DGS-3212SR Switch CLI Reference
WARRANTIES EXCLUSIVE
IF THE D-LINK PRODUCT DOES NOT OPERATE AS WARRANTED ABOVE, THE CUSTOMER'S SOLE REMEDY SHALL BE, AT D-LINK'S OPTION, REPAIR OR REPLACEMENT. THE FOREGOING WARRANTIES AND REMEDIES ARE EXCLUSIVE AND ARE IN LIEU OF ALL OTHER WARRANTIES, EXPRESSED OR IMPLIED, EITHER IN FACT OR BY OPERATION OF LAW, STATUTORY OR OTHERWISE, INCLUDING WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. D-LINK NEITHER ASSUMES NOR AUTHORIZES ANY OTHER PERSON TO ASSUME FOR IT ANY OTHER LIABILITY IN CONNECTION WITH THE SALE, INSTALLATION MAINTENANCE OR USE OF D-LINK'S PRODUCTS
D-LINK SHALL NOT BE LIABLE UNDER THIS WARRANTY IF ITS TESTING AND EXAMINATION DISCLOSE THAT THE ALLEGED DEFECT IN THE PRODUCT DOES NOT EXIST OR WAS CAUSED BY THE CUSTOMER'S OR ANY THIRD PERSON'S MISUSE, NEGLECT, IMPROPER INSTALLATION OR TESTING, UNAUTHORIZED ATTEMPTS TO REPAIR, OR ANY OTHER CAUSE BEYOND THE RANGE OF THE INTENDED USE, OR BY ACCIDENT, FIRE, LIGHTNING OR OTHER HAZARD.
LIMITATION OF LIABILITY IN NO EVENT WILL D-LINK BE LIABLE FOR ANY DAMAGES, INCLUDING
LOSS OF DATA, LOSS OF PROFITS, COST OF COVER OR OTHER INCIDENTAL, CONSEQUENTIAL OR INDIRECT DAMAGES ARISING OUT THE INSTALLATION, MAINTENANCE, USE, PERFORMANCE, FAILURE OR INTERRUPTION OF A D- LINK PRODUCT, HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY. THIS LIMITATION WILL APPLY EVEN IF D-LINK HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
IF YOU PURCHASED A D-LINK PRODUCT IN THE UNITED STATES, SOME STATES DO NOT ALLOW THE LIMITATION OR EXCLUSION OF LIABILITY FOR INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THE ABOVE LIMITATION MAY NOT APPLY TO YOU.
Limited Warranty Hardware:
D-Link warrants each of its hardware products to be free from defects in workmanship and materials under normal use and service for a period commencing on the date of purchase from D-Link or its Authorized Reseller and extending for the length of time stipulated by the Authorized Reseller or D-Link Branch Office nearest to the place of purchase.
This Warranty applies on the condition that the product Registration Card is filled out and returned to a D-Link office within ninety (90) days of purchase. A list of D-Link offices is provided at the back of this manual, together with a copy of the Registration Card.
If the product proves defective within the applicable warranty period, D-Link will provide repair or replacement of the product. D-Link shall have the sole discretion whether to repair or replace, and replacement product may be new or reconditioned. Replacement product shall be of equivalent or better specifications, relative to the defective product, but need not be identical. Any product or part repaired by D-Link pursuant to this warranty shall have a warranty period of not less than 90 days, from date of such repair, irrespective of any earlier expiration of original warranty period. When D-Link provides replacement, then the defective product becomes the property of D-Link.
Warranty service may be obtained by contacting a D-Link office within the applicable warranty period, and requesting a Return Material Authorization (RMA) number. If a Registration Card for the product in question has not been returned to D-Link, then a proof of purchase (such as a copy of the dated purchase invoice) must be provided. If Purchaser's circumstances require special handling of warranty correction, then at the time of requesting RMA number, Purchaser may also propose special procedure as may be suitable to the case.
After an RMA number is issued, the defective product must be packaged securely in the original or other suitable shipping package to ensure that it will not be damaged in transit, and the RMA number must be prominently marked on the outside of the package. The package must be mailed or otherwise shipped to D-Link with all costs of mailing|shipping|insurance prepaid. D-Link shall never be responsible for any software, firmware, information, or memory data of Purchaser contained in, stored on, or integrated with any product returned to D-Link pursuant to this warranty.
Any package returned to D-Link without an RMA number will be rejected and shipped back to Purchaser at Purchaser's expense, and D-Link reserves the right in such a case to levy a reasonable handling charge in addition mailing or shipping costs.
iii
Page 4
DGS-3212SR Switch CLI Reference
Software:
Warranty service for software products may be obtained by contacting a D-Link office within the applicable warranty period. A list of D-Link offices is provided at the back of this manual, together with a copy of the Registration Card. If a Registration Card for the product in question has not been returned to a D-Link office, then a proof of purchase (such as a copy of the dated purchase invoice) must be provided when requesting warranty service. The term "purchase" in this software warranty refers to the purchase transaction and resulting license to use such software.
D-Link warrants that its software products will perform in substantial conformance with the applicable product documentation provided by D-Link with such software product, for a period of ninety (90) days from the date of purchase from D-Link or its Authorized Reseller. D-Link warrants the magnetic media, on which D-Link provides its software product, against failure during the same warranty period. This warranty applies to purchased software, and to replacement software provided by D-Link pursuant to this warranty, but shall not apply to any update or replacement which may be provided for download via the Internet, or to any update which may otherwise be provided free of charge.
D-Link's sole obligation under this software warranty shall be to replace any defective software product with product which substantially conforms to D-Link's applicable product documentation. Purchaser assumes responsibility for the selection of appropriate application and system|platform software and associated reference materials. D-Link makes no warranty that its software products will work in combination with any hardware, or any application or system|platform software product provided by any third party, excepting only such products as are expressly represented, in D-Link's applicable product documentation as being compatible. D-Link's obligation under this warranty shall be a reasonable effort to provide compatibility, but D-Link shall have no obligation to provide compatibility when there is fault in the third-party hardware or software. D-Link makes no warranty that operation of its software products will be uninterrupted or absolutely error­free, and no warranty that all defects in the software product, within or without the scope of D-Link's applicable product documentation, will be corrected.
D-Link Offices for Registration and Warranty Service
The product's Registration Card, provided at the back of this manual, must be sent to a D-Link office. To obtain an RMA number for warranty service as to a hardware product, or to obtain warranty service as to a software product, contact the D-Link office nearest you. An address|telephone|fax|e-mail|Web site list of D-Link offices is provided in the back of this manual.
Trademarks
Copyright 2003 D-Link Corporation. Contents subject to change without prior notice. D-Link is a registered trademark of D-Link Corporation|D-Link Systems, Inc. All other trademarks belong to their respective proprietors.
Copyright Statement
No part of this publication may be reproduced in any form or by any means or used to make any derivative such as translation, transformation, or adaptation without permission from D-Link Corporation|D-Link Systems Inc., as stipulated by the United States Copyright Act of 1976.
iv
Page 5
DGS-3212SR Switch CLI Reference
FCC Warning
This equipment has been tested and found to comply with the limits for a Class A digital device, pursuant to Part 15 of the FCC Rules. These limits are designed to provide reasonable protection against harmful interference when the equipment is operated in a commercial environment. This equipment generates, uses, and can radiate radio frequency energy and, if not installed and used in accordance with this user’s guide, may cause harmful interference to radio communications. Operation of this equipment in a residential area is likely to cause harmful interference in which case the user will be required to correct the interference at his own expense.
CE Mark Warning
This is a Class A product. In a domestic environment, this product may cause radio interference in which case the user may be required to take adequate measures.
VCCI Warning
v
Page 6
Table of Contents
Introduction ............................................................................................... 1
Using the Console CLI.............................................................................. 3
Command Syntax ..................................................................................... 7
Basic Switch Commands..........................................................................9
Switch Port Commands .......................................................................... 30
SNMP Commands..................................................................................35
Download|Upload Commands................................................................70
Network Monitoring Commands ............................................................. 73
MAC Notification ..................................................................................... 89
Spanning Tree Commands..................................................................... 96
Forwarding Database Commands........................................................ 105
Broadcast Storm Control Commands................................................... 115
QOS Commands................................................................................... 118
802.1X COMMANDS............................................................................127
Access Control List (ACL) Commands.................................................142
Traffic Segmentation............................................................................. 151
Stacking ................................................................................................ 154
Port Mirroring Commands..................................................................... 157
VLAN Commands.................................................................................163
Link Aggregation Commands ............................................................... 173
IP Interface Commands........................................................................180
Routing Table Commands....................................................................183
IGMP Snooping Commands................................................................. 187
Command History List........................................................................... 197
Technical Specifications ....................................................................... 202
Page 7
DGS-3212SR Switch CLI Reference
1
INTRODUCTION
The switch can be managed through the switch’s serial port, Telnet, or the Web­based management agent. The Command Line Interface (CLI) can be used to configure and manage the switch via the serial port or Telnet interfaces.
This manual provides a reference for all of the commands contained in the CLI. Configuration and management of the switch via the Web-based management agent is discussed in the User’s Guide.
Accessing the Switch via the Serial Port
The switch’s serial port’s default settings 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 is then connected to the switch’s serial port via an RS-232 DB-9 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.

Introduction

Figure 1-1. Initial Console screen.
There is no initial username or password. Just press the Enter key twice to display the CLI input cursor DGS-3212SR:4#. 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. You 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 from the initial boot console screen – shown below.
1
Page 8
DGS-3212SR Switch CLI Reference
Figure 1-2. Boot Screen
The IP interface named System on the switch can be assigned an IP address and subnet mask which can then be used to connect a management station to the switch’s Telnet or Web-based management agent.
The switch’s MAC address can also be found from the Web management program on the Switch Information (Basic Settings) window on the Configuration menu.
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:
Starting at the command line prompt, enter the commands 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, you 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.
Introduction
Figure 1-3. Assigning the Switch an IP Address
In the above example, the switch was assigned an IP address of 10.42.73.100 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 and the CLI or via the Web-based management agent using the above IP address to connect to the switch.
2
Page 9
DGS-3212SR Switch CLI Reference
2
USING THE CONSOLE CLI
The DGS-3212SR supports a console management interface 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 network management software 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 save command. The current configuration will then be retained in the switch’s NV-RAM, and reloaded when the switch is rebooted. If the switch is rebooted without using the save command, the last configuration saved to NV-RAM will be loaded.
VT-100 compatible
9,600 baud
8 data bits
No parity
One stop bit
No flow control
You can also access the same functions over a Telnet interface. Once you have set an IP address for your Switch, you 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 you have logged in, the console looks like this:
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 RS-232C serial cable.
Your terminal parameters will need to be set to:

Using the Console CLI

Figure 2-1. Initial Console Screen
Commands are entered at the command prompt, DGS-3212SR:4#.
3
Page 10
DGS-3212SR Switch CLI Reference
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.
Figure 2-2. The ? Command
The dir command has the same function as the ? command. When you enter a command without its required parameters, the CLI will prompt
you with a Next possible completions: message.
Using the Console CLI
Figure 2-3. Example Command Parameter Help
In this case, the command config account was entered with the parameter <username>. The CLI will then prompt you 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 addition, after typing any given command plus one space, you can see all of the next possible sub-commands, 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
Page 11
DGS-3212SR Switch CLI Reference
Figure 2-4. Using the Up Arrow to Re-enter a Command Figure 2-5. The Next Available Commands Prompt
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 previous command (config account) at the command prompt. Now the appropriate User name can be entered and the config account command re­executed.
All commands in the CLI function in this way. In addition, the syntax of the help prompts are the same as presented 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.
Using the Console CLI
The top-level commands consist of commands like 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 you enter the show command with no additional parameters, the CLI will then display all of the possible next parameters.
5
Page 12
DGS-3212SR Switch CLI Reference
Figure 2-6. Next possible completions: Show Command
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 the user accounts configured on the switch.
Using the Console CLI
6
Page 13
DGS-3212SR Switch CLI Reference
3
COMMAND SYNTAX
The following symbols are used to describe how command entries are made and values and arguments are specified in this manual. The online help contained in the CLI and available through the console interface uses the same syntax.
<angle brackets> Purpose Encloses a variable or value that must be
specified.
Syntax
Description In the above syntax example, you must type
Example Command
create ipif System ipaddress <network_address>
create ipif System followed by the network
address in the <network_address> space. Do not type the angle brackets.
create ipif System ipaddress
10.24.22.5/55.0.0.0
[square brackets]
Encloses a required value or set of required
Purpose
Syntax
Description
Example Command
| vertical bar Purpose Separates two or more mutually exclusive items
Syntax Description In the above syntax example, you must specify
Example Command
arguments. One or more values or arguments can be specified.
create account [admin|user]
In the above syntax example, you must specify either an admin or a user level account to be created. Do not type the square brackets.
create account admin
in a list one of which must be entered.
show snmp [community|trap receiver|detail]
either community, trap receiver, or detail. Do not type the backslash.
show snmp community

Command Syntax

7
Page 14
DGS-3212SR Switch CLI Reference
{braces} Purpose Encloses an optional value or set of optional
arguments.
Syntax config igmp [<ipif_name>|all] {version
<value>|query_interval <sec>|max_response_time <sec>| robustness_variable <value>|last_member_query_interval <value>|state [enable|disable]}
Description In the above syntax example, you must choose
to enter an IP interface name in the <ipif_name> space or all, but version <value>, query_interval <sec>, max_response_time <sec>, robustness_variable <value>, last_member_query_interval <value>, and state [enable|disable] are all optional arguments. You can specify any or all of the arguments contained by braces. Do not type the braces.
Example command
config igmp all version 2
Line Editing Key Usage
Delete
Deletes character under the cursor and then shifts the remaining characters in the line to the left.
Backspace
Deletes the character to the left of the cursor and shifts the remaining characters in the line to the left.
Left Arrow Up Arrow Down Arrow
Moves the cursor to the left. Displays the previous command Displays the next possible command list, one-
by-one.
Right Arrow Tab
Moves the cursor to the right. Shifts the cursor to the next field to the left.
Multiple Page Display Control Keys
Space CTRL+c
Displays the next page. Stops the display of remaining pages when
multiple pages are to be displayed.
ESC
Stops the display of remaining pages when multiple pages are to be displayed.
n p q
Displays the next page. Displays the previous page. Stops the display of remaining pages when
multiple pages are to be displayed.
r a
Refreshes the pages currently displaying. Displays the remaining pages without pausing
between pages.
Enter
Displays the next line or table entry.
Command Syntax
8
Page 15
DGS-3212SR Switch CLI Reference
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
create account [admin|user]
<username> config account <username> show account show session show switch show serial_port config serial_port baud_rate [9600|19200|38400|115200]
auto_logout [never|2_minutes|5_minutes
|10_minutes|15_minutes] enable clipaging disable clipaging enable telnet <tcp_port_number> disable telnet enable web <tcp_port_number> disable web save reboot reset {config|system}
Command Parameters
login logout
Each command is listed, in detail, in the following sections.

Basic Switch Commands

9
Page 16
DGS-3212SR Switch CLI Reference
create account
Purpose Used to create user accounts Syntax Description The create account command is used to create
Parameters Admin <username>
Restrictions Only Administrator-level users can issue this
create [admin|user] <username>
user accounts that consist of a username of 1 to 15 characters and a password of 0 to 15 characters. Up to 8 user accounts can be created.
User <username>
command. Usernames can be between 1 and 15
characters. Passwords can be between 0 and 15
characters.
Example Usage:
To create an administrator-level user account with the username “dlink”.
DGS-3212SR:4#create account admin dlink Command: create account admin dlink
Enter a case-sensitive new password:**** Enter the new password again for confirmation:**** Success. DGS-3212SR:4#
Basic Switch Commands
10
Page 17
DGS-3212SR Switch CLI Reference
config account
Purpose Used to configure user accounts Syntax Description The config account command configures a
Parameters <username> Restrictions Only Administrator-level users can issue this
config account <username>
user account that has been created using the create account command.
command. Usernames can be between 1 and 15
characters. Passwords can be between 0 15 characters.
Example Usage:
To configure the user password of “dlink” account:
DGS-3212SR:4#config account dlink Command: config account dlink
Enter a old password:**** Enter a case-sensitive new password:**** Enter the new password again for confirmation:**** Success.
DGS-3212SR:4#
Basic Switch Commands
11
Page 18
DGS-3212SR Switch CLI Reference
show account
Purpose Used to display user accounts Syntax Description Displays all user accounts created on the
Parameters None. Restrictions None.
show account
switch. Up to 8 user accounts can exist on the switch at one time.
Example Usage:
To display the accounts that have been created:
DGS-3212SR:4#show account Command: show account
Current Accounts: Username Access Level
--------------- -----------­ dlink Admin DGS-3212SR:4#
Basic Switch Commands
12
Page 19
DGS-3212SR Switch CLI Reference
delete account
Purpose Used to delete an existing user account Syntax Description The delete account command deletes a user
Parameters <username> Restrictions Only Administrator-level users can issue this
delete account <username>
account that has been created using the create account command.
command.
Example Usage:
To delete the user account “System”:
DGS-3212SR:4#delete account System Command: delete account System
Success.
DGS-3212SR:4#
Basic Switch Commands
13
Page 20
DGS-3212SR Switch CLI Reference
show session
Purpose Used to display a list of currently logged-in
users. Syntax Description This command displays a list of all the users
Parameters None Restrictions None.
show session
that are logged-in at the time the command is
issued.
Example Usage:
To display the way that the users logged in:
DGS-3212SR:4#show session
ID Login Time Live Time From Level Name
-- -------------------------- ------------ ------------ ----- --------­ 8 0000 days 00:05:54 0:17:16.2 Serial Port 4 Anonymous
Basic Switch Commands
14
Page 21
DGS-3212SR Switch CLI Reference
show serial_port
Purpose Used to display the current serial port settings. Syntax Description This command displays the current serial port
Parameters None. Restrictions None
show serial_port
settings.
Example Usage:
To display the serial port setting:
DGS-3212SR:4#show serial_port Command: show serial_port
Baud Rate : 9600 Data Bits : 8 Parity Bits : None Stop Bits : 1 Auto-Logout : 10 mins
DGS-3212SR:4#
Basic Switch Commands
15
Page 22
DGS-3212SR Switch CLI Reference
show switch
Purpose Used to display information about the switch. Syntax Description This command displays information about the
Parameters None. Restrictions None.
show switch
switch.
Example Usage:
To display the switch information:
DGS-3212SR:4#show switch Command: show switch
Device Type : DGS-3212SR Fast-Ethernet Switch Module Type : DES-332GS 1-port GBIC Gigabit Ethernet and 1 Stacking Port Unit ID : 1 MAC Address : 00-80-C8-12-35-40 IP Address : 10.1.1.33 (Manual) VLAN Name : default Subnet Mask : 255.0.0.0 Default Gateway : 0.0.0.0 Boot PROM Version : Build 1.00.005 Firmware Version : Build 3.00-B24 Hardware Version : 1A1 Device S|N : System Name : System Location : System Contact : Spanning Tree : Disabled GVRP : Disabled IGMP Snooping : Disabled RIP : Disabled DVMRP : Disabled PIM-DM : Disabled OSPF : Disabled TELNET : Enable (TCP 23) WEB : Enable (TCP 80) RMON : Disabled DGS-3212SR:4#
Basic Switch Commands
16
Page 23
DGS-3212SR Switch CLI Reference
show serial_port
Purpose Used to display the current serial port settings. Syntax Description This command displays the current serial port
Parameters None. Restrictions None
show serial_port
settings.
Example Usage:
To display the serial port setting:
DGS-3212SR:4#show serial_port Command: show serial_port
Baud Rate : 9600 Data Bits : 8 Parity Bits : None Stop Bits : 1 Auto-Logout : 10 mins
DGS-3212SR:4#
Basic Switch Commands
17
Page 24
DGS-3212SR Switch CLI Reference
config serial_port
Purpose Used to configure the serial port. Syntax
Description This command is used to configure the serial port’s
Parameters
Restrictions Only administrator-level users can issue this
config serial_port {baud_rate[9600|19200|38400|115200]|auto_logout [never|2_minutes|5_minutes|10_minutes| 15_minutes]}
baud rate and auto logout settings. [9600|19200|38400|115200] The serial bit rate that
will be used to communicate with the management host.
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.
command.
Example Usage:
To configure baud rate:
DGS-3212SR:4#config serial_port baud_rate 9600 Command: config serial_port baud_rate 9600
Success.
DGS-3212SR:4#
Basic Switch Commands
18
Page 25
DGS-3212SR Switch CLI Reference
enable clipaging
Purpose Used to pause the scrolling of the console
screen when the show command displays more
than one page. Syntax Description This command is used when issuing the show
Parameters None. Restrictions Only administrator-level users can issue this
enable clipaging
command will cause 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 enable.
command.
Example Usage:
To enable pausing of the screen display when show command output reaches the end of the page:
DGS-3212SR:4#enable clipaging Command: enable clipaging
Success.
DGS-3212SR:4#
Basic Switch Commands
19
Page 26
DGS-3212SR Switch CLI Reference
disable clipaging
Purpose Used to disable the pausing of the console
screen scrolling at the end of each page when
the show command would display more than
one screen of information. Syntax Description This command is used to disable the pausing of
Parameters None. Restrictions Only administrator-level users can issue this
disable clipaging
the console screen at the end of each page
when the show command would display more
than one screen of information.
command.
Example Usage:
To disable pausing of the screen display when show command output reaches the end of the page:
DGS-3212SR:4#disable clipaging Command: disable clipaging
Success.
DGS-3212SR:4#
Basic Switch Commands
20
Page 27
DGS-3212SR Switch CLI Reference
enable telnet
Purpose Used to enable communication with and
management of the switch using the Telnet
protocol. Syntax Description This command is used to enable the Telnet
Parameters
Restrictions Only administrator-level users can issue this
enable telnet <tcp_port_number>
protocol on the switch. The user can specify the
TCP or UDP port number the switch will use to
listen for Telnet requests.
<tcp_port_number> The TCP port number.
TCP ports are numbered between 1 and 65535.
The “well-known” TCP port for the Telnet
protocol is 23.
command.
Example Usage:
To enable Telnet and configure port number:
DGS-3212SR:4#enable telnet 23 Command: enable telnet 23
Success.
DGS-3212SR:4#
Basic Switch Commands
21
Page 28
DGS-3212SR Switch CLI Reference
disable telnet
Purpose Used to disable the Telnet protocol on the
switch. Syntax Description This command is used to disable the Telnet
Parameters None. Restrictions Only administrator-level users can issue this
disable telnet
protocol on the switch.
command.
Example Usage:
To disable the Telnet protocol on the switch:
DGS-3212SR:4#disable telnet Command: disable telnet
Success.
DGS-3212SR:4#
Basic Switch Commands
22
Page 29
DGS-3212SR Switch CLI Reference
enable web
Purpose Used to enable the HTTP-based management
software on the switch. Syntax Description This command is used to enable the Web-
Parameters
Restrictions Only administrator-level users can issue this
enable web <tcp_port_number>
based management software on the switch.
The user can specify the TCP port number the
switch will use to listen for Telnet requests.
<tcp_port_number> The TCP port number.
TCP ports are numbered between 1 and 65535.
The “well-known” port for the Web-based
management software is 80.
command.
Example Usage:
To enable HTTP and configure port number:
DGS-3212SR:4#enable web 80 Command: enable web 80
Success.
DGS-3212SR:4#
Basic Switch Commands
23
Page 30
DGS-3212SR Switch CLI Reference
disable web
Purpose Used to disable the HTTP-based management
software on the switch. Syntax Description This command disables the Web-based
Parameters None. Restrictions Only administrator-level users can issue this
disable web
management software on the switch.
command.
Example Usage:
To disable HTTP:
DGS-3212SR:4#disable web Command: disable web
Success.
DGS-3212SR:4#
Basic Switch Commands
24
Page 31
DGS-3212SR Switch CLI Reference
save
Purpose Used to save changes in the switch’s
configuration to non-volatile RAM. Syntax Description This command is used to enter the current
Parameters None. Restrictions Only administrator-level users can issue this
save
switch configuration into non-volatile RAM. The
saved switch configuration will be loaded into
the switch’s memory each time the switch is
restarted.
command.
Example Usage:
To save the switch’s current configuration to non-volatile RAM:
DGS-3212SR:4#save Command: save
Saving all settings to NV-RAM... 100% done. DGS-3212SR:4#
Basic Switch Commands
25
Page 32
DGS-3212SR Switch CLI Reference
reboot
Purpose Used to restart the switch. Syntax Description This command is used to restart the switch. Parameters None. Restrictions None.
reboot
Example Usage: To restart the switch:
DGS-3212SR:4#reboot Command: reboot Are you sure you want to proceed with the system reboot? (y|n) Please wait, the switch is rebooting...
Basic Switch Commands
26
Page 33
DGS-3212SR Switch CLI Reference
reset
Purpose Used to reset the switch to the factory default
settings. Syntax Description This command is used to restore the switch’s
Parameters
Restrictions Only administrator-level users can issue this
reset {[config|system]}
configuration to the default settings assigned from
the factory.
config If config is specified, all of the factory
default settings are restored. The switch will not
reboot. New user accounts information and IP
settings will need to be assigned.
system If system is specified all of the factory
default settings are restored on the switch. The
switch will reboot. This will clear the dynamic
entries in the Forwrding Data Base (FDB). New
user accounts information and IP settings will need
to be assigned.
If no parameter is specified, the switch’s current IP
address, user accounts, and the switch history log
are retained. All other parameters are restored to
their factory default settings. The switch will not
reboot.
command.
Example Usage:
To restore all of the switch’s parameters to their default values:
DGS-3212SR:4#reset config Command: reset config
Success.
DGS-3212SR:4#
Basic Switch Commands
27
Page 34
DGS-3212SR Switch CLI Reference
login
Purpose Used to log in a user to the switch’s console. Syntax Description This command is used to initiate the login
Parameters None. Restrictions None.
login
procedure. The user will be prompted for his
Username and Password.
Example Usage:
To initiate the login procedure:
DGS-3212SR:4#login Command: login
UserName:
Basic Switch Commands
28
Page 35
DGS-3212SR Switch CLI Reference
logout
Purpose Used to log out a user from the switch’s
console. Syntax Description This command terminates the current user’s
Parameters None. Restrictions None.
logout
session on the switch’s console.
Example Usage:
To terminate the current user’s console session:
DGS-3212SR:4#logout
Basic Switch Commands
29
Page 36
DGS-3212SR Switch CLI Reference
5
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>
speed [auto|10_half|10_full|100_half|100_full| 1000_half|1000_full] flow_control [enable|disable] learning [enable|disable] state [enable|disable]
show ports <portlist|all>
Each command is listed, in detail, in the following sections.

Switch Port Commands

30
Page 37
DGS-3212SR Switch CLI Reference
config ports
Purpose Used to configure the switch’s Ethernet port settings. Syntax
Description This command allows for the configuration of the
Parameters
Restrictions Only administrator-level users can issue this command.
config ports [<portlist|all>] {speed[auto|10_half|10_full|100_half|100_half|1000_f ull] learning [enable|disable] state [enable|disable]}
switch’s Ethernet ports. Only the ports listed in the <portlist> will be affected.
all Displays all ports on the switch. <portlist> Specifies a range of ports to be configured.
The port list is specified by listing the beginning port number and the highest port number of the range. The beginning and end of the port list range are separated by a dash. For example, 3 would specify port 3. 4 specifies port 4. 3-4 specifies all of the ports between port 3 and port 4 in numerical order.
auto Enables auto-negotiation for the specified range of ports.
[10|100|1000] Configures the speed in Mbps for the specified range of ports.
[half|full] Configures the specified range of ports as either full- or half-duplex.
flow_control [enable|disable] - Enables or disables the flow control on the specified range of ports.
learning [enable|disable] Enables or disables the MAC address learning on the specified range of ports.
state [enable|disable] Enables or disables the specified range of ports.
Example Usage:
To configure the speed of port 3 to be 10 Mbps, full duplex, learning and state enable:
DGS-3212SR:4#config ports 1-3 speed 10_full learning on state enable
Command: config ports 1-3 speed 10_full learning on state enable Success. DGS-3212SR:4#
Switch Port Commands
31
Page 38
DGS-3212SR Switch CLI Reference
config port_security
Purpose Syntax
Description
Parameters
Restrictions
Used to configure port lock settings. config port_security
<portlist>|all admin_state [enable|disaled] max_learning_addr <max_lock_no 0-10> lock_address_mode [Permanent|DeleteOnTimout|DeleteOnReset] This command allows for the configuration of the port lock security feature. Only the ports listed in the <portlist> are effected. all configure port lock for all ports on the switch. portlist specifies a range of ports to be configured. The port list is specified by listing the lowest switch number and the beginning port number on that switch, separated by a colon. Then highest switch number, and the highest port number of the range (also separeted by a colon) are specified. The beginning and end of the port list range are seperated by a dash. For example, 1:3 would specify switch number 1, port 3. 2:4 specifies switch number 2, port 4. 1:3-2:4 specifies all of the ports between switch 1, port 3 and switch 2, port 4 in numerical order. admin_state [enable|disaled] – enable or disable port lock for the listed ports. max_learning_addr <1-10> - use this to limit the number of MAC addresses dynamically listed in the FDB for the ports. lock_address_mode[Permenent|DeleteOnTimout|Delete OnReset] – delete FDB MAC address entries for the ports on timeout of the FDB (see Forwarding Database Commands). Specify DeleteOnReset to delete all FDB entries, including static entries upon system reset or reboot. Only administrator-level users can issue this command.
Example Usage:
To configure the port lock for ports 1:12 – 1:14 to delete the dynamic address table entries on timeout:
DGS-3212SR:4#config port_security ports 12-14 lock_address_mode DeleteOnTimeout
Command: config port_security ports 12-14 lock_address_mode DeleteOnTimeout
Success.
DGS-3212SR:4#
Switch Port Commands
32
Page 39
DGS-3212SR Switch CLI Reference
show ports
Purpose Used to display the current configuration of a
range of ports. Syntax Description This command is used to display the current
Parameters
Restrictions None.
show ports {<portlist>}
configuration of a range of ports.
<portlist> Specifies a range of ports to be
configured. The port list is specified by listing
the beginning port number and the highest port
number of the range. The beginning and end of
the port list range are separated by a dash. For
example, 3 would specify port 3. 4 specifies port
4. 3-4 specifies all of the ports between port 3
and port 4 − in numerical order.
Example Usage:
To display the configuration of the ports:
DGS-3212SR:4#show ports Command: show ports
Port Port Settings Connection Address State Speed|Duplex|FlowCtrl Learning
---- -------- --------------------- --------------------- -------­ 1 Enabled Auto|Disabled Link Down Enabled 2 Enabled Auto|Disabled Link Down Enabled 3 Enabled Auto|Disabled Link Down Enabled 4 Enabled Auto|Disabled Link Down Enabled 5 Enabled Auto|Disabled Link Down Enabled 6 Enabled Auto|Disabled Link Down Enabled 7 Enabled Auto|Disabled Link Down Enabled 8 Enabled Auto|Disabled Link Down Enabled 9 Enabled Auto|Disabled Link Down Enabled 10 Enabled Auto|Disabled Link Down Enabled 11 Enabled Auto|Disabled Link Down Enabled 12 Enabled Auto|Disabled Link Down Enabled 13 Enabled Auto|Disabled Link Down Enabled 14 Enabled Auto|Disabled 100M|Full|None Enabled 15 Enabled Auto|Disabled Link Down Enabled 16 Enabled Auto|Disabled Link Down Enabled 17 Enabled Auto|Disabled Link Down Enabled 18 Enabled Auto|Disabled Link Down Enabled 19 Enabled Auto|Disabled Link Down Enabled
20 Enabled Auto|Disabled Link Down Enabled CTRL+C ESC q Quit SPACE n Next Page p Previous Page r
Refresh
Switch Port Commands
33
Page 40
DGS-3212SR Switch CLI Reference
show port_security
Purpose Used to display the current portr lock
configuration. Syntax Description This command is used to display the current
Parameters
Restrictions None.
show port_security {<portlist>}
port lock configuration of a range of ports.
<portlist> specifies a range of ports to be
viewed. The port list is specified by listing the
lowest switch number and the beginning port
number on that switch, separated by a colon.
Then highest switch number, and the highest
port number of the range (also separeted by a
colon) are specified. The beginning and end of
the port list range are seperated by a dash. For
example, 1:3 would specify switch number 1,
port 3. 2:4 specifies switch number 2, port 4.
1:3-2:4 specifies all of the ports between switch
1, port 3 and switch 2, port 4 in numerical
order.
Example Usage:
To display the port lock configuration:
DGS-3212SR:4#show port_security Command: show port_security Port# Admin State Max. Learning Addr. Lock Address Mode
---- ----------- ------------------- ----------------­ 1 Disabled 1 DeleteOnReset 2 Disabled 1 DeleteOnReset 3 Disabled 1 DeleteOnReset 4 Disabled 1 DeleteOnReset 5 Disabled 1 DeleteOnReset 6 Disabled 1 DeleteOnReset 7 Enabled 10 DeleteOnReset 8 Disabled 1 DeleteOnReset 9 Disabled 1 DeleteOnReset 10 Disabled 1 DeleteOnReset 11 Disabled 1 DeleteOnReset 12 Disabled 1 DeleteOnReset 13 Disabled 1 DeleteOnReset 14 Disabled 1 DeleteOnReset 15 Disabled 1 DeleteOnReset 16 Disabled 1 DeleteOnReset 17 Disabled 1 DeleteOnReset 18 Disabled 1 DeleteOnReset 19 Disabled 1 DeleteOnReset 20 Disabled 1 DeleteOnReset CTRL+C ESC q Quit SPACE n Next Page p Previous Page r Refresh
Switch Port Commands
34
Page 41
DGS-3212SR Switch CLI Reference
[byp
6
SNMP COMMANDS
The network management commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table.
The DGS-3212SR supports the Simple Network Management Protocol (SNMP) versions 1, 2c, and 3. You can specifiy which version of the SNMP you want to use to monitor and control the switch. The three versions of SNMP vary in the level of security provided 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
Authentication Method
Description
Community String is used for authentication NoAuthNoPriv
Community String is used for authentication 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
Command Parameters
enable rmon disable rmon config snmp
community config snmp
<community_string> [readonly|readwrite]
<sw_contact>
system_contact config snmp
<sw_location>
system_location config snmp
<sw_name>
system_name enable snmp
traps disable snmp
traps enable snmp
authenticate traps
disable snmp authenticate traps
create
<ipaddr>
trusted_host show
<ipaddr>
trusted_host delete
<ipaddr>
trusted_host create snmp user <username 32> <groupname 32> {encrypted (1)
assword(1) auth[md5(2) <authpassword

SNMP Commands

35
Page 42
DGS-3212SR Switch CLI Reference
Command Parameters
8-16 > | sha(3) <auth_password 8-20 >] priv [none(1) | des(2) <priv_password 8-16> ]|
by_key(2) auth [md5(2) <auth_key 32-32>| sha(3) <auth_key 40-40>]
priv [none(1) |des(2) <priv_key 32-32> ]]} delete snmp user <username 32> show snmp user show snmp
groups 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 delete snmp
<community_string 32> view <view_name 32>
[read_only|read_write]
<community_string 32> community
show snmp
{<community_string 32>} community
config snmp
<snmp_engineID> engineID
show snmp engineID
create snmp group
<groupname 32> [v1|v2c|v3
[noauth_nopriv|auth_nopriv|auth_priv]]{read_vie
w <view_name 32> | write_view <view_name
32> |notify_view <view_name 32>} delete snmp
<groupname 32> group
Command Parameters
delete snmp user <username 32> show snmp user show snmp
groups 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 delete snmp
<community_string 32> view <view_name 32>
[read_only|read_write]
<community_string 32> community
show snmp
{<community_string 32>} community
config snmp
<snmp_engineID> engineID
show snmp engineID
create snmp group
<groupname 32> [v1|v2c|v3
[noauth_nopriv|auth_nopriv|auth_priv]]{read_vie
w <view_name 32> | write_view <view_name
32> |notify_view <view_name 32>} delete snmp
<groupname 32> group
SNMP Commands
36
Page 43
DGS-3212SR Switch CLI Reference
Command Parameters
create snmp host <ipaddr> [v1|v2c|v3 [noauth_nopriv | auth_nopriv
| auth_priv]] <auth_string 32> delete snmp host <ipaddr> show snmp host {<ipaddr>}
Each command is listed, in detail, in the following sections.
SNMP Commands
37
Page 44
DGS-3212SR Switch CLI Reference
config snmp community
Purpose Used to create an SNMP community string. Syntax config snmp community <community_string>
[readonly|readwrite]
Description This command is used to create an SNMP
community string on the switch that will be used to authenticate management stations that want to access the switch using SNMP management software.
Parameters
Restrictions Only administrator-level users can issue this
<community_string> An alpha-numeric string of up to 32 characters that will be used to authenticate management stations that want to access the switch’s SNMP agent.
readonly Allows the user using the above community string to have read only access to the switch’s SNMP agent. The default read only community string is public.
readwrite Allows the user using the above community string to have read and write access to the switch’s SNMP agent. The default read write community string is private.
command.
Example Usage:
To configure an SNMP community “System”:
DGS-3212SR:4#config snmp community System readwrite Command: config snmp community System readwrite
Success.
DGS-3212SR:4#
SNMP Commands
38
Page 45
DGS-3212SR Switch CLI Reference
config snmp system_name
Purpose Used to configure a name for the switch. Syntax config snmp system_name <sw_name> Description This command is used to give the switch an
alpha-numeric name of up to 128 characters.
Parameters
Restrictions Only administrator-level users can issue this
<sw_name> An alpha-numeric name for the switch of up to 128 characters.
command.
Example Usage:
To configure the switch name for “DES-3250”:
DGS-3212SR:4#config snmp system_name DES3250 Command: config snmp system_name DES3250
Success.
DGS-3212SR:4#
SNMP Commands
39
Page 46
DGS-3212SR Switch CLI Reference
config snmp system_location
Purpose Used to enter a description of the location of the
switch. Syntax config snmp system_location <sw_location> Description This command is used to enter a description of
the location of the switch. A maximum of 128
characters can be used. Parameters
Restrictions Only administrator-level users can issue this
<sw_location> − A description of the location of
the switch. A maximum of 128 characters can
be used.
command.
Example Usage:
To configure the switch location for “Taiwan”:
.
DGS-3212SR:4#config snmp system_location Taiwan Command: config snmp system_location Taiwan
Success.
DGS-3212SR:4#
SNMP Commands
40
Page 47
DGS-3212SR Switch CLI Reference
config snmp system_contact
Purpose Used to enter the name of a contact person who
is responsible for the switch. Syntax config snmp system_contact <sw_contact> Description 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
Restrictions Only administrator-level users can issue this
<sw_contact> − A maximum of 128 characters
used to identify a contact person who is
responsible for the switch.
command.
Example Usage:
To configure the switch contact to “ctsnow”:
.
DGS-3212SR:4#config snmp system_contact ctsnow Command: config snmp system_contact ctsnow
Success.
DGS-3212SR:4#
SNMP Commands
41
Page 48
DGS-3212SR Switch CLI Reference
enable rmon
Purpose Used to enable RMON on the switch. Syntax Description This command is used, in conjunction with the
Parameters None. Restrictions Only administrator-level users can issue this
enable rmon
disable RMON command below, to enable and
disable remote monitoring (RMON) on the
switch.
command.
Example Usage:
To enable RMON:
DGS-3212SR:4#enable rmon Command: enable rmon
Success.
DGS-3212SR:4#
SNMP Commands
42
Page 49
DGS-3212SR Switch CLI Reference
disable rmon
Purpose Used to disable RMON on the switch. Syntax Description This command is used, in conjunction with the
Parameters None. Restrictions Only administrator-level users can issue this
disable rmon
enable rmon command above, to enable and
disable remote monitoring (RMON) on the
switch.
command.
Example Usage: To disable RMON:
DGS-3212SR:4#disable rmon Command: disable rmon
Success.
DGS-3212SR:4#
SNMP Commands
43
Page 50
DGS-3212SR Switch CLI Reference
create trusted_host
Purpose Used to create trusted hosts. Syntax Description This command is used to create trusted hosts. A
Parameters Restrictions Only administrator-level users can issue this
create trusted_host <ipaddr>
trusted host is a recipient of SNMP, Web, and
Telnet messages generated by the switch’s
SNMP agent.
<ipaddr> The IP address of the trusted host.
command.
Example Usage:
To create a trusted host:
DGS-3212SR:4#create trusted_host Command: create trusted_host 10.1.1.1
Success.
DGS-3212SR:4#
SNMP Commands
44
Page 51
DGS-3212SR Switch CLI Reference
show trusted_host
Purpose Used to display a list of trusted hosts entered on
the switch using the create trusted_host
command above. Syntax Description This command is used to display a list of trusted
Parameters None. Restrictions None.
show trusted_host
hosts entered on the switch using the create
trusted_host command above.
Example Usage:
To display the list of trusted hosts:
DGS-3212SR:4#show trusted_host Command: show trusted_host
Management Stations IP Address:
-------------------------
10.1.1.1 Total Entries: 1 DGS-3212SR:4#
SNMP Commands
45
Page 52
DGS-3212SR Switch CLI Reference
delete trusted_host
Purpose Used to delete a trusted host entry made using
the create trusted_host command above. Syntax Description This command is used to delete a trusted host
Parameters Restrictions Only administrator-level users can issue this
delete trusted _host <ipaddr>
entry made using the create trusted_host
command above.
<ipaddr> The IP address of the trusted host.
command.
Example Usage:
To delete a trusted host with an IP address 10.48.74.121:
DGS-3212SR:4#delete trusted_host 10.48.74.121 Command: delete trusted_host 10.48.74.121
Success.
DGS-3212SR:4#
SNMP Commands
46
Page 53
DGS-3212SR Switch CLI Reference
enable snmp traps
Purpose Used to enable SNMP trap support. Syntax Description This command is used to enable SNMP trap
Parameters None. Restrictions Only administrator-level users can issue this
enable snmp traps
support on the switch.
command.
Example Usage:
To turn on SNMP trap support:
DGS-3212SR:4#enable snmp traps Command: enable snmp traps
Success.
DGS-3212SR:4#
SNMP Commands
47
Page 54
DGS-3212SR Switch CLI Reference
disable snmp traps
Purpose Used to disable SNMP trap support on the
switch. Syntax Description This command is used to disable SNMP trap
Parameters None. Restrictions Only administrator-level users can issue this
enable snmp traps
support on the switch.
command.
Example Usage:
To prevent SNMP traps from being sent from the switch:
DGS-3212SR:4#disable snmp traps Command: disable snmp traps
Success.
DGS-3212SR:4#
SNMP Commands
48
Page 55
DGS-3212SR Switch CLI Reference
enable snmp authenticate traps
Purpose Used to enable SNMP authentication trap
support. Syntax Description This command is used to enable SNMP
Parameters None. Restrictions Only administrator-level users can issue this
enable snmp authenticate traps
authentication trap support on the switch.
command.
Example Usage:
To turn on SNMP authentication trap support:
DGS-3212SR:4#enable snmp authenticate traps Command: enable snmp authenticate traps
Success.
DGS-3212SR:4#
SNMP Commands
49
Page 56
DGS-3212SR Switch CLI Reference
disable snmp authenticate traps
Purpose Used to disable SNMP authentication trap
support. Syntax Description This command is used to disable SNMP
Parameters None. Restrictions Only administrator-level users can issue this
disable snmp authenticate traps
authentication support on the switch.
command.
Example Usage:
To turn off SNMP authentication trap support:
DGS-3212SR:4#disable snmp authenticate traps Command: disable snmp authenticate traps
Success.
DGS-3212SR:4#
SNMP Commands
50
Page 57
DGS-3212SR Switch CLI Reference
create snmp user
Purpose Used to create a new SNMP user and adds the
user to an SNMP group that is also created by
this command. Syntax
Description The create snmp user command creates a new
Parameters
create snmp user <username 32>
<groupname 32> {encrypted (1)
[by_password(1) auth[md5(2)
<auth_password 8-16 > | sha(3)
<auth_password 8-20 >]priv [none(1) | des(2)
<priv_password 8-16> ]| by_key(2) auth
[md5(2) <auth_key 32-32>| sha(3) <auth_key
40-40>]priv [none(1) |des(2) <priv_key 32-
32> ]]}
SNMP user and adds the user to an SNMP
group that is also created by this command.
<username 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 – Specifies that the password will be
in an encrypted format.
by_password – Indicate input password for
authentication and privacy.
by_key – Indicate input key for authentication
and privacy.
auth – Initiates an authentication level setting
session. The options are MD5 and SHA.
md5 – The HMAC-MD5-96 authentication level.
sha – The HMAC-SHA-96 authentication level.
<auth_password 8-16> An alphanumeric sting of between 8 and 20 characters that will be used to authorize the agent to receive packets for the host.
<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.
<auth_key> – An authentication key used by MD5 or SHA1, it is hex string type.
<priv_key> – A privacy key used by DES, it is hex string type.
Restrictions Only administrator-level users can issue this
command.
Example Usage:
To create an SNMP user on the switch:
DGS-3212SR:4#create snmp user dlink default encrypted by_password auth md5 auth_password none
Command: create snmp user dlink default encrypted by_password auth md5 auth_password none
Success.
DGS-3212SR:4#
SNMP Commands
51
Page 58
DGS-3212SR Switch CLI Reference
delete snmp user
Purpose Used to remove an SNMP user from an SNMP
group and to delete the associated SNMP
group. Syntax Description The delete snmp user command removes an
Parameters
Restrictions Only administrator-level users can issue this
delete snmp user <username 32>
SNMP user from its SNMP group and then
deletes the associated SNMP group.
<username 32> An alphanumeric string of up
to 32 characters that identifies the SNMP user
that will be deleted.
command.
Example Usage:
To delete a previously ent ered SNMP user on the switch:
DGS-3212SR:4#delete snmp user dlink Command: delete snmp user dlink
Success.
DGS-3212SR:4#
SNMP Commands
52
Page 59
DGS-3212SR Switch CLI Reference
show snmp user
Purpose Used to display information about each SNMP
username in the SNMP group username table. Syntax Description The show snmp user command displays
Parameters None. Restrictions Only administrator-level users can issue this
show snmp user
information about each SNMP username in the
SNMP group username table.
command.
Example Usage:
To display the SNMP users currently configured on the switch:
DGS-3212SR:4#show snmp user Command: show snmp user
Username Group Name Ver Auth Priv
------------------------------ ------------------- ------- -------- -----------­ initial initial V3 None None
Total Entries: 1
DGS-3212SR:4#
SNMP Commands
53
Page 60
DGS-3212SR Switch CLI Reference
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
is also displayed. Syntax Description The show snmp groups command displays the
Parameters None. Restrictions None.
show snmp groups
group-names of SNMP groups currently
configured on the switch. The security model,
level, and status of each group are also
displayed.
Example Usage:
To display the currently configured SNMP groups on the switch:
DGS-3212SR:4#show snmp groups Command: show snmp groups Vacm Access Table Settings
Group Name : initial ReadView Name : restricted WriteView Name : Notify View Name : restricted Securiy Model : SNMPv3 Securiy Level : NoAuthNoPriv
Group Name : ReadGroup ReadView Name : CommunityView WriteView Name : Notify View Name : CommunityView Securiy Model : SNMPv1 Securiy Level : NoAuthNoPriv Total Entries: 2 DGS-3212SR:4#
SNMP Commands
54
Page 61
DGS-3212SR Switch CLI Reference
create snmp view
Purpose Used to assign views to community strings to
limit which MIB objects and SNMP manager can
access. Syntax
Description The create snmp view assigns views to
Parameters
Restrictions Only administrator-level users can issue this
create snmp view <view_name 32> <oid>
view_type [included|excluded]
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.
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.
command.
Example Usage:
To create an SNMP view:
DGS-3212SR:4#create snmp view dlinkview 1.3.6 view_type included
Command: create snmp view dlinkview 1.3.6 view_type included
Success.
DGS-3212SR:4#
SNMP Commands
55
Page 62
DGS-3212SR Switch CLI Reference
delete snmp view
Purpose Used to remove an SNMP view entry previously
created on the switch. Syntax
Description The delete snmp view command is used to
Parameters
Restrictions Only administrator-level users can issue this
delete snmp view <view_name 32>
[all|<oid>]
remove an SNMP view previously created on
the switch.
<view_name 32> An alphanumeric string of
up to 32 characters that identifies the SNMP
view 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.
command.
Example Usage:
To delete a previously configured SNMP view from the switch:
DGS-3212SR:4#delete snmp view dlinkview Command: delete snmp view dlinkview
Success.
DGS-3212SR:4#
SNMP Commands
56
Page 63
DGS-3212SR Switch CLI Reference
show snmp view
Purpose Used to display an SNMP view previously
created on the switch. Syntax Description The show snmp view command displays an
Parameters
Restrictions None.
show snmp view {<view_name 32>}
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.
Example Usage:
To show SNMP view:
DGS-3212SR:4#show snmp view Command: show snmp view
Vacm View Table Settings View Name Subtree View Type
-------------------- ------------------------- ---------­ ReadView 1 Included WriteView 1 Included NotifyView 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 .3.6.1.6.3.1 Included
Total Entries: 11
DGS-3212SR:4#
SNMP Commands
57
Page 64
DGS-3212SR Switch CLI Reference
create snmp community
Purpose 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 Access List of IP addresses of SNMP
managers that are permitted to use the
community string to gain access to the switch’s
SNMP agent.
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. Syntax
Description The create snmp community command is used
Parameters
create snmp community <community_string
32> view <view_name 32>
[read_only|read_write]
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_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 users can issue this
command.
Example Usage:
To create the SNMP community string “dlink:”
DGS-3212SR:4#create snmp community dlink view ReadView read_write
Command: create snmp community dlink view ReadView read_write
Success.
SNMP Commands
58
Page 65
DGS-3212SR Switch CLI Reference
delete snmp community
Purpose Used to remove a specific SNMP community
string from the switch. Syntax
Description The delete snmp community command is used
Parameters
Restrictions Only administrator-level users can issue this
delete snmp community <community_string
32>
to remove a previously defined SNMP
community string from the switch.
<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.
command.
Example Usage:
To delete the SNMP community string “dlink:”
DGS-3212SR:4#delete snmp community dlink Command: delete snmp community dlink
Success.
DGS-3212SR:4#
SNMP Commands
59
Page 66
DGS-3212SR Switch CLI Reference
show snmp community
Purpose Used to display SNMP community strings
configured on the switch. Syntax
Description The show snmp community command is used to
Parameters
Restrictions None.
show snmp community {<community_string
32>}
display SNMP community strings that are
configured on the switch.
<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.
Example Usage:
To display the currently entered SNMP community strings:
DGS-3212SR:4#show snmp community Command: show snmp community
SNMP Community Table
Community Name View Name Access Right
-------------------------------- -------------------------------- -----------­ dlink ReadView read_write private CommunityView read_write public CommunityView read_only
Total Entries: 3
SNMP Commands
60
Page 67
DGS-3212SR Switch CLI Reference
config snmp engineID
Purpose Used to configure a name for the SNMP engine
on the switch. Syntax Description The config snmp engineID command configures
Parameters
Restrictions Only administrator-level users can issue this
config snmp engineID <snmp_engineID>
a name for the SNMP engine on the switch.
<snmp_engineID> An alphanumeric string
that will be used to identify the SNMP engine on
the switch.
command.
Example Usage:
To give the SNMP agent on the switch the name “0035636666:”
DGS-3212SR:4#config snmp 0035636666 Command: config snmp engineID 0035636666
Success.
DGS-3212SR:4#
SNMP Commands
61
Page 68
DGS-3212SR Switch CLI Reference
show snmp engineID
Purpose Used to display the identification of the SNMP
engine on the switch. Syntax Description The show snmp engineID command displays
Parameters None. Restrictions None.
show snmp engineID
the identification of the SNMP engine on the
switch.
Example Usage:
To display the current name of the SNMP engine on the switch:
DGS-3212SR:4#show snmp engineID Command: show snmp engineID
SNMP Engine ID : 0035636666
DGS-3212SR:4#
SNMP Commands
62
Page 69
DGS-3212SR Switch CLI Reference
create snmp group
Purpose Used to create a new SNMP group, or a table
that maps SNMP users to SNMP views. Syntax
Description The create snmp group command creates a
Parameters
create snmp group <groupname 32>
[v1|v2c|v3
[noauth_nopriv|auth_nopriv|auth_priv]]
{read_view <view_name 32>|notify_view
<view_name 32>|notify_view <view_name
32>}
new SNMP group, or a table that maps SNMP
users to SNMP views.
<groupname 32> − An alphanumeric name of
up to 32 characters that will identify the SNMP
group the new SNMP user will be associated
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 network
management strategies. It includes
improvements in the Structure of Management
Information (SMI) and adds some security
features.
v3 – Specifies that the SNMP version 3 will be
used. SNMP 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 in transit. Authentication determines that an SNMP
message is from a valid source. Encryption scrambles the contents of
messages to prevent it being seen 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 swtich and a remote SNMP manger will be encrypted.
read_view – Specifies that the SNMP group being created can request SNMP messages.
<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.
notify_view Specifies that the SNMP group being created can recieve SNMP trap messages generated by the switch’s SNMP agent.
Restrictions Only administrator-level users can issue this
command.
Example Usage:
SNMP Commands
63
Page 70
DGS-3212SR Switch CLI Reference
To create an SNMP group named “sg1:”
DGS-3212SR:4#create snmp group sg1 v3 noauth_nopriv read_view v1 write_view v1 no
tify_view v1 Command: create snmp group sg1 v3 noauth_nopriv read_view
v1 write_view v1 notif y_view v1
Success.
DGS-3212SR:4#
SNMP Commands
64
Page 71
DGS-3212SR Switch CLI Reference
delete snmp group
Purpose Used to remove an SNMP group from the
switch. Syntax Description The delete snmp group command is used to
Parameters
Restrictions Only administrator-level users can issue this
delete snmp group <groupname 32>
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.
command.
Example Usage:
To delete the SNMP group named “sg1”.
DGS-3212SR:4#delete snmp group sg1 Command: delete snmp group sg1
Success.
DGS-3212SR:4#
SNMP Commands
65
Page 72
DGS-3212SR Switch CLI Reference
create snmp host
Purpose Used to create a recipient of SNMP traps
generated by the switch’s SNMP agent. Syntax
Description The create snmp host command creates a
Parameters
create snmp host <ipaddr> [v1|v2c|v3
[noauth_nopriv|auth_nopriv|auth_priv]
<auth_string 32>]
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 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 network
management strategies. It includes
improvements in the Structure of Management
Information (SMI) and adds some security
features.
v3 – Specifies that the SNMP version 3 will be
used. SNMP 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 in transit.
Authentication determines that an SNMP
message is from a valid source.
Encryption scrambles the contents of messages to prevent it being seen 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 swtich and a remote SNMP manger will be encrypted.
<auth_sting 32> An alphanumeric string used to authorize a remote SNMP manager to access the switch’s SNMP agent.
Restrictions Only administrator-level users can issue this
command.
Example Usage:
To create an SNMP host to receive SNMP messages:
DGS-3212SR:4#create snmp host 10.48.74.100 v3 auth_priv public
Command: create snmp host 10.48.74.100 v3 auth_priv public
Success.
DGS-3212SR:4#
SNMP Commands
66
Page 73
DGS-3212SR Switch CLI Reference
SNMP Commands
67
Page 74
DGS-3212SR Switch CLI Reference
delete snmp host
Purpose Used to remove a recipient of SNMP traps
generated by the switch’s SNMP agent. Syntax Description The delete snmp host command deletes a
Parameters
Restrictions Only administrator-level users can issue this
delete snmp host <ipaddr>
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.
command.
Example Usage:
To delete an SNMP host entry:
DGS-3212SR:4#delete snmp host 10.48.74.100 Command: delete snmp host 10.48.74.100
Success.
DGS-3212SR:4#
SNMP Commands
68
Page 75
DGS-3212SR Switch CLI Reference
show snmp host
Purpose Used to display the recipient of SNMP traps
generated by the switch’s SNMP agent. Syntax Description The show snmp host command is used to
Parameters
Restrictions None.
show snmp host {<ipaddr>}
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.
Example Usage:
To display the currently configured SNMP hosts on the switch:
DGS-3212SR:4#show snmp host Command: show snmp host
SNMP Host Table Host IP Address SNMP Version Community Name
--------------- --------------------- ------------------------------
10.48.76.23 V2c private
10.48.74.100 V3 authpriv public
Total Entries: 2
SNMP Commands
69
Page 76
DGS-3212SR Switch CLI Reference
7
DOWNLOAD|UPLOAD COMMANDS
The download|upload commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table.
Command
download firmware <ipaddr>
upload
Each command is listed, in detail, in the following sections.
configuration
Parameters
<path_filename> unit [all|<unitid>] configuration <ipaddr> <path_filename> {increment}
log <ipaddr> <path_filename>

Download|Upload Commands

70
Page 77
DGS-3212SR Switch CLI Reference
download
Purpose Used to download and install new firmware or a
switch configuration file from a TFTP server. Syntax
Description This command is used to download a new firmware
Parameters
Restrictions The TFTP server must be on the same IP subnet
download [ firmware <ipaddr> <path_filename>
{unit [all|<unitid>]}|configuration <ipaddr>
<path_filename> {increment}]
or a switch configuration file from a TFTP server.
firmware Download and install new firmware on
the switch from a TFTP server.
configuration Download a switch configuration file
from a TFTP server.
<ipaddr> − The IP 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:\3326S.had.
unit [all|<unitid>] all specifies all units (switches),
<unitid> is the unit id of the switch that will receive
the download.
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.
as the switch. Only administrator-level users can
issue this command.
Example Usage:
DGS-3212SR:4#download configuration 10.48.74.121 c:\cfg\setting.txt
Command: download configuration 10.48.74.121 c:\cfg\setting.txt
Connecting to server................... Done.
Download configuration............. Done.
DGS-3212SR:4#
Download|Upload Commands
71
Page 78
DGS-3212SR Switch CLI Reference
upload
Purpose Used to upload the current switch settings or the
switch history log to a TFTP server. Syntax
Description This command is used to upload either the switch’s
Parameters
Restrictions The TFTP server must be on the same IP subnet
upload [configuration|log] <ipaddr>
<path_filename>
current settings or the switch’s history log to a
TFTP server.
configuration Specifies that the switch’s current
settings will be uploaded to the TFTP server.
log − 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.
<path_filename> − Specifies the location of the
switch configuration file on the TFTP server. This
file will be replaced by the uploaded file from the
switch.
as the switch. Only administrator-level users can
issue this command.
Example Usage:
DGS-3212SR:4#upload configuration 10.48.74.121 c:\cfg\log.txt Command: upload configuration 10.48.74.121 c:\cfg\log.txt
Connecting to server................... Done.
Upload configuration...................Done.
DGS-3212SR:4#
Download|Upload Commands
72
Page 79
DGS-3212SR Switch CLI Reference
[
]
[
]
8
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 utilitzation clear counters ports <portlist> clear log show log index <value> enable syslog disable syslog show syslog create syslog host all
<index 1-4> severity informational warning all facility local0 local1 local2 local3 local4
Command Parameters
local5 local6 local7 udp_port <int> ipaddress <ipaddr>
enable|disable
state
config syslog host all
<index 1-4> severity informational warning all facility local0 local1 local2 local3 local4 local5 local6 local7 udp_port <int> ipaddress <ipaddr>
enable|disable
state
delete syslog host <index 1-4>
all
show syslog host <index 1-4>
Each command is listed, in detail, in the following sections.

Network Monitoring Commands

73
Page 80
DGS-3212SR Switch CLI Reference
show packet ports
Purpose Used to display statistics about the packets sent
and received by the switch. Syntax Description This command is used to display statistics about
Parameters
Restrictions None.
show packet ports <portlist>
packets sent and received by ports specified in
the port list.
<portlist> specifies a range of ports to be
configured. The port list is specified by listing
the lowest switch number and the beginning
port number on that switch, separated by a
colon. Then highest switch number, and the
highest port number of the range (also
separeted by a colon) are specified. The
beginning and end of the port list range are
seperated by a dash. For example, 1:3 would
specify switch number 1, port 3. 2:4 specifies
switch number 2, port 4. 1:3-2:4 specifies all of
the ports between switch 1, port 3 and switch 2,
port 4 in numerical order.
Example Usage:
To display the packets analysis for port 14:
DGS-3212SR:4#show packet port 14 Command: show packet ports 14 Port number : 14 Frame Size Frame Counts Frames|sec Frame Type Total
Total|sec
------------ ------------ ---------- ---------- --------- --------­ 64 254290 52 RX Bytes 41286744 17290 65-127 38129 12 RX Frames 359507 86 128-255 51878 13 256-511 8058 3 TX Bytes 72755 0 512-1023 2046 0 TX Frames 335 0 1024-1518 5441 6
Unicast RX 2245 0 Multicast RX 57480 20 Broadcast RX 299782 66
Network Monitoring Commands
74
Page 81
DGS-3212SR Switch CLI Reference
show error ports
Purpose Used to display the error statistics for a range of
ports. Syntax Description This command will display all of the packet error
Parameters
Restrictions None.
show error ports <portlist>
statistics collected and logged by the swtich for
a given port list.
<portlist> Specifies a range of ports to be
configured. The port list is specified by listing
the lowest switch number and the beginning
port number on that switch, separated by a
colon. Then highest switch number, and the
highest port number of the range (also
separated by a colon) are specified. The
beginning and end of the port list range are
separated by a dash. For example, 1:3 would
specify switch number 1, port 3. 2:4 specifies
switch number 2, port 4. 1:3-2:4 specifies all of
the ports between switch 1, port 3 and switch 2,
port 4 in numerical order.
Example Usage:
To display the error statistics of the port 3 of module 1:
DGS-3212SR:4#show errors port 1:3
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 0 Collision 0
Network Monitoring Commands
75
Page 82
DGS-3212SR Switch CLI Reference
show utilization
Purpose Used to display real-time port utilization
statistics. Syntax Description This command will display the real-time port
Parameters None. Restrictions None.
show utilization
utilization statistics for the switch.
Example Usage:
To display the port utilization statistics:
DGS-3212SR:4#show utilization Port TX|sec RX|sec Util Port TX|sec RX|sec Util
---- ---------- ---------- ---- ---- ---------- ---------- ---­ 1:1 0 0 0 1:22 0 0 0 1:2 0 0 0 1:23 0 0 0 1:3 0 0 0 1:24 0 0 0 1:4 0 0 0 1:25 0 0 0 1:5 0 0 0 1:26 19 49 1 1:6 0 0 0 2:1 0 0 0 1:7 0 0 0 2:2 0 0 0 1:8 0 0 0 2:3 0 0 0 1:9 0 0 0 2:4 0 0 0 1:10 0 0 0 2:5 0 0 0 1:11 0 0 0 2:6 0 0 0 1:12 0 0 0 2:7 0 30 1 1:13 0 0 0 2:8 0 0 0 1:14 0 0 0 2:9 30 0 1 1:15 0 0 0 2:10 0 0 0 1:16 0 0 0 2:11 0 0 0 1:17 0 0 0 2:12 0 0 0 1:18 0 0 0 2:13 0 0 0 1:19 0 0 0 2:14 0 0 0 1:20 0 0 0 2:15 0 0 0 1:21 0 0 0 2:16 0 0 0
Network Monitoring Commands
76
Page 83
DGS-3212SR Switch CLI Reference
clear counters
Purpose Used to clear the switch’s statistics counters. Syntax Description This command will clear the counters used by
Parameters
Restrictions Only administrator-level users can issue this
clear counters {ports <portlist>}
the switch to compile statistics.
<portlist> Specifies a range of ports to be
configured. The port list is specified by listing
the lowest switch number and the beginning
port number on that switch, separated by a
colon. Then highest switch number, and the
highest port number of the range (also
separated by a colon) are specified. The
beginning and end of the port list range are
separated by a dash. For example, 1:3 would
specify switch number 1, port 3. 2:4 specifies
switch number 2, port 4. 1:3-2:4 specifies all of
the ports between switch 1, port 3 and switch 2,
port 4 in numerical order.
command.
Example Usage:
To clear the counters:
DGS-3212SR:4#clear counters ports 2:7-2:9 Command: clear counters ports 2:7-2:9
Success.
Network Monitoring Commands
77
Page 84
DGS-3212SR Switch CLI Reference
clear log
Purpose Used to clear the switch’s history log. Syntax Description This command will clear the switch’s history log. Parameters None. Restrictions Only administrator-level users can issue this
clear log
command.
Example Usage:
To clear the log information:
DGS-3212SR:4#clear log Command: clear log
Success.
DGS-3212SR:4#
Network Monitoring Commands
78
Page 85
DGS-3212SR Switch CLI Reference
show log
Purpose Used to display the switch history log. Syntax Description This command will display the contents of the
Parameters
Restrictions None.
show log {index <value>}
switch’s history log.
index <value> The show log command will
display the history log until the log number
reaches this value.
Example Usage:
To display the switch history log:
DGS-3212SR:4#show log Index Time Log Text
----- ---------- --------------------------------------------------------------­ 4 000d00h50m Unit 1, Successful login through Console
(Username: Anonymous) 3 000d00h50m Unit 1, Logout through Console (Username:
Anonymous) 2 000d00h49m Unit 1, Successful login through Console
(Username: Anonymous) 1 000d00h49m Unit 1, Logout through Console (Username:
Anonymous)
DGS-3212SR:4#
Network Monitoring Commands
79
Page 86
DGS-3212SR Switch CLI Reference
enable syslog
Purpose Used to enable the system log to be sent to a
remote host. Syntax Description
Parameters None. Restrictions Only administrator-level users can issue this
enable syslog
The enable syslog command enables the
system log to be sent to a remote host.
command.
Example Usage:
To enable the syslog function on the switch:
DGS-3212SR:4#enable syslog Command: enable syslog
Success.
DGS-3212SR:4#
Network Monitoring Commands
80
Page 87
DGS-3212SR Switch CLI Reference
disable syslog
Purpose Used to enable the system log to be sent to a
remote host. Syntax Description
Parameters None. Restrictions Only administrator-level users can issue this
disable syslog
The disable syslog command disables the
system log to be sent to a remote host.
command.
Example Usage:
To disable the syslog function on the swtich:
DGS-3212SR:4#disable syslog Command: disable syslog
Success.
DGS-3212SR:4#
Network Monitoring Commands
81
Page 88
DGS-3212SR Switch CLI Reference
show syslog
Purpose Used to display the syslog protocol status as
enable or disable. Syntax show syslog Description
Parameters None. Restrictions None.
The show syslog command displays the syslog
status as enable or disable.
Example Usage:
To display the current status of the syslog function:
DGS-3212SR:4#show syslog Command: show syslog
Syslog Global State: Enable
DGS-3212SR:4#
Network Monitoring Commands
82
Page 89
DGS-3212SR Switch CLI Reference
create syslog host
Purpose Used to create a new syslog host. Syntax create syslog host [all|<index 1-4>] {severity
[informational|warning|all]| facility[local0|local1|local2|local3| local4|local5|local6|local7]|udp_port<int>| ipaddress <ipaddr>| state[enable|disable]
Description
Parameters
Parameters
Network Monitoring Commands
The create syslog host command is used to create a new syslog host.
all − Specifies that the command will be applied to all hosts.
<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
informational Specifies that informational messages will be sent to the remote host. This corresponds to number 6 from the list above.
warning Specifies that warning messages will be
sent to the remote host. This corresponds to number 4 from the list above.
all Specifies that all of the currently supported syslog messages that are generated by the switch will be sent to the remote host.
facility Some of the operating system daemons and processes have been assigned Facility values. Processes and daemons that have not been explicitly assigned a Facility may use any of the"local use" facilities or they may use the "user-level" Facility. Those Facilities that have been designated are shown in the following: Bold font means the facility values the switch supports now.
Numerical Facility Code 0 kernel messages 1 user-level messages 2 mail system 3 system daemons 4 security|authorization messages 5 messages generated internally by syslog 6 line printer subsystem 7 network news subsystem 8 UUCP subsystem 9 clock daemon
Parameters 10 security|authorization messages
11 FTP daemon 12 NTP subsystem 13 log audit
83
Page 90
DGS-3212SR Switch CLI Reference
create syslog host
14 log alert 15 clock daemon 16 local use 0 (local0) 17 local use 1 (local1) 18 local use 2 (local2) 19 local use 3 (local3) 20 local use 4 (local4) 21 local use 5 (local5) 22 local use 6 (local6) 23 local use 7 (local7) local0 Specifies that local use 0 messages will be
sent to the remote host. This corresponds to number 16 from the list above.
local1 Specifies that local use 1 messages will be sent to the remote host. This corresponds to number 17 from the list above.
local2 Specifies that local use 2 messages will be sent to the remote host. This corresponds to number 18 from the list above.
local3 Specifies that local use 3 messages will be sent to the remote host. This corresponds to number 19 from the list above.
local4 Specifies that local use 4 messages will be sent to the remote host. This corresponds to number 20 from the list above.
local5 Specifies that local use 5 messages will be sent to the remote host. This corresponds to number 21 from the list above.
local6 Specifies that local use 6 messages will be
sent to the remote host. This corresponds to number 22 from the list above.
local7 Specifies that local use 7 messages will be sent to the remote host. This corresponds to number 23 from the list above.
udp_port <int> − Specifies the UDP port number that the syslog protocol will use to send messages to the remote host. UDP ports available for this purpose are port 514 or any port in the range 6000-65535.
ipaddress <ipaddr> Specifies the IP address of the remote host where syslog messages will be sent.
state [enable|disable] Allows the sending of syslog messages to the remote host, specified above, to be enabled and disabled.
Restrictions Only administrator-level users can issue this
command.
Example Usage:
To create syslog host:
DGS-3212SR:4#create syslog host 1 severity all facility local0 Command: create syslog host 1 severity all facility local0 Success. DGS-3212SR:4#
Network Monitoring Commands
84
Page 91
DGS-3212SR Switch CLI Reference
config syslog host
Purpose
Syntax
Description
Parameters
Parameters
Used to configure the syslog protocol to send system log data to a remote host.
config syslog host [all|<index 1-4>] {severity [informational|warning|all]| facility[local0|local1|local2|local3| local4|local5|local6|local7]|udp_port<int>| ipaddress <ipaddr>| state[enable|disable]
The config syslog host command is used to configure the syslog protocol to send system log information to a remote host.
all − Specifies that the command will be applied to all hosts.
<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
informational Specifies that informational messages will be sent to the remote host. This corresponds to number 6 from the list above.
warning Specifies that warning messages will be sent to the remote host. This corresponds to number 4 from the list above.
all Specifies that all of the currently supported syslog messages that are generated by the switch will be sent to the remote host.
facility Some of the operating system daemons and processes have been assigned Facility values. Processes and daemons that have not been explicitly assigned a Facility may use any of the"local use" facilities or they may use the "user-level" Facility. Those Facilities that have been designated are shown in the following: Bold font means the facility values the switch supports now.
Numerical Facility Code 0 kernel messages 1 user-level messages 2 mail system 3 system daemons 4 security|authorization messages 5 messages generated internally by syslog 6 line printer subsystem 7 network news subsystem 8 UUCP subsystem 9 clock daemon
Network Monitoring Commands
85
Page 92
DGS-3212SR Switch CLI Reference
config syslog host
Parameters 10 security|authorization messages
11 FTP daemon 12 NTP subsystem 13 log audit 14 log alert 15 clock daemon 16 local use 0 (local0) 17 local use 1 (local1) 18 local use 2 (local2) 19 local use 3 (local3) 20 local use 4 (local4) 21 local use 5 (local5) 22 local use 6 (local6) 23 local use 7 (local7) local0 Specifies that local use 0 messages will be
sent to the remote host. This corresponds to number 16 from the list above.
local1 Specifies that local use 1 messages will be sent to the remote host. This corresponds to number 17 from the list above.
local2 Specifies that local use 2 messages will be sent to the remote host. This corresponds to number 18 from the list above.
local3 Specifies that local use 3 messages will be sent to the remote host. This corresponds to number 19 from the list above.
local4 Specifies that local use 4 messages will be sent to the remote host. This corresponds to number 20 from the list above.
local5 Specifies that local use 5 messages will be sent to the remote host. This corresponds to number 21 from the list above.
local6 Specifies that local use 6 messages will be sent to the remote host. This corresponds to number 22 from the list above.
local7 Specifies that local use 7 messages will be sent to the remote host. This corresponds to number 23 from the list above.
udp_port <int> − Specifies the UDP port number that the syslog protocol will use to send messages to the remote host. UDP ports available for this purpose are port 514 or any port in the range 6000-65535.
ipaddress <ipaddr> Specifies the IP address of the remote host where syslog messages will be sent.
state [enable|disable] Allows the sending of syslog messages to the remote host, specified above, to be enabled and disabled.
Restrictions Only administrator-level users can issue this
command.
Example Usage:
To create syslog host:
DGS-3212SR:4#config syslog host all severity all facility local0 Command: config syslog host all severity all facility local0 Success. DGS-3212SR:4#
Network Monitoring Commands
86
Page 93
DGS-3212SR Switch CLI Reference
delete syslog host
Purpose Used to remove a syslog host, that has been
previously configured, from the switch. Syntax Description
Parameters
Restrictions Only administrator-level users can issue this
delete syslog host [<index 1-4>|all]
The delete syslog host command is used to
remove a syslog host, that has been previously
configured, from the switch.
<index 1-4> Specifies that the command will
be applied to an index of hosts. There are four
available indexes, numbered 1 through 4.
all Specifies that the command will be applied
to all hosts.
command.
Example Usage:
To delete a previously configured syslog host:
DGS-3212SR:4#delete syslog host 4 Command: delete syslog host 4
Success.
DGS-3212SR:4#
Network Monitoring Commands
87
Page 94
DGS-3212SR Switch CLI Reference
show syslog host
Purpose Used to display the syslog hosts currently
configured on the switch. Syntax show syslog host {<index 1-4>} Description
Parameters
Restrictions None.
The show syslog host command is used to
display the syslog hosts that are currently
configured on the switch.
<index 1-4> Specifies that the command will
be applied to an index of hosts. There are four
available indexes, numbered 1 through 4.
Example Usage:
To show Syslog host information:
DGS-3212SR:4#show syslog host Command: show syslog host Syslog Global State: Disabled Host Id Host IP Address Severiry Facility UDP port Status
------- --------------- -------------- -------- -------- -------­ 1 10.1.1.2 All Local0 514 Disabled 2 10.40.2.3 All Local0 514 Disabled 3 10.21.13.1 All Local0 514 Disabled
Total Entries : 3
DGS-3212SR:4#
Network Monitoring Commands
88
Page 95
DGS-3212SR Switch CLI Reference
9
MAC NOTIFICATION
The network monitoring commands in the Command Line Interface (CLI) are listed (along with the appropriate parameters) in the following table.
Command Parameters
config mac_notification
config mac_notification ports
enable mac_notification
disable mac_notification
show mac_notification
show mac_notification ports
interval <int 1-214783647> historysize <int 1-500>
<portlist> all enable disable
<portlist>
Each command is listed, in detail, in the following sections.

MAC Notification

89
Page 96
DGS-3212SR Switch CLI Reference
config mac_notification
Purpose Used to configure MAC address notification. Syntax
Description MAC address notificiation is used to monitor
Parameters
Restrictions Only administrator-level users can issue this
config mac_notification
ports <portlist>|all
interval <sec>
historysize <1 - 500>
MAC addresses learned and entered into the
FDB.
ports <portlist> - specifies a range of ports to
be configured. The port list is specified by
listing the lowest switch number and the
beginning port number on that switch, separated
by a colon. Then highest switch number, and
the highest port number of the range (also
separeted by a colon) are specified. The
beginning and end of the port list range are
seperated by a dash. For example, 1:3 would
specify switch number 1, port 3. 2:4 specifies
switch number 2, port 4. 1:3-2:4 specifies all of
the ports between switch 1, port 3 and switch 2,
port 4 in numerical order.
all – to configure all ports for MAC notification.
interval <sec 1-2147483647> - time in seconds
between notifications.
historysize <1 - 500> - maximum number of
entries listed in the history log used for
notification.
command.
Example Usage:
To configure a 60 second interval for MAC address notification on unit 1 ports 6-9:
DGS-3212SR:4#config mac_notification ports 1:6-1:9 60 Command: config mac_notification ports 1:6-1:9 interval 60
Success.
DGS-3212SR:4#
MAC Notification
90
Page 97
DGS-3212SR Switch CLI Reference
config mac_notification ports
Purpose Used to configure MAC address notification on
a port basis. Syntax
Description MAC address notificiation is used to monitor
Parameters
Restrictions Only administrator-level users can issue this
config mac_notification ports
ports <portlist>|all
enable
disable
MAC addresses learned and entered into the
FDB.
ports <portlist> - Specifies a range of ports to
be configured. The port list is specified by
listing the lowest switch number and the
beginning port number on that switch, separated
by a colon. Then highest switch number, and
the highest port number of the range (also
separeted by a colon) are specified. The
beginning and end of the port list range are
seperated by a dash. For example, 1:3 would
specify switch number 1, port 3. 2:4 specifies
switch number 2, port 4. 1:3-2:4 specifies all of
the ports between switch 1, port 3 and switch 2,
port 4 in numerical order.
all – To configure all ports for MAC notification.
enable Used to enable a port’s MAC
notification
disable Used to disable a port’s MAC
notification.
command.
Example Usage:
To configure MAC address notification on unit 1 ports 6-9:
DGS-3212SR:4#config mac_notification ports 1:6-1:9 Command: config mac_notification ports 1:6-1:9 Success.
DGS-3212SR:4#
MAC Notification
91
Page 98
DGS-3212SR Switch CLI Reference
enable mac_notification
Purpose Used to globally enable MAC address
notification without changing the
mac_notification configuration. Syntax Description Enables MAC notication on the switch. Parameters None. Restrictions Only administrator-level users can issue this
enable mac_notification
command.
Example Usage:
To globally enable MAC notification:
DGS-3212SR:4#enable mac_notification Command: enable mac_notification
Success.
DGS-3212SR:4#
MAC Notification
92
Page 99
DGS-3212SR Switch CLI Reference
disable mac_notification
Purpose Used to disable MAC address notification
globally without changing mac_notification
configuration.. Syntax Description Disables MAC notication on the switch. Parameters None. Restrictions Only administrator-level users can issue this
disable mac_notification
command.
Example Usage:
To globally disnable MAC notification:
DGS-3212SR:4#disable mac_notification Command: disable mac_notification
Success.
DGS-3212SR:4#
MAC Notification
93
Page 100
DGS-3212SR Switch CLI Reference
show mac_notification
Purpose Used to display MAC address notification. Syntax Description Displays MAC notification settings either per
Parameters None – this will display global MAC notification
Restrictions Only administrator-level users can issue this
Example usage: To display global MAC notification settings:
DGS-3212SR:4#show mac_notification Command: show mac_notification
Global Mac Notification Settings
State : Disabled Interval : 1 History Size : 1
DGS-3212SR:4#
show mac_notification {ports}
port or globally as desired.
settings currently configured including Interval,
History Size and State.
ports – this displays per ports MAC notification
settings.
command.
MAC Notification
94
Loading...