l2protocol-tunnel vlan

Function

The l2protocol-tunnel vlan command enables Layer 2 protocol tunneling on a tagged interface.

The undo l2protocol-tunnel vlan command disables Layer 2 protocol tunneling on a tagged interface.

By default, Layer 2 protocol tunneling is disabled on tagged interfaces.

Format

l2protocol-tunnel { all | { protocol } &<1-19> } { [ reverse ] vlan } { low-vid [ to high-vid ] } &<1-10>

undo l2protocol-tunnel { all | { protocol } &<1-19> } { [ reverse ] vlan } { low-vid [ to high-vid ] } &<1-10>

Parameters

Parameter Description Value
all

Enables or disables Layer 2 protocol tunneling for all supported standard and user-defined Layer 2 protocols.

-

protocol

Enables or disables Layer 2 protocol tunneling for a specified Layer 2 protocol.

The protocol as follows:

  • stp
  • lacp
  • dtp
  • gmrp
  • gvrp
  • lldp
  • vtp
  • udld
  • pagp
  • cdp
  • eoam3ah
  • dldp
  • mvrp
  • mmrp
  • e-lmi
  • sstp

One or up to all of the preceding Layer 2 protocols can be specified.

reverse

Enables the reverse Layer 2 protocol tunneling function on an interface. After the function is enabled, a specified multicast MAC address is replaced with the multicast destination MAC address in Layer 2 PDUs.

-

low-vid

Specifies a start VLAN ID.

The value is an integer ranging from 1 to 4094. <vidEnd> must be greater than <vidBgn>.

high-vid

Specifies an end VLAN ID.

The value is an integer ranging from 1 to 4094. <vidEnd> must be greater than <vidBgn>.

Views

Layer 2 100GE interface view, Layer 2 10GE interface view, 25GE-L2 view, 400GE-L2 view, Layer 2 40GE interface view, Layer 2 50GE interface view, Layer 2 Eth-Trunk interface view, Layer 2 GE interface view, Interface group view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
ethernet write

Usage Guidelines

Usage Scenario

  • Layer 2 protocols running between user networks, such as Spanning Tree protocol (STP), Link Aggregation Control Protocol (LACP), must traverse a backbone network to perform Layer 2 protocol calculation.
  • When each edge device interface on a backbone network connects to more than one user network and Layer 2 protocol data units (PDUs) from the user networks carry VLAN tags, run the l2protocol-tunnel vlan command to configure Layer 2 protocol tunneling on tagged interfaces to allow the Layer 2 PDUs from the user networks to be tunneled across the backbone network.
  • On some special networks, for example, a network with both Huawei and non-Huawei devices, to ensure that the Huawei device can communicate with the non-Huawei device, specify reverse so that a specified multicast MAC address is replaced with the multicast destination MAC address in Layer 2 PDUs.

Prerequisites

The l2protocol-tunnel group-mac command has been run to configure an edge device on a backbone network to replace the multicast destination MAC addresses in Layer 2 PDUs with a specified multicast MAC address.

Configuration Impact

When all the parameters are the same except for the VLAN ID, if the l2protocol-tunnel vlan command is run more than once, all configurations take effect.

Example

# Enable Layer 2 protocol tunneling for STP on the tagged interface GE 0/1/1 to tunnel Layer 2 PDUs carrying VLAN IDs ranging from 100 to 200.
<HUAWEI> system-view
[~HUAWEI] l2protocol-tunnel stp group-mac 0100-5e00-0011
[*HUAWEI] vlan batch 100 to 200
[*HUAWEI] gvrp
[*HUAWEI] interface GigabitEthernet 0/1/1
[*HUAWEI-GigabitEthernet0/1/1] portswitch
[*HUAWEI-GigabitEthernet0/1/1] port link-type trunk
[*HUAWEI-GigabitEthernet0/1/1] gvrp
[*HUAWEI-GigabitEthernet0/1/1] l2protocol-tunnel stp vlan 100 to 200
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >