×

Warning message

  • Cisco Support Forums is in Read Only mode while the site is being migrated.
  • Cisco Support Forums is in Read Only mode while the site is being migrated.

How to Copper Test a Port on a Switch through the Command Line Interface (CLI)

Document

Tue, 05/02/2017 - 11:00
May 1st, 2017
User Badges:

Cisco Support Community

Article ID: 5560

Objective

The Copper Test feature of the switch tests whether a port can link up or not through a RJ45 connector and also helps to determine the cable performance with the use of the Virtual Cable Tester (VCT). If an interface has problems, you can perform a diagnostic test on the cable that is plugged on that interface to see its status. With this information in hand, you can make better decisions when you troubleshoot an interface.

Through the Command Line Interface (CLI) of your switch, you can use the Time Domain Reflectometry (TDR) technology to test the quality and characteristics of a copper cable attached to a port. Cables of up to 140 meters long can be tested.

This article explains the performance of the copper ports test done by the VCT on Gigabit Ethernet (GE) ports through the CLI of your switch.

Note: To learn how to copper test a port through the web-based utility of the switch, click here.

Applicable Devices

  • Sx300 Series
  • Sx350 Series
  • SG350X Series
  • Sx500 Series
  • Sx550X Series

Software Version

  • 1.4.7.05 — Sx300, Sx500
  • 2.2.8.4 — Sx350, SG350X, Sx550X

Copper Test a Port on a Switch through the CLI

Preconditions to Running the Copper Port Test

Before running the test, do the following:

  • Use a CAT6a data cable when testing cables.
  • (Mandatory) Disable Short Reach mode. Basic cable test results are accurate if Short Reach is disabled.
  • (Optional) Disable Energy Efficient Ethernet (EEE). The advanced cable test results are accurate if EEE is disabled on the port that you are going to test.

Note: To learn how to configure the Short Reach and EEE settings on the ports of your switch through the CLI, click here for instructions.

Important: When a port is tested, it is set to the Down state and communications are interrupted. After the test, the port returns to the Up state.

Run the Copper Port Test

Step 1. Log in to the switch console. The default username and password is cisco/cisco. If you have configured a new username or password, enter the credentials instead.

ijgm_05022017_copper-test-port-cli_step1.png

Note: The available commands or options may vary depending on the exact model of your device. In this example, the SG350X switch is accessed through Telnet.

Step 2. In the Privileged EXEC mode of the switch, run the port test by entering either of the following command:

  • interface-id — (Optional) Specifies an Ethernet port ID.

Note: In this example, GE1/0/2 is used as the specific interface to copper test.

ijgm_05022017_copper-test-port-cli_step2a.png

The test above shows that the cable on the tested port has short circuit at 0 meter. This indicates that the cable used on the specific port could be damaged.

Step 3. (Optional) Replace the damaged cable on the port and then run the port test again on the same interface.

ijgm_05022017_copper-test-port-cli_step3.png

The test above shows that the cable on the tested port is good after the cable has been changed.

Step 4. (Optional) Repeat Step 2 to the remaining ports on your switch that you want to test.

Note: Copper port test does not work on fiber ports. If the port that you are going to test is a part of a combination port with fiber port active, it does not need to be shut down because the test does not work on fiber ports.

ijgm_05022017_copper-test-port-cli_step4.png

You should now have successfully run the copper port test on the specific port on your switch through the CLI.

View the Copper Port Test Results

In the event of an open or shorted cable, the accuracy of length of where the cable is open or shorted is -/+ 2 meters. Follow these steps to show the copper port test results on your switch through the CLI:

Step 1. In the Privileged EXEC mode of the switch, show the results of the copper test performed to all ports or to a specific port by entering the following:

  • interface interface-id — (Optional) Specifies an Ethernet port ID.

Note: In this example, show cable-diagnostics tdr command is entered.

The Cable Diagnostics TDR table shows the following information:

  • Port — The interface tested.
  • Result — The result of the conducted port test. Possible values are:

- OK — Cable has passed the test.

- No Cable — Cable is not connected to the port.

- Open Cable — Only one side of the cable is connected.

- Short Cable — Short circuit has occurred in the cable.

- Unknown Test Result — Error has occurred.

- Not tested — TDR test has not been conducted on the port.

  • Length — The cable length in meters.
  • Date — The date and time the port test was conducted.

ijgm_05022017_view-copper-test-port-cli_step1a.png

The table above shows that Gigabit ports 1, 2, 3, 5, and 7 are good, the fourth one (gi1/0/4) has a Short cable, the eighth one (gi1/0/8) has an Open cable, while the rest are Not tested.

Step 2. (Optional) To display the estimated copper cable length attached to all ports or to a specific port, enter the following:

  • interface interface-id — (Optional) Specifies an Ethernet port ID.

Note: In this example, show cable-diagnostics cable-length command is entered.

The Cable Diagnostics Cable Length table shows the following information:

  • Port — The name of the interface.
  • Length — The cable length in meters.

ijgm_05022017_view-copper-test-port-cli_step2a.png

The table above shows that Gigabit Ethernet ports 1, 2, 3, 5, 6, 7, and 9 have less than 50 meters cable attached, while the rest are not active. All Ten Gigabit Ethernet ports are fiber ports, therefore, the Copper port test does not work on them.

You should now have successfully viewed the results of copper tests that were conducted on the ports of your switch.

Loading.

Actions

This Document