cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3494
Views
5
Helpful
28
Replies

Updating IOS on Catalyst 9200L

chiseledst
Level 1
Level 1

Can someone tell me the commands to use to update the firmware on my 9200L? I am copying from a USB but I think I used the wrong commands.

It was stuck on a boot loop, I've taken the switch out of boot loop with:

SWITCH_IGNORE_STARTUP_CFG=1

boot flash:packages.conf

Then,

SWITCH_IGNORE_STARTUP_CFG=0

boot flash:packages.conf

 

But now when I am using

copy usbflash0-1: bootflash: cat9k_lite_iosxe.17.09.04.SPA.bin

The new .bin file does not show in dir. When I use dir flash:*.bin, it says no file type found. I think I am copying it wrong or something was done incorrectly before.


When I am copying, this is what I'm doing
Switch#copy usbflash0-2:/cat9k_lite_iosxe.17.09.04.SPA.bin flash:
Destination filename [cat9k_lite_iosxe.17.09.04.SPA.bin]? y
%Warning:There is a file already existing with this name
Do you want to over write? [confirm]y

But it does not work. I can't install it afterwards, and it says .bin files do not exist.

 


Switch#dir flash.*.bin
Directory of flash:/flash.*.bin

No such file

1956839424 bytes total (786567168 bytes free)
Switch#

1 Accepted Solution

Accepted Solutions

I fixed it. Thanks for your help. The emergency install command and auto-upgrade did not work. However, I was able to boot the flash from ROMMON. The first try it did not work so I removed the stacking module, and unprovisioned the other switch in the CLI. Then I went back into ROMMON and did "boot usbflash0:cat9k_lite_iosxe.17.09.04.SPA.bin". After this, when the switch boots back up, I used "install remove inactive" to remove the old IOS. Then I used "install add file usbflash0:cat9k_lite_iosxe.17.09.04.SPA.bin activate commit" which installs the new firmware successfully. When I connected the stack afterwards, there was a firmware mismatch and "show switch" showed V-mismatch so I basically had to re-do the same process on the other switch. Once both switches were on the firmware from USB, I connected the stacking module and renumbered and changed priority of the switches so everything was back to what I needed it to be.

I definitely did something to get it stuck on the boot from flash loop. So if anyone reading this and is having the same problem, try what I did.

View solution in original post

28 Replies 28

what install command do you use? Also on your dir, use a : after flash, your example is a . and would not work.

dir flash:*.bin

I show the 9200 is the same as a 9300, so install command is this:

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

I am using "install add" but it fails

 

Switch#$ file flash:cat9k_lite_iosxe.17.09.04.SPA.bin activate commit
install_add_activate_commit: START Thu Oct 19 20:18:38 UTC 2023
<5>%INSTALL-5-INSTALL_START_INFO: R0/0: install_engine: Started install one-shot flash:cat9k_lite_iosxe.17.09.04.SPA.bin
FAILED: install_add_activate_commit : flash:cat9k_lite_iosxe.17.09.04.SPA.bin is not valid file or cannot be handled by install CLI.
<3>%INSTALL-3-OPERATION_ERROR_MESSAGE: R0/0: install_engine: Failed to install_add_activate_commit package flash:cat9k_lite_iosxe.17.09.04.SPA.bin, Error: install_add_activate_commit : flash:cat9k_lite_iosxe.17.09.04.SPA.bin is not valid file or cannot be handled by install CLI.
Switch#

 

I think im not copying it over correctly.

I know on a 9300 the USB is usbflash0, this is the command I use, you can do a dir ? to see what the USB is named.

 

copy usbflash0:cat9k_iosxe.17.09.03.SPA.bin flash:

 

 


Another is if the flash is full and can't take the new file, can try the cleanup command:

install remove inactive

USB is this
Switch#show usb?
usb-devices usbflash0-2:

I am trying install remove inactive but after copying, when i do dir, i don't see the new package, it is still the old package and this is after I install remove inactive...going to try again.

CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
470661439 bytes copied in 32.296 secs (14573366 bytes/sec)

Switch#dir flash:cat9k_lite_iosxe.17.09.04.SPA.bin
%Error opening flash:/cat9k_lite_iosxe.17.09.04.SPA.bin (No such file or directory)
Switch#

 

 

This is what I get after copying

I think that may be showing the USB can take 0-2, or up to 3 devices? do dir ? with the USB in and see what it shows in the list.

 

I don't show a drive as there isn't one installed, but this is what I'm talking about.

Test#show usb?
usb-devices

Test#dir ?
/all List all files
/recursive List files recursively
all-filesystems List files on all filesystems
bootflash: Directory or file name
cns: Directory or file name
crashinfo: Directory or file name
flash: Directory or file name
null: Directory or file name
nvram: Directory or file name
system: Directory or file name
tar: Directory or file name
tmpsys: Directory or file name
webui: Directory or file name
| Output modifiers
<cr> <cr>

This is what i get


Switch#show usb?
usb-devices usbflash0-2:

Switch#dir ?
/all List all files
/recursive List files recursively
all-filesystems List files on all filesystems
bootflash: Directory or file name
cns: Directory or file name
crashinfo-1: Directory or file name
crashinfo-2: Directory or file name
crashinfo: Directory or file name
flash-1: Directory or file name
flash-2: Directory or file name
flash: Directory or file name
null: Directory or file name
nvram: Directory or file name
revrcsf: Directory or file name
stby-crashinfo: Directory or file name
stby-flash: Directory or file name
stby-nvram: Directory or file name
stby-rcsf: Directory or file name
stby-usbflash0: Directory or file name
system: Directory or file name
tar: Directory or file name
tmpsys: Directory or file name
usbflash0-2: Directory or file name
webui: Directory or file name
| Output modifiers
<cr> <cr>

Switch#dir

if you can show dir flash: and dir usbflash0-2: just to verify the filename still exists.

 

Only other thing I can think of is can you reboot the switch? It's seeming like the flash is locked or something where the copy is failing for some reason.

it exists, im trying on the other switch (it's a stack)

Switch#dir usbflash0:
Directory of usbflash0:/

288 drwx 8192 Oct 18 2023 14:09:00 +00:00 System Volume Information
289 -rwx 470661439 Oct 18 2023 13:59:32 +00:00 cat9k_lite_iosxe.17.09.04.SPA.bin

15507390464 bytes total (15036694528 bytes free)
Switch#


I also copied and did dir flash:*.bin but it says No such file exists......

why is this so difficult to update the ios

try the copy to flash-1: or flash-2:

This calls out switch 1/2 and Flash: is just the active managing switch.

 

And no, it's not normally this complicated, we just did 122 stacks on Saturday with just the 2 commands. Other than transfering from FTP vs USB.

 

This is what we did on all 9300 stacks.

copy usbflash0:cat9k_iosxe.17.09.03.SPA.bin flash:
install add file flash:cat9k_iosxe.17.09.03.SPA.bin activate commit
install remove inactive

doesn't work, it has to be usbflash0-1:

 

like it copies....but that's it.

well, says it copies, but you don't see on the flash. Seems odd definately.

Do you know how I can i reset to factory default? When i reboot the switch, it gets stuck in boot loop trying to boot the flash and I need to take it into ROMMON mode.

Is the switch in a stack?
If it is in a stack, what is the firmware of the switch stack master?

Review Cisco Networking for a $25 gift card