Introduction

Cisco is no doubt a leader in networking products today. There would be very few Service Provider networks where the Cisco devices are not installed. Naturally, due to their popularity and reach, Service Providers and network engineering teams should have the basic knowledge of the Cisco devices, their configuration, and how to troubleshoot and monitor them. In this article, we are going to talk about some of the basic but popular Cisco show commands that we should know of if we are working with the Cisco devices.

These commands help in fetching various kinds of information related to Cisco devices like hardware details, software details, device configuration, interfaces configuration, IP routes, etc. Thus, these show commands, are very useful in troubleshooting and monitoring of the Cisco devices.

The stated Cisco show commands are useful for network engineers, network admins, NOC/SOC teams, and even developers.

Cisco Show Commands

We will cover the following Cisco show commands in this post:

  • show running-config
  • show interfaces
  • show ip interface & show ip interface brief
  • show ip route
  • show version
  • show ip cef
  • show ip cache

1. show running-config

The command displays the current running configuration of the Cisco device. It shows information like Cisco IOS version, interfaces, interfaces configuration, users, passwords, user roles, traps configuration, etc. It is RAM that stores this configuration.

show run or sh run are the abbreviations and can also be used for displaying the running configuration.

The running configuration is not necessarily the same as the startup configuration.

copy running-config startup-config command copies the running configuration to the startup configuration.

show startup-config command shows the startup configuration

Example

The following sample shows the output of show running-config command:

R1# show running-config
Building configuration…

Current configuration : 750 bytes
!
version 12.4
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname R1
…..
ip cef
!
…..
!
Interface FastEthernet 0/1
ip address 1.1.1.1 255.255.255.0
duplex auto
speed auto
!…

The command is heavy i.e. it fetches and displays the full configuration of the device. So, running this command as it is will not be beneficial and can unnecessarily load the device degrading its performance.

The command has some options to filter out a specific output. Run the following command and you will see the options that you can use to view specific configuration.

R1# show running-config ?

Suppose, we need to find the configuration of FastEthernet 0/1, so we can run:

R1# show running-config interface fa0/1
Building configuration…

Current configuration : 750 bytes
!
Interface FastEthernet 0/1
ip address 1.1.1.1 255.255.255.0
duplex auto
speed auto
end

2. show interfaces

If you want to have a detailed view of the interface-related data on a Cisco device, this is your go-to Cisco show command. The command displays all the interface-related data/statistics like interface status, settings, counters, etc. on the device. The command is extensively used in troubleshooting.

Using the default command will display the output relating to all the interfaces which might not be useful. We can use the interface name to filter out the configuration specific to that interface.

Example

Following is the sample output:

R1#show interfaces fa0/1


FastEthernet0/1 is up, line protocol is up (connected)
Hardware is ABCD, address is 0050.0bbb.0bbb (bia 0050.0bbb.0bbb)
BW 200000 Kbit, DLY 2000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Full-duplex, 100Mb/s


850 packets input, 193400 bytes, 0 no buffer
Received 956 broadcasts, 0 runts, 0 giants, 0 throttles
……
2450 packets output, 264000 bytes, 0 underruns
0 output errors, 0 collisions, 10 interface resets
0 babbles, 0 late collision, 0 deferred
0 lost carrier, 0 no carrier
0 output buffer failures, 0 output buffers swapped out
….

The above output is detailed and useful. You can see all the possible interface-related data. Let us see at some of the lines in the output and find out what do they mean.

  • FastEthernet0/1 is up, line protocol is up (connected) – indicates interface Fa0/1 is up and running
  • Hardware is ABCD, address is 0050.0bbb.0bbb (bia 0050.0bbb.0bbb) – indicates the chipset used by the port is ABCD. The MAC address of the port is also displayed.
  • BW 200000 Kbit, DLY 2000 usec – indicates the bandwidth of the interface and delay.
  • 850 packets input, 193400 bytes, 0 no buffer – total number of packets received on the port and their total size.
  • 2450 packets output, 264000 bytes, 0 underruns – total number of packets sent from the port, and their total size.

3. show ip interface & show ip interface brief

These two Cisco show commands are widely used in fetching the IP-related information of the device’s interfaces/ports. Details like IP Address, Subnet Mask, Interface status, etc are part of the command’s output.

So, when compared with the show interfaces command, this one is targeted for IP (L3) specific information.

Example

show ip interface command shows all the IP-related information for all the interfaces. Following is the sample output:

R1#show ip interface

FastEthernet0/1 is up, line protocol is up (connected)
Internet address is 1.1.1.1 /24
Broadcast address is 255.255.255.255

IP CEF switching enabled
….
FastEthernet0/2 is down, line protocol is down
Internet address is 2.2.2.2 /24

In the above output, the IP information related to two interfaces FastEthernet0/1 and FastEthernet0/2 is shown.

As a default, this command displays the IP information related to all the interfaces in a textual format which makes it a bit hard to read and interpret.

We can use the show ip interface brief command instead. The output is user-friendly and displayed in a tabular form.

R1#show ip interface brief

Interface IP-Address OK? Method Status Protocol
FastEthernet0/1 1.1.1.1 YES manual up up
FastEthernet0/2 2.2.2.2 YES manual administratively down down

4. show ip route

This is also one of the very popular Cisco show commands. The command displays the global Routing table (Routing Information Base, RIB) of the Cisco device. All the routing information (routes received from routing protocols, directly connected routes, etc.) is available as part of this command.

So, if there is an L3 routing issue, you might want to check the output of this command.

Example

Following is the sample output:

R1#show ip route

Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP,D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area
N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2
E1 – OSPF external type 1, E2 – OSPF external type 2, E – EGP
i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2
ia – IS-IS inter area, * – candidate default, U – per-user static route
o – ODR, P – periodic downloaded static route

D 216.238.54.0/24 [20/100] via 1.1.1.2, 3w6d, FastEthernet 0/4…
C 3.3.3.3 is directly connected, FastEthernet 0/1

In the above output, there is a route 216.238.54.0/24 learned via EIGRP (labeled as D), and there is another route 3.3.3.3 which is directly reachable (labeled as C) via FastEthernet 0/1.

5. show version

The command displays all the hardware and software-related information of the Cisco device. You can see the IOS version, memory information, number of interfaces, system uptime, etc.

Example

Following is the sample output:

R1#show version

Cisco IOS Software, CXXX Software (CXXXX-YYYYYY-M), Version 15.0(2)SE4, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2013 by Cisco Systems, Inc.

ROM: Bootstrap program is C2960 boot loader
BOOTLDR: CXXXX Boot Loader (CXXXX-YYYYYY-M)Version 12.2(25r)FX, RELEASE SOFTWARE (fc4)
Switch uptime is 39 minutes
System returned to ROM by power-on
System image file is …
…..

6. show ip cef

Cisco Express Forwarding (CEF), is a fast IP packet forwarding mechanism used in Cisco devices. CEF is enabled by default on almost all Cisco devices today. The command show ip cef is similar to show ip route command, but the latter is related to the control-plane or RIB, while the former is related to Forwarding Information Base (FIB) which is created as part of CEF. The show ip cef command displays the information at the data-plane level.      

Example

Following are the sample outputs of both show ip route and show ip cef so that you can relate:

R1# show ip route

Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP
D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area
N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2
E1 – OSPF external type 1, E2 – OSPF external type 2
i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2
ia – IS-IS inter area, * – candidate default, U – per-user static route
o – ODR, P – periodic downloaded static route

Gateway of last resort is not set
10.0.0.0/8 is variably subnetted, 10 subnets, 2 masks
C 10.0.9.0/30 is directly connected, FastEthernet0/1
O 10.0.0.2/32 [110/11] via 10.0.9.2, 00:01:30, FastEthernet0/1

The above command displays all the information about the different routes, via which routing protocol were they learned, the metric of routes learned, next-hop address, etc.

Now, let us look at the show ip cef command. The output here is restricted and targeted to a few specific fields (Destination Prefix, Next Hop IP, Interface) only.

R1# show ip cef

Prefix Next Hop Interface
0.0.0.0/0 drop Null0 (default route handler entry)
0.0.0.0/32 receive
10.0.0.1/32 receive
10.0.9.0/30 attached FastEthernet0/1
10.0.0.2/32 10.0.9.2 FastEthernet0/1

7. show ip cache

If the IP Fast Switching mechanism (a forwarding mechanism like CEF) is enabled on a Cisco device for packet forwarding, this command will be useful in displaying the cache information built as part of the mechanism.

Example

Sample output is shown below. It contains fields: Prefix length, Age, Interface, and Next Hop.

R1#show ip cache

Prefix Length Age Interface Next Hop
3.3.3.0/24 00:00:10 FastEthernet0/0 192.168.10.1

Check out our article on Cisco Express Forwarding (CEF), Routing Information Base (RIB), and Forwarding Information Base (FIB) for more information on CEF and IP Fast Switching.

Conclusion

Though there are many more Cisco show” commands, the commands highlighted in this article are the most popular ones. These commands can be treated as generic commands because they are not related to any specific network service. For services like MPLS, L2 VPN, etc. separate “show” commands are available.

Bookmark this article as your cheat sheet for the generic Cisco show commands.

For more information on Cisco devices and commands, visit Cisco’s website. Drop your comments below if you liked the article.

CURATED & WRITTEN BY

AYUSH PANDYA
(AUTHOR- THE UNPRECEDENTED CULT)

Ayush Pandya

Author. Blogger. Poet. Lyricist.

Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments