Tuesday, April 2, 2013

Update Cisco Catalyst Switch Firmware

The easy way to upgrade the firmware on a Cisco switch is to use Cisco Network Assistant or the web GUI.  Unfortunately many(most) times that will not work and you will receive the following message(s):
Cisco switch firmware upgrade error - Failed to execute the command archive download-sw /overwrite /http iosFile
Error: Failed to execute the command archive download-sw /overwrite /http iosFile

The failed firmware upload/upgrade is a result of a lack of flash space.

The below process should always work, but require a few more steps.
Note that in the example below my switch hostname is 'Switch01', you will see a different name in this place.

  1. Connect Cisco Catalyst to PC serial port via blue Cisco cable.  A standard serial cable will not work.  See step four.  You may not need Cisco cable.
  2. Download the application Putty on your PC.  The file can be found here: http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html
  3. Launch the application Putty on your PC. 
  4.  If your switch is functioning, you should be able create a Telnet connection to the switch from Putty.  Enter the switch's IP and the port number should be 23.  This saves you the trouble of connecting via the serial port with the blue Cisco cable.
  5. The default serial settings are: Bits per sec : 9600, Data bits : 8, Parity : none, Stop bits : 1, Flow control : none
  6. You can increase the baud rate with the following: enter 'configure terminal', enter 'line con 0', enter 'speed 115200', enter CTRL/Z to end
  7. Switch01> will be displayed
  8. Enter 'ena'
  9. Enter 'PASSWORD'.  This is your own password.
  10. Prompt will change to Switch01#
  11. Enter 'dir' to view flash directory.  Most likely you will see several files in this directory that need to be deleted.  These files are taking up space and preventing you from upgrading via the Cisco Network Assistant application.
  12. Delete all files except: config.text, startup-config.bak, vlan.dat, multiple-fs, private-config.text
  13. Delete all folders except: dc_profile_dir
  14. Enter 'delete /force /recursive flash:NAME OF FILE OR FOLDER HERE'  Check capitalization if you are having issues deleting files/folders.
  15. Download the application Tftpd32 on your PC.  The file can be found here :
    http://tftpd32.jounin.net/
  16. Start TFTP server application with IOS/firmware file ready to be served (see below).
  17. Ping TFTP server to make sure it is working.  Enter 'ping IPADDRESS'
  18. Enter 'archive download-sw /overwrite /allow-feature-upgrade tftp://IPADDRESS/c3560-ipservicesk9-tar.150-2.SE2.tar' Check capitalization!!!  This step will take some time as it extracts all the files.  Note that file ends in 'tar'.  If this fails, drop the '/allow-feature-upgrade' from the command.  The /allow-feature-upgrade option allows installation of an image with a different feature set (for example, upgrade from the IP base image to the IP services image).  'c3560-ipservicesk9-tar.150-2.SE2.tar' is the firmware file name for my model.  You will need to download the correct TAR file for you model from the Cisco web site.
  19. You should get the message 'All software images installed.' if everything went ok.  do not interrupt the process, wait for the 'All software images installed.' message.
  20. Enter 'sh flash' and you will see the new contents of the flash directory.  Hopefully with your new IOS listed.
  21. Enter 'sh boot' and you will see the new ISO listed in the BOOT path-list field.
  22. Enter 'wr' to save changes and reload the switch.  It will say 'Building configuration...' and then say '[OK]'
  23. Enter 'reload' and confirm to reboot the switch.
  24. After switch finished rebooting, enter 'sh ver' to display version and confirm switch is running with correct/new firmware. 
  25. Congratulations!  You are finished.