Investigating Cisco's built-in TDR

I love finding stuff like this. In the course of my daily Internet browsing, today I came across this post from a while back on the CCNP Recertification blog. It turns out a number of Cisco switches (apparently the 3560/3750, and some 4500 and 6500 modules) have a TDR embedded in each interface. How cool is that?

Cisco's documentation shows the simple but very handy two-part command syntax.

Switch# test cable-diagnostics tdr interface g0/1
TDR test started on interface Gi0/1
A TDR test can take a few seconds to run on an interface
Use 'show cable-diagnostics tdr' to read the TDR results.

Switch# sh cable-diagnostics tdr int g0/1
TDR test last run on: March 01 00:09:06

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     auto  Pair A     20   +/- 4  meters N/A         Open                
                Pair B     20   +/- 4  meters N/A         Open                
                Pair C     21   +/- 4  meters N/A         Open                
                Pair D     20   +/- 4  meters N/A         Open                

This output shows a cable approximately 20 meters in length connected to interface G0/1, with nothing attached to the far end. If you're like me, your first thought is "very cool, but is it accurate?" I grabbed a couple spare cables of various lengths and set about an unscientific benchmark. I measured each cable in three manners: by hand, with my Fluke TDR, and with a Catalyst 3560G-24PS-S. My observed results are below.

Cable       Length      Fluke   3560 
----------------------------------------------
A           69 ft       69 ft   20 +/- 4m (~66 ft)
B           21 ft       21 ft   6 +/- 4m  (~20 ft)
C           83 ft       83 ft   25 +/- 4m (~82 ft)

As you can see, the 3560 is impressively accurate, even without its allowed 4m variance. My next consideration was whether a TDR test would disrupt interface operation. Trying it on a live port while running a constant ping yielded no observable effect, not even a brief disconnection pop-up. This is clearly a very handy tool. I only wish Cisco would do more to publicize cool features like this.

About the Author

Jeremy Stretch is a freelance networking engineer, instructor, and the maintainer of PacketLife.net. He currently lives in Fairfax, Virginia, on the edge of the Washington, DC metro area. Although primarily an R&S guy, he likes to get into everything, and runs a free network training lab out of his basement for fun. You can contact him by email or follow him on Twitter.

Comments

Can this get the full length of a cable as it is connect from the switch ---> to the patch panel ---> to the user office ?

On a 7600 with WS-X6748-GE-TX, there is disruption on the traffic :(. On a 3750 i didn't see any.

Definately saw a drop on my 3560, also got the following result:

CNPAS226#sh cable-diagnostics tdr int g0/1
TDR test last run on: November 14 18:06:36

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- -----------
Gi0/1     100M  Pair A     N/A                Pair A      Normal
               Pair B     N/A                Pair B      Normal
               Pair C     180  +/- 2  meters Pair C      Short
               Pair D     164  +/- 2  meters Pair D      Short

That's a really cool feature. Seems to work only with gig interfaces, though - bummer :)

This works on one of my 2960's with 100Mb too. Although I did have something plugged into it far side - no packets dropped on testing. Impressed!

Cisco IOS Software, C2960 Software (C2960-LANBASE-M), Version 12.2(25)SEE3, RELE ASE SOFTWARE (fc2)

DARWIN_SW2#sh cable-diagnostics tdr int fa0/3
TDR test last run on: June 29 00:44:25

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/3     100M  Pair A     0    +/- 15 meters Pair A      Normal
                Pair B     0    +/- 15 meters Pair B      Normal
                Pair C     N/A                Pair C      Not Supported
                Pair D     N/A                Pair D      Not Supported

On some of my 2960 switches, I get length "N/A" when I have lost connectivity to the end-node. Has anyone found what this means - other than the switch couldn't determine the length?

There was a drop on 6500 with 6748s as well. Should have scrolled down to the comments before trying it....

This is a list of some of the findings I have gotten from testing with a 2960 switch:

While testing a port with a POE attached:
POE will 'sometimes' add one meter to length, with or without power.

Normal port with nothing attached and a 3ft patch cord: (sometimes with poe attached)

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/2     auto      Pair A     1    +/- 1  meters N/A         Open
                Pair B     1    +/- 1  meters N/A         Open
                    Pair C     N/A                N/A         Not Supported
                    Pair D     N/A                N/A         Not Supported

Normal port with 5 ft patch cord: (also with 3ft patch cord and POE attached)

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/2     auto      Pair A     2    +/- 1  meters N/A         Open
                    Pair B     2    +/- 1  meters N/A         Open
                    Pair C     N/A                N/A         Not Supported
                    Pair D     N/A                N/A         Not Supported

Normal with 5ft patch cord and POE attached:

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/2     auto      Pair A     3    +/- 1  meters N/A         Open
                    Pair B     3    +/- 1  meters N/A         Open
                    Pair C     N/A                N/A         Not Supported
                    Pair D     N/A                N/A         Not Supported

Normal with 42ft cable and device plugged in:

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/2     100M      Pair A     15   +/- 15 meters Pair A      Normal
                    Pair B     15   +/- 15 meters Pair B      Normal
                    Pair C     N/A                Pair C      Not Supported
                    Pair D     N/A                Pair D      Not Supported

I have not found a definite reason for the N/A response on active ports (Pair A, Pair B) but it is usually due to a defective NIC.
Hope this helps!

I've done some investigation with regard to using a Gigabit Crossover cable and a Straight Through cable and TDR on a Cisco 2960, and came across some interesting things.

PART I:
Tests using a Crossover cable, type "Gigabit T568B crossover, All four pairs crossed" (see Wikipedia) of 2 meter in length:

1) From Gig0/1 on 2960 to a Gig0/23 port on 3750:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:44:36

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     1000M Pair A     0    +/- 10 meters Pair A      Normal
                Pair B     0    +/- 10 meters Pair B      Normal
                Pair C     0    +/- 10 meters Pair C      Normal
                Pair D     0    +/- 10 meters Pair D      Normal
2960#

2) From Gig0/1 on 2960 to Gig8 port on Linksys SRW2016:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:47:05

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     1000M Pair A     0    +/- 10 meters Pair B      Normal
                Pair B     0    +/- 10 meters Pair A      Normal
                Pair C     0    +/- 10 meters Pair D      Normal
                Pair D     0    +/- 10 meters Pair C      Normal
2960#
Notice the difference in remote pairs!

3) From Gig0/1 on 2960 to 10/100 port on a CPE device:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:45:09

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     auto  Pair A     N/A                Pair A      Normal
                Pair B     N/A                Pair B      Normal
                Pair C     2    +/- 2  meters Pair C      Short
                Pair D     1    +/- 2  meters Pair D      Short
2960#

4) From Fa0/40 on 2960 to 10/100 port on a CPE device:

2960#show cable-diagnostics tdr interface fastEthernet 0/40
TDR test last run on: April 16 04:16:47

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/40    100M  Pair A     0    +/- 15 meters Pair A      Normal
                Pair B     0    +/- 15 meters Pair B      Normal
                Pair C     N/A                Pair C      Not Supported
                Pair D     N/A                Pair D      Not Supported
2960#

PART II:
Then, all tests were repeated with a Straight-Through cable of 3 meter in length.

1) From Gig0/1 on 2960 to a Gig0/23 port on 3750:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:50:16

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     1000M Pair A     0    +/- 10 meters Pair B      Normal
                Pair B     0    +/- 10 meters Pair A      Normal
                Pair C     0    +/- 10 meters Pair D      Normal
                Pair D     0    +/- 10 meters Pair C      Normal
2960#

2) From Gig0/1 on 2960 to Gig8 port on Linksys SRW2016:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:48:46

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     1000M Pair A     0    +/- 10 meters Pair A      Normal
                Pair B     0    +/- 10 meters Pair B      Normal
                Pair C     0    +/- 10 meters Pair C      Normal
                Pair D     0    +/- 10 meters Pair D      Normal
2960#

3) From Gig0/1 on 2960 to 10/100 port on a CPE device:

2960#show cable-diagnostics tdr interface gigabitEthernet 0/1
TDR test last run on: April 16 03:51:37

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Gi0/1     100M  Pair A     N/A                Pair A      Normal
                Pair B     N/A                Pair B      Normal
                Pair C     2    +/- 2  meters Pair C      Short
                Pair D     2    +/- 2  meters Pair D      Short
2960#

4) From Fa0/40 on 2960 to 10/100 port on a CPE device:

2960#show cable-diagnostics tdr interface fastEthernet 0/40
TDR test last run on: April 16 04:18:15

Interface Speed Local pair Pair length        Remote pair Pair status
--------- ----- ---------- ------------------ ----------- --------------------
Fa0/40    100M  Pair A     4    +/- 15 meters Pair B      Normal
                Pair B     4    +/- 15 meters Pair A      Normal
                Pair C     N/A                Pair D      Not Supported
                Pair D     N/A                Pair C      Not Supported
2960#

Leave a Comment


Register to comment as a member. You'll look cooler.

Optional; will not be displayed publicly or given out.

No commercial links. Only personal (e.g. blog, Twitter, or LinkedIn) and/or on-topic links, please.
The _____ TCP flag is used to initiate a connection.