The encapsulation dot1q vid 8021p command is used to configure a Layer 2 sub-interface to access packets with a specified 802.1Q Tag.
The undo encapsulation dot1q vid 8021p command is used to cancel the access of a specified Layer 2 sub-interface to a specified 802.1Q Tag.
By default, no encapsulation type is specified on an EVC Layer 2 sub-interface.
Parameter | Description | Value |
---|---|---|
pevid1 |
Specifies a range of VLAN IDs for single-tagged packets to be received by an EVC Layer 2 sub-interface. The parameters are as follows: pevid1: specifies the start VLAN ID. |
The value is an integer ranging from 1 to 4094. |
pevid2 |
Specifies a range of VLAN IDs for single-tagged packets to be received by an EVC Layer 2 sub-interface. The parameters are as follows: pevid2: specifies the end VLAN ID. pevid2 must be greater than or equal to pevid1. pevid2 and pevid1 define a range of VLAN IDs. If you do not specify to pevid2, pevid1 specifies the single VLAN ID carried in packets. If the pevid1 [ to pevid2 ] parameters are run more than once, all configurations take effect. |
The value is an integer ranging from 1 to 4094. |
8021p |
Specifies a range of priority values for single-tagged packets to be received by an EVC Layer 2 sub-interface. |
- |
val8021p1 |
Specifies a range of priority values for single-tagged packets to be received by an EVC Layer 2 sub-interface. The parameters are as follows: val8021p1: specifies the smallest priority value. |
The value is an integer ranging from 0 to 7. A larger value indicates a higher priority. |
val8021p2 |
Specifies a range of priority values for single-tagged packets to be received by an EVC Layer 2 sub-interface. The parameters are as follows: val8021p2: specifies the largest priority value. val8021p2 must be greater than or equal to val8021p1. val8021p2 and val8021p1 define a range of priority values. If you do not specify to val8021p2, val8021p1 specifies a priority value carried in a VLAN frame.If the val8021p1 [ to val8021p2 ] parameters are run more than once, all configurations take effect. |
The value is an integer ranging from 0 to 7. A larger value indicates a higher priority. |
Usage Scenario
On a Layer 2 Ethernet network, packets may not carry VLAN Tags or carry one or two VLAN Tags. To enable different packets to be forwarded through different EVC Layer 2 sub-interfaces, run this command to configure different flow encapsulation modes for the EV Layer 2 sub-interface. The encapsulation dot1q vid 8021p command is used to configure a Layer 2 sub-interface to access packets with a specified 802.1Q Tag.
Precautions
Only a single encapsulation type can be specified on each EVC Layer 2 sub-interface. Before changing an encapsulation type, run the undo encapsulation command to delete the existing encapsulation type and run the encapsulation to specify an encapsulation type.
In a data transparent transmission scenario, dot1q or QinQ encapsulation is configured on an EVC Layer 2 sub-interface, and a range of VLAN IDs is specified for VLAN tags carried in packets. In this situation, traffic may be returned or dropped if the undo encapsulation dot1q vid low-pe-vid or undo encapsulation qinq vid pe-vid ce-vid low-ce-vid command is run to delete the existing encapsulation type with the smallest VLAN ID specified. To prevent problems, perform the following operations: 1.Run the shutdown command on the EVC Layer 2 sub-interface. 2.Run the commit command to commit configuration. 3.Run the undo encapsulation dot1q vid command to delete the minimum VLAN. 4.Run the undo shutdown command on the EVC Layer 2 sub-interface. 5.Run the commit command to commit configuration.