< Home

Configuring a Traffic Behavior

Procedure

  1. Run traffic behavior behavior-name

    A traffic behavior is created and the traffic behavior view is displayed, or the view of an existing traffic behavior is displayed.

  2. Define actions in the traffic behavior. You can configure multiple non-conflicting actions in a traffic behavior.

    Table 1 Actions in the traffic behavior

    Action

    Command

    Remarks

    Packet filtering

    deny | permit

    In the same traffic behavior, the deny action cannot be used together with other traffic actions except for traffic statistics collection and traffic mirroring.

    For details on how to configure packet filtering, see Packet Filtering Configuration.

    Priority re-marking

    Re-marking the 802.1p priority of VLAN packets: remark 8021p [ 8021p-value | inner-8021p ]

    Re-marking the DSCP priority of IP packets: remark dscp { dscp-name | dscp-value }

    Re-marking the internal priority of packets: remark local-precedence { local-precedence-name | local-precedence-value } [ green | yellow | red ]

    Re-marking the IP precedence of packets: remark ip-precedence ip-precedence

    For details on how to configure MQC-based priority re-marking on the S2720-EI, S5720-LI, S5720S-LI, S5720-SI, S5720S-SI, S5720I-SI, S5730-SI, S5730S-EI, S6720-LI, S6720S-LI, S6720-SI, and S6720S-SI, see Configuring MQC-based Priority Re-marking.

    For details on how to configure MQC-based priority re-marking on the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-S, S5731S-H, S5732-H, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735S-S, S5735-S-I, S6720-EI, S6720S-EI, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S, see Configuring MQC-based Priority Re-marking.

    Destination MAC address re-marking

    remark destination-mac mac-address

    Only the S5720-EI, S6720-EI, and S6720S-EI support this action.

    For details on how to configure MQC-based destination MAC address re-marking, see Configuring Re-marking of Destination MAC Addresses in "MAC Address Table Configuration" in the S2720, S5700, and S6700 V200R019C10 Configuration Guide - Ethernet Switching Configuration Guide.

    Flow ID re-marking

    remark flow-id flow-id

    Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-S, S5731S-H, S5732-H, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735-S-I, S5735S-S, S6720-EI, S6720-HI, S6730-H, S6730S-H, S6730-S, S6730S-S, and S6720S-EI support this action.

    Redirection

    Redirecting packets to the CPU: redirect cpu

    Redirecting packets to a specified interface: redirect interface interface-type interface-number [ forced ]

    Redirecting packets to a VPN instance: redirect vpn-instance vpn-instance-name

    Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support redirect cpu.

    A traffic policy containing redirect interface and redirect cpu can only be applied to the inbound direction.

    The S5735-L, S5735-S, S5735-S-I, S5735S-L, S5735S-L-M, and S5735S-L-M do not support redirect vpn-instance.

    For details on how to configure redirection, see Redirection Configuration.

    Traffic policing

    car

    For details on how to configure MQC-based traffic policing, see Configuring MQC to Implement Traffic Policing.

    Hierarchical traffic policing

    car car-name share

    Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this action.

    A traffic policy containing car share can only be applied to the inbound direction.

    Traffic mirroring

    mirroring to observe-port observe-port-index

    The S2720-EI, S5720I-SI, S5720-LI, S5720S-LI, S5720S-SI, S5720-SI, S5730S-EI, S5730-SI, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735S-S, S5735-S-I, S6720-LI, S6720S-LI, S6720S-SI, and S6720-SI support traffic mirroring only in the inbound direction.

    For details on how to configure MQC-based traffic mirroring, see Configuring Mirroring in "Mirroring Configuration" in the S2720, S5700, and S6700 V200R019C10 Configuration Guide - Network Management and Monitoring.

    PBR

    Redirecting packets to a next hop IP address: redirect ip-nexthop

    Redirecting packets to a next hop IPv6 address: redirect ipv6-nexthop

    Redirecting packets to multiple next hop IP addresses: redirect ip-multihop

    Redirecting packets to multiple next hop IPv6 addresses: redirect ipv6-multihop

    A traffic policy containing PBR takes effect only for IP packets.

    For details on how to configure PBR, see Configuring PBR in "PBR Configuration" in the S2720, S5700, and S6700 V200R019C10 Configuration Guide - IP Unicast Routing.

    Disabling MAC address learning

    mac-address learning disable

    Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S5735-L, S5735S-L, S5735S-L-M, S5735-S, S5735-S-I, S5735S-S, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this action.

    VLAN mapping

    Re-marking the VLAN tag in VLAN packets: remark vlan-id vlan-id

    Re-marking the inner VLAN tag in QinQ packets: remark cvlan-id cvlan-id

    Only the S5720-EI, S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6730-H, S6730S-H, S6730-S, and S6730S-S support the action of re-marking the inner VLAN tag in QinQ packets (specified by remark cvlan-id) in a traffic behavior.

    When a traffic classifier defines if-match outbound-interface interface-type interface-number, VLAN mapping cannot be defined in the bound traffic behaviors.

    For details on how to configure MQC-based VLAN mapping, see Configuring MQC-based VLAN Mapping in "VLAN Mapping Configuration" in the S2720, S5700, and S6700 V200R019C10 Configuration Guide - Ethernet Switching Configuration Guide.

    Selective QinQ

    add-tag vlan-id vlan-id

    Only the S5730-SI, S5730S-EI, S6720-LI, S6720S-LI, S6720-SI, and S6720S-SI support this action.

    For details on how to configure MQC-based selective QinQ, see Configuring MQC-based Selective QinQ in "QinQ Configuration" in the S2720, S5700, and S6700 V200R019C10 Configuration Guide - Ethernet Switching Configuration Guide.

    Traffic statistics collection

    statistic enable

    For details on how to configure traffic statistics collection, see Traffic Statistics Collection Configuration.

    Making the deny rule in an ACL or ACL6 ineffective

    rule-deny skip-action

    A traffic behavior configured with this action must be bound to a traffic classifier configured with the ACL or ACL6 rule.

    On the S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S, if selective QinQ, VLAN mapping, flow ID re-marking, 802.1p priority re-marking, or MAC address learning disabling is configured in a traffic behavior, the following actions cannot be defined in the traffic behavior: traffic statistics collection, traffic mirroring, redirection, policy-based routing, DSCP priority re-marking, internal priority re-marking, destination MAC address re-marking, traffic policing, and hierarchical traffic policing.

    On the S5720-EI, S6720-EI, and S6720S-EI, if flow ID re-marking, re-marking of inner VLAN tags in QinQ packets, MAC address learning disabling, or redirection of packets to a VPN instance is configured in a traffic behavior, the following actions cannot be defined in the traffic behavior: traffic statistics collection, traffic mirroring, redirection, policy-based routing, DSCP priority re-marking, internal priority re-marking, destination MAC address re-marking, traffic policing, and hierarchical traffic policing.

  3. Run quit

    Exit from the traffic behavior view.

  4. Run quit

    Exit from the system view.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >