L2X Operational Commands
The L2X show commands provide detailed information about the L2X operations.
L2X Show Commands
The L2X show commands display data from FIB local table. Therefore, local L2X with down ports or remote l2x with unresolved nexthop address are not displayed.
L2X Details
The show commands display L2X information, including total entry count, entry details, filtered L2X output, and L2X traffic statistics.
Syntax:
| Option | Description |
|---|---|
|
Without any option, the command displays all L2X information such as ingress L2X and egress L2X. |
|
Displays the total number of L2X entries. |
|
Displays detailed information for L2X entries. |
|
Displays L2X information based on specified filter criteria. |
|
Displays L2X traffic statistics. |
Example: Summary of total L2X entries
The show l2x count output provides a summary of total L2X entries, ingress and egress, download success and failure status, and the number of L2X mappings between MPLS ports and VLAN ports.
supervisor@rtbrick.net: cfg> show l2x count
L2X count
Total_count : 22
Ingress_count : 12
Egress_count : 10
Download_success_count : 22
Download_failure_count : 0
MPLS_port_to_Vlan_port_count : 10
Vlan_port_to_MPLS_port_count : 10
Example: L2X filter direction
The show l2x filter direction ingress type remote output lists all ingress remote L2X entries, showing their VLAN/service-label mapping, incoming and outgoing interfaces, operational status, and the remote next-hop address.
supervisor@rtbrick.net: cfg> show l2x filter direction ingress type remote
Name Direction Incoming Intf Status Outer VLAN Inner VLAN Service label Outgoing Intf Status NextHop
l2bsa_lag_1_101 ingress lag-1 up 101 - 10001 ifl-0/0/2/0 up 192.0.2.2
l2bsa_lag_1_111 ingress lag-1 up 111 - 10011 ifl-0/0/2/0 up 192.0.2.2
l2bsa_lag_1_121 ingress lag-1 up 121 - 10021 ifl-0/0/2/0 up 192.0.2.2
l2bsa_lag_1_131 ingress lag-1 up 131 - 10031 ifl-0/0/2/0 up 192.0.2.2
l2bsa_lag_1_141 ingress lag-1 up 141 - 10041 ifl-0/0/2/0 up 192.0.2.2
l2bsa_lag_1_201 ingress lag-1 up 201 - 10201 ifl-0/0/2/0 up 2001:db8:0:1::2
l2bsa_lag_1_211 ingress lag-1 up 211 - 10211 ifl-0/0/2/0 up 2001:db8:0:1::2
l2bsa_lag_1_221 ingress lag-1 up 221 - 10221 ifl-0/0/2/0 up 2001:db8:0:1::2
l2bsa_lag_1_231 ingress lag-1 up 231 - 10231 ifl-0/0/2/0 up 2001:db8:0:1::2
l2bsa_lag_1_241 ingress lag-1 up 241 - 10241 ifl-0/0/2/0 up 2001:db8:0:1::2
Example for detailed view of L2X information.
The show l2x detail command displays detailed information for each L2X entry, including direction, download status, VLAN match criteria, interface status and so on.
supervisor@rtbrick.net: cfg> show l2x detail
L2X name: IFP-CE1-PE1
Direction: ingress
Status: Download success
Incoming interface: lag-1
Incoming interface status: up
Subtype: Incoming Port - Outer Vlan Match
Incoming outer VLAN: 501
Incoming inner VLAN: -
Outgoing interface: ifp-0/0/2
Outgoing interface status: up
NextHop:
NextHop type: Local egress cross connect
NextHop action: No vlan manipulation - l2 forward
L2X name: IFP-PE1-CE1-501
Direction: ingress
Status: Download success
Incoming interface: ifp-0/0/2
Incoming interface status: up
Subtype: Incoming Port - Outer Vlan Match
Incoming outer VLAN: 501
Incoming inner VLAN: -
Outgoing interface: lag-1
Outgoing interface status: up
NextHop:
NextHop type: Local egress cross connect
NextHop action: No vlan manipulation - l2 forward
L2X name: l2bsa_lag_1_101
Direction: ingress
Status: Download success
Incoming interface: lag-1
Incoming interface status: up
Service label: 10001
Subtype: Incoming Port - Outer Vlan Match
Incoming outer VLAN: 101
Incoming inner VLAN: -
Outgoing interface: ifl-0/0/2/0
Outgoing interface status: up
NextHop:
NextHop IP: 192.0.2.2
Lookup instance: default
Lookup AFI: ipv4
Lookup SAFI: unicast
NextHop type: Remote ingress cross connect
NextHop action: mpls label push
L2X Filter
The command displays L2X entries based on filter criteria such as interface, VLAN, next-hop, direction, service label, and so on.
Syntax:
| Option | Description |
|---|---|
|
Without any option, displays the L2X filter output using the configured filter criteria. |
|
Filters the output by the total L2X entry count. |
|
Displays detailed information for matching L2X entries. |
|
Filters L2X entries by traffic direction. |
|
Filters L2X entries by the incoming interface name. |
|
Filters L2X entries by the inner VLAN ID. |
|
Filters the output by a specific L2X name. |
|
Filters L2X entries by the remote IPv4 next-hop address. |
|
Filters L2X entries by the remote IPv6 next-hop address. |
|
Filters L2X entries by the outer VLAN ID. |
|
Filters L2X entries by the outgoing interface name. |
|
Filters L2X entries by the service label value. |
|
Filters L2X entries by the L2X type. |
To access the Operational State API that corresponds to this CLI, click
here.
Example: Output of L2X Statistics command
The show l2x statistics command output displays ingress and egress traffic counters for the specified L2X, including forwarded and dropped packets and bytes.
supervisor@rtbrick.net: cfg> show l2x statistics l2bsa_lag_1_111
L2X Name: l2bsa_lag_1_111
Ingress
Counters:
In-Forward-Packets: 0
In-Forward-Bytes: 0
In-Drop-Packets: 0
In-Drop-Bytes: 0
Out-Forward-Packets: 0
Out-Forward-Bytes: 0
Out-Drop-Packets: 0
Out-Drop-Bytes: 0
L2X Name: l2bsa_lag_1_111
Egress
Counters:
In-Forward-Packets: 0
In-Forward-Bytes: 0
In-Drop-Packets: 0
In-Drop-Bytes: 0
Out-Forward-Packets: 0
Out-Forward-Bytes: 0
Out-Drop-Packets: 0
Out-Drop-Bytes: 0
Example for the specified service label.
The show l2x filter service-label <label> command displays L2X filter entries matching the specified service label, VLAN match criteria, and interface status.
supervisor@rtbrick.net: cfg> show l2x filter service-label 10011 Name Direction Incoming Intf Status Outer VLAN Inner VLAN Service label Outgoing Intf Status NextHop l2bsa_lag_1_111 ingress lag-1 up 111 - 10011 ifl-0/0/2/0 up 192.0.2.2
Example for the specified L2X filter type
The show l2x filter type remote command displays the remote L2X filter entries for ingress and egress traffic, including VLAN match criteria, service labels, and interface status.
supervisor@rtbrick.net: cfg> show l2x filter type remote Name Direction Incoming Intf Status Outer VLAN Inner VLAN Service label Outgoing Intf Status NextHop l2bsa_lag_1_101 ingress lag-1 up 101 - 10001 ifl-0/0/2/0 up 192.0.2.2 l2bsa_lag_1_101 egress - - - - 20001 lag-1 up - l2bsa_lag_1_111 ingress lag-1 up 111 - 10011 ifl-0/0/2/0 up 192.0.2.2 l2bsa_lag_1_111 egress - - - - 20011 lag-1 up - l2bsa_lag_1_121 ingress lag-1 up 121 - 10021 ifl-0/0/2/0 up 192.0.2.2 l2bsa_lag_1_121 egress - - - - 20021 lag-1 up - l2bsa_lag_1_131 ingress lag-1 up 131 - 10031 ifl-0/0/2/0 up 192.0.2.2 l2bsa_lag_1_131 egress - - - - 20031 lag-1 up - l2bsa_lag_1_141 ingress lag-1 up 141 - 10041 ifl-0/0/2/0 up 192.0.2.2 l2bsa_lag_1_141 egress - - - - 20041 lag-1 up - l2bsa_lag_1_201 ingress lag-1 up 201 - 10201 ifl-0/0/2/0 up 2001:db8:0:1::2 l2bsa_lag_1_201 egress - - - - 20201 lag-1 up - l2bsa_lag_1_211 ingress lag-1 up 211 - 10211 ifl-0/0/2/0 up 2001:db8:0:1::2 l2bsa_lag_1_211 egress - - - - 20211 lag-1 up - l2bsa_lag_1_221 ingress lag-1 up 221 - 10221 ifl-0/0/2/0 up 2001:db8:0:1::2 l2bsa_lag_1_221 egress - - - - 20221 lag-1 up - l2bsa_lag_1_231 ingress lag-1 up 231 - 10231 ifl-0/0/2/0 up 2001:db8:0:1::2 l2bsa_lag_1_231 egress - - - - 20231 lag-1 up - l2bsa_lag_1_241 ingress lag-1 up 241 - 10241 ifl-0/0/2/0 up 2001:db8:0:1::2 l2bsa_lag_1_241 egress - - - - 20241 lag-1 up -
L2X Hierarchy
The show l2x hierarchy command displays L2X information in a hierarchical format, showing each instance’s direction-specific configuration and operational state across both control and forwarding planes.
Syntax:
| Option | Description |
|---|---|
|
Displays the hierarchy for a specific user-defined L2X instance name. |
|
Displays hierarchies for the traffic entering the router. |
|
Displays hierarchies for the outgoing traffic. |
|
Displays both the Ingress and Egress hierarchies simultaneously. |
|
Provides the detailed information. |
The following example output shows the ingress L2X configuration for l2x_local. The information is structured in a hierarchical order for each daemon. It matches traffic on interface 'ifp-0/1/51' with outer VLAN 200 and adding outer VLAN 400. The 'staticd' and 'ribd' sections display the forwarding parameters. The 'fibd' section confirms that the entry is successfully programmed.
supervisor@rtbrick.net: op> show l2x hierarchy l2x_local direction ingress
staticd:
l2x name: l2x_local
direction: ingress
incoming ifp: ifp-0/1/51
incoming outer vlan: 200
vlan operation: single-vlan-add
outer vlan: 400
nexthop set hash: 88815a358f521438074f8207ea9196c5b17116cbf16ee70f
nexthop hash: a70e95a94e65f1583a97e086c2c6df72f95e59ed07d981d8
outgoing ifp: ifp-0/1/52
ribd:
l2x name: l2x_local
direction: ingress
incoming interface: ifp-0/1/51
incoming outer vlan: 200
vlan operation: single-vlan-add
outer vlan: 400
adjacency set hash: 88815a358f521438074f8207ea9196c5b17116cbf16ee70f
nexthop hash: a70e95a94e65f1583a97e086c2c6df72f95e59ed07d981d8
outgoing ifp: ifp-0/1/52
fibd:
l2x name: l2x_local
direction: ingress
incoming interface: ifp-0/1/51
incoming outer vlan: 200
vlan operation: single-vlan-add
outer vlan: 400
bcm status: Download success
adjacency set hash: 88815a358f521438074f8207ea9196c5b17116cbf16ee70f
nexthop hash: a70e95a94e65f1583a97e086c2c6df72f95e59ed07d981d8
outgoing ifp: ifp-0/1/52
adjacency status: Success
Example for remote L2X hierarchy information
This output displays the hierarchical ingress L2X information for the L2X remote instance. The details include configuration, routing adjacency, and hardware programming state. The 'staticd' and 'ribd' sections show VLAN delete operations and service label association. The 'fibd' section shows that the corresponding adjacencies and service label are successfully programmed in hardware.
supervisor@rtbrick.net: op> show l2x hierarchy l2x_remote direction ingress
staticd:
l2x name: l2x_remote
direction: egress
nexthop set hash: b4097df5d61079a99bafd02ed2ab12d9125c02e9e0688b45
vlan operation: single-vlan-delete
ribd:
l2x name: l2x_remote
direction: ingress
incoming interface: ifp-0/1/51
incoming outer vlan: 100
incoming inner vlan: 200
vlan operation: single-vlan-delete
service label: 10000
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
nexthop hash: 02c86c766b675e4a693b78ef395a65a1a1c6793e77629142
nexthop: 100.1.1.1, exit interface: ifl-0/1/51/10
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
nexthop hash: 02c86c766b675e4a693b78ef395a65a1a1c6793e77629142
nexthop: 100.1.1.1, exit interface: ifl-0/1/52/10
fibd:
l2x name: l2x_remote
direction: egress
bcm status: Download success
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
adjacency status: Success
bcm status: Download success
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
adjacency status: Success
service label: label:10000
Example for detailed view of remote L2X hierarchy.
This following example output provides a detailed hierarchical view of the L2X remote ingress instance with in-depth next-hop and lookup information. It shows MPLS label push actions, resolved next-hop attributes, and lookup context details from the RIB.
supervisor@rtbrick.net: op> show l2x hierarchy l2x_remote direction ingress detail
staticd:
l2x name: l2x_remote
direction: egress
nexthop set hash: b4097df5d61079a99bafd02ed2ab12d9125c02e9e0688b45
vlan operation: single-vlan-delete
ribd:
l2x name: l2x_remote
direction: ingress
incoming interface: ifp-0/1/51
incoming outer vlan: 100
incoming inner vlan: 200
vlan operation: single-vlan-delete
service label: 10000
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
nexthop hash: 02c86c766b675e4a693b78ef395a65a1a1c6793e77629142
nexthop: 100.1.1.1, exit interface: ifl-0/1/51/10
nexthop type: Remote ingress cross connect, nexthop action: mpls label push
lookup instance: default, lookup afi: ipv4, lookup safi: unicast
mac address: 7a:21:db:c0:00:05
covering prefix: 100.1.1.1/32
expanded nexthop: 10.1.1.2
lookup instance id: 1
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
nexthop hash: 02c86c766b675e4a693b78ef395a65a1a1c6793e77629142
nexthop: 100.1.1.1, exit interface: ifl-0/1/52/10
nexthop type: Remote ingress cross connect, nexthop action: mpls label push
lookup instance: default, lookup afi: ipv4, lookup safi: unicast
mac address: 7a:21:db:c0:00:06
covering prefix: 100.1.1.1/32
expanded nexthop: 20.1.1.2
lookup instance id: 1
fibd:
l2x name: l2x_remote
direction: egress
bcm status: Download success
bcm type: MPLS port to Vlan port
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
type: Remote ingress cross connect, action: mpls label push
adjacency status: Success
bcm status: Download success
bcm type: MPLS port to Vlan port
adjacency set hash: daf65a1cf024de74eb406450cdb4e8e1a163724811158c4e
type: Remote ingress cross connect, action: mpls label push
adjacency status: Success
service label: label:10000