l2protocol-tunnel

Function

The l2protocol-tunnel reverse command enables reverse Layer 2 protocol tunneling on an interface.

The undo l2protocol-tunnel reverse command cancels reverse Layer 2 protocol tunneling on an interface.

The l2protocol-tunnel drop command enables an interface to discard Layer 2 PDUs.

The undo l2protocol-tunnel drop command disables an interface from discarding Layer 2 PDUs.

By default, reverse Layer 2 protocol tunneling is not enabled on interfaces, interfaces do not discard Layer 2 PDUs.

Format

l2protocol-tunnel { all | { protocol } &<1-19> } { [ reverse ] drop }

undo l2protocol-tunnel { all | { protocol } &<1-19> } { [ reverse ] drop }

Parameters

Parameter Description Value
all

Enables reverse tunneling for Layer 2 protocol data units (PDUs) of all protocols.

-

protocol

Enables the Layer 2 PDUs of a specified protocol.

You can enter a question mark (?) and select a value from the displayed value range.

reverse

Enables reverse tunneling for Layer 2 PDUs of a specified protocol.

-

drop

Discards packets after the packets' specified multicast MAC address is replaced with the multicast destination MAC address in Layer 2 PDUs.

-

Views

Layer 2 100GE interface view, 100GE interface view, Layer 2 10GE interface view, 10GE interface view, 25GE-L2 view, 25GE interface view, 400GE Layer 2 sub-interface view, 400GE-L2 view, 400GE interface view, Layer 2 40GE interface view, 40GE interface view, 50GE Layer 2 sub-interface view, Layer 2 50GE interface view, 50GE interface view, Eth-Trunk Layer 2 sub-interface view, Layer 2 Eth-Trunk interface view, Eth-Trunk interface view, FlexE sub-interface view, FlexE interface view, GE Layer 2 sub-interface view, Layer 2 GE interface view, GE optical interface view, GE interface view, GE electrical interface view, Layer 2 sub-interface view, Sub-interface view, Interface group view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
ethernet write

Usage Guidelines

Usage Scenario

  • Generally, the destination MAC addresses in Layer 2 PDUs of the same Layer 2 protocol are the same. For example, the destination MAC addresses of MSTP PDUs (called BPDUs) are all 0180-C200-0000. To allow a backbone network device to determine whether a Layer 2 PDU is from a user or backbone network, the l2protocol-tunnel group-mac command can be run on the user-side interface of the backbone device to replace the multicast destination MAC address of the Layer 2 PDU sent by the user network with a specified MAC address, so that devices between the user networks can complete Layer 2 spanning tree calculation.
  • If you do not need PDUs of some Layer 2 protocols, such as MSTP and LACP, to traverse a backbone network, run the l2protocol-tunnel drop command to enable an interface to discard Layer 2 PDUs. This implementation allows the interface to discard received Layer 2 PDUs.

Prerequisites

The multicast destination MAC addresses in Layer 2 PDUs have been replaced with a specified multicast MAC address using the l2protocol-tunnel group-mac command run on an edge device of a backbone network.

Configuration Impact

If the l2protocol-tunnel reverse command is run more than once, the latest configuration overrides the previous one.

Precautions

The l2protocol-tunnel { all | protocol } reverse and l2protocol-tunnel { all | protocol } reverse vlan low-id commands cannot be run on the same interface.

Example

# Enable reverse Layer 2 protocol tunneling on GE 0/1/1 to replace a specified multicast MAC address with the multicast destination MAC address (0180-C200-0000) of STP BPDUs.
<HUAWEI> system-view
[~HUAWEI] l2protocol-tunnel stp group-mac 0180-C200-0000
[*HUAWEI] interface GigabitEthernet 0/1/1
[*HUAWEI-GigabitEthernet0/1/1] portswitch
[*HUAWEI-GigabitEthernet0/1/1] l2protocol-tunnel stp reverse
# Enable GE 0/1/1 to discard STP PDUs.
<HUAWEI> system-view
[~HUAWEI] interface GigabitEthernet 0/1/1
[*HUAWEI-GigabitEthernet0/1/1] portswitch
[*HUAWEI-GigabitEthernet0/1/1] l2protocol-tunnel stp drop
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >