Cisco brings out new versions of the operating system quite frequently, and of course there are different versions of the operating system for each of the appliances. Different IOS’s will support different commands and different features and it’s not uncommon to have to change the IOS that your device is running to support commands you wish to use.
The other major reason for IOS upgrades is to fix bugs that Cisco may have found in the software.
The 2 most common ways to do an upgrade are:
- Take the Flash card out the router, plug it into a card reader and paste the new file on the card. Replace the card in the router and reboot.
- Copy the file over the network using a protocol like TFTP.
When copying the IOS over the network, the router will check to confirm it has enough storage space to accommodate the file. It will often ask to erase the flash before copying the new image. Before erasing the flash on the router, make sure there are no other files on the flash that you might need. If there are files that you will require, make sure you have made a backup of them before erasing!
Here are the steps for upgrading via the network.
- Run your TFTP server and confirm it’s hosting the IOS that you wish to upgrade to
- Configure the following on the router
AOIP.ORG# copy tftp: flash:
Address or name of remote host ? 192.168.1.1
Source filename ? c1841-ipbase-mz.124-5b.bin
Destination filename [c1841-ipbase-mz.124-5b.bin]?
%Warning: There is a file already existing with this name
Do you want to over write? [confirm]
In the example above, I had chosen to upgrade to the same image that was already loaded on the router. Although not a practical solution, it does show the commands to upgrade.
Below you will see the different output when I chose a different file.
AOIP.ORG# copy tftp: flash:
Address or name of remote host [192.168.1.1]?
Source filename [c1841-ipbase-mz.124-5b.bin]? c1841.bin
Destination filename [c1841.bin]?
Loading c1841.bin from 192.168.1.1 (via FastEthernet0/0): !
%Error copying tftp://192.168.1.1/c1841.bin (Not enough space on device)
Again, I have received an error message, this time due to lack of free space on my flash card on the router. I would then have a chance to confirm there are no files on the flash that I need to keep before erasing the flash. If there are files I need to retain, make sure you back them up before erasing!
Make sure that you have already confirmed that the router physically has enough flash to be able to support the image you wish to install. You can see how much Flash is available and installed by using the ‘show flash:’ and ‘show version’ commands
Depending on the router model, you can erase the contents of the flash by typing
AOIP.ORG# erase flash:
AOIP.ORG# erase nvram:
After the flash has been erased, you would then be able to copy the file from the tftp server.
Below is a live demo of an upgrade.