使用MTrace检测组播网络
组播Tracert(Multicast trace route,以下简称MTrace),是一种组播路径的追踪工具,可以追踪某一接收者沿着组播分发树到组播源的路径。
前提条件
在本次检测开始前,对于需要检测的组播路径或者反向转发路径RPF(Reverse Path Forwarding)上的各设备,请执行undo mtrace echo disable命令使能对MTrace Request/Query报文的响应功能,避免MTrace检测被设备中止。
背景信息
在组播故障处理和日常维护中使用mtrace命令,有助于定位故障结点,减少配置错误。
执行mtrace命令,在追踪过程中收集流量信息。循环执行追踪过程,可以统计组播流速率。
网管通过分析mtrace命令输出的异常节点信息,产生告警信息或故障节点信息。
可在客户端所有视图下进行如下的配置。
操作步骤
- (可选)执行命令reset mtrace statistics清除MTrace报文统计信息。
执行reset mtrace statistics命令清除MTrace报文的统计信息后,相应的统计信息不能被恢复。
- 请根据需要选择配置:
说明:
为确保mtrace检测成功,要求当前设备必须存在相应的(S,G)表项,而且必须满足以下条件之一:- 当前设备与目的主机直接相连。
- 在当前设备能够Ping通最后一跳设备或者目的主机。
- 当前设备位于从组播源到目的主机的组播路径上。
下述配置只列出部分参数,详细选项及参数意义请参见mtrace。
执行命令mtrace source source-address检测从组播源到当前设备的RPF路径。
<HUAWEI> mtrace source 10.1.0.1 Press Ctrl+C to break multicast traceroute facility From the receiver(10.1.5.1), trace reverse path to source (10.1.0.1) according to RPF rules Num Reverse-Path FwdTTL Protocol 0 10.1.5.1 -1 10.1.5.1 1 PIM -2 10.1.2.1 1 PIM -3 10.1.0.1 1 PIM In maximum-hop mode, received the response message, and multicast traceroute finished.
执行命令mtrace -g group source source-address检测从组播源到当前设备的组播路径。
<HUAWEI> mtrace -g 225.0.0.1 -l 2 -st 10 source 10.1.0.1 Press Ctrl+C to break multicast traceroute facility From the receiver(10.1.5.1), trace (10.1.0.1, 225.0.0.1)'s reverse path according to multicast routing-table In calculating-rate mode, current statistic times is: 1 -1 10.1.5.1 Incoming Interface Address: 10.1.5.1 Input packets rate: 0xffffffff Outgoing Interface Address: 0.0.0.0 Output packets rate: 0xffffffff Forwarding Cache (10.1.0.1, 225.0.0.1) Forwarding packets rate: 0 The packet loss rate of (10.1.0.1, 225.0.0.1) is 0.00% -2 10.1.2.1 Incoming Interface Address: 10.1.2.1 Input packets rate: 0xffffffff Outgoing Interface Address: 10.1.5.2 Output packets rate: 0xffffffff Forwarding Cache (10.1.0.1, 225.0.0.1) Forwarding packets rate: 0 The packet loss rate of (10.1.0.1, 225.0.0.1) is 0.00% -3 10.1.0.1 Incoming Interface Address: 10.1.0.1 Input packets rate: 0xffffffff Outgoing Interface Address: 10.1.2.2 Output packets rate: 0xffffffff Forwarding Cache (10.1.0.1, 225.0.0.1) Forwarding packets rate: 0 ******************************************************** In calculating-rate mode, reach the demanded number of statistic,and multicast traceroute finished.
执行命令mtrace [ -gw last-hop-router | -d ] -r receiver source source-address检测从组播源到目的主机的RPF路径。
<HUAWEI> mtrace -gw 10.1.6.3 -r 10.1.6.4 -v source 10.1.0.1 Press Ctrl+C to break multicast traceroute facility From the receiver(11.1.6.4), trace reverse path to source (11.1.0.1) according to RPF rules Num Reverse-Path FwdTTL Protocol 0 10.1.6.4 -1 10.1.5.1 1 PIM Incoming Interface Address: 10.1.5.1 Outgoing Interface Address: 10.1.6.3 Previous-Hop Router Address: 10.1.5.2 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR -2 10.1.2.1 1 PIM Incoming Interface Address: 10.1.2.1 Outgoing Interface Address: 10.1.5.2 Previous-Hop Router Address: 10.1.2.2 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR -3 10.1.0.1 1 PIM Incoming Interface Address: 10.1.0.1 Outgoing Interface Address: 10.1.2.2 Previous-Hop Router Address: 0.0.0.0 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR In maximum-hop mode, received the response message, and multicast traceroute finished.
执行命令mtrace [ -b | -gw last-hop-router | -d ] -r receiver -g group source source-address检测从组播源到目的主机的组播路径。
<HUAWEI> mtrace -gw 10.1.6.3 -r 10.1.6.4 -v source 10.1.0.1 Press Ctrl+C to break multicast traceroute facility From the receiver(11.1.6.4), trace reverse path to source (11.1.0.1) according to RPF rules Num Reverse-Path FwdTTL Protocol 0 10.1.6.4 -1 10.1.5.1 1 PIM Incoming Interface Address: 10.1.5.1 Outgoing Interface Address: 10.1.6.3 Previous-Hop Router Address: 10.1.5.2 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR -2 10.1.2.1 1 PIM Incoming Interface Address: 10.1.2.1 Outgoing Interface Address: 10.1.5.2 Previous-Hop Router Address: 10.1.2.2 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR -3 10.1.0.1 1 PIM Incoming Interface Address: 10.1.0.1 Outgoing Interface Address: 10.1.2.2 Previous-Hop Router Address: 0.0.0.0 Input packet count on incoming interface: 0xffffffff Output packet count on outgoing interface: 0xffffffff Total number of packets for this source-group pair: 0xffffffff Forwarding TTL: 1 Forwarding Code: NO_ERROR In maximum-hop mode, received the response message, and multicast traceroute finished.
- (可选)执行命令display mtrace statistics查看当前MTrace报文统计信息。
如果mtrace命令检测结果异常,或者想了解组播网络中节点收发IGMP报文情况时,可以执行该命令。
- (可选)执行命令mtrace echo disable关闭对MTrace Request/Query报文的响应功能。
执行mtrace echo disable命令后会使设备丢弃MTrace Request/Query类型的报文,从而导致MTrace检测到此设备被中止。