华为 | SD-WAN场景丢包类问题定位

SD-WAN场景丢包类问题定位

现象描述

SD-WAN场景报文转发路径比较复杂,遇到丢包类问题,建议通过流量统计分析报文转发路径,从而定位丢包类问题。

网络拓扑与流量转发路径

SD-WAN分为集中上网和本地上网两种场景,不同的场景流量的转发路径有所不同。集中上网的场景下,流量通过业务隧道进行封装转发到HUB;而在本地上网的场景下,流量是通过内环隧道不做封装转发。

流量统计通常需要部署的位置有:LAN口,WAN口,业务隧道口,内环隧道口,双网关InterLink口。

集中上网场景下,流量的通常的转发路径有两种:

  1. 转发路径:LAN口(CPE1)------>业务隧道口(CPE1的Tunnel0/0/601)------>WAN(CPE1的Underlay口):

  2. 转发路径:LAN口(CPE1)------>双网关InterLink口(CPE1)------>业务隧道口(CPE2的Tunnel0/0/601)------>WAN(CPE2的Underlay口):

本地上网场景下,转发路径如下所示:

转发路径:LAN口(CPE1)------>内环隧道(CPE1 Tunnel0/0/1)------>WAN(CPE1的underlay口):

部署流量统计

可以通过控制器或者通过命令行部署流量统计,建议通过控制器完成。

通过控制器的操作如下所示:

  1. 在主菜单中选择"网络维护 > 网络诊断 > 诊断工具",单击"流量统计任务"页签。

  2. 创建流量统计任务:单击"创建"。

  3. 在"选择站点"处,单击"新增",选择需要创建流量统计任务的站点。

  4. 在设备列表中单击"新增",增加需要进行流量统计的设备和接口,配置完成后,单击

    保存该条配置,若需要对该设备的多个接口进行流量统计,可以继续单击"新增"进行增加。

  5. 若需要在同一任务里对多个站点进行流量统计,可以在"选择站点"页签单击增加,继续增加设备,并在该设备的接口上配置流量统计。

  6. 配置完成后单击"确认",可以在流量统计任务界面查看已创建的流量统计任务。

  7. 单击任务名称,进入"任务详情"页面,可以查看详细的流量统计。单击"重置",可清除此任务的流量统计。

    在执行查询功能或者清除流量统计功能时,需要设备在线才能生效。

  8. 选择站点,可以同时选择两个站点查看站点上不同设备的接口的流量统计信息。

通过命令行的方式如下所示:

1:跟客户确定存在丢包的业务流特征,源目的IP地址、协议号端口号,配置未使用的ACL,用于部署在LAN口、业务隧道口、双网关InterLink口、内环隧道口、WAN口。

配置部署在LAN口的ACL:

复制代码
acl number 3000description LAN  rule5 permit ip source 172.16.1.10 destination 172.16.2.20rule10 permit ip source 172.16.2.20 destination 172.16.1.10 

配置部署在业务隧道口的ACL:

复制代码
acl number 3001description ServiceTunnel  rule5 permit ip source 172.16.1.10 destination 172.16.2.20rule10 permit ip source 172.16.2.20 destination 172.16.1.10 

配置部署在双网关InterLink口的ACL:

复制代码
acl number 3002description interlink rule5 permit ip source 172.16.1.10 destination 172.16.2.20rule10 permit ip source 172.16.2.20 destination 172.16.1.10 

配置部署在内环隧道口的ACL:

复制代码
acl number 3003description UnderlayTunnel rule5 permit ip source 172.16.1.10 destination 172.16.2.20rule10 permit ip source 172.16.2.20 destination 172.16.1.10 

配置部署在WAN口的ACL:

复制代码
acl number 3004description Underlay rule5 permit ip source 172.16.1.10 destination 172.16.2.20rule10 permit ip source 172.16.2.20 destination 172.16.1.10

2:在相应的接口下部署对应的ACL。

在LAN口部署对应的ACL。

复制代码
interface Vlanif2ip binding vpn-instance vpn1tcp adjust-mss 1200ip address 192.168.103.1255.255.255.0traffic-policy mqcinAcl1 inbound preprocesstraffic-filter inbound acl 3000traffic-filter outbound acl 3000sa application-statistic enable
复制代码

在WAN口部署对应的ACL。其中R23C00版本后支持解封装后统计,且隧道口配置了对原始报文信息的预提取,可以匹配原始报文,多个Underlay口能区分从哪个WAN口发送出去。

复制代码
interface GigabitEthernet0/0/8set flow-stat interval 10ip binding vpn-instance underlay_1tcp adjust-mss 1200ip address 192.168.12.55255.255.255.240nat static protocol tcp global current-interface 50000 inside 192.168.233.2344000 vpn-instance OPENSSHLINKVPORT netmask 255.255.255.255nat static protocol tcp global current-interface 50001 inside 192.168.233.2344001 vpn-instance OPENSSHLINKVPORT netmask 255.255.255.255nat outbound 3178qos pre-natqos gts cir 102400 cbs 2560000traffic-filter inbound acl 3004 decap-processtraffic-filter outbound acl 3004 

在双网关InterLink口部署对应的ACL。

复制代码
interface GigabitEthernet0/0/9.4000dot1q termination vid 4000ip binding vpn-instance vpn1ip address 192.168.22.33255.255.255.0traffic-filter inbound acl 3002traffic-filter outbound acl 3002sa application-statistic enable
复制代码

在内环隧道口部署对应的ACL,用于本地上网的场景。

​​​​​​​

复制代码
interface Tunnel0/0/1description physical port: GigabitEthernet0/0/8ip binding vpn-instance vpn1ip address 10.10.0.27255.255.255.248tunnel-protocol gresource LoopBack101destination vpn-instance vpn1 10.10.0.26ip netstream sampler fix-packets 1 inboundip netstream sampler fix-packets 1 outboundip netstream inboundip netstream outboundqos group 1traffic-filter inbound acl 3003traffic-filter outbound acl 3003sa application-statistic enable
复制代码

在业务隧道口部署对应的ACL,可以判断是否走隧道封装。

复制代码
interface Tunnel0/0/600description evpn tunneltcp adjust-mss 1102vpn-mapping enableip address 10.10.0.236255.255.255.255tunnel-protocol svpnip netstream sampler fix-packets 1 inboundip netstream sampler fix-packets 1 outboundip netstream inboundip netstream outboundqos pre-classifyipsec p2mp-policy enableweak-state-control enablesa application-statistic enable#interface Tunnel0/0/601description evpn tunnelip binding vpn-instance vpn1tcp adjust-mss 1102vpn-mapping enableip address 10.10.0.238255.255.255.255tunnel-protocol svpnip netstream sampler fix-packets 1 inboundip netstream sampler fix-packets 1 outboundip netstream inboundip netstream outboundqos pre-classifyqos group 1weak-state-control enabletraffic-filter decap-process enable traffic-filter inbound acl 3001traffic-filter outbound acl 3001sa application-statistic enable
  1. 查询流量统计信息。

基于ACL的查询:

​​​​​​​

复制代码
[huawei]display acl 3000AdvancedACL3000, 2 rulesLAN Acl's step is5  rule 5 permit ip source 172.16.1.10 destination 172.16.2.20 (5 matches) rule 10 permit ip source 172.16.2.20 destination 10.1.1.10 (5 matches)

基于接口的查询:

​​​​​​​

复制代码
[Huawei]display traffic-filter statistics interfaceGigabitEthernet 0/0/8 outboundverboserule-base-----------------------------------------------------------*interfaceGigabitEthernet0/0/8 outboundrule 5 permit ip source 172.16.1.10 destination 172.16.2.20Passed Packet 0,Passed Bytes 0Dropped Packet 0,Dropped Bytes 0rule 10 permit ip source 172.16.2.20 destination 172.16.1.10Passed Packet 5,Passed Bytes 610Dropped Packet 0,Dropped Bytes 0

FAQ
问题:怎么确定流量走了哪个connect连接,然后在对端设备部署流量统计?

回答:转发面可以通过打印connect模块确定流量走了哪个connect连接。步骤如下:

设置报文特征。

复制代码
[diagnose]set forward debug-packet-filter destination-ip 10.252.5.5
复制代码

打印Connect 模块看encap走哪个connectid。

复制代码
[diagnose]debugging forward connect packet debug-num 20 verbose

查看连接信息,找到对应connectid对应的源和目的IP地址,通过Destnation IP地址找到对端的设备。

复制代码
[diagnose]display evpn connection

清除debug报文特征。

复制代码
[diagnose]clear forward debug-packet-filter

问题:如何判断流量是走本地上网还是走集中上网?

回答:本地上网会做underlay的nat,通常有两张流表,一个是underlay的流表,一个是overlay的流表。可通过以下命令查询流表,如果存在两张流表说明流量是走本地上网,反之如果只有overlay的流表则流量走集中上网。

复制代码
[diagnose]display session source 192.168.92.26 destination 212.129.162.xxx verbose
相关推荐
yenggd14 小时前
centos系统apache支持php配置
centos·php·apache
liulilittle15 小时前
OPENPPP2 —— IP标准校验和算法深度剖析:从原理到SSE2优化实现
网络·c++·网络协议·tcp/ip·算法·ip·通信
北极光SD-WAN组网17 小时前
从0到1搭建某铝箔智慧工厂网络:5G与WiFi 6助力智能制造
网络·5g·制造
阿昭L17 小时前
HTTP原理
网络·网络协议·http
hazy1k18 小时前
STM32H750 RTC介绍及应用
网络·stm32·实时音视频
没书读了18 小时前
考研复习-计算机网络-第三章-数据链路层
网络·计算机网络·考研
on the way 12319 小时前
多线程之HardCodedTarget(type=OssFileClient, name=file, url=http://file)异常
网络·网络协议·http
WhoisXMLAPI19 小时前
WhoisXML API再次荣登2025年美国Inc. 5000快速成长企业榜单
网络·安全
爱笑的眼睛1119 小时前
HarmonyOS 应用开发新范式:深入剖析 Stage 模型与 ArkTS 状态管理
华为·harmonyos
阿sir19820 小时前
ZYNQ 自定义IP
服务器·网络·tcp/ip