5-9
Software Configuration Guide—Release 12.2(25)SG
OL-7659-03
Chapter5 Checking Port Status and Conne ctivity
Using Layer 2 Traceroute

Running IP Traceroute

To trace the path that packets take through the network, perform this task in EXEC or privileged EXEC
mode:
This example shows use the trace command to display the route a packet takes through the network to
reach its destination:
Switch# trace ip ABA.NYC.mil
Type escape sequence to abort.
Tracing the route to ABA.NYC.mil (26.0.0.73)
1 DEBRIS.CISCO.COM (192.180.1.6) 1000 msec 8 msec 4 msec
2 BARRNET-GW.CISCO.COM (192.180.16.2) 8 msec 8 msec 8 msec
3 EXTERNAL-A-GATEWAY.STANFORD.EDU (192.42.110.225) 8 msec 4 msec 4 msec
4 BB2.SU.BARRNET.NET (192.200.254.6) 8 msec 8 msec 8 msec
5 SU.ARC.BARRNET.NET (192.200.3.8) 12 msec 12 msec 8 msec
6 MOFFETT-FLD-MB.in.MIL (192.52.195.1) 216 msec 120 msec 132 msec
7 ABA.NYC.mil (26.0.0.73) 412 msec 628 msec 664 msec
Switch#
Using Layer 2 Traceroute
The Layer 2 traceroute feature allows the switch to identify the physical pa th that a packet takes from a
source device to a destination device. Layer 2 traceroute supports only unicast source and destination
MAC addresses. It determines the path by using the MAC address tables of the switches in the path.
When the switch detects a device in the path that does not support Layer 2 traceroute, the switch
continues to send Layer 2 trace queries and lets them time out.
If you want the switch to trace the path from a host on a source device to a host on a destination device,
the switch can identify only the path from the source device to the destination device. It cannot identify
the path that a packet takes from source host to the source device or from the destination device to the
destination host.
These sections describe how to use the Layer 2 traceroute feature:
Layer 2 Traceroute Usage Guidelines, page 5-9
Running Layer 2 Traceroute, page 5-10

Layer 2 Traceroute Usage Guidelines

These are the Layer 2 traceroute usage guidelines:
CDP must be enabled on all the devices in the network. For Layer 2 traceroute to functional properly,
do not disable CDP.
If any devices in the physical path are transparent to CDP, the switch cannot identify the path
through these devices.
Command Purpose
Switch# trace [
protocol
] [
destination
]Runs IP traceroute to trace the path that packets
take through the network.