The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
This chapter contains the following topics:
With online diagnostics, you can test and verify the hardware functionality of the switch while the switch is connected to a live network.
The online diagnostics contain packet switching tests that check different hardware components and verify the data path and the control signals.
The online diagnostics detect problems in these areas:
Online diagnostics are categorized as on-demand, scheduled, or health-monitoring diagnostics. On-demand diagnostics run from the CLI; scheduled diagnostics run at user-designated intervals or at specified times when the switch is connected to a live network; and health-monitoring runs in the background with user-defined intervals. By default, the health-monitoring test runs for every 30 seconds.
After you configure online diagnostics, you can manually start diagnostic tests or display the test results. You can also see which tests are configured for the switch or switch stack and the diagnostic tests that have already run.
After you configure diagnostic tests to run on the switch, use the diagnostic start privileged EXEC command to begin diagnostic testing.
After starting the tests, you cannot stop the testing process.
Use this privileged EXEC command to manually start online diagnostic testing.
1. diagnostic start switch number test {name | test-id | test-id-range | all | basic | non-disruptive }
You must configure the failure threshold and the interval between tests before enabling diagnostic monitoring.
You can schedule online diagnostics to run at a designated time of day or on a daily, weekly, or monthly basis for a switch. Use the no form of this command to remove the scheduling.
1. configure terminal
2. diagnostic schedule switch number test {name | test-id | test-id-range | all | basic | non-disruptive |} {daily | on mm dd yyyy hh:mm | weekly day-of-week hh:mm}
You can configure health-monitoring diagnostic testing on a switch while it is connected to a live network. You can configure the execution interval for each health-monitoring test, enable the switch to generate a syslog message because of a test failure, and enable a specific test.
By default, health monitoring is disabled, but the switch generates a syslog message when a test fails.
1. configure terminal
2. diagnostic monitor interval switch number test {name | test-id | test-id-range | all} hh:mm:ss milliseconds day
3. diagnostic monitor syslog
4. diagnostic monitor threshold switch number test {name | test-id | test-id-range | all} failure count count
5. diagnostic monitor switch number test {name | test-id | test-id-range | all}
6. end
You can display the online diagnostic tests that are configured for the switch ro switch stack and check the test results by using the privileged EXEC show commands in this table:
Command |
Purpose |
---|---|
show diagnostic content switch [number | all] |
Displays the online diagnostics configured for a switch. The switch [number | all] parameter is supported only on stacking switches. |
show diagnostic status |
Displays the currently running diagnostic tests. |
show diagnostic result switch [number | all] [detail | test {name | test-id | test-id-range | all} [detail]] |
Displays the online diagnostics test results. The switch [number | all] parameter is supported only on stacking switches. |
show diagnostic switch [number | all] [detail] |
Displays the online diagnostics test results. The switch [number | all] parameter is supported only on stacking switches. |
show diagnostic schedule switch [number | all] |
Displays the online diagnostics test schedule. The switch [number | all] parameter is supported only on stacking switches. |
show diagnostic post |
Displays the POST results. (The output is the same as the show post command output.) |
After you configure diagnostic tests to run on the switch, use the diagnostic start privileged EXEC command to begin diagnostic testing.
After starting the tests, you cannot stop the testing process.
Use this privileged EXEC command to manually start online diagnostic testing.
1. diagnostic start switch number test {name | test-id | test-id-range | all | basic | non-disruptive }
This example shows how to configure a health-monitoring test:
Switch(config)# diagnostic monitor threshold switch 1 test 1 failure count 50 Switch(config)# diagnostic monitor interval switch 1 test TestPortAsicStackPortLoopback
This example shows how to schedule diagnostic testing for a specific day and time on a specific switch:
Switch(config)# diagnostic schedule test TestPortAsicCam on June 3 2013 22:25
This example shows how to schedule diagnostic testing to occur weekly at a certain time on a specific switch:
Switch(config)# diagnostic schedule switch 1 test 1,2,4-6 weekly saturday 10:30
This example shows how to display the online diagnostic detailed information on a specific switch:
Switch# show diagnostic switch 1 detail
Switch 1: SerialNo :
Overall Diagnostic Result for Switch 1 : UNTESTED
Test results: (. = Pass, F = Fail, U = Untested)
___________________________________________________________________________
1) TestPortAsicStackPortLoopback ---> U
Error code ------------------> 3 (DIAG_SKIPPED)
Total run count -------------> 0
Last test testing type ------> n/a
Last test execution time ----> n/a
First test failure time -----> n/a
Last test failure time ------> n/a
Last test pass time ---------> n/a
Total failure count ---------> 0
Consecutive failure count ---> 0
___________________________________________________________________________
2) TestPortAsicLoopback ------------> U
Error code ------------------> 3 (DIAG_SKIPPED)
Total run count -------------> 0
Last test testing type ------> n/a
Last test execution time ----> n/a
First test failure time -----> n/a
Last test failure time ------> n/a
Last test pass time ---------> n/a
Total failure count ---------> 0
Consecutive failure count ---> 0
___________________________________________________________________________
3) TestPortAsicCam -----------------> U
Error code ------------------> 3 (DIAG_SKIPPED)
Total run count -------------> 0
Last test testing type ------> n/a
Last test execution time ----> n/a
First test failure time -----> n/a
Last test failure time ------> n/a
Last test pass time ---------> n/a
Total failure count ---------> 0
Consecutive failure count ---> 0
___________________________________________________________________________
4) TestPortAsicMem -----------------> U
Error code ------------------> 3 (DIAG_SKIPPED)
Total run count -------------> 0
Last test testing type ------> n/a
Last test execution time ----> n/a
First test failure time -----> n/a
Last test failure time ------> n/a
Last test pass time ---------> n/a
Total failure count ---------> 0
Consecutive failure count ---> 0
___________________________________________________________________________
5) TestInlinePwrCtlr ---------------> U
Error code ------------------> 3 (DIAG_SKIPPED)
Total run count -------------> 0
Last test testing type ------> n/a
Last test execution time ----> n/a
First test failure time -----> n/a
Last test failure time ------> n/a
Last test pass time ---------> n/a
Total failure count ---------> 0
Consecutive failure count ---> 0
___________________________________________________________________________
This example shows how to display the online diagnostics that are configured on a specific switch:
Switch# show diagnostic content switch 3
Switch 1:
Diagnostics test suite attributes:
B/* - Basic ondemand test / NA
P/V/* - Per port test / Per device test / NA
D/N/* - Disruptive test / Non-disruptive test / NA
S/* - Only applicable to standby unit / NA
X/* - Not a health monitoring test / NA
F/* - Fixed monitoring interval test / NA
E/* - Always enabled monitoring test / NA
A/I - Monitoring is active / Monitoring is inactive
R/* - Switch will reload after test list completion / NA
P/* - will partition stack / NA
Test Interval Thre-
ID Test Name Attributes day hh:mm:ss.ms shold
==== ================================== ============ =============== =====
1) TestPortAsicStackPortLoopback ---> B*N****I** not configured n/a
2) TestPortAsicLoopback ------------> B*D*X**IR* not configured n/a
3) TestPortAsicCam -----------------> B*D*X**IR* not configured n/a
4) TestPortAsicRingLoopback --------> B*D*X**IR* not configured n/a
5) TestMicRingLoopback -------------> B*D*X**IR* not configured n/a
6) TestPortAsicMem -----------------> B*D*X**IR* not configured n/a
This example shows how to display the online diagnostic results for a switch:
Switch# show diagnostic result
Switch 1: SerialNo :
Overall diagnostic result: PASS
Test results: (. = Pass, F = Fail, U = Untested)
1) TestPortAsicStackPortLoopback ---> .
2) TestPortAsicLoopback ------------> .
3) TestPortAsicCam -----------------> .
4) TestPortAsicRingLoopback --------> .
5) TestMicRingLoopback -------------> .
6) TestPortAsicMem -----------------> .
This example shows how to display the online diagnostic test status:
Switch# show diagnostic status
<BU> - Bootup Diagnostics, <HM> - Health Monitoring Diagnostics,
<OD> - OnDemand Diagnostics, <SCH> - Scheduled Diagnostics
====== ================================= =============================== ======
Card Description Current Running Test Run by
------ --------------------------------- --------------------- ------
1 N/A N/A
2 TestPortAsicStackPortLoopback <OD>
TestPortAsicLoopback <OD>
TestPortAsicCam <OD>
TestPortAsicRingLoopback <OD>
TestMicRingLoopback <OD>
TestPortAsicMem <OD>
3 N/A N/A
4 N/A N/A
====== ================================= =============================== ======
Switch#
This example shows how to display the online diagnostic test schedule for a switch:
Switch# show diagnostic schedule switch 1
Current Time = 14:39:49 PST Tue May 5 2013
Diagnostic for Switch 1:
Schedule #1:
To be run daily 12:00
Test ID(s) to be executed: 1.
Related Topic | Document Title |
---|---|
Online diagnostics commands |
Catalyst 2960-X Switch System Management Command Reference |
Platform-independent command references |
Cisco IOS 15.3M&T Command References |
Platform-independent configuration information |
Cisco IOS 15.3M&T Configuration Guides |
Standard/RFC | Title |
---|---|
None | — |
MIB | MIBs Link |
---|---|
All supported MIBs for this release. |
To locate and download MIBs for selected platforms, Cisco IOS releases, and feature sets, use Cisco MIB Locator found at the following URL: |
Description | Link |
---|---|
The Cisco Support website provides extensive online resources, including documentation and tools for troubleshooting and resolving technical issues with Cisco products and technologies. To receive security and technical information about your products, you can subscribe to various services, such as the Product Alert Tool (accessed from Field Notices), the Cisco Technical Services Newsletter, and Really Simple Syndication (RSS) Feeds. Access to most tools on the Cisco Support website requires a Cisco.com user ID and password. |
Release |
Modification |
---|---|
Cisco IOS 15.0(2)EX |
This feature was introduced. |