神州数码交换机实训手册.docx

上传人:b****7 文档编号:8551543 上传时间:2023-01-31 格式:DOCX 页数:24 大小:894.78KB
下载 相关 举报
神州数码交换机实训手册.docx_第1页
第1页 / 共24页
神州数码交换机实训手册.docx_第2页
第2页 / 共24页
神州数码交换机实训手册.docx_第3页
第3页 / 共24页
神州数码交换机实训手册.docx_第4页
第4页 / 共24页
神州数码交换机实训手册.docx_第5页
第5页 / 共24页
点击查看更多>>
下载资源
资源描述

神州数码交换机实训手册.docx

《神州数码交换机实训手册.docx》由会员分享,可在线阅读,更多相关《神州数码交换机实训手册.docx(24页珍藏版)》请在冰豆网上搜索。

神州数码交换机实训手册.docx

神州数码交换机实训手册

 

网络互联技术实验手册

-2011-2012学年第二学期-

 

一、交换机基本命令-------------------------------------------03

二、交换机的访问控制----------------------------------------05

三、交换机系统文件的备份和还原-------------------------08

四、交换机VLAN的划分--------------------------------------11

五、跨交换机相同VLAN之间通信--------------------------14

六、MAC地址功能扩展-------------------------------------17

七、交换机的DHCP功能------------------------------------20

八、生成树实验-------------------------------------------------22

九、交换机链路聚合-------------------------------------------25

十、三层交换机的路由功能----------------------------------28

十一、私有VLAN----------------------------------------------32

十二、动态vlan-------------------------------------------------36

 

一、交换机基本命令

一、快捷键的使用

Tab制表:

用于补齐命令

上光标:

显示上一个命令

下光标:

显示下一个命令

Ctrl+P:

相当于上光标

Ctrl+n:

相当于下光标

Ctrl+z:

从其他配制模式(除一般用户配制模式)直接退出到特权配制模式

Ctrl+c:

打断交换机的ping进程

二、检查输入错误原因

Unrecognizedcommandorillegalparameter!

命令不存在,或者参数的范围,类型,格式有错误。

Ambiguouscommand根据已有的输入可以产生至少两种不同的解释

Invalidcommandorparameter命令解析成功/但没有任何有效的参数纪录

Shelltaskerror多任务时,新的shell任务启动失败

Thiscommandisnotexistincurrentmode命令可解析,但当前模式下不能配制该命令

Pleaseconfigurateprecursorcomand“*”atfist!

当前输入可以被正确解析,但其前导命令尚未配制。

Syntxerror:

missing“”beforcetheendoldcommandline!

输入中使用了引号,但没有成对出现。

三、常用命令

?

描述命令可使用的参数或者提示信息

Help提示帮助信息

Showversion显示交换机版本信息

Showrunning-config显示当前运行状态下生效的交换机参数配置

Showstartup-config显示当前运行状态下写在闪存中的交换机参数配置

ShowinterfaceEthernet0/0/01显示指定交换机端口信息

Showflash显示保存在FLASH中的文件及大小

Showarp显示ARP映射表

Showhistory显示用户最近输入的历史命令

Showrom显示启动文件及大小

四、将交换机恢复出厂设置

switch#setdefault置enable密码

switch(Config)#enablepasswordleveladmin除enable密码

switch(Config-If-Vlan1)#ipaddress进行计算机与交换机的连通性测试

switch(Config)#telnet-serverenable

Telnetdalreadyenabled.

.

Userjincongftp:

收到134字节,用时sec.

ftp>getc:

\ftp:

收到1688131字节,用时sec.

四、交换机VLAN的划分

一、实验目的:

了解VLAN工作原理(每个vlan就是一个广播域,划分vlan可以隔离广播风暴);

熟练掌握二层交换机VLAN的划分方法;

了解如何验证VLAN的划分;

二、实验设备:

1.DCS-3926S交换机1台

2.PC机1台

3.Console线、直通双绞线

三、

实验拓扑:

Console线网线

PC1

四、实验要求:

Vlan

IP

端口号

Vlan1

100

9-16

Vlan200

17-24

PC1位置

动作

结果

1-7端口

PC1ping交换机

8-16端口

PC1ping交换机

不通

17-24端口

PC1ping交换机

不通

1-7端口

交换机pingPC1

8-16端口

交换机pingPC1

不通

17-24端口

交换机pingPC1

不通

五、实验步骤:

1.交换机恢复出厂设置。

switch#setdefault

switch#write

switch#reload

2.对交换机设置IP地址即管理IP地址

switch#config

switch(Config)#interfacevlan1

switch(Config-If-Vlan1)#ipaddress在交换机中创建vlan100和vlan200

switch(Config)#vlan100

switch(Config-Vlan100)#exit/并把17-24的端口划分给VLAN200

SettheportEthernet0/0/22accessvlan200successfully

SettheportEthernet0/0/23accessvlan200successfully

SettheportEthernet0/0/24accessvlan200successfully

switch(Config-Vlan200)#exit

查看验证是否已经按照要求把端口划分给两个VLAN

switch#showvlan

VLANNameTypeMediaPorts

---------------------------------------------------------------------------

1defaultStaticENETEthernet0/0/1Ethernet0/0/2

Ethernet0/0/3Ethernet0/0/4

Ethernet0/0/5Ethernet0/0/6

Ethernet0/0/7

100VLAN0100StaticENETEthernet0/0/8Ethernet0/0/9

Ethernet0/0/10Ethernet0/0/11

Ethernet0/0/12Ethernet0/0/13

Ethernet0/0/14Ethernet0/0/15

Ethernet0/0/16

200VLAN0200StaticENETEthernet0/0/17Ethernet0/0/18

Ethernet0/0/19Ethernet0/0/20

Ethernet0/0/21Ethernet0/0/22

Ethernet0/0/23Ethernet0/0/24

..

VlanMacAddressTypeCreatorPorts

---------------------------------------------------------------------------

100-03-0f-02-ca-5bSTATICSystemCPU

100-13-72-e9-e6-c0STATICUserEthernet0/0/23

..

VlanMacAddressTypeCreatorPorts

---------------------------------------------------------------------------

100-03-0f-02-ca-5bSTATICSystemCPU

100-13-72-e9-e6-c0STATICUser(blackhole)

switch(Config)#amenableswitch#showam

GlobalAMisenabled

InterfaceEthernet0/0/23

ammac-ip-pool00-13-72-E9-E6-C0USER_CONFIG

switch(Config)#interfaceethernet0/0/23

switch(Config-Ethernet0/0/23)#amip-pool15

.*.1--*.*.*.32

PC接交换机端口

23口

23口

20口

MAC地址

00-13-72-E9-E6-C8

00-13-72-E9-E6-C0

00-13-72-E9-E6-C0

IP地址

结果

不通

switch#showam

.........

MSTPisenabledsuccessfully.

SwitchB.........

MSTPisenabledsuccessfully.

1.查看设置

SwitchA

SwitchB

连通性测试(启动生成树后):

互联设备

交换机Aping交换机B

PC1pingPC2

Ping(通/不通)

.........

MSTPisenabledsuccessfully.

switchA(Config)#

交换机B:

switch#config

switch(Config)#hostnameswitchB

switchB(Config)#interfacevlan1

switchB(Config-If-Vlan1)#ipaddress.........

MSTPisenabledsuccessfully.

switchB(Config)#

2.创建port-group

交换机A:

switchA(Config)#port-group1

为交换机设置管理IP

交换机A

switchA(Config)#interfacevlan2

switchA(Config-If-Vlan2)#ipaddressvlan3

00:

07:

47:

%LINK-5-CHANGED:

InterfaceVlan3,changedstatetoUP

switchA(Config-If-Vlan3)#ipaddress思考:

此时PC1能否ping通PC2?

回答:

不行

交换机B

switchB(Config)#interfacevlan2

switchB(Config-If-Vlan2)#ipaddressvlan3

switchB(Config-If-Vlan3)#ipaddress思考:

此时PC3能否ping通PC2?

回答:

不行

此时PC3能否ping通PC1?

回答:

不行

11.设置静态路由

交换机A

switchA#showiproute设置动态路由(RIP)

注:

应首先删除静态路由。

问:

该如何删除静态路由?

//switchA(Config)#noiproute//删除静态路由

//switchB(Config)#noiproute//删除静态路由

 

交换机A

switchA#config

switchA(Config)#routerip//启用rip路由协议

switchA(Config-Router-Rip)#exit

switchA(Config)#interfacevlan2

switchA(Config-If-Vlan2)#ipripwork//使VLAN2接口可以发送、接受RIP数据报

switchA(Config-If-Vlan2)#exit

switchA(Config)#interfacevlan3

switchA(Config-If-Vlan3)#ipripwork//使VLAN3接口可以发送、接受RIP数据报

switchA(Config-If-Vlan3)#exit

switchA(Config)#exit

switchA#showiproute

Totalrouteitemsis3,thematchedrouteitemsis3

Codes:

C-connected,S-static,R-RIPderived,O-OSPFderived

A-OSPFASE,B-BGPderived,D-DVMRPderived

DestinationMaskNexthopInterfacePreference

RVlan3120

CVlan30

CVlan20

交换机B

switchB#config

switchB(Config)#routerip

switchB(Config-Router-Rip)#exit

switchB(Config)#interfacevlan2

switchB(Config-If-Vlan2)#ipripwork

switchB(Config-If-Vlan2)#exit

switchB(Config)#interfacevlan3

switchB(Config-If-Vlan3)#ipripwork

switchB(Config-If-Vlan3)#exit

switchB(Config)#exit

switchB#showiproute

Totalrouteitemsis3,thematchedrouteitemsis3

Codes:

C-connected,S-static,R-RIPderived,O-OSPFderived

A-OSPFASE,B-BGPderived,D-DVMRPderived

DestinationMaskNexthopInterfacePreference

RVlan3120

CVlan30

CVlan20

//思考:

此时PC3能否与PC1互ping?

回答:

可以

此时PC3能否与PC2互ping?

回答:

可以

动态路由协议还有OSPF路由协议,可以根据网络的不同需要来选择不同的路由协议。

十一、私有VLAN

一实验目的

1.了解私有vlan原理

2.掌握私有vlan的划分方法

3.了解vlan和私有vlan的不同

二应用环境

1.不便划分vlan却又需要隔离的。

2.各vlan之间不需要通信,但需要访问同一台服务器的

三实验拓扑结构

PC1PC2(用于测试,可在需要的时候接入)

四实验要求

在交换机上划分vlan:

vlan100、vlan200、vlan300、vlan400;

Vlan

Vlan类型

端口成员

100

primary

1-4

200

community

7-12

300

community

13-18

400

isolated

19-24

五实验步骤

1.划分vlan

switch(Config)#vlan100

switch(Config-Vlan100)#exit

switch(Config)#vlan200

switch(Config-Vlan200)#exit

switch(Config)#vlan300

switch(Config-Vlan300)#exit

switch(Config)#vlan400

switch(Config-Vlan400)#exit

2.启用私有vlan

switch(Config)#vlan100

switch(Config-Vlan100)#private-vlan?

association--配置私有Vlan间的联合

community--配置为团体Vlan

isolated--配置为隔离Vlan

primary--配置为基本Vlan

//注意:

只有不包含任何以太网端口的vlan才可以被设置成private-vlan,普通vlan若被设置成private-vlan,会自动将所属的以太网口清除掉。

3.划分private-vlan类型

switch(Config)#vlan100

switch(Config-Vlan100)#private-vlanprimary//vlan100配置为基本vlan

Note:

Thiswillremovealltheportsfromvlan100

switch(Config-Vlan100)#exit

switch(Config)#vlan200

switch(Config-Vlan200)#private-vlancommunity//vlan200配置为团体vlan

Note:

Thiswillremovealltheportsfromvlan200

switch(Config-Vlan200)#exit

switch(Config)#vlan300

switch(Config-Vlan300)#private-vlancommunity//vlan300配置为团体vlan

Note:

Thiswillremovealltheportsfromvlan300

switch(Config-Vlan300)#exit

switch(Config)#vlan400

switch(Config-Vlan400)#private-vlanisolated//vlan400配置为隔离vlan

Note:

Thiswillremovealltheportsfromvlan400

switch(Config-Vlan400)#

switch#showvlanprivate-vlan//验证私有vlan

VLANNameTypeAssoVLANPorts

---------------------------------------------------------------------------

100VLAN0100Primary

200VLAN0200Community

300VLAN0300Community

400VLAN0400Isolate

4.建立私有vlan之间的关联

switch(Config)#vlan100

switch(Config-Vlan100)#private-vlanassociation200;300;400//私有vlan100关联

Setvlan100associatedvlansuccessfully

switch#showvlanprivate-vlan//验证私有vlan关联

VLANNameTypeAssoVLANPorts

---------------------------------------------------------------------------

100VLAN0100Primary200300400

200VLAN0200Community100

300VLAN0300Community100

400VLAN0400Isolate100

//注意:

只有primary类型vlan才能设置private-vlan关联关系;设置关联前private-vlan中都没有以太网口;存在private-vlan关联关系的primaryvlan不能被删除。

5.添加private-vlan端口

switch(Config)#vlan100

switch(Config-Vlan100)#switchportinterfaceethernet0/0/1-4//给vlan100分配端口

SettheportEthernet0/0/1accessvlan100successfully

SettheportEthernet0/0/2accessvlan100success

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 外语学习 > 法语学习

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1