cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
23041
Views
2
Helpful
5
Replies

difference between sh config and sh run config

prabhdeepnijjar
Level 1
Level 1

Is there any differnce between sh config and sh run config commands?

5 Replies 5

Brian Meade
Level 7
Level 7

sh config will show the start-up configuration that will load everytime the device reboots.

sh run config will show the configuration that is currently running on the device. This configuration will go away when you reboot the device unless you save it as the start-up config.

williamsdo
Level 3
Level 3

Hi the show run is the running config that is the simple part, as the other post said the show config it the startup-config for when the unit reboots or starts up. When you make config changes that result with bad problems and long as you didn't do a wr mem or copy runing-config startup-config you can reboot the unit and recover.

Istvan_Rabai
Level 7
Level 7

Hi,

Simply put:

"show config" shows the config that is saved to NVRAM.

"show running-config" shows the config that is in the router RAM and the IOS is currently running on.

Cheers:

Istvan

Prabhdeep

Istvan makes a good distinction that startup-config is stored in NVRAM while running-config is stored in volatile RAM. And other have made the valid point that running-config is what is controlling the current operation of the router while startup-config will control the operation of the router after the router reboots.

I would like to approach the answer from a slightly different perspective. Perhaps the important aspect is not where they are stored but is the content of startup-config and running-config. Most of the time there should be no difference in the content of these two. In that sense we can say that most of the time there is no difference in the two. There can be differences if you have made config changes in running-config and have not saved the running-config to startup-config. The potential issue with this is that right now the router has a certain behavior and if the router reloads then the router will have a (somewhat) different behavior.

When I am making config changes on a live router I sometimes delay saving the config changes - just in case there is some issue with the change and I want to back it out. But we should not delay too long in saving the changes.

HTH

Rick

HTH

Rick

Slighty related to this is the possibility to revert to the startup-config after locking yourself out of a remote session. Assume you need to make a config change which you believe may lock out your vty session; say, for example, that you're reconfiguring the interface over which your vty session is connected, or you're changing the routing configuration or an access list. Simply issue a 'reload in xx' and then make the config change. If you're subsequently locked out then just wait x minues plus reload time and you'll be back to the point prior to your most recent change, allowing you to re-establish your remote session. If the config change works as planned, simply cancel the reload and carry on!

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card