top of page
  • Writer's pictureAaron Magruder

Daily Cisco Commands


Below are the most common Cisco commands I use when getting around a Cisco Network or troubleshooting an issue. Some of these are for switches, routers or both. I'll let you play around with them to see which is which. Not all of them may be available depending on what version of code you are running.

What are your favorite commands?

show run (interface) will show you the current running configuration of the device.

show run partition ? is extremely useful to show only sections of the config you want to see but I also use the | command listed at the end of this article.

access-list All access-list configurations class-map All class-map configurations common All remaining unregistered configurations global-cdp All global cdp configurations interface Each Interface specific Configurations ip-as-path All IP as-path configurations ip-community All IP community list configurations ip-domain-list All ip domain list configurations ip-prefix-list All ip prefix-list configurations ip-static-routes All IP static configurations line All line mode configurations policy-map All policy-map configurations route-map All route-map configurations router All routing configurations snmp All SNMP configurations

show interface status (sh int status) is useful on switches to determine what is connected, in what vlan and speed/duplex.

Port Name Status Vlan Duplex Speed Type Fa0/2/0 IPPhone connected 10 a-full a-100 10/100BaseTX

sh mac-address-table or show mac address-table depending on if you are in a switch or router with a switching module is useful to find out what device is connected to what port. Can be used in conjunction with the show arp to find the IP or Mac depending on which one you know.

Destination Address Address Type VLAN Destination Port ------------------- ------------ ---- -------------------- c47d.4fc9.d343 Self 1 Vlan1

show ip interface brief (sh ip int brief) is useful to quickly discovery what ip addresses are assigned to what interfaces on a device.

Interface IP-Address OK? Method Status Protocol GigabitEthernet0/0 10.0.0.1 YES NVRAM up up

show cdp neighbors (details) shows you what other CDP enabled devices are connected to your device and what their ip address is.

show arp tells you what mac address was discovered to what ip address. Useful for find the mac address of a device if you need to track down what switchport it is one.

Protocol Address Age (min) Hardware Addr Type Interface Internet 10.1.1.1 191 0025.8409.2d65 ARPA Vlan100

show log is invaluable to identifying issues on your device. Many people don't have logging enable or have such a small buffer, the logs are overwritten. Increasae your log size and use a syslog server to keep a larger history of events.

All these commands can be used in conjunction with the | command after them.

show run | ?

The most common are begin, exclude and include. Try doing a show run | beg router eigrp to get to the eigrp section faster than looking through a show run.

append Append redirected output to URL (URLs supporting append operation only). begin Begin with the line that matches count Count number of lines which match regexp exclude Exclude lines that match format Format the output using the specified spec file include Include lines that match redirect Redirect output to URL section Filter a section of output tee Copy output to URL

What are your favorite commands?


27 views0 comments
bottom of page