Cisco Copy From Usb To Flash

broken image


The content of new flash memory card is empty, therefore, the router will have to be first booted from an external USB flash memory. Step 8 Copy the desired Cisco image from an external USB flash memory card to the bootflash using the copy usb0:imagename bootflash command.

  • Assuming the usb port is not disabled, you would issue the command 'sh version' and allocate the usb flash, then you would use the command 'copy flashusb 0-9.' Instead if the usb port is disabled then you can enabled it by issuing the command 'no hw-module usb disable' and reload the router to take effect after saving the configs.
  • 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.

If you have a Cisco IOS Router that you need to update via USB, you're in the right place.

Copying your firmware image to your Cisco Router from a USB thumb drive is totally possible, provided you jump through a few hoops.

Namely, you need format your thumb drive using the FAT (FAT 16) file system which only supports partitions up to 4GB in size. This means we need to create a 4GB partition on your USB drive it's over 4GB in size (most are these days).

Let's review the steps, using a Windows 10 computer, and get you on your way to updating your router.

How to Format USB Drive for Use with Cisco IOS Router

The first step to updating your router is to set up a USB drive so that your router can read it. Make sure the thumb drive you use is free of any data you wish to keep because we are going to format (erase the content of) the drive.

For this example I'm going to use a 16GB Kingston DataTraveler USB2.0 drive.

  1. Plug your drive into your computer
  2. Open command prompt as an admin.
  3. Enter the following command to launch diskpart:
  1. List out the disks attached to your computer using the following command:
  1. Find the number in the first column for your usb drive and enter the following command:
  1. Create a partition on that disk (your usb drive) by entering the following command:
  1. Set the new 4GB partition as active by entering the command:
  1. Open file explorer and right click on your usb drive and click format. You should now see FAT as an option in the File system drop down.
  2. Select FAT in the file system dropdown, give your drive a volume label, and click Start to format the drive.
  3. Your drive is now ready to use so you can go ahead and copy over your firmware file.

If you want to see the above steps in action, here is my command prompt output:

And here is what my Format screen for the drive looked like after running the above commands:

Usb

How to Update a Cisco IOS Router using a USB Drive

Now that we have our properly formatted usb drive we can proceed with updating our router. In this example I'm going to update a Cisco 2921 router using the IOS image c2900-universalk9-mz.SPA.157-3.M3.bin. When following these instructions replace c2900-universalk9-mz.SPA.157-3.M3.bin with your own firmware file name.

  1. Copy your firmware image to your usb drive using your computer.
  2. Plug the usb drive into your router. You should see usbflash0: has been inserted in the terminal prompt.
  3. Run the following command to copy the IOS image into the router's flash:
Cisco Copy From Usb To Flash
  1. Verify your file is in flash by running the command:
  1. Tell the router to boot to the new image by running the following commands:

    Also, if you've previously configured your router to boot to a specific IOS file you'll need to remove that line from your config before reloading the device. To see what all is in your boot config run the following command:

    Find any erroneous boot system commands and remove them using the 'no' command followed by the erroneous config line like so:

  1. Reload your router to boot to the new image by running the following command:
  1. Once the router is booted back up, go ahead and delete the old firmware image from the flash by running:

And that's it. Very simple, yet tedious, process!

I should add, the name of your router or switches internal flash may differ from mine. Some devices uses flash:, flash0:, and even bootflash:. So be sure to check which syntax your device needs. You can find this out by running the following command and looking for the name under the Prefixes column:

Hopefully this tutorial was helpful and saved you some time and heartache!

Recommended for You: Solarwinds Network Configuration Manager (NCM)

What would you do if one of your pieces of networking equipment failed? Could you rebuild it quickly? Do you know exactly what configuration it had? What ports were on what vlan? What about port channels?
You get the point.
Copy usbflash0
Automate backing up configurations and updating of all your switching, routing, and firewall equipment without needing to know a single line of code with Solarwinds Network Configuration Manager.
Cisco

How to Update a Cisco IOS Router using a USB Drive

Now that we have our properly formatted usb drive we can proceed with updating our router. In this example I'm going to update a Cisco 2921 router using the IOS image c2900-universalk9-mz.SPA.157-3.M3.bin. When following these instructions replace c2900-universalk9-mz.SPA.157-3.M3.bin with your own firmware file name.

  1. Copy your firmware image to your usb drive using your computer.
  2. Plug the usb drive into your router. You should see usbflash0: has been inserted in the terminal prompt.
  3. Run the following command to copy the IOS image into the router's flash:
  1. Verify your file is in flash by running the command:
  1. Tell the router to boot to the new image by running the following commands:

    Also, if you've previously configured your router to boot to a specific IOS file you'll need to remove that line from your config before reloading the device. To see what all is in your boot config run the following command:

    Find any erroneous boot system commands and remove them using the 'no' command followed by the erroneous config line like so:

  1. Reload your router to boot to the new image by running the following command:
  1. Once the router is booted back up, go ahead and delete the old firmware image from the flash by running:

And that's it. Very simple, yet tedious, process!

I should add, the name of your router or switches internal flash may differ from mine. Some devices uses flash:, flash0:, and even bootflash:. So be sure to check which syntax your device needs. You can find this out by running the following command and looking for the name under the Prefixes column:

Hopefully this tutorial was helpful and saved you some time and heartache!

Recommended for You: Solarwinds Network Configuration Manager (NCM)

What would you do if one of your pieces of networking equipment failed? Could you rebuild it quickly? Do you know exactly what configuration it had? What ports were on what vlan? What about port channels?
You get the point.
Automate backing up configurations and updating of all your switching, routing, and firewall equipment without needing to know a single line of code with Solarwinds Network Configuration Manager.
This is one of those tools that pays for itself in man hours the first time you need to rely on it. Plus, you'll sleep easier knowing you really have

Copy From Usb To Flash Cisco 2960

backed up all the things.

Copy Usbflash0






broken image