No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Configuration Examples for NE and ME60 Routers in Typical Enterprise Scenarios 2.0

This document provides NE series routers typical configuration examples.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
QoS

QoS

Example for Configuring a Traffic Policy to Limit the Rate of High-Bandwidth Traffic

This section provides an example for configuring a traffic policy to limit the rate of high-bandwidth traffic to protect the bandwidth of key services on the network.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

In Figure 1-65, the traffic rate of Eth-Trunk 1, which connects the edge router PE1 of a WAN to LAN X, exceeds the limit. According to fault locating results, a host with the IP address 10.1.1.1/32 on LAN X is downloading many files from a remote server with the IP address 10.2.1.1/32, causing excessive bandwidth consumption. You can limit the traffic rate to protect the bandwidth of key services on the network.

Figure 1-65  Configuring a traffic policy to limit the rate of high-bandwidth traffic
Configuration Roadmap
  1. Configure an advanced ACL to match traffic with the source address 10.1.1.1/32 and destination address 10.2.1.1/32.

  2. Configure a traffic classifier and specify the ACL in the traffic classifier.

  3. Configure a traffic behavior and set its action to CAR.

  4. Configure a traffic policy, and associate the traffic classifier with the traffic behavior in this policy.

  5. Apply the traffic policy to the inbound interface.

Procedure

  1. Configure an advanced ACL on PE1 to match high-bandwidth traffic.

    #
    system-view                                                   //Enter the system view.
    #
    acl name flow-limit advance                                   //Configure an advanced ACL named flow-limit to match high-bandwidth traffic.
    rule 5 permit ip source 10.2.1.1 0 destination 10.1.1.1 0     //Match traffic with the source IP address of 10.2.1.1 and the destination IP address of 10.1.1.1
    #
    

  2. Configure a traffic classifier.

    #
    traffic classifier flow-limit operator or                 //Configure a traffic classifier named flow-limit.
    if-match acl name flow-limit                              //Specify the ACL named flow-limit.
    #
    

  3. Configure a traffic behavior.

    #
    traffic behavior flow-limit                                //Configure a traffic behavior named flow-limit.
    car cir 10 pir 10 green pass yellow discard red discard    //Limit the traffic rate. In this example, the values of CIR and PIR are 10 kbps. Set these values according to your actual situation.
    #
    

  4. Configure a traffic policy.

    #
    traffic-policy flow-limit                                  //Configure a traffic policy named flow-limit.
    classifier flow-limit behavior flow-limit                  //Associate the traffic classifier with the traffic behavior in the traffic policy.
    #
    

  5. Apply the traffic policy.

    #
    interface Eth-trunk 1                                      //Enter the view of the inbound interface of high-bandwidth traffic. In this example, the inbound interface is Eth-Trunk 1. Specify an interface according to your actual situation.
     traffic-policy flow-limit outbound                        //Apply the traffic policy to the interface.
    #
    

  6. Verify the configuration.

    Run the display interface [ interface-type [ interface-number ] ] command to view traffic information of the specified interface.

Example for Configuring a Traffic Policy to Block Traffic

This section provides an example for configuring a traffic policy to block traffic to prevent multicast protocol packets from affecting the MAN.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

In Figure 1-66, a MAN carries multicast services, and multicast replication points are located on the MAN edge router. To prevent multicast protocol packets from affecting the MAN, the multicast protocol packets sent by the downstream devices must be blocked on the edge devices of the MAN.

Figure 1-66  Configuring a traffic policy to block traffic
Configuration Roadmap
  1. Configure an advanced ACL to match multicast protocol packets such as those of PIM and IGMP.

  2. Configure a traffic classifier and specify the ACL in the traffic classifier.

  3. Configure a traffic behavior and set its action to deny.

  4. Configure a traffic policy and associate the traffic classifier with the traffic behavior in this policy.

  5. Apply the traffic policy to all network-side interfaces.

Procedure

  1. Configure an advanced ACL to match multicast protocol packets such as those of PIM and IGMP.

    #
    system-view                                                //Enter the system view.
    #
    acl number 3001                                           //Configure an ACL.
     rule 10 permit 103 destination 224.0.0.13 0               
     rule 20 permit igmp destination 224.0.0.1 0               
     rule 30 permit ip source 10.89.8.0 0.0.0.255 
     rule 40 permit ip source 10.222.8.0 0.0.0.255 
    #
    #
    

  2. Configure a traffic classifier.

    #
    traffic classifier 3001 operator or                     //Configure a traffic classifier.
     if-match acl 3001
    #
    

  3. Configure a traffic behavior.

    #
    traffic behavior 3001                                   //Configure a traffic behavior.
     deny
    #
    

  4. Configure a traffic policy.

    #
    traffic policy LOOP_AVOID                             //Configure a traffic policy.
     share-mode
     statistics enable
     classifier 3001 behavior 3001
    #
    

  5. Apply the traffic policy.

    #
    interface Eth-Trunk1
     traffic-policy LOOP_AVOID outbound                  //Apply the traffic policy.
     trust upstream default
    #
    

  6. Verify the configuration.

    Run the display interface [ interface-type [ interface-number ] ] command to view traffic information of the specified interface.

Example for Configuring IP-based Complex Traffic Classification

This section provides an example of how to configure IP-based complex traffic classification.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

As shown in Figure 1-67, MF classification is configured on Device C to implement access control between Device A and Device B. In addition, traffic statistics can be collected to verify packet sending and receiving.

NOTE:

Interfaces 1 and 2 in this example are GE 0/1/0 and GE 0/2/0, respectively.

Figure 1-67  Configuring a traffic policy based on MF classification

Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure an ACL rule.

  2. Configure a traffic classifier.

  3. Configure a traffic behavior.

  4. Configure a traffic policy.

  5. Apply the traffic policy.

Data Preparation

To complete the configuration, you need the following data:

  • ACL number

  • Names of the traffic classifier, traffic behavior, and traffic policy, and number of the interface to which the traffic policy is applied

Procedure

  1. Configure an ACL rule.

    <HUAWEI> system-view
    [~HUAWEI] sysname DeviceC
    [*HUAWEI] commit
    [~DeviceC] acl number 3333
    [*DeviceC-acl-adv-3333]rule 5 permit ip source 1.1.1.1 0 destination 2.2.2.2 0
    [*DeviceC-acl-adv-3333]rule 10 permit ip source 2.2.2.2 0 destination 1.1.1.1 0
    [*DeviceC-acl-adv-3333] commit
    [~DeviceC-acl-adv-3333] quit

  2. Configure a traffic classifier.

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

  3. Configure a traffic behavior.

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

  4. Configure a traffic policy.

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

  5. Apply the traffic policy.

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

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

  6. Verify the configuration.

    After completing the configurations, run the ping 2.2.2.2 command on Device A to ping Device B, and run the display traffic policy statistics command on Device C to view statistics about traffic exchanged between Device A and Device B.

    [~DeviceC] display traffic policy statistics interface gigabitethernet 0/1/0 inbound
    Info: The statistics is shared because the policy is shared.
    Interface: GigabitEthernet0/1/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                       100
    

Configuration File on Device C
#
sysname DeviceC
#
acl number 3333
 rule 5 permit ip source 1.1.1.1 0 destination 2.2.2.2 0
 rule 10 permit ip source 2.2.2.2 0 destination 1.1.1.1 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/1/0
 traffic-policy p1 inbound
 traffic-policy p1 outbound
#
interface GigabitEthernet0/2/0
 traffic-policy p1 inbound
 traffic-policy p1 outbound

Example for Configuring IP-based Multi-Field Classification on an MPLS Interface

This section provides an example for configuring IP-based multi-field (MF) classification on an MPLS interface.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

As shown in Figure 1-68, PE1, P, and PE2 are routers on an MPLS backbone network. CE1, CE2, CE3, and CE4 are access routers on the edge of the backbone network. Use PE1 as an example. You can configure IP-based MF classification on the public network interface (interface 3) of PE1 to implement traffic control on the public network side and verify the packet sending and receiving through traffic statistics.

NOTE:

Interfaces 1 through 3 in this example are GE 0/1/0, GE 0/2/0, and GE 0/3/0, respectively.

Figure 1-68  Configuring IP-based MF classification on an MPLS interface

Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure basic MPLS functions.

  2. Configure IP-based MF classification for outgoing or incoming packets on the public network interface.

  3. Configure an ACL rule.

  4. Configure a traffic classifier.

  5. Configure a traffic behavior.

  6. Configure a traffic policy.

  7. Apply the traffic policy.

Data Preparation

To complete the configuration, you need the following data:

  • ACL number

  • Names of the traffic classifier, traffic behavior, and traffic policy, and number of the interface to which the traffic policy is applied

Procedure

  1. Configure basic MPLS functions.

    For details about how to configure basic MPLS functions, see Example for Configuring BGP/MPLS IP VPN in HUAWEI NE20E-S Configuration Guide - VPN - BGP/MPLS IP VPN Configuration.

  2. Configure IP-based MF classification for outgoing or incoming packets on the public network interface.

    <HUAWEI> 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. Configure an ACL rule.

    [~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. Configure a traffic classifier.

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

  5. Configure a traffic behavior.

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

  6. Configure a traffic policy.

    [~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. Apply the traffic policy.

    [~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. Verify the configuration.

    After completing the configurations, run the ping 33.33.33.33 command on CE1 to ping CE3, and run the display traffic policy statistics command on PE1 to view statistics about traffic exchanged between CE3 and 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                       100
    

Configuration Files on 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

Example for Configuring Redirection on Dual Outbound Interfaces

This section provides an example for configuring redirection on dual outbound interfaces.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

As shown in Figure 1-69, Device A connects to the intranet through interface 1 and connects to the public network through interface 2 and interface 3. By default, traffic from the intranet is transmitted to the public network through interface 3. To enable traffic from the server to be transmitted to the public network through interface 2 and other traffic to the public network through interface 3, configure a traffic policy on Device A.

NOTE:

Interfaces 1 through 3 are GE 0/1/0, GE 0/2/0, and GE 0/3/0, respectively.

Figure 1-69  Configuring redirection on dual outbound interfaces
Configuration Roadmap

The configuration roadmap is as follows:

  1. Configure a default route.

  2. Configure an ACL rule.

  3. Configure traffic classifiers.

  4. Configure traffic behaviors.

  5. Configure a traffic policy.

  6. Apply the traffic policy.

Data Preparation

To complete the configuration, you need the following data:

  • ACL number

  • Names of the traffic classifier, traffic behavior, and traffic policy, and number of the interface to which the traffic policy is applied

Procedure

  1. Configure the default route so that intranet traffic is transmitted to the public network through interface 3 by default and interface 2 is used as the backup outbound interface.

    <HUAWEI> system-view
    [~HUAWEI] ip route-static 0.0.0.0 0.0.0.0 10.1.99.1
    [*HUAWEI] ip route-static 0.0.0.0 0.0.0.0 10.1.99.5 pre 70
    [*HUAWEI] commit

  2. Configure an ACL rule.

    # Configure rule 3001 to match the traffic from the server to other devices on the intranet.

    [~HUAWEI]acl 3001
    [*HUAWEI-acl-adv-3001]rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.40.0 0.0.0.255
    [*HUAWEI-acl-adv-3001]rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.41.0 0.0.0.255 
    [*HUAWEI-acl-adv-3001]rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.42.0 0.0.0.255 
    [*HUAWEI-acl-adv-3001]commit
    [~HUAWEI-acl-adv-3001]quit

    # Configure rule 3002 to match the traffic with the source address being the IP address of the server.

    [~HUAWEI] acl 3002
    [*HUAWEI-acl-adv-3002] rule permit ip source 10.1.40.0 0.0.0.255
    [*HUAWEI-acl-adv-3002] commit
    [~HUAWEI-acl-adv-3001]commit

  3. Configure traffic classifiers.

    # Configure a traffic classifier named c1.

    [~HUAWEI]traffic classifier c1
    [*HUAWEI-classifier-c1]if-match acl 3001
    [*HUAWEI-classifier-c1]commit
    [~HUAWEI-classifier-c1]quit

    # Configure a traffic classifier named c2.

    [~HUAWEI]traffic classifier c2
    [*HUAWEI-classifier-c2]if-match acl 3002
    [*HUAWEI-classifier-c2]commit
    [~HUAWEI-classifier-c2]quit

  4. Configure traffic behaviors.

    # Configure a traffic behavior named b1.

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

    # Configure a traffic behavior b2.

    [~HUAWEI] traffic behavior b2
    [*HUAWEI-behavior-b2] redirect ip-nexthop 10.1.99.5
    [*HUAWEI-behavior-b2] commit
    [~HUAWEI-behavior-b2] quit

  5. Configure a traffic policy.

    [~HUAWEI] traffic policy p1
    [*HUAWEI-trafficpolicy-p1] classifier c1 behavior b1
    [*HUAWEI-trafficpolicy-p1] classifier c2 behavior b2
    [*HUAWEI-trafficpolicy-p1] commit
    [~HUAWEI-trafficpolicy-p1] quit

  6. Apply the traffic policy.

    [~HUAWEI] interface gigabitethernet 0/1/0
    [~HUAWEI-GigabitEthernet0/1/0] traffic-policy p1 inbound
    [*HUAWEI-GigabitEthernet0/1/0] commit
    [~HUAWEI-GigabitEthernet0/1/0] quit

  7. Verify the configuration.

    After completing the configurations, run the display traffic policy command on Device A to view the configurations of the traffic policy, traffic classifier, and traffic behavior.

    [~HUAWEI] display traffic policy user-defined p1
      User Defined Traffic Policy Information:                                      
        Policy: p1                                                                  
          Total: 5120  Used: 3  Free: 5117                                          
          Description:                                                              
          Step: 1                                                                   
          Share-mode                                                                
          Classifier: c1 Precedence: 1                                              
            Behavior: b1                                                            
            -none-                                                                  
                                                                                    
          Classifier: c2 Precedence: 2                                              
            Behavior: b2                                                            
            Redirecting:                                                            
              redirect ip-nexthop 10.1.99.5                                         
                                                                                    
          Classifier: default-class Precedence: 65535                               
            Behavior: be                                                            
            -none-                              

Configuration Files
#
ip route-static 0.0.0.0 0.0.0.0 10.1.99.1     
ip route-static 0.0.0.0 0.0.0.0 10.1.99.5 pre 70  
#
acl 3001
 rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.40.0 0.0.0.255    
 rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.41.0 0.0.0.255    
 rule permit ip source 10.1.40.0 0.0.0.255 destination 10.1.42.0 0.0.0.255
acl 3002
 rule permit ip source 10.1.40.0 0.0.0.255                   
#
traffic classifier c1
 if-match acl 3001
traffic classifier c2
 if-match acl 3002
#
traffic behavior b1
 permit                     
traffic behavior b2
 redirect ip-nexthop 10.1.99.5   
#
traffic policy p1
 classifier c1 behavior b1      
 classifier c2 behavior b2            
#
interface gigabitethernet0/1/0
 traffic-policy p1 inbound
#
return

Example for Configuring Congestion Avoidance

This section provides an example of how to configure congestion avoidance. A device on which congestion avoidance is configured checks the use of network resources and starts to discard packets when it determines that congestion is intensifying.

Applicable Products and Versions

This configuration example applies to NE40E/ME60 series products running V800R010C00 or later.

Networking Requirements

As shown in Figure 1-70, Server sends mission-critical data, Telephone sends voice data, and PC1 and PC2 send non-mission-critical data to the network through Device A. On Device A, the rate of the inbound interface GE 0/1/0 is greater than that of the outbound interface GE 0/2/0. Therefore, congestion may occur on GE 0/2/0 and may be intensifying.

In the case of network congestion, the service data from the server and the telephone must be preferentially sent. In addition, the telephone requires 5 Mbit/s bandwidth, and the server requires 4 Mbit/s bandwidth. As PC1 and PC2 are VIP users, bandwidth must be assured for the data that PC1 and PC2 send. The delay must be as low as possible. If congestion intensifies on the network, packets are dropped according to priority.

In this scenario, WFQ and WRED need to be configured on Device A.

NOTE:

Interfaces 1 through 2 in this example are GE 0/1/0, GE 0/2/0.

Figure 1-70  Networking diagram for configuring congestion avoidance

Configuration Roadmap

The configuration roadmap is as follows:

  1. Mark the service priorities of different flows on the inbound interface GE 0/1/0 of Device A.
  2. Configure a WRED profile and set the lower drop threshold, upper drop threshold, and drop probability for packets.

  3. On the outbound interface GE 0/2/0 of Device A, configure a different scheduling policy for class queues of each service level and apply a configured WRED object to the scheduling policy.

Data Preparation

To complete the configuration, you need the following data:

  • ACL numbers, traffic classifier names, traffic behavior names, re-marked service priorities, and traffic policy names
  • WRED profile name, lower and upper drop thresholds, drop probability, and packet color in each queue

  • Interfaces and class queues to which WRED drop policies are applied

Procedure

  1. Configure ACL rules for packets from Server, Telephone, PC1, and PC2.

    <*DeviceA> system-view
    [~DeviceA] acl number 2001
    [*DeviceA-acl4-basic-2001] rule permit source 10.1.1.3 0.0.0.0
    [*DeviceA-acl4-basic-2001] commit
    [~DeviceA-acl4-basic-2001] quit
    [~DeviceA] acl number 2002
    [*DeviceA-acl4-basic-2002] rule permit source 10.1.1.2 0.0.0.0
    [*DeviceA-acl4-basic-2002] commit
    [~DeviceA-acl4-basic-2002] quit
    [~DeviceA] acl number 2003
    [*DeviceA-acl4-basic-2003] rule permit source 10.1.1.4 0.0.0.0
    [*DeviceA-acl4-basic-2003] commit
    [~DeviceA-acl4-basic-2003] quit
    [~DeviceA] acl number 2004
    [*DeviceA-acl4-basic-2004] rule permit source 10.1.1.5 0.0.0.0
    [*DeviceA-acl4-basic-2004] commit
    [~DeviceA-acl4-basic-2004] return

  2. On GE 0/1/0 of Device A, configure complex traffic classification and mark the service priority of each flow.

    <*DeviceA> system-view
    [~DeviceA] traffic classifier aa
    [*DeviceA-classifier-aa] if-match acl 2001
    [*DeviceA-classifier-aa] commit
    [~DeviceA-classifier-aa] quit
    [~DeviceA] traffic classifier bb
    [*DeviceA-classifier-bb] if-match acl 2002
    [*DeviceA-classifier-bb] commit
    [~DeviceA-classifier-bb] quit
    [~DeviceA] traffic classifier cc
    [*DeviceA-classifier-cc] if-match acl 2003
    [*DeviceA-classifier-cc] commit
    [~DeviceA-classifier-cc] quit
    [~DeviceA] traffic classifier dd
    [*DeviceA-classifier-dd] if-match acl 2004
    [*DeviceA-classifier-dd] commit
    [~DeviceA-classifier-dd] quit
    [~DeviceA] traffic behavior aa
    [*DeviceA-behavior-aa] remark ip-precedence 5
    [*DeviceA-behavior-aa] car cir 5000
    [*DeviceA-behavior-aa] commit
    [~DeviceA-behavior-aa] quit
    [~DeviceA] traffic behavior bb
    [*DeviceA-behavior-bb] remark ip-precedence 4
    [*DeviceA-behavior-bb] car cir 4000
    [*DeviceA-behavior-bb] commit
    [~DeviceA-behavior-bb] quit
    [~DeviceA] traffic behavior cc
    [*DeviceA-behavior-cc] remark ip-precedence 3
    [*DeviceA-behavior-cc] commit
    [~DeviceA-behavior-cc] quit
    [~DeviceA] traffic behavior dd
    [*DeviceA-behavior-dd] remark ip-precedence 2
    [*DeviceA-behavior-dd] commit
    [~DeviceA-behavior-dd] quit
    [~DeviceA] traffic policy ee
    [*DeviceA-trafficpolicy-ee] classifier aa behavior aa
    [*DeviceA-trafficpolicy-ee] classifier bb behavior bb
    [*DeviceA-trafficpolicy-ee] classifier cc behavior cc
    [*DeviceA-trafficpolicy-ee] classifier dd behavior dd
    [*DeviceA-trafficpolicy-ee] commit
    [~DeviceA-trafficpolicy-ee] quit
    [~DeviceA] interface gigabiethernet0/1/0
    [~DeviceA-GigabitEthernet0/1/0] undo shutdown
    [*DeviceA-GigabitEthernet0/1/0] traffic-policy ee inbound
    [*DeviceA-GigabitEthernet0/1/0] commit
    [~DeviceA-GigabitEthernet0/1/0] return
    NOTE:
    NOTE:

    For details about the mapping between the IP precedence and service class, see Default Mapping Between IP Precedence/MPLS EXP/802.1p and Service Class in the HUAWEI NE20E-S Feature Description - QoS Priority Mapping.

    The priorities of queues with specific service classes are calculated based on scheduling algorithms.
    • If PQ scheduling is configured for all queues with the eight service classes, the priorities of the queues are placed in descending order as follows: CS7 > CS6 > EF > AF4 > AF3 > AF2 > AF1 > BE.
    • If PQ scheduling is configured for the BE queue (not applied in most cases) and WFQ scheduling is configured for the queues with the other service classes, the priority of the BE queue is higher than that of the other queues.
    • If WFQ scheduling is configured for all queues with the eight service classes, all the queues have the same priority.

  3. Configure a WRED profile on Device A.

    <DeviceA> system-view
    [~DeviceA] port-wred pw
    [*DeviceA-port-wred-pw] color green low-limit 70 high-limit 100 discard-percentage 100
    [*DeviceA-port-wred-pw] color yellow low-limit 60 high-limit 90 discard-percentage 100
    [*DeviceA-port-wred-pw] color red low-limit 50 high-limit 80 discard-percentage 100
    [*DeviceA-port-wred-pw] commit
    [~DeviceA-port-wred-pw] quit

    After you complete the preceding configuration, run the display port-wred configuration verbose command to check the WRED profile parameters.

    <DeviceA> display port-wred configuration verbose
    Port wred name : pw
    ---------------------------------------------------
    Color    Low-limit    High-limit    Discard-percent
    ---------------------------------------------------
    green    70           100           100
    yellow   60           90            100
    red      50           80            100
    Queue Depth : 8000
    Reference relationships : NULL 

  4. On GE 0/2/0 of Device A, configure class queues and apply the configured WRED object pw to the class queues.

    [~DeviceA] interface gigabitethernet0/2/0
    [~DeviceA-GigabitEthernet0/2/0] undo shutdown
    [*DeviceA-GigabitEthernet0/2/0] port-queue ef pq port-wred pw outbound
    [*DeviceA-GigabitEthernet0/2/0] port-queue af4 wfq weight 15 shaping 100 port-wred pw outbound
    [*DeviceA-GigabitEthernet0/2/0] port-queue af3 wfq weight 10 shaping 50 port-wred pw outbound
    [*DeviceA-GigabitEthernet0/2/0] port-queue af2 wfq weight 10 shaping 50 port-wred pw outbound
    [*DeviceA-GigabitEthernet0/2/0] commit
    [~DeviceA-GigabitEthernet0/2/0] return

    After you complete the preceding configuration, run the display port-queue configuration interface command to view detailed configurations of the class queues.

    <DeviceA> display port-queue configuration interface gigabitethernet 0/2/0 outbound
    GigabitEthernet0/2/0                                                         
     be current configuration:                                                      
       Arithmetic: wfq                                                              
       weight: 10                                                                   
       tm weight: 3                                                                 
       fact weight: 10                                                              
       shaping(mbps): NA                                                            
       port-wred name: NA                                                           
     af1 current configuration:                                                     
       Arithmetic: wfq                                                              
       weight: 10                                                                   
       tm weight: 3                                                                 
       fact weight: 10                                                              
       shaping(mbps): NA                                                            
       port-wred name: NA                                                           
     af2 current configuration:                                                     
       Arithmetic: wfq                                                              
       weight: 10                                                                   
       tm weight: 3                                                                 
       fact weight: 10                                                              
       shaping(mbps): 50                                                            
       port-wred name: pw                                                           
     af3 current configuration:                                                     
       Arithmetic: wfq                                                              
       weight: 10                                                                   
       tm weight: 3                                                                 
       fact weight: 10                                                              
       shaping(mbps): 50                                                            
       port-wred name: pw                                                           
     af4 current configuration:                                                     
       Arithmetic: wfq                                                              
       weight: 15                                                                   
       tm weight: 3                                                                 
       fact weight: 10                                                              
       shaping(mbps): 100                                                           
       port-wred name: pw                                                           
     ef current configuration:                                                      
       Arithmetic: pq                                                               
       weight: NA                                                                   
       tm weight: NA                                                                
       fact weight: NA                                                              
       shaping(mbps): NA                                                            
       port-wred name: pw                                                           
     cs6 current configuration:                                                     
       Arithmetic: pq                                                               
       weight: NA                                                                   
       tm weight: NA                                                                
       fact weight: NA                                                              
       shaping(mbps): NA                                                            
       port-wred name: NA                                                           
     cs7 current configuration:                                                     
       Arithmetic: pq                                                               
       weight: NA                                                                   
       tm weight: NA                                                                
       fact weight: NA                                                              
       shaping(mbps): NA                                                            
       port-wred name: NA     

  5. Verify the configuration.

    When the network has traffic, run the display port-queue statistics [ slot slot-id | interface { interface-type interface-number | interface-name } ] [ cos-value ] outbound command on Device A. The command output shows that the traffic volumes of varying service levels increase rapidly. With the rapid increase in traffic volumes, the volume of discarded traffic also increases rapidly according to the configured WRED drop parameters.

Configuration Files
  • Configuration file of Device A

    #
     sysname DeviceA
    #
    acl number 2001
     rule permit source 10.1.1.3 0
    #
    acl number 2002
     rule permit source 10.1.1.2 0
    #
    acl number 2003
     rule permit source 10.1.1.4 0
    #
    acl number 2004
     rule permit source 10.1.1.5 0 
    #
    traffic classifier cc operator or
     if-match acl 2003
    traffic classifier dd operator or
     if-match acl 2004
    traffic classifier aa operator or
     if-match acl 2001
    traffic classifier bb operator or
     if-match acl 2002
    #
    traffic behavior cc
     remark ip-precedence 3
    traffic behavior dd
     remark ip-precedence 2
    traffic behavior aa
     car cir 5000
     remark ip-precedence 5
    traffic behavior bb
     car cir 4000
     remark ip-precedence 4
    #
    traffic policy ee
     classifier aa behavior aa
     classifier bb behavior bb
     classifier cc behavior cc
     classifier dd behavior dd
    #
    port-wred pw
     color green low-limit 70 high-limit 100 discard-percentage 100
     color yellow low-limit 60 high-limit 90 discard-percentage 100
     color red low-limit 50 high-limit 80 discard-percentage 100
    #
    interface GigabitEthernet0/1/0
     undo shutdown
     ip address 10.1.1.1 255.255.255.0
     traffic-policy ee inbound
    #
    interface GigabitEthernet0/2/0
     undo shutdown
     ip address 10.10.1.1 255.255.255.0
     port-queue af2 wfq weight 10 shaping 50 port-wred pw outbound
     port-queue af3 wfq weight 10 shaping 50 port-wred pw outbound
     port-queue af4 wfq weight 15 shaping 100 port-wred pw outbound
     port-queue ef pq port-wred pw outbound
    #
    ospf 1
     area 0.0.0.0
      network 10.1.1.0 0.0.0.255
      network 10.10.1.0 0.0.0.255
    #
    return
Updated: 2019-05-16

Document ID: EDOC1000120969

Views: 25972

Downloads: 873

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next