飞速(FS) S3900系列交换机如何配置基于协议划分的VLAN?
在局域网中,VoIP、IPTV、Internet等业务一般通过不同的协议来传输语音、电视和网络等服务。为了方便网络管理,采用相同协议的业务会被划分到同一个VLAN中进行管理。因此,在一个局域网中将会存在着多个基于协议划分的VLAN。基于协议划分的VLAN是根据IP、IPX、AT等协议来进行的VLAN划分,它只能在Hybrid端口进行配置,用来定义Untagged数据帧的过滤标准。飞速(FS)S3900系列交换机是专门为校园网,中小型企业和家庭网服务的交换机,本文将着重讲述如何在S3900系列交换机上配置基于协议划分的VLAN。
飞速(FS) S3900系列交换机基于协议划分VLAN的应用
下图展示了S3900-24T4S管理型交换机的基于协议划分VLAN的典型组网应用。在网络中,两个不同的Internet业务分别通过IPv4和IPv6两种协议来传输服务。通过在S3900-24T4S交换机上配置基于协议划分的VLAN,两种不同的Internet业务被划分到不同的VLAN中——即VLAN 10和VLAN 20。 在VLAN 10 中,终端用户通过IPv4 协议和网络服务器通信,而在VLAN 20中,用户则使用IPv6和网络服务器通信。
注意:
1. 当设备接口接收到Untagged帧时, 设备会先识别帧的协议模板,然后确定报文所属的VLAN。
2. 如果接口配置了某些协议VLAN,且报文的协议模板匹配其中某个协议VLAN,则给报文打上该协议VLAN的Tag。
3. 如果接口配置了某些协议VLAN,但报文的协议模板和所有协议VLAN不匹配,则给报文打上接口PVID的Tag。
飞速(FS) S3900系列交换机基于协议划分VLAN的配置思路
S3900系列交换机基于协议划分VLAN的配置可以通过命令行界面来实现。配置的方法适用于S3900全系列交换机,下面以S3900-24T4S这款交换机的配置为例进行说明。
配置思路:
1.配置PC的IP地址。
2.创建各网络层协议所需要关联的VLAN。
3.配置交换机端口类型及允许相应协议的VLAN通过。
4.查看配置信息。
飞速(FS) S3900系列交换机通过命令行界面划分协议VLAN的配置
1. 为PC1和PC3配置IPv4地址;为PC2和PC4配置IPv6地址
IP: 192.168.10.2
IP:192.168.10.3
IP: 2001::1:2
IP: 2001::1:3
2. 在S3900-24T4S交换机上创建VLAN 10和VLAN 20.
S3900-24T4S(config)#vlan database
S3900-24T4S(config-vlan)#vlan 10
S3900-24T4S(config-vlan)#vlan 20
S3900-24T4S(config-vlan)#exit
3. 配置网络协议并与对应VLAN关联
S3900-24T4S(config)#protocol-vlan protocol-group 1 add frame-type ethernet protocol-type ip
S3900-24T4S(config)#protocol-vlan protocol-group 2 add frame-type ethernet protocol-type ipv6
S3900-24T4S(config)#protocol-vlan protocol-group 3 add frame-type ethernet protocol-type arp
S3900-24T4S(config)#interface ethernet 1/2
S3900-24T4S(config-if)#protocol-vlan protocol-group 1 vlan 10
S3900-24T4S(config-if)#protocol-vlan protocol-group 3 vlan 10
S3900-24T4S(config-if)#exit
S3900-24T4S(config)#interface ethernet 1/3
S3900-24T4S(config-if)#protocol-vlan protocol-group 2 vlan 20
S3900-24T4S(config-if)#exit
S3900-24T4S(config)#interface ethernet 1/4
S3900-24T4S(config-if)#protocol-vlan protocol-group 1 vlan 10
S3900-24T4S(config-if)#exit
S3900-24T4S(config)#interface ethernet 1/5
S3900-24T4S(config-if)#protocol-vlan protocol-group 2 vlan 20
S3900-24T4S(config-if)#exit
4. 将S3900-24T4S交换机的eth1/2-5端口配置为Hybrid端口,并剥离对应VLAN tag标签。
S3900-24T4S(config)#int ethernet 1/2
S3900-24T4S(config-if)#switchport mode hybrid
S3900-24T4S(config-if)#switchport hybrid allowed vlan add 10 untagged
S3900-24T4S(config)#int ethernet 1/3
S3900-24T4S(config-if)#switchport mode hybrid
S3900-24T4S(config-if)#switchport hybrid allowed vlan add 20 untagged
S3900-24T4S(config)#int ethernet 1/4
S3900-24T4S(config-if)#switchport mode hybrid
S3900-24T4S(config-if)#switchport hybrid allowed vlan add 10 untagged
S3900-24T4S(config)#int ethernet 1/5
S3900-24T4S(config-if)#switchport mode hybrid
S3900-24T4S(config-if)#switchport hybrid allowed vlan add 20 untagged
5. 将S3900-24T4S交换机的eth1/1端口配置为Trunk端口,并允许所有VLAN通过。
S3900-24T4S(config)#int ethernet 1/1
S3900-24T4S(config-if)#switchport mode trunk
S3900-24T4S(config-if)#switchport trunk allowed vlan all
6. 在S5800-8TF12S交换机上创建VALN 10和VLAN 20,然后将S5800-8TF12S交换机的eth1/1端口配置为Trunk端口,并允许所有VLAN通过。
S5800-8TF12S(config)#vlan database
S5800-8TF12S(config-vlan)#vlan 10
S5800-8TF12S(config-vlan)#vlan 20
S5800-8TF12S(config-vlan)#exit
S5800-8TF12S(config)#int ethernet 1/1
S5800-8TF12S(config-if)#switchport mode trunk
S5800-8TF12S(config-if)#switchport trunk allowed vlan all
7. 将S5800-8TF12S交换机的eth1/2-3端口配置为Trunk端口,并允许对应VLAN通过。
S5800-8TF12S(config)#int ethernet 1/2
S5800-8TF12S(config-if)#switchport mode trunk
S5800-8TF12S(config-if)#switchport trunk allowed vlan add 10
S5800-8TF12S(config)#int ethernet 1/3
S5800-8TF12S(config-if)#switchport mode trunk
S5800-8TF12S(config-if)#switchport trunk allowed vlan add 20
8. 查看配置信息。 .
S3900-24T4S# show protocol-vlan protocol-group
S3900-24T4S# show int protocol-vlan protocol-group
相关推荐
飞速(FS) S3900系列交换机如何配置基于接口划分的VLAN?
相关文章推荐
邮箱地址
-
Cat5e、Cat6、Cat6a和Cat7网线有什么区别?哪个更好?
2020年08月21日
-
一文带你了解SFP、SFP+、SFP28、QSFP+和QSFP28之间的区别
2024年04月13日
-
OM1、OM2、OM3、OM4和OM5多模光纤有什么区别?
2021年11月24日
-
SFP端口是什么?有什么作用?可以接RJ45吗?
2020年09月15日
-
QSFP-DD封装有何优势?800G光模块是否会沿用QSFP-DD封装?
2020年10月16日