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

NE40E V800R010C10SPC500 Configuration Guide - QoS 01

This is NE40E V800R010C10SPC500 Configuration Guide - QoS
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).
Defining a Traffic Classifier

Defining a Traffic Classifier

You need to configure a traffic classifier before configuring class-based QoS. The traffic classifier can be configured based on ACL, IP precedence, protocol type, MAC address, protocol address, and so on.

Procedure

  • Define a traffic classifier based on Layer 3 or Layer 4 information
    1. Run system-view

      The system view is displayed.

    2. Run traffic classifier classifier-name [ operator { and | or } ]

      A traffic classifier is defined, and the traffic classifier view is displayed.

    3. Choose the required matching rule as required:

      • To set a matching rule to classify traffic based on the ACL number, run the if-match [ ipv6 ] acl { acl-number | name acl-name } command.

      • To define a matching rule to classify traffic based on a DSCP value, run the if-match [ ipv6 ] dscp dscp-value command.

      • To define a matching rule to classify traffic based on the TCP flag value, run the if-match tcp syn-flag { tcpflag-value [ mask tcpflag-mask ] | bit-match { established | fin | syn | rst | psh | ack | urg | ece | cwr | ns } } command.

      • To define a matching rule to classify traffic based on the precedence of an IP packet, run the if-match [ ipv6 ] ip-precedence ip-precedence command.

      • To define a matching rule to classify traffic based on the MPLS EXP value, run the if-match mpls-exp exp-value command.

      • To define a matching rule to match all packets, run the if-match [ ipv6 ] any command.

      • To define a matching rule to classify traffic based on the value of the next IPv6 header, run the if-match ipv6 next-header command.

      • To set a matching rule to classify traffic based on the source IPv6 address, run the if-match ipv6 source-address ipv6-address prefix-length command.

      • To define a matching rule to classify traffic based on a destination IPv6 address, run the if-match ipv6 destination-address ipv6-address prefix-length command.

      • To define a matching rule to classify traffic based on the QoS policy ID, run the if-match qos-local-id qos-local-id command.
      • To define a matching rule based on the IPv6 QoS policy ID, run the if-match ipv6 qos-local-id qos-local-id command.
      NOTE:

      For IPv6 packets, you need to specify the keyword ipv6 when defining a matching rule in Step 3. A matching rule defined to match packets based on source or destination addresses is valid with IPv6 packets, but not with IPv4 packets.

      You can define different ACL rules as required, including the protocol type, source address, destination address, and ToS in packets. The if-match acl command filters packets according to ACL rules defined in the rule command, and then the system performs the corresponding traffic behavior for the matching packets.

      If you define multiple matching rules in one traffic classifier, you can set the logical relationship between the matching rules by specifying the parameter operator in Step 2.

      • and: A packet belongs to the classifier only when it matches all the rules.
      • or: A packet belongs to the classifier if it matches any one of the rules.

    4. Run commit

      The configuration is committed.

  • Define a traffic classifier based on Layer 2 information
    1. Run system-view

      The system view is displayed.

    2. Run traffic classifier classifier-name [ operator { and | or } ]

      The traffic class is defined, and the traffic class view is displayed.

    3. Define desired matching rules on the router according to your requirements.

      • To set a matching rule to classify traffic based on the ACL number, run the if-match [ ipv6 ] acl { acl-number | name acl-name } command.

      • To set a matching rule to classify VLAN packets based on the 802.1p priority, run the if-match 8021p 8021p-value command.

      • To set a matching rule to classify traffic based on the service class , run the if-match service-class service-class-value command.

      • To set a matching rule to classify traffic based on the source MAC address, run the if-match source-mac mac-address command.

      • To set a matching rule to classify traffic based on the destination MAC address, run the if-match destination-mac mac-address command.

      If you set more than one matching rule for the same classifier, you can set their logical relations by specifying the parameter operator in Step 2. For detailed instructions, see the previous section.

      If multiple traffic classifiers are configured in one traffic policy, the traffic behaviors corresponding to these traffic classifiers are implemented in different orders.
      • When multiple traffic classifiers match the different fields of an IP packet, the traffic behavior of the traffic classifier that is first bound to a traffic policy is preferentially implemented.

        For example, as shown in Table 5-1, Policy 1 defines two traffic classifiers and their corresponding traffic behaviors in sequence. If a packet matches all the two traffic classifier rules, behavior 1 is performed on the packet. That is, the 802.1p value of the packet is re-marked as 1.

        Table 5-1 Traffic classifiers and behaviors defined in Policy 1

        Traffic Classifier

        Matching Rule

        Traffic Behavior

        Traffic Action

        Classifier 1

        Matching the destination MAC address

        Behavior 1

        Re-marking the 8021p value as 1

        Classifier 3

        Matching the source MAC address

        Behavior 3

        Re-marking the 8021p value as 3

      • Multiple traffic rules can match the same field of an IP packet, but no packet can match multiple traffic classifiers once. This means that only the traffic action for the traffic classifier that matches the traffic rule is performed on the packet.

        For example, as shown in Table 5-2, three traffic classifiers and their corresponding traffic behaviors are associated in policy 2 in order. If the destination MAC address of a packet is 2-2-2, the action defined in behavior 2, re-marking the 8021p value as 2, is implemented for the packet.

        Table 5-2 Traffic classifiers and behaviors defined in Policy 2

        Traffic Classifier

        Matching Rule

        Traffic Behavior

        Traffic Action

        Classifier 1

        Matching the destination MAC address 1-1-1

        Behavior 1

        Re-marking the 8021p value as 1

        Classifier 2

        Matching the destination MAC address 2-2-2

        Behavior 2

        Re-marking the 8021p value as 2

        Classifier 3

        Matching the destination MAC address 3-3-3

        Behavior 3

        Re-marking the 8021p value as 3

    4. Run commit

      The configuration is committed.

Translation
Download
Updated: 2019-01-03

Document ID: EDOC1100055024

Views: 22109

Downloads: 114

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