Warning: Invalid argument supplied for foreach() in /home/techrecipes/public_html/wp-content/themes/techrecipes/header.php on line 77

Copy Cisco Router Config into Flash to Back Up or Replace Hardware

When replacing a faulty router that is not completely dead, it may be possible to copy the startup configuration to the removable flash memory and swap the flash to get the new router up and configured in as short a time as possible. Without this procedure, manually copying the old configuration to the new router will be necessary. This simple command also provides a local backup copy of the router’s config which can save hours of work when replacing a dead router.


To copy the startup-config to flash as a file called backupconfig, use the following command:

copy startup-config flash:backupconfig

It will verify the destination filename. (Just press Enter to continue.) This must be done on the old router. (I try to do it whenever I make a configuration change.)

When moving the configuration to another router, physically move the flash memory, power on the router, and answer “no” to the system configuration prompt. Enter enable mode. (No password should be required if this is an unconfigured router.) Then use the following command to load the configuration from flash:

copy flash:backupconfig running-config

This pulls the configuration out of flash and makes it the current running configuration. While it is possible to copy the config directly into the startup-config and reload the router, I like to place it into running-config directly to make sure that everything comes up as it should.

When you copy into running-config, all of the interfaces will be administratively down. You will need to configure each interface with a “no shut” (short for no shutdown).

conf t
int serial0/0
no shut
int fasteth0/0
no shut
...

Doing this manually will give you the warm, fuzzy feeling of watching the interfaces come up. However, if there are more than a handful of interfaces, copying to the startup-config will save time.

 

About Quinn McHenry

Quinn was one of the original co-founders of Tech-Recipes. He is currently crafting iOS applications as a senior developer at Small Planet Digital in Brooklyn, New York.
View more articles by Quinn McHenry

The Conversation

Follow the reactions below and share your own thoughts.

  • Sheryar Saqib

    thanks

  • Joyjitonly

    I am unable to save the configuration on WS-C6509-E using command prompt. IOS is ‘cat6000-sup32pfc3cvk8.8-4-2a.bin’. Error message shows
    Cisco (enable) write memory
    This command is available only in text configuration mode.
    Cisco(enable)

  • Ian

    Thanks for this article.
    How are license keys and crypto handled with this method?
    If I copy the startup-config to another router I get a License error.
    Thanks

  • Jon

    Just stumbled across your article . . . “int f0/0 – 24″ for example will allow you to apply the “no shut” to all those interfaces at once, which is even quicker than copying to startup-config and reloading.