Let’s investigate how to upgrade the Cisco IOS-XE image in Cisco 9000 (9200L/9200/9300) series switches.

Check the current IOS version and boot mode

To verify the mode of operation and IOS version, use the show version command in enabled mode.

image 2 - Cyberhaiku

Change Boot Mode

Change the boot mode of the switches from Bundle Mode to Install Mode before installing IOS-XE. Here is a guide you can refer how to convert the bundle to install mode.

How to Identify the Mode of Operation?

show version command output will show the boot mode.

IOS UPGRADE
image - Cyberhaiku

Bundle mode

Bundle mode boots a switch with monolithic Cisco IOS images. Since the packages are extracted from the bundle and copied to RAM during booting, this mode will consume more RAM than the Install mode. The bundle imposes the following limitation:

  • Auto-upgrade is disabled by default and unavailable in Bundle mode.

Install Mode

The default mode for most modern switches is the install mode. This mode boots the switch using the packages.conf file to provision packages. Since Install Mode is the mode, Cisco recommends, doing so likely has additional advantages. Install mode eliminates the need to manually copy IOS XE to each stack member. This can be accomplished using an upgrade-specific option. This is particularly useful when managing a large number of switches.

  • In Install mode, booting from a USB driver or TFTP is not supported.

Remove the unused software packages from flash

switch#install remove inactive
install_remove: START Sun xxxx  xx:xx:33 UTC xxxx
<5>%INSTALL-5-INSTALL_START_INFO: R0/0: install_engine: Started install remove

Cleaning up unnecessary package files
No path specified, will use booted path flash:packages.conf
Cleaning flash:
  Scanning boot directory for packages ... done.
  Preparing packages list to delete ...
    cat9k_lite-rpbase.17.06.04.SPA.pkg
      File is in use, will not delete.
    cat9k_lite-rpboot.17.06.04.SPA.pkg
      File is in use, will not delete.
    cat9k_lite-srdriver.17.06.04.SPA.pkg
      File is in use, will not delete.
    cat9k_lite-webui.17.06.04.SPA.pkg
      File is in use, will not delete.
    packages.conf
      File is in use, will not delete.
  done.

The following files will be deleted:
[switch 1]:
/flash/cat9k_lite-rpbase.16.09.04.SPA.pkg
/flash/cat9k_lite-rpboot.16.09.04.SPA.pkg
/flash/cat9k_lite-srdriver.16.09.04.SPA.pkg
/flash/cat9k_lite-webui.16.09.04.SPA.pkg
/flash/cat9k_lite_iosxe.16.09.04.SPA.bin
/flash/cat9k_lite_iosxe.17.06.04.SPA.bin
/flash/cat9k_lite_iosxe.17.06.04.SPA.conf

Do you want to remove the above files? [y/n]y
[switch 1]:
Deleting file flash:cat9k_lite-rpbase.16.09.04.SPA.pkg ... done.
Deleting file flash:cat9k_lite-rpboot.16.09.04.SPA.pkg ... done.
Deleting file flash:cat9k_lite-srdriver.16.09.04.SPA.pkg ... done.
Deleting file flash:cat9k_lite-webui.16.09.04.SPA.pkg ... done.
Deleting file flash:cat9k_lite_iosxe.16.09.04.SPA.bin ... done.
Deleting file flash:cat9k_lite_iosxe.17.06.04.SPA.bin ... done.
Deleting file flash:cat9k_lite_iosxe.17.06.04.SPA.conf ... done.
SUCCESS: Files deleted.
--- Starting Post_Remove_Cleanup ---
Performing Post_Remove_Cleanup on all members
  [1] Post_Remove_Cleanup package(s) on switch 1
  [1] Finished Post_Remove_Cleanup on switch 1
Checking status of Post_Remove_Cleanup on [1]
Post_Remove_Cleanup: Passed on [1]
Finished Post_Remove_Cleanup

SUCCESS: install_remove  Sun Dec 11 08:32:39 UTC 2022
<5>%INSTALL-5-INSTALL_COMPLETED_INFO: R0/0: install_engine: Completed install remove

Setting the install mode

Switch# config terminal
Switch(config)# no boot system
Switch(config)# boot system flash:packages.conf
Switch(config)# do write mem

The first thing we got to do is upload the IOS-XE image to the flash memory of the switch (the master switch in case of the stack, you do not need to manually upload the IOS-XE image to every switch in the stack. Copy the recommended IOS-XE image to the flash directory. This refers to the flash memory of the active switch.

Switch# copy tftp://10.x.x.x/cat9k_lite_iosxe.17.06.04.SPA.bin flash:

Now the IOS image is on the active switch in a stack or a stand-alone switch. Occasionally, when transferring a file using TFTP, it can behave erratically; therefore, we will use MD5 hash checking to ensure a successful transfer. Compare the MD5 value you calculated to the one displayed on Cisco’s website, from which you downloaded the image in the first place.

verify /md5 <flash:file name> <Expected md5 signature>

Switch#verify /md5 flash:cat9k_lite_iosxe.17.06.04.SPA.bin 656f3b02325435c69cb6dd33ee9ef684

Run the below command to get started on the actual IOS upgrade

install add file flash:<imagefilename> activate commit

install add file flash:cat9k_lite_iosxe.17.06.04.SPA.bin activate commit

After the upgrade has been completed, all switches will reboot and become operational. Then verify the IOS version

IOS-XE

Tagged in:

, ,