Cisco IOS Show Commands in Switch and Router – Cheat Sheet

Cisco routers/switch run an operating system, called IOS. Like any operating system, IOS includes a command language to enable equipment owners to retrieve information and change the device’s settings. One of the most powerful commands in IOS is show.

The following is a list of the most common IOS commands associated with questions from the CCNA exam. They are all standard IOS commands used to configure, verify and troubleshoot network connectivity. The IOS commands are based on all topics from the published CCNA exam guidelines.

CCNA CLI Help Facility

Mode Level

The List of commands available from each Cisco device mode is available with question mark ? from each top level mode prompt.

rommon > ?
switch > ?
switch# ?
switch(config)# ?
switch(config-if)# ?

Command Level

The command level ? provides a list of all commands for that subgroup such as show commands for instance. In addition the question ? after any IOS command displays syntax options for that specific command. It is a quick reference for correct configuration syntax and commands not supported with the current IOS version.

switch# show ?
switch(config)# vtp mode ?
switch(config-if)# ?
switch(config-if)# show interfaces ?

Partial Commands

The partial command level question ? provides a list of all commands that begin with the letters specified. That helps list commands available that start with the same letters.

switch# c?

Global Commands

show running-config

Display the current running configuration script on any Cisco device.

show version

Display a variety of device information including the following:

  • IOS version
  • license feature set
  • configuration register setting
  • hardware

show protocols

Verify operational status (up/up), IP address and subnet mask of all network interfaces.

show ip interface brief

Summarizes the operational status (up/up) and IP address of all switch and router interfaces. The Status column is equivalent to Interface (Layer 1) for show interfaces command. The Protocol column is equivalent to Line Protocol (Layer 2) for show interfaces command.

show interfaces [interface]

Display the operational status (up/up), IP address, configuration settings and errors for a specific switch or router interface.

  • operational status
  • speed
  • duplex
  • MTU
  • interface errors

show cdp

Verify that CDP is enabled, update timer, hold timer and CDP version.

show cdp neighbor detail

Display all directly connected neighbor devices and confirm there is Layer 2 connectivity to each neighbor and the following neighbor details:

  • local interface
  • neighbor hostname
  • neighbor interface
  • neighbor IOS version
  • neighbor hardware platform

show lldp

Verify that LLDP is enabled and timer settings.

show lldp neighbors detail

Display all multi-vendor neighbors directly connected to a Cisco device and confirm there is Layer 2 connectivity to each neighbor.

  • local interface
  • neighbor hostname
  • neighbor interface
  • neighbor IOS version
  • neighbor hardware platform

show memory

Display the total, used and available memory on a Cisco device.

show process cpu

Display the CPU utilization for a Cisco device at five minute intervals.

show environment

Verify the operational status of fans, temperature and power supplies. In addition list the percentage of power supply utilization and what amount is available.

do [show command]

Run show commands from any device mode prompt.

LAN Switching Technologies

show vlan brief

Display all configured VLANs, verify active status and any switch ports assigned.

show vlan

Display all configured VLANs, verify active status and any switch ports assigned. There is some additional VLAN information provided as well.

show interface switchport

Display the operational mode and administrative mode for local switch ports and enable status. In addition there is a variety of trunking configuration and VLAN pruning information.

show interfaces trunk

Verify the operational status of trunk interfaces and list configuration settings:

  • switch port members
  • allowed VLANs
  • native VLAN
  • encapsulation type
  • trunk mode

show interfaces status

Display the Layer 2 connected / notconnect status for each switch port and configuration settings.

  • connected / not connect
  • interface speed
  • duplex settings
  • VLAN
  • Ethernet standard

show interfaces [interface] transceiver

Display the Layer 1 characteristics of the transceiver connected to a switch port interface.

show etherchannel summary

Verify all EtherChannel links configured on the local switch including the operational status.

  • operational status
  • channel group number
  • negotiation protocol (PAgP/LACP)
  • switch ports assigned

show interface port-channel [number]

Verify the operational status (up/up), configuration and errors for a port channel interface assigned to an EtherChannel.

  • IP address
  • speed
  • duplex
  • MTU
  • interface errors
  • port members

show spanning-tree vlan [number]

Display the spanning tree information for a specific VLAN.

  • root bridge
  • timers
  • STP port types (local interfaces)
  • port path cost

show spanning-tree interface [interface]

Display the spanning tree information for a specific switch interface.

  • STP port type
  • STP port state
  • port path cost
  • STP timers

show spanning-tree

Display the bridge ID for the local switch and root bridge ID for each VLAN including priority and timer settings.

  • local bridge ID, priority and timers
  • root bridge priority per VLAN
  • root bridge MAC address per VLAN
  • priority and path cost for local switch ports

show spanning-tree summary

Display the spanning tree protocol enabled on the local switch.

  • spanning tree protocol enabled
  • root bridge ID for each VLAN
  • STP enhancements (PortFast etc.).
  • STP port states per VLAN

show vtp status

Display various configuration information for the VTP domain where the local switch is a member.

  • version number
  • configuration revision
  • operating mode of local switch
  • domain name

show mac address-table

Display MAC address, port number and VLAN of each host connected to the local switch.

Routing Technologies

ping [ip address] [hostname]

Confirms Layer 3 network connectivity between a source and destination based on sending and return of ICMP packets.

traceroute [ip address] [hostname]

Confirm the routing path for Layer 3 connectivity between a source and destination based on UDP packets.

show ip route

Display the routing table for the local router that includes all known subnets, routing protocol, next hop address, metrics and administrative distance. In addition the gateway of last resort (default route) is shown when it is configured.

show ip arp

Display the IP address and MAC address bindings in the router ARP table. The MAC address of servers and network devices are learned through ARP requests and added to the local cache.

show ipv6 interface brief

Verify the operational status (up/up) and IPv6 address for all router interfaces.

show ipv6 interface [interface]

Verify the operational status (up/up), IPv6 addressing, configuration settings and errors for a router interface.

  • speed
  • duplex
  • MTU
  • interface errors

show ip protocols

Display a variety of settings and configuration for all enabled routing protocols on the router.

show ip ospf

Display various configuration settings for each OSPF process enabled on the router.

  • router ID
  • timers
  • interfaces per area
  • area range (subnet)

show ip ospf neighbor

Verify all OSPF adjacencies established with directly connected OSPF neighbors.

  • neighbor router ID
  • IP address
  • adjacency state
  • assigned DR/BDR

show ip ospf interface [interface]

Verify the operational status (up/up) of an OSPF enabled interface. In addition Display the OSPF configuration for the interface.

  • IP address
  • area assigned
  • process ID
  • router ID
  • network type
  • timers
  • assigned DR/BDR
  • adjacent neighbor

show ip ospf database

Display the OSPF link state database topology that includes Link State Advertisements (LSAs) for all OSPF neighbors advertising from all areas.

  • link state advertisements
  • advertising router
  • process ID
  • router ID

show ipv6 ospf interface [interface]

Verify the operational status (up/up) of an OSPF for IPv6 enabled interface. In addition list the IPv6 addressing and OSPF configuration for the interface.

  • IPv6 address
  • area assigned
  • process ID
  • network type
  • timers
  • assigned DR/BDR

show ipv6 ospf neighbor detail

Display all OSPFv3 for IPv6 adjacencies established with OSPF neighbors.

  • neighbor router ID
  • IPv6 addressing
  • adjacency state
  • assigned DR/BDR

show ip eigrp neighbors

Display all EIGRP adjacencies established with directly connected EIGRP neighbors.

  • neighbor IP address
  • local interface
  • autonomous system number
  • hold time
  • SRTT, RTO and queue count

show ip eigrp interfaces

Display all active EIGRP interfaces associated with an autonomous system (AS).

show ipv6 eigrp neighbors

Display all EIGRP for IPv6 adjacencies established with directly connected neighbors.

  • neighbor IPv6 address
  • local interface
  • autonomous system
  • hold time
  • SRTT, RTO and queue count

show ipv6 eigrp interfaces [interface]

Verify all active EIGRP for IPv6 interfaces associated with an autonomous system (AS).

show ip eigrp topology

Display all successor and feasible successor routes to a destination in addition to DUAL states.

show ip rip neighbors

Display all active sessions the local router has established with RIPv2 neighbors that include neighbor IP address and interface.

WAN Technologies

show interfaces multilink [interface]

Display the IP address and encapsulation type for the multilink interface.

  • operational status (up/up)
  • interface errors
  • LCP / IPCP negotiation status

show ppp multilink

Verify the multilink interface status as enabled for the router.

  • bundle name
  • local and remote hostnames
  • member interfaces
  • packet errors

show pppoe session

Display all PPP over Ethernet (PPPoE) sessions enabled for the router.

  • local and remote MAC address of peers
  • local interface
  • dialer number

show ip bgp neighbors

Display all BGP neighbor peering sessions established and TCP connection information. The neighbor configuration includes the following.

  • router ID
  • IP address
  • neighbor feature capabilities

show ip bgp summary

Display all BGP routing information for the neighbor connections including prefix (subnet), attribute and prefix (subnet) information.

show interface tunnel [number]

Verify the operational status (up/up) of the tunnel and the assigned IP address. In addition the tunnel source address and local interface is shown along with transport configuration.

Infrastructure Services

show ip dhcp conflict

Display all IP address conflicts detected on the IOS DHCP server when allocating IP addresses to DHCP clients.

show ip dhcp binding

Display the IP address and MAC address of DHCP client, lease expiration and assignment type on the IOS DCHP server.

show ip dhcp snooping

Verify that DHCP snooping is enabled along with assigned VLANs and interfaces configured for snooping. In addition verify the VLANs are operational for snooping.

show standby

Display the HSRP configuration on the local router for the router group configured.

  • virtual IP address
  • virtual MAC address
  • timers
  • active router
  • standby router

show ip nat translations

Verify the NAT addressing assigned for translating between private and public addressing.

Infrastructure Security

show port-security interface [interface]

Display the port security configuration for a switch interface.

show dot1x interface [interface] details

Display the switch side settings for port-based authentication of a host.

show access-lists

Display all IPv4 access control lists configured on the local router to verify filtering of packets.

show ipv6 access-lists

Display all IPv6 access control lists configured on the local router to verify filtering of packets.

Infrastructure Management

show ntp status

Verify the synchronization status to an NTP peer, IP address of NTP peer, local stratum level and clock signaling.

show users all

Display all inbound connections to the local device including VTY, console and AUX lines.

show terminal

Display terminal settings for the current terminal line and transport protocols allowed for remote management access (SSH, Telnet etc.)

show flash

List the files currently on flash memory including available memory.

erase nvram:

Delete all the files on NVRAM including the startup configuration.

show logging

Verify the logging configuration and where it is enabled/disabled on the network device. In addition list all error messages logged for a specific device

Host Commands

ipconfig /all

Verify the network connectivity status, IPv4/IPv6 addressing and MAC address for a host. In addition the DNS servers and DHCP configuration are listed.

arp -a

Display the contents of the local ARP cache.

tracert [ip address] [hostname]

The host version of traceroute command to verify routing path from the host.

nslookup [domain name]

Confirm DNS server is working correctly.


Related Articles

Leave a Reply

avatar

Send this to a friend