Dell EMC Networking OS6 如何在 N 系列交换机中远程配置 RSPAN/捕获数据包或端口镜像

Summary: 本文介绍如何在 N 系列交换机中远程捕获数据包 (RSPAN)

This article applies to This article does not apply to This article is not tied to any specific product. Not all product versions are identified in this article.

Instructions

索引

什么是RSPAN
示例配置
配置
注意事项

 

什么是RSPAN

Dell EMC Networking N 系列交换机支持 RSPAN 目标,通过这些目标可通过运营网络隧道传输流量。镜像流量在 RSPAN VLAN 中通过任何中间交换机从源涌洪到目标。

警报: 反射器端口必须是中继或通用端口,并且 RSPAN vlan 不能是未标记的 vlan/本机。

对于本文档,我们将上行链路和下行链路端口配置为中继。但是,我们也可以使用通用端口。确保 RSPAN vlan 在端口中标记为 vlan。
 

示例配置

请考虑以下情形

  • 整个网络的 RSPAN Vlan 为 100
  • 我们需要监控端口 Gi 1/0/1(在源交换机中)连接到路由器,并且监控站连接到另一个交换机(目标交换机)端口 Gi1/0/10



源交换机

配置 RSPAN Vlan
SOURCE-SWITCH(config)#vlan 100
SOURCE-SWITCH(config-vlan100)#remote-span

Configure Downlink port
(connecting to destination switch)
SOURCE-SWITCH(config)#interface gigabitethernet 1/0/5
SOURCE-SWITCH(config-if-Gi1/0/5)#switchport mode trunk
SOURCE-SWITCH(config-if-Gi1/0/5)#switchport trunk allowed vlan add 100

Configure Monitor session
SOURCE-SWITCH(config)#monitor session 1 source interface gigabitethernet 1/0/1
SOURCE-SWITCH(config)#monitor session 1 destination remote vlan 100 reflector-port gigabitethernet 1/0/5
SOURCE-SWITCH(config)#monitor session 1 mode


DESTINATION-SWITCH

Configure RSPAN Vlan
DESTINATION-SWITCH(config)#vlan 100
DESTINATION-SWITCH(config-vlan100)#remote-span

配置上行链路端口
DESTINATION-SWITCH(config)#interface gigabitethernet 1/0/10
DESTINATION-SWITCH(config-if-Gi1/0/10)#switchport trunk allowed vlan add 100
DESTINATION-SWITCH(config-if-Gi1/0/10)#switchport mode trunk

Configure Monitor session
DESTINATION-SWITCH(config)#monitor session 1 source remote vlan 100
DESTINATION-SWITCH(config)#monitor session 1 destination interface gigabitethernet 1/0/15
DESTINATION-SWITCH(config)#monitor session 1 mode

 

验证

使用命令 show monitor session <session number>“

Sample output

Source-Switch



Destination-Switch



 

配置语法


RPAN VLAN

必须在源和目标交换机上配置 RSPAN Vlan
 

配置

说明

console#configure

进入配置模式

console(config)#vlan <Vlan ID>

创建 VLAN

console(config-vlanXXX)#remote-span

将 Vlan 指定为远程跨度


在下行链路(在源中)和上行链路(在目标中)中继接口中添加 RSPAN Vlan。
 

配置

说明

console#configure

进入配置模式

console(config)#interface <接口编号>

指定源


console(config-if-XXX)#switchport trunk allowed vlan add <RSPAN-Vlan-ID>

在中继端口中指定远程 vlan


源交换机
 

配置

说明

console#configure

进入配置模式

console(config)#monitor session <ID> 源接口 <接口>

指定源接口/端口通道

console(config)#monitor session <ID> destination remote vlan <VLAN-ID> reflector-port <Interface>

指定目标远程 vlan、反射器端口

console(config)#monitor session <会话 ID> 模式

激活监视会话



目标交换机
 

配置

说明

console#configure

进入配置模式

console(config)#monitor session <ID> source remote vlan <RSPAN-Vlan>

指定源接口/Vlan/Portchannel

console(config)#monitor session <ID> destination Interface <Interface >

指定目标接口

console(config)#monitor session <会话 ID> 模式

激活监视会话


 

注意事项

 
  • 源可以具有物理端口或 VLAN。它不能是两者的组合。
  • 我们建议在网络中保留唯一的 Vlan ID 用于端口监控。
  • 内部 CPU 不能是 RSPAN 的源端口。
  • 我们不能使用 RSPAN 来捕获源交换机(如 LLDP、ISDP、OSPF 等)生成的 CPU 流量。
  • 每个 RSPAN 会话都必须使用唯一的反射器端口、目标端口和 RSPAN VLAN。
  • 传输交换机应使用源交换机和目标交换机中使用的相同 RSPAN vlan ID   
  • 反射器端口(源/中转/目标)应配置为中继模式或常规模式,并且应是 RSPAN VLAN 的成员。请勿将其他端口分配给 RSPAN VLAN。
  • 配置 VLAN 镜像时,源 VLAN 不能与 RSPAN VLAN 相同。源 VLAN 和目标 RSPAN VLAN 不能配置在同一端口上。
  • 交换机本地生成并通过源端口传输的数据包不会在 RSPAN VLAN 镜像会话中镜像。
  • RSPAN vlan 只能在反射器端口中配置
  • 配置为反射器端口的端口也可以承载正常流量,我们可以允许其他 VLAN 通过它们
  • 一台源交换机中只允许一个 RSPAN 会话
  • 在 RSPAN 会话中进行配置之前,必须使用 remote-span 命令配置 RSPAN VLAN。
  • 如果 VLAN 的多个交换机成员上的源是 RSPAN,则不建议对 RSPAN 进行 VLAN 镜像。这是因为,当站点通过镜像 VLAN 相互通信时,将向探测器发送重复的数据包:一次用于源端口,一次用于源 VLAN 中接收数据包的每台交换机。

Affected Products

N Series, PowerSwitch N1100-ON Series, PowerSwitch N1500 Series, PowerSwitch N2000 Series, PowerSwitch N2100 Series, PowerSwitch N3000 Series, Dell EMC PowerSwitch N3000E-ON Series, Dell EMC PowerSwitch N3100 Series, Dell EMC Networking N3200-ON , PowerSwitch N4000 Series ...
Article Properties
Article Number: 000184776
Article Type: How To
Last Modified: 29 Apr 2021
Version:  2
Find answers to your questions from other Dell users
Support Services
Check if your device is covered by Support Services.