作者:叶澜╭
中职网络搭建神州数码内容
远程镜象RSPAN功能典型配置
组网说明
源交换机E 1/1口的收发流量需要镜象给目地交换机的E 1/2口,使用RSPAN功能完成上述要求。RSPAN使用的Vlan为Vlan 10。
配置步骤
源交换机的配置
#配置RSPAN,远程Vlan为Vlan 10
switch(config)#vlan 10
switch(config-Vlan10)#remote-span
switch(config-Vlan10)#exit
switch(config)#interface ethernet 1/24
switch(config-If-Ethernet1/24)#switchport mode trunk
switch(config-If-Ethernet1/24)#exit
switch(config)#monitor session 1 source interface ethernet 1/1 both
switch(config)#monitor session 1 destination interface ethernet 1/24
switch(config)#monitor session 1 remote vlan 10
中间交换机的配置
#指定远程Vlan为Vlan 10,配置端口模式为Trunk
switch(config)#vlan 10
switch(config-Vlan10)#remote-span
switch(config-Vlan10)#exit
switch(config)#interface ethernet 1/23-24
switch(config-If-Port-Range)#switchport mode trunk
switch(config-If-Port-Range)#exit
目地交换机的配置
#指定远程Vlan为Vlan 10,并将目地交换机的E 1/2端口划分到远程Vlan中
switch(config)#vlan 10
switch(config-Vlan10)#remote-span
switch(config-Vlan10)#exit
switch(config)#interface ethernet 1/24
switch(config-If-Ethernet1/24)#switchport mode trunk
switch(config-If-Ethernet1/24)#exit
switch(config)#interface ethernet 1/2
switch(config-If-Ethernet1/2)#switchport mode access
switch(config-If-Ethernet1/2)#switchport access vlan 10
switch(config-If-Ethernet1/2)#exit
注意事项
1.使用RSPAN功能时,远程Vlan不能在需要转发的设备上被做为Native Vlan使用。(本例中,SW 1/2/3上的Native Vlan都不能是Vlan 10)
2.使用RSPAN时,如果源端口的实际流量超过目地端口的实际流量,数据会丢失(比如源端口共有1500M数据,但目地端口是千兆,那只能接收1000M的数据)