配置IP FPM逐点性能统计功能
当用户发现网络存在丢包或者时延性能故障,希望准确定位发生性能故障的网络节点时,可以配置IP FPM逐点性能统计功能。
应用环境
- 当目标流是单向流时,该目标流可以直接用作逐点性能统计。
- 当目标流是双向流时:
- 目标流是对称的双向流,用户可以任意选取该双向流的正向流或者反向流用作逐点性能统计。
- 目标流是非对称的双向流,用户必须分别选取该双向流的正向流和反向流用作逐点性能统计,才能分别获取正向和反向的逐点性能统计结果。
通过IP FPM逐点性能统计功能获取的丢包和时延数据,同样为网络运维提供了有效的参考依据。网络管理员可以根据这些数据诊断网络故障,并及时对用户的业务进行调整,从而保证网络的可靠性,提升用户的用网体验。
配置MCP
MCP是IP FPM统计系统的控制角色,完成性能统计数据的收集、汇总和计算,并负责向用户终端或者网管系统发送性能统计结果。
背景信息
操作步骤
- 执行命令system-view,进入系统视图。
- 执行命令nqa ipfpm mcp,使能全局的MCP功能,并进入IPFPM-MCP视图。
- 执行命令mcp
id mcp-id,配置MCP的标识。
建议用户将MCP的标识配置为当前设备的Router ID。
MCP的标识必须是一个DCP可达的IP地址,并且该标识必须和用户在各关联DCP的统计实例下通过命令mcp mcp-id [ port port-number ]指定的MCP标识相同。如果用户需要修改MCP的标识,必须同步修改各关联DCP的统计实例下指定的MCP的标识,否则DCP和MCP之间的通信会中断。
- (可选)执行命令protocol udp port port-number,配置MCP上的UDP端口号,即MCP和DCP之间通信时使用的UDP端口号。
MCP上的UDP端口号必须和用户在各关联DCP的统计实例下通过命令mcp mcp-id [ port port-number ]指定的UDP端口号相同。如果用户需要修改MCP上的UDP端口号,必须同步修改各关联DCP的统计实例下指定的UDP端口号,否则各DCP从TLP收集的统计数据将无法上报MCP。
- (可选)执行命令authentication-mode hmac-sha256 key-id key-id [ cipher ] password,配置MCP上的认证模式和认证密码。
MCP上的认证模式和认证密码必须和用户在各关联的DCP上通过命令authentication-mode hmac-sha256 key-id key-id [ cipher ] password,配置的认证模式和认证密码相同,否则MCP将不能获取DCP上报的统计数据。
- 执行命令instance instance-id,创建IP FPM统计实例,并进入统计实例视图。
在IP FPM统计系统中,统计实例的标识instance-id必须在其所属MCP的管理域中唯一。且对于同一个统计实例,必须在MCP及其关联的所有DCP上同时配置,否则统计功能不生效。
- (可选)执行命令description text,配置统计实例的描述信息。
通过为统计实例添加详细的功能描述信息,可以帮助用户更好地理解该统计实例监控的业务和功能,避免造成用户对该统计实例的误解或者误用。
- 执行命令dcp dcp-id,指定统计实例包含的DCP的标识。
统计实例包含的DCP的标识必须和用户在DCP上通过命令dcp id dcp-id配置的DCP的标识相同,否则MCP无法收到DCP上报的统计数据。
- 配置原子闭合跳ACH(Atomic Closed Hop)。
ACH用来标识网络中指定两台设备之间的一段范围,由两个相邻的测量点组成。根据ACH的划分原则,可以将图2-7所示的组网划分为3个ACH,分别为ACH1:{ TLP100,TLP200 }、ACH2:{ TLP200,TLP300 }和ACH3:{ TLP200,TLP310 }。其中,ACH1中包含的目标流的入口和出口测量点组中的测量点分别为TLP100和TLP200;ACH2中包含的目标流的入口和出口测量点组中的测量点分别为TLP200和TLP300;ACH3中包含的目标流的入口和出口测量点组中的测量点分别为TLP200和TLP310。
- 执行命令ach ach-id,创建ACH,并进入ACH视图。
- 执行命令flow { forward | backward | bidirectional },配置进行逐点时延统计功能的目标流的方向。
执行命令in-group dcp dcp-id tlp tlp-id,配置目标流的入网络测量点组。
执行命令out-group dcp dcp-id tlp tlp-id,配置目标流的出网络测量点组。
配置DCP
DCP是IP FPM统计系统的关键角色,是IP FPM性能统计动作的执行者。DCP负责控制和管理各TLP,完成性能统计数据的收集,并负责向MCP上报性能统计数据。
背景信息
如图2-8所示,DeviceA、DeviceB和DeviceC均作为DCP,分别控制并管理TLP100、TLP200、TLP300和TLP310,完成性能统计数据的收集并向MCP上送收集到的性能统计数据。
为了实现上述功能,请在DeviceA、DeviceB和DeviceC上完成如下配置:
操作步骤
- 执行命令system-view,进入系统视图。
- 执行命令nqa ipfpm dcp,使能全局的DCP功能,并进入IPFPM-DCP视图。
- 执行命令dcp
id dcp-id,配置DCP的标识。
建议用户将DCP的标识配置为当前设备的Router ID。
DCP的标识必须和用户在MCP的统计实例下通过命令dcp dcp-id指定的DCP标识相同,否则MCP无法收到DCP上报的统计数据。
- (可选)执行命令authentication-mode hmac-sha256 key-id key-id [ cipher ] password,配置DCP上的认证模式和认证密码。
DCP上的认证模式和认证密码必须和用户在其所属的MCP上通过命令authentication-mode hmac-sha256 key-id key-id [ cipher ] password配置的认证模式和认证密码相同,否则MCP将不能获取DCP上报的统计数据。
- (可选)执行命令color-flag loss-measure { tos-bit tos-bit | flags-bit0 } delay-measure { tos-bit tos-bit | flags-bit0 },配置IP FPM测量统计使用的染色位。
部署IP FPM测量统计时,必须保证丢包、时延统计所使用的染色位各不相同,并且没有被其他统计使用。
- 执行命令mcp mcp-id [ port port-number ] [ vpn-instance vpn-instance-name | net-manager-vpn ],指定DCP上所有统计实例所属的MCP的标识,并配置DCP上的UDP端口号,即DCP和MCP之间通信时使用的UDP端口号。
DCP上的UDP端口号必须和用户在MCP上通过命令protocol udp port port-number配置的UDP端口号相同,否则DCP从TLP收集的统计数据将无法上报MCP。
如果用户希望DCP通过指定的VPN或者管理VPN向MCP发送统计数据,在执行该命令指定vpn-instance vpn-instance-name或者net-manager-vpn之前,必须保证DCP上已经成功创建了相应的VPN实例。
- (可选)执行命令period source ntp,指定IP
FPM计算统计周期号时优选NTP作为时钟源。
对于点到多点(最多两点)时延统计的场景,如果业务流量的入口设备采用的时钟源是NTP,但是出口设备采用了不同的时钟源(比如NTP和1588v2),用户需要为出口设备指定其计算IP FPM统计周期号时使用的时钟源为NTP,保持和入口设备的时钟源一致。
- 执行命令instance instance-id,创建IP FPM统计实例,并进入统计实例视图。
在IP FPM统计系统中,统计实例的标识instance-id必须在其所属MCP的管理域中唯一。且对于同一个统计实例,必须在DCP及其所属的MCP上同时配置,否则统计功能不生效。
- (可选)执行命令description text,配置统计实例的描述信息。
通过为统计实例添加详细的功能描述信息,可以帮助用户更好地理解该统计实例监控的业务和功能,避免造成用户对该统计实例的误解或者误用。
- (可选)执行命令interval interval,配置IP FPM统计实例的统计周期。
- 配置IP FPM统计实例中的目标流的流特征。根据目标流的类型不同,请用户选择如下方式中的一种进行配置:
配置正向或者反向目标流的流特征。
当参数protocol是TCP或者UDP协议时,配置目标流的流特征的命令格式为:
flow { forward | backward } { protocol { tcp | udp } { source-port src-port-number1 [ to src-port-number2 ] | destination-port dest-port-number1 [ to dest-port-number2 ] } * | dscp dscp-value | source src-ip-address [ src-mask-length ] | destination dest-ip-address [ dest-mask-length ] } *
当参数protocol是TCP和UDP之外的其他协议时,配置目标流的流特征的命令格式为:
flow { forward | backward } { protocol protocol-number | dscp dscp-value | source src-ip-address [ src-mask-length ] | destination dest-ip-address [ dest-mask-length ] } *
配置对称的双向目标流的流特征。当参数protocol是TCP或者UDP协议时,配置目标流的流特征的命令格式为:
flow bidirectional { protocol { tcp | udp } { source-port src-port-number1 [ to src-port-number2 ] | destination-port dest-port-number1 [ to dest-port-number2 ] } * | dscp dscp-value | source src-ip-address [ src-mask-length ] | destination dest-ip-address [ dest-mask-length ] } *
当参数protocol是TCP和UDP之外的其他协议时,配置目标流的流特征的命令格式为:
flow bidirectional { protocol protocol-number | dscp dscp-value | source src-ip-address [ src-mask-length ] | destination dest-ip-address [ dest-mask-length ] } *
说明:
如果IP FPM统计实例中的目标流是一条单向流,则用户只能指定forward配置一条正向流。
- 如果IP FPM统计实例中的目标流是一条双向流:
- 目标双向流是非对称的,则用户需要分别指定forward和backward配置正向流和反向流的流特征。
- 目标双向流是对称的,则用户只需要指定bidirectional配置一条双向流即可,此时配置的流特征默认为正向流的流特征,反向流的流特征默认为正向流的流特征的倒置。值得注意的是,当指定的目标流为对称的双向流时,用户必须同时配置src-ip-address和dest-ip-address为该目标流指定源IP和目的IP地址。
- 配置IP FPM统计实例包含的TLP。
执行命令tlp { in-point | out-point } { ingress | egress } [ vpn-label vpn-label ] [ backward-vpn-label backward-vpn-label ]配置IP FPM统计实例包含的入口测量点和出口测量点及其角色。
如图2-8所示,该网络包含的入口测量点为TLP100,出口测量点为TLP310。
执行命令tlp tlp-id mid-point flow { forward | backward } { ingress | egress } [ vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] ],配置IP FPM统计实例包含的中间测量点及其角色;对于负载分担共路场景,执行命令tlp tlp-id index index-id mid-point flow { forward | backward } { ingress | egress } vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] ],配置IP FPM统计实例包含的中间测量点及其角色。
如图2-8所示,该网络包含的中间测量点为TLP200和TLP300。
执行命令tlp tlp-id mid-point flow bidirectional { ingress | egress } [ forward { vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] } ] [backward { vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] } ],配置IP FPM统计实例包含的双向目标流的中间测量点及其角色;对于负载分担共路场景,执行命令tlp tlp-id index index-id mid-point flow bidirectional { ingress | egress } { forward vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] | backward vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] | forward vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] backward vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 lsp-label2 ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] },配置IP FPM统计实例包含的双向目标流的中间测量点及其角色。
执行命令tlp tlp-id mid-point flow { forward | backward } { ingress | egress } [ vpn-label vpn-label [ lsp-label lsp-label lsp-label2 { lsp-label2 | any } ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] } ],或执行tlp mid-point flow bidirectional { ingress | egress } [ forward { vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 { lsp-label2 | any } ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] } ] [backward { vpn-label vpn-label [ lsp-label lsp-label [ lsp-label2 { lsp-label2 | any } ] ] [ flow-label ] [ control-word ] [ l2vpn [ tpid tpid ] ] } ],配置IP FPM统计实例下TLP的TE标签为通配标签。
说明:
- 下行口带标签检测时,可能会出现标签重叠,配置tlp nexthop指定下一跳地址区分。
- tlp-id相同,会覆盖已有配置。
- 执行命令quit,退回IPFPM-DCP视图。
- 执行命令quit,退回系统视图。
- 配置TLP与设备接口的绑定关系。
执行命令interface interface-type interface-name,进入需要配置绑定测量点TLP的接口视图。
- 选择执行以下命令,配置测量点TLP和设备接口的绑定关系。
- 如果设备接口是三层接口:执行命令ipfpm tlp(三层接口) tlp-id。
- 如果设备接口是二层接口:执行命令ipfpm tlp(二层接口) tlp-id { ce-default-vlan | vlan-id vlan-id }。
- 执行命令quit,退回系统视图。
- 使能IP FPM逐点性能统计功能。
- 执行命令nqa ipfpm dcp,进入IPFPM-DCP视图。
- 执行命令instance instance-id,进入统计实例视图。
- 执行命令loss-measure enable mid-point [ time-range time-range | continual ],使能逐点丢包统计功能。
使能时延统计功能。
如果目标流是单向流,请用户根据自身需要选择如下方式中的一种进行配置:执行命令delay-measure enable one-way tlp mid-point [ time-range time-range ],使能按需的单向时延统计功能。
执行命令delay-measure enable one-way tlp mid-point continual,使能连续的单向时延统计功能。
如果目标流是双向流,请用户根据自身需要选择如下方式中的一种进行配置:执行命令delay-measure enable two-way tlp mid-point [ time-range time-range ],使能按需的双向时延统计功能。
执行命令delay-measure enable two-way tlp mid-point continual,使能连续的双向时延统计功能。
检查配置结果
通过查看MCP、DCP以及TLP的配置和状态信息,用户可以检查IP FPM逐点性能统计功能是否配置成功。
操作步骤
- 使用display ipfpm mcp命令查看IP FPM统计系统中MCP上的配置和状态信息。
- 使用display ipfpm dcp命令查看IP FPM统计系统中DCP上的配置信息。
- 使用display ipfpm statistic-type { loss | oneway-delay | twoway-delay } instance instance-id ach ach-id命令查看IP FPM统计系统中指定ACH内的逐点性能统计数据。
任务示例
执行命令display ipfpm mcp,可以查看IP FPM统计系统中MCP上的配置和状态信息。
<HUAWEI> display ipfpm mcp
Specification Information:
Max Instance Number :64
Max DCP Number Per Instance :256
Max ACH Number Per Instance :16
Max TLP Number Per ACH :16
Configuration Information:
MCP ID : 1.1.1.1
Status : Active
Protocol Port : 65030
Total Instances : 10
执行命令display ipfpm dcp,可以查看IP FPM统计系统中DCP上的配置信息。
<HUAWEI> display ipfpm dcp
Specification Information(Main Board):
Max Instance Number :64
Max 10s Instance Number :64
Max 1s Instance Number :--
Max TLP Number :512
Max TLP Number Per Instance :8
Configuration Information:
DCP ID : 2.2.2.2
Loss-measure Flag : tos-bit6(default)
Delay-measure Flag : tos-bit7(default)
Authentication Mode :hmac-sha256
Test Instances MCP ID :1.1.1.1
Test Instances MCP Port :65030
Total Instances : 10
执行命令display ipfpm statistic-type loss,查看IP FPM统计系统中指定ACH内的逐点丢包统计数据。
<HUAWEI> display ipfpm statistic-type loss instance 1 ach 1
Latest loss statistics of forward flow:
Unit: p - packet, b - byte
------------------------------------------------------------------------------------------
Period Loss(p) LossRatio(p) Loss(b) LossRatio(b)
------------------------------------------------------------------------------------------
136190088 10 10.000000% 1000 10.000000%
136190087 10 10.000000% 1000 10.000000%
136190086 10 10.000000% 1000 10.000000%
136190085 10 10.000000% 1000 10.000000%
136190084 10 10.000000% 1000 10.000000%
136190083 10 10.000000% 1000 10.000000%
136190082 10 10.000000% 1000 10.000000%
Latest loss statistics of backward flow:
Unit: p - packet, b - byte
------------------------------------------------------------------------------------------
Period Loss(p) LossRatio(p) Loss(b) LossRatio(b)
------------------------------------------------------------------------------------------
执行命令display ipfpm statistic-type oneway-delay,查看IP FPM统计系统中指定ACH内的单向逐点时延统计数据。
<HUAWEI> display ipfpm statistic-type oneway-delay instance 1 ach 1
Latest one-way delay statistics of forward flow:
--------------------------------------------------
Period Delay(usec) Delay
Variation(usec)
--------------------------------------------------
136190120 100 0
136190119 100 0
136190118 100 0
136190117 100 0
136190116 100 0
136190115 100 0
136190114 100 0
Latest one-way delay statistics of backward flow:
--------------------------------------------------
Period Delay(usec) Delay
Variation(usec)
--------------------------------------------------
执行命令display ipfpm statistic-type twoway-delay,查看IP FPM统计系统中指定统计实例内的双向时延统计数据。
<HUAWEI> display ipfpm statistic-type twoway-delay instance 1
Latest two-way delay statistics:
--------------------------------------------------
TimeStamp Delay(usec) Delay
Variation(usec)
--------------------------------------------------
136118757 800 0
136118756 800 0
136118755 800 0
136118753 800 0
136118752 800 0
136118751 800 0
136118750 800 0
136118749 800 0
136118748 800 0
136118747 800 0
136118746 800 0
136118745 800 0
Latest one-way delay statistics of bidirectional flow:
--------------------------------------------------------------------------------
TimeStamp Forward ForwardDelay Backward BackwardDelay
Delay(usec) Variation(usec) Delay(usec) Variation(usec)
--------------------------------------------------------------------------------
136118757 400 0 400 0
136118756 400 0 400 0
136118755 400 0 400 0
136118753 400 0 400 0
136118752 400 0 400 0
136118751 400 0 400 0
136118750 400 0 400 0
136118749 400 0 400 0
136118748 400 0 400 0
136118747 400 0 400 0
136118746 400 0 400 0
136118745 400 0 400 0