if-match vlan

Function

The if-match vlan command defines a matching rule for MF classification based on the VLAN.

The undo if-match vlan command removes the setting.

By default, no matching rule for MF classification based on the VLAN is configured.

Format

if-match vlan vlan-id [ cvlan ce-vlan-id ]

undo if-match vlan vlan-id [ cvlan ce-vlan-id ]

Parameters

Parameter Description Value
vlan-id

Specifies VLAN ID.

The value is an integer in the range of 1 to 4094.

cvlan ce-vlan-id

Specifies the inner VLAN ID.

The value is an integer in the range of 1 to 4094.

Views

Traffic classifier view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
qos write

Usage Guidelines

Usage Scenario

You can configure more than one VLAN ID for a traffic classifier to match packets of different types.

You can configure a matching rule based on both the inner and outer VLAN IDs in a traffic classifier.

Prerequisites

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

Follow-up Procedure

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

Example

# Set the packets with the VLAN ID as 8 to match the traffic classifier c1.
<HUAWEI> system-view
[~HUAWEI] traffic classifier c1
[*HUAWEI-classifier-c1] if-match vlan 8
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >