一、实验TOP图及说明
二、配置说明
2.1 交换机一配置(floor1)
[floor 1]vlan batch 2 3 #创建vlan 2 vlan3
[floor 1]int e0/0/1 #进入e0/0/1接口
[floor 1-Ethernet0/0/1]port link-type trunk #设置端口类型为Trunk
[floor 1-Ethernet0/0/1]port trunk allow-pass vlan 2 3 # 允许vlan 2 vlan3 通过
[floor 1-Ethernet0/0/1]int e0/0/2 #进入e0/0/2接口
[floor 1-Ethernet0/0/2]port link-type access #设置端口类型为access
[floor 1-Ethernet0/0/2]port default vlan 2 #将端口加入到vlan2
[floor 1-Ethernet0/0/2]int e0/0/3 #进入e0/0/3接口
[floor 1-Ethernet0/0/3]port link-type access #设置端口类型为access
[floor 1-Ethernet0/0/3]port default vlan 3 #将端口加入到vlan2
[floor 1]int e0/0/1 #进入e0/0/1接口
[floor 1-Ethernet0/0/1]port trunk pvid vlan 2 #修改Trunk PVID值
<floor 1>dis cur int e0/0/1 #查看 e0/0/1配置
2.1 交换机二配置(floor2)
[floor 2]vlan batch 2 3 #创建vlan 2 vlan3
[floor 2]int e0/0/1 #进入e0/0/1接口
[floor 2-Ethernet0/0/1]port link-type trunk #设置端口类型为Trunk
[floor 2-Ethernet0/0/1]port trunk allow-pass vlan 2 3 # 允许vlan 2 vlan3 通过
[floor 2-Ethernet0/0/1]int e0/0/2 #进入e0/0/2接口
[floor 2-Ethernet0/0/2]port link-type access #设置端口类型为access
[floor 2-Ethernet0/0/2]port default vlan 2 #将端口加入到vlan2
[floor 2-Ethernet0/0/2]int e0/0/3 #进入e0/0/3接口
[floor 2-Ethernet0/0/3]port link-type access #设置端口类型为access
[floor 2-Ethernet0/0/3]port default vlan 3 #将端口加入到vlan2
[floor 2]int e0/0/1 #进入e0/0/1接口
[floor 2-Ethernet0/0/1]port trunk pvid vlan 2 #修改Trunk PVID值
<floor 2>dis cur int e0/0/1 #查看 e0/0/1配置