if-match destination-mac

Function

The if-match destination-mac command configures a matching rule for complex traffic classification based on destination MAC addresses of packets.

The undo if-match destination-mac command cancels the configuration.

By default, the matching rule for complex traffic classification based on destination MAC addresses of packets is not configured in traffic classifier view.

Format

if-match destination-mac mac-address

undo if-match destination-mac mac-address

Parameters

Parameter Description Value
mac-address

Specifies the destination MAC address to be matched.

It is in the format of H-H-H with each H representing four hexadecimal digits.

Views

Traffic classifier view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
qos write

Usage Guidelines

Usage Scenario

To configure a certain traffic policy for the traffic with a certain destination MAC address, you can run this command in the traffic classifier view to configure a matching rule for complex traffic classification based on the destination MAC address. Then, you can configure the corresponding traffic behavior and traffic policy and apply the policy to interfaces.

Prerequisites

A traffic classifier is configured in the system view and the traffic classifier view is displayed.

Configuration Impact

The traffic action in the traffic behavior bound to the traffic classifier is performed for the traffic matching the specified destination MAC address.

Follow-up Procedure

You need to configure the traffic behavior and traffic policy, bind the traffic behavior to the traffic classifier in the traffic policy, and apply the traffic policy to interfaces.

Precautions

This rule based on the destination MAC address is valid for only outbound policies.

This command can be used to set more than one destination MAC address for one traffic classifier to match the packets with different destination MAC addresses.

Example

# Configure the packets with the destination MAC address being 00e0-fc12-3456 to match the traffic classifier c1.
<HUAWEI> system-view
[~HUAWEI] traffic classifier c1
[*HUAWEI-classifier-c1] if-match destination-mac 00e0-fc12-3456
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >