华为路由器限速:MQC限速和QOS

phxc8 3月前 80

MQC
#创建acl匹配源IP地址
acl number 2000
 rule 5 permit source 10.5.1.0 0.0.0.255

#配置流分类
traffic classifier c1 operator and
 if-match acl 2000
 if-match protocol ip
 if-match any

#配置流行为
traffic behavior 10m
 permit
 car cir 10240 pir 10240 cbs 1250000 pbs 1250000 green pass yellow pass red discard
 statistic enable
traffic behavior 5m
 permit                                   
 car cir 4000 pir 5000 cbs 625000 pbs 625000 green pass yellow pass red discard
 statistic enable
traffic behavior 8m
 permit
 car cir 8000 pir 8000 cbs 1000000 pbs 1000000 green pass yellow pass red discard
 statistic enable

#绑定流行为和流分类
traffic policy vlan10-s-5m match-order config
 classifier c1 behavior 5m
traffic policy vlan10-x-8m match-order config
 classifier c1 behavior 8m


#挂到接口上去
vlan 10
 traffic-policy vlan10-s-5m inbound
 traffic-policy vlan10-x-8m outbound
结果查询:
<HEXIN-SWH>dis traffic policy statistics vlan 10 inbound 

 Vlan: 10
 Traffic policy inbound: vlan10-s-5m
 Rule number: 1
 Current status: success
 Statistics interval: 300
---------------------------------------------------------------------
 Board : 0
---------------------------------------------------------------------
 Matched          |      Packets:                       149,116
                  |      Bytes:                     155,063,292
                  |      Rate(pps):                           0
                  |      Rate(bps):                           0
---------------------------------------------------------------------
   Passed         |      Packets:                       130,921
                  |      Bytes:                     129,841,006
                  |      Rate(pps):                           0
                  |      Rate(bps):                           0
---------------------------------------------------------------------
   Dropped        |      Packets:                        18,195
                  |      Bytes:                      25,222,286
                  |      Rate(pps):                           0
                  |      Rate(bps):                           0
---------------------------------------------------------------------
     Filter       |      Packets:                             0
                  |      Bytes:                               0
---------------------------------------------------------------------
     Car          |      Packets:                        18,195
                  |      Bytes:                      25,222,286
---------------------------------------------------------------------


 
<HEXIN-SWH>dis traffic policy statistics vlan 10 outbound 

 Vlan: 10
 Traffic policy outbound: vlan10-x-8m
 Rule number: 1
 Current status: success
 Statistics interval: 300
---------------------------------------------------------------------
 Board : 0
---------------------------------------------------------------------
 Matched          |      Packets:                       120,992
                  |      Bytes:                      68,640,084
                  |      Rate(pps):                         400
                  |      Rate(bps):                   1,824,824
---------------------------------------------------------------------
   Passed         |      Packets:                       120,992
                  |      Bytes:                      68,640,084
                  |      Rate(pps):                         400
                  |      Rate(bps):                   1,824,824
---------------------------------------------------------------------
   Dropped        |      Packets:                             0
                  |      Bytes:                               0
                  |      Rate(pps):                           0
                  |      Rate(bps):                           0
---------------------------------------------------------------------
     Filter       |      Packets:                             0
                  |      Bytes:                               0
---------------------------------------------------------------------
     Car          |      Packets:                             0
                  |      Bytes:                               0
---------------------------------------------------------------------
<HEXIN-SWH>
Info: The max number of VTY users is 10, and the number
      of current VTY users on line is 0.
QOS
interface GigabitEthernet0/0/1
 undo portswitch
 ip address 10.5.255.1 255.255.255.248

上传:
 qos car inbound source-ip-address range 10.5.1.2 to 10.5.1.199 per-address cir 4000 pir 5000 cbs 500000 pbs 625000 green pass yellow pass red discard
 下载
 qos car outbound destination-ip-address range 10.5.1.2 to 10.5.1.254 per-address cir 8000 pir 10000 cbs 1000000 pbs 1250000 green pass yellow pass red discard

最新回复 (0)
返回
发新帖