网络工程实验指导书(基于华为路由器交换机)
信管专业用
实验1 计算机和交换机的基本设置
1.实验目的
(1)学会计算机网中主机IP地址和网关地址的设置。
(2)掌握主机与交换机间连通测试。
(3)掌握交换机端口参数的设置,熟悉交换机私有地址的设定规则。2.实验拓扑结构
3.实验容与步骤
(1)打开软件调用交换机和主机,建立实验拓扑要求的连接。
(2)配置交换机名和密码,操作如下:
Quidway>system
password:
[Quidway]sysname switch ;交换机命名[switch]super password simple 111 ;设置特权密码[switch]user-interface vty 0 4
[switch-ui-vty0-4]authentication-mode password
[switch-ui-vty0-4]set authentication-mode password simple 222 [switch-ui-vty0-4]user privilege level 3
[switch-ui-vty0-4]quit
[switch]quit
(3)配置并查看VLAN
switch]vlan 2
[switch-vlan2]port ethernet0/2
[switch-vlan2]port e0/4 to et0/6
[switch-vlan2]quit
[switch]dis vlan
[switch]int e0/3
[switch-Ethernet0/3]port access vlan 2
[switch-Ethernet0/3]quit
[switch]dis vlan
[switch]dis curr
[switch]interface vlan 1
[switch-Vlan-interface1]ip address 10.65.1.8 255.255.0.0 [switch-Vlan-interface1]quit
[switch]ip route-static 0.0.0.0 0.0.0.0 10.65.1.2 [switch]ip default-gateway 10.65.1.2
[switch]dis curr
[switch]save
(4)配置主机地址
login:root
password:linux
[rootPCA root]#ifconfig eth0 10.65.1.1 netmask 255.255.0.0 [rootPCA root]#ifconfig
[rootPCA root]#route add default gw 10.65.1.2
[rootPCA root]#route
(5)主机与交换机间的连通测试
[rootPCA root]#ping 10.65.1.8
[rootPCA root]#telnet 10.65.1.8
4.思考总结
(1)特权密码的作用是什么?密码丢失如何处理?
(2)主机地址与交换机IP地址设置应注意哪些问题。
、
实验2 端口聚合配置
1.实验目的
(1)熟悉端口聚合命令的使用场合与注意事项
(2)掌握端口聚合配置的基本方法
(3)了解端口的属性类型
2.实验拓扑结构
3.实验容步骤
(1)打开实验软件调用两台交换机并按实验拓扑连接(2)配置交换机A的端口参数
端口E0/1
[Quidway]sysname SwitchA
[SwitchA]interface ethernet0/1
[SwitchA-Ethernet0/1]duplex full
[SwitchA-Ethernet0/1]speed 100
[SwitchA-Ethernet0/1]port link-type trunk [SwitchA-Ethernet0/1]port trunk permit vlan all 端口E0/2
[SwitchA-Ethernet0/1]int e0/2
[SwitchA-Ethernet0/2]duplex full
[SwitchA-Ethernet0/2]speed 100
[SwitchA-Ethernet0/2]port link-type trunk [SwitchA-Ethernet0/2]port trunk permit vlan all (3)配置交换机B的端口参数
[Quidway]sysname SwitchB
[SwitchB]interface ethernet0/1
[SwitchB-Ethernet0/1]duplex full
[SwitchB-Ethernet0/1]speed 100
[SwitchB-Ethernet0/1]port link-type trunk
[SwitchB-Ethernet0/1]port trunk permit vlan all
[SwitchB-Ethernet0/1]int e0/2
[SwitchB-Ethernet0/2]duplex full
[SwitchB-Ethernet0/2]speed 100
[SwitchB-Ethernet0/2]port link-type trunk
[SwitchB-Ethernet0/2]port trunk permit vlan all
(4)配置端口聚合
[SwitchA]link-aggregation ethernet0/1 to ethernet0/2 both [SwitchB]link-aggregation ethernet0/1 to ethernet0/2 both
[SwitchA]display link-aggregation ethernet0/1 [SwitchA]undo link-aggregation all
4.思考总结
(1)TRUNK端口可否属于多个VLAN?
(2)如何测试TRUNK端口的工作状态?
实验3 VLAN的配置
1.实验目的
(1)掌握VLAN命令使用的基本原则(2)掌握VLAN划分的规则
(3)熟悉VLAN地址的分配方法(4)学会如何测试VLAN间的连通性2.实验拓扑结构
3.实验容与步聚
(1)调用主机和交换机并按拓扑结构连(2)配置交换机A的VLAN [SwitchA]vlan 2
[SwitchA-vlan2]port e0/2 [SwitchA-vlan2]port e0/3 to e0/4 [SwitchA-vlan2]vlan 3
[SwitchA-vlan3]port e0/5 to e0/6 [SwitchA]dis vlan all
[SwitchA]dis current
(3)配置交换机B的VLAN [SwitchB]vlan 2
[SwitchB-vlan2]port e0/3 to e0/4 [SwitchB-vlan2]vlan 3
[SwitchB-vlan3]port e0/5 to e0/6 [SwitchB-vlan3]quit
[SwitchB]dis vlan all
[SwitchB]dis current
(4)配置主机的IP
设置计算机的IP为: