2024年3月29日发(作者:)
青岛开发区职业中专
神州数码交换机路由器命令汇总(部分)
2016年3月23日星期三修改
_________________________________________________________________________
注:本文档命令为最简命令,如不懂请在机器上实验
注:交换机版本信息:
DCRS-5650-28(R4) Device, Compiled on Aug 12 10:58:26 2013
sysLocation China
CPU Mac 00:03:0f:24:a2:a7
Vlan MAC 00:03:0f:24:a2:a6
SoftWare Version 7.0.3.1(B0043.0003)
BootRom Version 7.1.103
HardWare Version 2.0.1
CPLD Version N/A
Serial No.:1
Copyright (C) 2001-2013 by Digital China Networks Limited.
All rights reserved
Last reboot is warm reset.
Uptime is 0 weeks, 0 days, 1 hours, 42 minutes
路由器版本信息:
Digital China Networks Limited Internetwork Operating System Software
DCR-2659 Series Software, Version 1.3.3H (MIDDLE), RELEASE SOFTWARE
Copyright 2012 by Digital China Networks(BeiJing) Limited
Compiled: 2012-06-07 11:58:07 by system, Image text-base: 0x6004
ROM: System Bootstrap, Version 0.4.2
Serial num:8IRTJ610CA15000001, ID num:201404
System image file is "DCR-2659_"
Digital China-DCR-2659 (PowerPC) Processor
65536K bytes of memory,16384K bytes of flash
Router uptime is 0:00:44:44, The current time: 2002-01-01 00:44:44
Slot 0: SCC Slot
Port 0: 10/100Mbps full-duplex Ethernet
Port 1: 2M full-duplex Serial
Port 2: 2M full-duplex Serial
Port 3: 1000Mbps full-duplex Ethernet
Port 4: 1000Mbps full-duplex Ethernet
Port 5: 1000Mbps full-duplex Ethernet
Port 6: 1000Mbps full-duplex Ethernet
第 1 页 共 8 页
青岛开发区职业中专
一、交换机配置命令
1.基本配置
switch > en (enable)进入特权用户模式
switch # con (config) 进入全局配置模式
switch (config)# ho switch (hostname) 配置交换机名称
switch (config)# in e1/0/1 进入接口配置模式
switch (config-if-ethernet1/0/1)# ex
switch (config)# in vl 1 进入VLAN配置模式
switch (config-if-vlan1)# ip ad 192.168.1.252 255.255.255.0
switch (config-if-vlan1)# ex
switch (config)# ena p 1234 配置交换机密码(不加密)
switch (config)# ena p 7 1234 配置交换机密码(加密)
switch (config)# vl 10 创建vlan
switch (config-vlan10)#ex
switch (config)# in vl 10
switch (config-if-vlan10)# ip ad 172.16.10.1 255.255.255.0 配置VLAN地址
输入这条命令会出现: Invalid
ENCRYPTED password! Please
input the ENCRYPTED password
with length 32 密码位数不够32位
2.生成树技术
switch (config)# sp (spanning-tree) 启用全局生成树(默认mstp生成树技术)
switch (config)# sp mo stp/rstp /mstp (生成树/快速生成树/多生成树技术)
switch (config)# sp ms 0 p 4096 设置交换机的优先级 默认32768
switch (config)# sh sp (show spanning-tree) 查看生成树
3.交换机Web管理
switch (config)# ip ht ser
switch (config)# usern admin pa 1234 用户名和密码
4.交换机Telnet管理
switch (config)# telnet-s e (telnet enable) 开启telnet服务
switch (config)# usern admin pa 1234 用户名和密码
5.链路聚合(不需启动生成树)
switchA (config)# port-g 1 (prot-group)
switchA (config)# in e1/0/1-2
switchA (config-port-range)# po 1 m on/active
switchA (config-port-range)# ex
switchA (config)# no port-g 1 删除组1
switchB (config)# port-g 2
switchB (config)# in e1/0/3-4
switchB (config-port-range)# po 2 m on/active
switchB (config-port-range)# ex
switchB (config)# no port-g 2 删除组2
6.交换机MAC与IP绑定
switch (config)# am e (am enable) 启用全局am功能
switch (config)# in e1/0/1
switch (config_if_ethernet1/0/1)# am p (am port) 打开端口am功能
switch (config_if_ethernet1/0/1)# am m (mac-ip-pool) 00-A0-D1-D1-07-FF 192.168.1.101
switch (config_if_ethernet1/0/1)# ex
switch (config)# in e1/0/2
第 2 页 共 8 页


发布评论