Factory resetting old network equipment before repurposing is a crucial step that should not be overlooked. By wiping out previous configurations and restoring the equipment to its default settings, organizations can ensure data security, minimize compatibility issues, simplify management, optimize performance, and enhance supportability. Performing a factory reset sets the stage for a successful integration into new network environments or redistribution within the network infrastructure. Remember, before conducting a factory reset, it’s important to back up any necessary data and configurations, as the process erases all existing information.

In case of a boot loop

If you are in a boot loop because the switch was a member of previously configured stack, then unset the stack mode with the following command.

switch: unset STACK_1_1
switch: unset SWITCH_PRIORITY
switch: set SWITCH_NUMBER=1
switch: set MANUAL_BOOT=no
switch: boot flash:packages.conf

After the next boot, you will able to factory reset the whole switch

factory-reset all

Typically, if the emergency firmware is newer than the previously installed one, the boot loader should automatically upgrading to. It’s the case on the current exemple. The switch was in IOSXE Bengaluru 17.06.03 and on Cupertino 17.09.03 on the emergency install process. The MCU and boot loader will be upgraded.

In case of emergency install only when the old configuration are present, use same firmware version that was on the switch. Then, upgrade after.

switch: emergency-install usbflash0:cat9k_iosxe.17.09.03.SPA.bin

The switch reformats the system partition, installs the new image, and then automatically reboots with it.