How Update Cisco Router using USB Drive

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:
  4. List out the disks attached to your computer using the following command:
    list disk
  5. Find the number in the first column for your usb drive and enter the following command:
    select disk disknumber
  6. Create a partition on that disk (your usb drive) by entering the following command:
    create part primary size=4000
  7. 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:


DISKPART> list disk

Disk ###  Status         Size     Free     Dyn  Gpt

--------  -------------  -------  -------  ---  ---

Disk 0    Online          238 GB      0 B        *

Disk 1    Online           14 GB      0 B

DISKPART> select disk 1

Disk 1 is now the selected disk.

DISKPART> create part primary size=4000

DiskPart succeeded in creating the specified partition.

DISKPART> active

DiskPart marked the current partition as active.


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

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:
    copy usbflash0:c2900-universalk9-mz.SPA.157-3.M3.bin flash0:
  4. Verify your file is in flash by running the command:
    dir flash0:
  5. Tell the router to boot to the new image by running the following commands:
    conf t
    boot system flash0 c2900-universalk9-mz.SPA.157-3.M3.bin
    copy run start

    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:

    show run | begin boot

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

    conf t
    no boot system flash0 oldconfigfilename.bin
    copy run start
  6. Reload your router to boot to the new image by running the following command:
  7. Once the router is booted back up, go ahead and delete the old firmware image from the flash by running:
    delete /recursive /force flash0:c2900-universalk9-mz.SPA.156-2.M2.bin

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:

show file systems

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 backed up all the things.

Chase Smith, CCNP

Chase Smith, CCNP is a Network Engineer III who has spent the last decade elbow deep in enterprise system administration and networking. He can usually be found trying to warm up behind the storage in the datacenter.

Leave a Reply

Your email address will not be published. Required fields are marked *