Configuring Ethernet Data Plane Loopback
The Ethernet Data Plane Loopback feature provides a means for remotely testing the throughput of an Ethernet port. You can verify the maximum rate of frame transmission with no frame loss. This feature allows for bidirectional or unidirectional throughput measurement, and on-demand/out-of-service (intrusive) operation during service turn-up.
This chapter consists of these sections:
Limitations and Configuration Guidelines
The following limitations and configuration guidelines apply when configuring Ethernet Data Plane Loopback on the Cisco ME 3600X and ME 3800X:
- The switch does not support data plane loopback on routed port infrastructure.
- The switch does not support Etype, src-mac, or llc-oui based loopback traffic filtering.
- In external loopback on service instances, the ingress qos on the service instance will be bypassed but not the port level qos. Similarly, the egress port shaper cannot be bypassed.
- In internal loopback, the expected sequence is ingress qos, egress qos (egress port), but the ingress port shaper will also take effect.
- The switch cannot bypass the port shaper on the ingress port in both external and internal loopback.
- The switch supports one active session per EFP, per port.
- Internal session on the switchport is not supported.
- Internal session is supported only of EFPs (service instances, Ethernet flow points, EVCs).
- While configuring internal sessions on EFPs, dot1q tags are mandatory. Therefore, internal loopback is not supported on a range of dot1q tags. However, loopback sessions can be configured using dot1q/QinQ, even if the underlying EFP has the dot1q/QinQ range configured.
- Multiple external loopback sessions can be configured on the same EFP or switchport (VLAN).
- Internal and external loopback cannot be configured under EFP with encapsulation default or encapsulation untagged.
- At one time, only one terminal loopback session can be active on an EFP.
- Egress span on the port and internal loopback on an EFP on the same port cannot be configured at the same time.
- The switch has only 1 Gigabit of bandwidth reserved for internal loopback. All internal sessions traffic has to be within this limit. There is an additional 18 bytes of overhead per packet in the internal loopback path.
Configuring Ethernet Data Plane Loopback
To enable and start Ethernet Data Plane Loopback on an interface, perform the following steps:
|
|
|
Step 1 |
enable |
Enables privileged EXEC mode.
- Enter your password if prompted.
|
Step 2 |
configure terminal |
Enters global configuration mode. |
Step 3 |
interface ethernet 0/1 |
Specifies an interface and enters interface configuration mode. |
Step 4 |
ethernet loopback permit external [ vlan { vlan-list | untagged }] |
Configures ethernet permit external loopback on a switchport interface. External loopback allows loopback of traffic from wire. This command is supported under a service instance. vlan vlan-list —Configures VLAN loopback for non-disruptive loopback testing. The vlan vlan-list keyword and argument is only supported on a switchport. |
Step 5 |
ethernet loopback permit internal [ vlan { vlan-list | untagged }] |
Configures ethernet permit internal loopback on an interface. Internal loopback allows loopback of traffic from relay. vlan vlan-list —Configures VLAN loopback for non-disruptive loopback testing. The vlan vlan-list keyword and argument is only supported on a switchport. |
Step 6 |
end |
Return to privileged EXEC mode. |
Step 7 |
enable |
Enables privileged EXEC mode.
- Enter your password if prompted.
|
Step 8 |
ethernet loopback start local interface interface-id [ service instance id ] { external | internal } [ destination mac-address address ] [{ dot1q | dot1ad vlan-id } [ second-dot1q inner-vlan-id ]] [ cos cos value ] [ timeout { seconds | none }] |
Starts ethernet external or internal loopback on the interface for a specific service, as follows:
- (Optional) Enter destination mac-address address to specify the destination mac address of the packets to be loopbacked. If the filter option is not specified, all of the packets with “Any” destination mac are eligible to be loopbacked.
- (Optional) Enter dot1q vlan_id to specify the s-tag of the packets to be loopbacked. If the filter option is not specified, all of the packets with all VLANs are eligible to be loopbacked.
- (Optional) Enter second-dot1q i nner-vlan-id to specify the c-tag of the packets to be loopbacked. If the filter option is not specified, all of the packets with all inner VLANs are eligible to be loopbacked.
- (Optional) Enter cos cos_value to specify the 802.1p/cos of the packets to be loopbacked. If the filter option is not specified, all of the packets with “Any” cos are eligible to be loopbacked.
- (Optional) Enter timeout seconds to set a loopback timeout period. The range is from 5 to 90000 seconds (25 hours). The default is 60 seconds.
- (Optional) Enter timeout none to set the loopback to no time out.
|
Note
By default the Session would be running for 300 seconds unless explicitly specified by the user and automatically stopped after the session time expiry.
To stop an active session on an interface or to stop all sessions use the ethernet loopback stop command.
Switch# ethernet loopback stop local interface gigabitethernet 0/1 id 1
Displaying Ethernet Dataplane Loopback Information
To verify the configuration on the switch use the show ethernet loopback command.
|
|
show ethernet loopback { active | permitted }[ interface interface number ] |
Displays ethernet dataplane loopback information. Enter active keyword to display all active sessions on the switch. Enter the permitted keyword to display loopback capabilities per interface. Use the interface interface number keyword and argument to display information on a specific interface. |
Sample Configurations
The example below enables and starts loopback, vlan 100 on the switchport trunk interface gigabitethernet 0/1 for external loopback.
Switch(config)#interface GigabitEthernet0/1
Switch(config-if)switchport trunk allowed vlan none
Switch(config-if)switchport mode trunk
Switch(config-if)media-type rj45
Switch(config-if)ethernet loopback permit external vlan 100
Switch#ethernet loopback start local interface gigabitethernet 0/1 external dot1q 100 cos 3
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
*Mar 25 11:14:04.863: %E_DLB-6-DATAPLANE_LOOPBACK_START: Ethernet Dataplane Loopback Start on interface GigabitEthernet0/1 with session id 1
Note
Note: By default the Session would be running for 300 seconds unless explicitly specified by the user and automatically stopped after the session time expiry.
Stop a session:
Switch#ethernet loopback stop local int gi 0/1 id <session_id>
*Nov 26 11:24:29.666: %E_DLB-6-DATAPLANE_LOOPBACK_STOP: Ethernet Dataplane Loopback Stop on interface GigabitEthernet0/1 with session id 1
This example shows the default behavior of ethernet data plane loopback. The VLAN keyword is not specified, therefore packets with all VLAN tags and untagged packets will be loopbacked:
Switch(config)# interface ethernet 1/0
Switch(config-if)# ethernet loopback permit external
This example shows data plane loopback on a switch port. In this example, the packets tagged with VLAN 2 coming from the wire on ethernet 1/0 will be loopbacked:
Switch(config)#interface ethernet 1/0
Switch(config-if)#switchport
Switch(config-if)#ethernet loopback permit external vlan 2
In this example, packets tagged with VLAN 3/4/5 coming from the wire on ethernet1/0 will be loopbacked:
Switch(config)#interface ethernet 1/0
Switch(config-if)#switchport
Switch(config-if)#ethernet loopback permit external vlan 3-5
In this example, packets tagged with VLAN 3/4/5 coming from the relay on ethernet1/0 will be loopbacked:
Switch(config)#interface ethernet 1/0
Switch(config-if)#switchport
Switch(config-if)#ethernet loopback permit internal vlan 3-5
In this example, untagged packets from the wire on ethernet 1/0 will be loopbacked:
Switch(config)#interface ethernet 1/0
Switch(config-if)#switchport
Switch(config-if)#ethernet loopback permit external vlan untagged
In this example, external loopback for VLAN 100 on the switch port trunk GigabitEthernet 0/1 is enabled:
interface GigabitEthernet 0/1
switchport trunk allowed vlan none
ethernet loopback permit external vlan 100
In this example, internal loopback for EFP 100 on GigabitEthernet 0/5 is enabled:
interface GigabitEthernet 0/5
switchport trunk allowed vlan none
service instance 101 ethernet
encapsulation dot1q 101 second-dot1q 200
rewrite ingress tag pop 2 symmetric
ethernet loopback permit internal
In this example, both internal and external loopback for EFP 100 on GigabitEthernet 0/5 is enabled:
interface GigabitEthernet 0/5
switchport trunk allowed vlan none
service instance 101 ethernet
rewrite ingress tag pop 1 symmetric
ethernet loopback permit internal
ethernet loopback permit external
In this example, internal loopback is started on an EFP:
Ethernet loopback start local int gi 0/5 service instance 100 internal dot1q 100 second-dot1q 200 cos 5
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
In these examples, external loopback is started on an EFP:
Ethernet loopback start local int gi 0/5 service instance 101 external dot1q 101 cos 5
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
Ethernet loopback start local int gi 0/5 service instance 101 external dot1q 101 cos 5 destination mac-address 0000.1111.2222
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
In this example, external loopback is started on a switchport trunk VLAN:
ethernet loopback start local int gi 0/1 external dot1q 100 cos 3
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
In this example, all active sessions on the switch are displayed:
Switch#show ethernet loopback active
============================================================
Interface : GigabitEthernet0/1
Start time : *11:19:29.670 UTC Sun Nov 26 2000
Destination Mac Address : Any
Total Active Session(s): 1
Total Internal Session(s): 0
Total External Session(s): 1
The following example displays the loopback capabilities per interface:
Switch#show ethernet loopback permitted interface gigabitethernet 0/1
--------------------------------------------------------------------------------
Interface SrvcInst Direction
Dot1q/Dot1ad(s) Second-Dot1q(s)
--------------------------------------------------------------------------------
Switch#ethernet loopback start local int gi 0/5 service instance 100 internal dot1q 100 second-dot1q 200 cos 5
This is an intrusive loopback and the packets matched with the service will not be able to pass through. Continue? (yes/[no]): yes
*Nov 26 11:58:38.921: %E_DLB-6-DATAPLANE_LOOPBACK_START: Ethernet Dataplane Loopback Start on interface GigabitEthernet0/5 service instance 100 with session id 2
Switch#show ethernet loopback active interface gigabitethernet 0/5
============================================================
Interface : GigabitEthernet0/5
Start time : *11:58:38.925 UTC Sun Nov 26 2000
Destination Mac Address : Any
Total Active Session(s): 1
Total Internal Session(s): 1
Total External Session(s): 0