MPLS百科
您的位置:网站首页 > MPLS百科 > 根据IP的繁杂流分类配置MPLS公网口

根据IP的繁杂流分类配置MPLS公网口

时间:2020-07-20 13:01 发布:http://www.pbsvpn.com 点击量:479

MPLS公网口为例子,介绍流分类、流行为的配置以及应用。

可用商品和版本号

适用V800R010C00及之后版本号的NE40E/ME60产品系列。

组网方案要求

如图所示1-74所显示,PE1、P、PE2为MPLS骨干网机器设备,CE1、CE2、CE3、CE4为骨干网边沿接入机器设备。以PE1为例子,根据在PE1的公网插口(即interface3)上配置根据IP的繁杂流分类对策,完成公网侧的流量监控,并能够根据流量监控认证报文的收发状况。

本例中interface1、interface2、interface5分钟别意味着GE0/1/0、GE0/2/0、GE0/3/0。

图1-74配置MPLS公网口根据IP的繁杂流分类实例图

配置构思

选用以下的构思配置根据繁杂流分类的流量对策:

配置MPLS基本要素。

配置对出/入公网方位的报文,根据IP层信息内容做繁杂流分类。

定义ACL标准。

定义流分类。

定义流行为。

定义流量对策。

应用流量对策。

数据准备

为进行此配置举例说明,需提前准备以下的数据:

ACL序号。

流分类、流行为、流量对策的姓名及其应用的接口号。

操作流程

1.配置MPLS基本要素(略)。

MPLS基本要素的配置,能够参照《HUAWEINE20E-S配置指南-VPN-BGP/MPLSIPVPN配置》中的配置BGP/MPLSIPVPN实例

2.配置对出/入公网方位的报文,根据IP层信息内容做繁杂流分类。

 system-view [~HUAWEI] sysname PE1[*HUAWEI] commit [~PE1] slot 1 [~PE1-slot-1] traffic-policy match-ip-layer mpls-pop [*PE1-slot-1] traffic-policy match-ip-layer mpls-push [*PE1-slot-1] commit[~PE1-slot-1] quit

3.定义ACL标准。

[~PE1] acl number 3333 [*PE1-acl-adv-3333] rule 5 permit ip source 11.11.11.11 0 destination 33.33.33.33 0[*PE1-acl-adv-3333] rule 10 permit ip source 33.33.33.33 0 destination 11.11.11.11 0 [*PE1-acl-adv-3333] commit[~PE1-acl-adv-3333] quit

4.定义流分类。

 [~PE1] traffic classifier c1  [*PE1-classifier-c1] if-match acl 3333  [*PE1-classifier-c1] commit  [~PE1-classifier-c1] quit

5.定义流行为。

[~PE1] traffic behavior b1[*PE1-behavior-b1] permit[*PE1-behavior-b1] commit[~PE1-behavior-b1] quit

6.定义流量对策。

[~PE1] traffic policy p1[*PE1-trafficpolicy-p1] classifier c1 behavior b1[*PE1-trafficpolicy-p1] share-mode [*PE1-trafficpolicy-p1] statistic enable[*PE1-trafficpolicy-p1] commit [~PE1-trafficpolicy-p1] quit

7.应用流量对策。

[~PE1] interface gigabitethernet 0/3/0 [~PE1-GigabitEthernet0/3/0] traffic-policy p1 inbound [*PE1-GigabitEthernet0/3/0] traffic-policy p1 outbound [*PE1-GigabitEthernet0/3/0] commit [~PE1-GigabitEthernet0/3/0] quit

8.查验配置結果。

进行所述配置后,能够最先在CE1上实行ping33.33.33.33指令,来对CE3进行ping实际操作,再在PE1上根据displaytrafficpolicystatistics命令来查询CE3与CE1中间的流量监控状况。

    [~PE1] display traffic policy statistics interface gigabitethernet 0/3/0 inbound    Info: The statistics is shared because the policy is shared.    Interface: GigabitEthernet0/3/0    Traffic policy inbound: p1    Traffic policy applied at 2017-08-30 18:30:20     Statistics enabled at 2017-08-30 18:30:20    Statistics last cleared: Never    Rule number: 1 IPv4, 0 IPv6     Current status: OK!    Item                             Packets                      Bytes    -------------------------------------------------------------------    Matched                                5                       500      +--Passed                            4                       400      +--Dropped                           1                       100    Last 30 seconds rate    Item                                 pps                        bps    -------------------------------------------------------------------    Matched                                5                       500      +--Passed                            4                       400      +--Dropped                           1                       100PE1的配置文件

PE1的配置文件

#sysname PE1#slot 1  traffic-policy match-ip-layer mpls-pop traffic-policy match-ip-layer mpls-push#acl number 3333 rule 5 permit ip source 11.11.11.11 0 destination 33.33.33.33 0 rule 5 permit ip source 33.33.33.33 0 destination 11.11.11.11 0#traffic classifier c1 if-match acl 3333#traffic behavior b1 permit#        traffic policy p1 share-mode statistic enable classifier c1 behavior b1#interface GigabitEthernet0/3/0 traffic-policy p1 inbound traffic-policy p1 outbound
以上就是五分钟内快速掌握MPLS基础介绍配置的介绍。
如果你还有其他问题,欢迎进行咨询探讨,希望我们的专业的解决方案,可以解决你目前遇到的这些问题。