Effectively managing and troubleshooting Cisco switches is essential for maintaining a robust network infrastructure. The Command-Line Interface (CLI) offers a powerful means to configure, monitor, and resolve issues within your network.
1. Verifying Interface Status
Begin by assessing the operational status of all interfaces to identify any that are down or administratively disabled.
- Command:
show ip interface brief
This command provides a concise overview of each interface’s status, including its IP address and operational state.
2. Examining Interface Details
For a more in-depth analysis of a specific interface, including error statistics and configuration, use:
- Command:
show interfaces [interface_id]
(Replace [interface_id] with the actual interface identifier (e.g., GigabitEthernet1/0/1).
3. Reviewing VLAN Configuration
Ensure that VLANs are correctly configured and active.
- Command:
show vlan brief
This displays a summary of VLANs, their status, and associated ports.
4. Checking Spanning Tree Protocol (STP) Status
STP issues can lead to network loops or connectivity problems.
- Command:
show spanning-tree
This command provides information about the STP topology and any potential issues.
5. Analyzing MAC Address Table
Investigate the MAC address table to ensure proper learning and forwarding of frames.
- Command:
show mac address-table
This displays the MAC addresses learned by the switch and their associated ports.
6. Inspecting Port Security Settings
Port security configurations can impact connectivity if misconfigured.
- Command:
show port-security
This command shows the port security status and any security violations.
7. Examining Interface Counters
Check for errors or drops that might indicate hardware issues or misconfigurations.
- Command:
show interfaces counters
This provides statistics on input and output packets, including errors and drops.
8. Utilizing Cisco Discovery Protocol (CDP)
CDP helps identify directly connected Cisco devices, aiding in topology verification.
- Command:
show cdp neighbors
This displays information about neighboring Cisco devices.
9. Reviewing System Logs
System logs can provide insights into events and errors affecting the switch.
- Command:
show logging
This command displays the system log messages.
10. Performing a Ping Test
Verify connectivity to other devices or network segments.
- Command:
ping [destination_ip]
Replace [destination_ip] with the IP address of the device you want to test connectivity to.
11. Displaying the Running Configuration
To view the current configuration of the switch:
- Command:
show running-config
This command displays the active configuration, including interface settings, VLANs, and routing protocols.
12. Displaying the Startup Configuration
To view the configuration that the switch will use upon reboot:
- Command:
show startup-config
This shows the configuration stored in non-volatile memory, which is loaded during startup.
13. Displaying Interface Status
To check the status of all interfaces:
- Command:
show interfaces status
This provides a summary of each interface’s status, including its VLAN assignment and operational state.
14. Displaying Interface Configuration
To view the configuration of a specific interface:
- Command:
show running-config interface [interface_id]
Replace [interface_id] with the actual interface identifier (e.g., GigabitEthernet1/0/1).
15. Displaying the Routing Table
To view the current routing table:
- Command:
show ip route
This command displays the routing table, including directly connected networks, static routes, and dynamic routing protocols.