The add-tag vlan-id command configures an action of adding an outer VLAN tag in a traffic behavior.
The undo add-tag command deletes the action.
By default, no action of adding an outer VLAN tag is configured in a traffic behavior.
Only the S5730-SI, S5730S-EI, S6720-LI, S6720S-LI, S6720-SI, and S6720S-SI support this command.
Parameter |
Description |
Value |
---|---|---|
vlan-id |
Specifies the VLAN ID in the outer VLAN tag. |
The value is an integer that ranges from 1 to 4094. |
Usage Scenario
When the downstream device needs to provide services based on the outer VLAN tag, run the add-tag vlan-id command to configure the device to add an outer VLAN tag to packets matching the traffic classifier.
Follow-up Procedure
Run the traffic policy command to create a traffic policy and run the classifier behavior command in the traffic policy view to bind the traffic classifier to the traffic behavior containing the action of adding an outer VLAN tag.
Precautions
After the add-tag vlan-id, remark 8021p, remark cvlan-id or remark vlan-id command is used, the system modifies the VLAN tag of packets according to its configuration. The behavior configured through these commands is called VLAN-based action.
To apply a VLAN-based action and a non-VLAN-based action to the same upstream traffic policy, configure the VLAN-based action and non-VLAN-based action in different traffic behaviors bound to the same traffic policy.
The add-tag vlan-id command is invalid for double-tagged VLAN packets.
When port vlan-stacking, port vlan-stacking untagged, or port link-type dot1q-tunnel is configured on an interface to add a VLAN tag to packets so that packets carry double VLAN tags, the add-tag vlan-id command is invalid for the double-tagged VLAN packets.