O processo de atualização do Catalyst 9300 (IOS-XE) pode ser tão simples quanto o upgrade de um 2960 (IOS), mas os comandos são diferentes.
Assim como nos swiches mais antigos o software do 9300 fica armazenado na flash, e usamos o comando show version para verificar a versão em uso.
Caso seja feita mudança de licenciamento, no show version continuaremos vendo o modelo original, como saiu de fábrica.
Quando é feito o upgrade do IOS-XE, o boot loader pode ser atualizado automaticamente. Em caso de downgrade do IOS-XE o boot loader não volta para a versão anterior, e não tem problema já que as versões mais novas suportam todos os IOSs anteriores.
Em modelos com suporte a PoE/UPoE também pode ocorrer o upgrade do Microcode.
Tanto boot loader quanto Microcode são atualizados se necessário, de acordo com a versão em uso e versão que vai ser instalada. Não é necessária nenhuma configuração específica para isso.
Fazendo o Upgrade (Install Mode)
Este passo-a-passo pode ser utilizado quando o switch está no modo “Install”, e usando a versão 16.6.2 ou mais recente.
Além do modo Install o switch pode trabalhar no modo Bundle. No modo Install (nosso exemplo) o boot é feito de acordo com instruções que estão no arquivo packages.conf. No modo Bundle devemos apontar o boot para o arquivo .bin.
1) Confirmar o modo e a versão em uso.
Switch#show version <outpu omitido> Switch Ports Model SW Version SW Image Mode ------ ----- ----- ---------- ---------- ---- 1 64 C9300-48T 16.9.1 CAT9K_IOSXE INSTALL * 2 64 C9300-48T 16.9.1 CAT9K_IOSXE INSTALL
2) É necessário pelo menos 1 GB livre para descompactar o novo software, então começamos removendo arquivos de instalações anteriores.
Switch#install remove inactive install_remove: START Thu Feb 28 03:23:33 UTC 2019 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-cc_srdriver.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-espbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-guestshell.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-rpbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-rpboot.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-sipbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-sipspa.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-srdriver.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-webui.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-wlc.16.08.01a.SPA.pkg File is in use, will not delete. packages.conf File is in use, will not delete. done. 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-cc_srdriver.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-espbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-guestshell.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-rpbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-rpboot.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-sipbase.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-sipspa.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-srdriver.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-webui.16.08.01a.SPA.pkg File is in use, will not delete. cat9k-wlc.16.08.01a.SPA.pkg File is in use, will not delete. packages.conf File is in use, will not delete. done. SUCCESS: No extra package or provisioning files found on media. Nothing to clean. The following files will be deleted: [switch 1]: /flash/cat9k_iosxe.16.09.02.SPA.bin Do you want to remove the above files? [y/n]y [switch 1]: Deleting file flash:cat9k_iosxe.16.09.02.SPA.bin ... 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 [2] Post_Remove_Cleanup package(s) on switch 2 [2] Finished Post_Remove_Cleanup on switch 2 Checking status of Post_Remove_Cleanup on [1 2] Post_Remove_Cleanup: Passed on [1 2] Finished Post_Remove_Cleanup SUCCESS: install_remove Thu Feb 28 03:24:05 UTC 2019 Switch#
3) Copie a nova imagem para a flash do switch. Se for uma pilha copie para o switch ativo.
Switch#copy tftp: flash: Address or name of remote host [1.1.1.2]? Source filename [cat9k_iosxe.16.09.02.SPA.bin]? Destination filename [cat9k_iosxe.16.09.02.SPA.bin]? Accessing tftp://1.1.1.2/cat9k_iosxe.16.09.02.SPA.bin... Loading cat9k_iosxe.16.09.02.SPA.bin from 1.1.1.2 (via Vlan1): !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! [OK - 700524979 bytes] 700524979 bytes copied in 128.086 secs (5469177 bytes/sec) Switch#
4) Confira se o boot está apontado para “packages.conf”. Se não estiver, no modo de configuração global (config) adicione boot system switch all flash:packages.conf e salve a configuração (wr mem).
Switch#sh run | in boot boot system switch all flash:packages.conf diagnostic bootup level minimal Switch#show boot system --------------------------- Switch 1 --------------------------- Current Boot Variables: BOOT variable = flash:packages.conf; Boot Variables on next reload: BOOT variable = flash:packages.conf; Manual Boot = no Enable Break = no Boot Mode = DEVICE iPXE Timeout = 0 --------------------------- Switch 2 --------------------------- Current Boot Variables: BOOT variable = flash:packages.conf; Boot Variables on next reload: BOOT variable = flash:packages.conf; Manual Boot = no Enable Break = no Boot Mode = DEVICE iPXE Timeout = 0 Switch#
5) Instale o software novo. No caso de empilhamento, se a imagem tiver sido copiada para um switch membro, temos que apontar a flash específica.
Switch#install add file flash:cat9k_iosxe.16.09.02.SPA.bin activate commit install_add_activate_commit: START Thu Feb 28 03:37:10 UTC 2019 --- Starting initial file syncing --- [1]: Copying flash:cat9k_iosxe.16.09.02.SPA.bin from switch 1 to switch 2 [2]: Finished copying to switch 2 Info: Finished copying flash:cat9k_iosxe.16.09.02.SPA.bin to the selected switch(es) Finished initial file syncing --- Starting Add --- Performing Add on all members [1] Add package(s) on switch 1 [1] Finished Add on switch 1 [2] Add package(s) on switch 2 [2] Finished Add on switch 2 Checking status of Add on [1 2] Add: Passed on [1 2] Finished Add install_add_activate_commit: Activating PACKAGE Following packages shall be activated: /flash/cat9k-wlc.16.09.02.SPA.pkg /flash/cat9k-webui.16.09.02.SPA.pkg /flash/cat9k-srdriver.16.09.02.SPA.pkg /flash/cat9k-sipspa.16.09.02.SPA.pkg /flash/cat9k-sipbase.16.09.02.SPA.pkg /flash/cat9k-rpboot.16.09.02.SPA.pkg /flash/cat9k-rpbase.16.09.02.SPA.pkg /flash/cat9k-guestshell.16.09.02.SPA.pkg /flash/cat9k-espbase.16.09.02.SPA.pkg /flash/cat9k-cc_srdriver.16.09.02.SPA.pkg This operation requires a reload of the system. Do you want to proceed? [y/n]y --- Starting Activate --- Performing Activate on all members [1] Activate package(s) on switch 1 --- Starting list of software package changes --- Old files list: Removed cat9k-cc_srdriver.16.08.01a.SPA.pkg Removed cat9k-espbase.16.08.01a.SPA.pkg Removed cat9k-guestshell.16.08.01a.SPA.pkg Removed cat9k-rpbase.16.08.01a.SPA.pkg Removed cat9k-rpboot.16.08.01a.SPA.pkg Removed cat9k-sipbase.16.08.01a.SPA.pkg Removed cat9k-sipspa.16.08.01a.SPA.pkg Removed cat9k-srdriver.16.08.01a.SPA.pkg Removed cat9k-webui.16.08.01a.SPA.pkg Removed cat9k-wlc.16.08.01a.SPA.pkg New files list: Added cat9k-cc_srdriver.16.09.02.SPA.pkg Added cat9k-espbase.16.09.02.SPA.pkg Added cat9k-guestshell.16.09.02.SPA.pkg Added cat9k-rpbase.16.09.02.SPA.pkg Added cat9k-rpboot.16.09.02.SPA.pkg Added cat9k-sipbase.16.09.02.SPA.pkg Added cat9k-sipspa.16.09.02.SPA.pkg Added cat9k-srdriver.16.09.02.SPA.pkg Added cat9k-webui.16.09.02.SPA.pkg Added cat9k-wlc.16.09.02.SPA.pkg Finished list of software package changes [1] Finished Activate on switch 1 [2] Activate package(s) on switch 2 --- Starting list of software package changes --- Old files list: Removed cat9k-cc_srdriver.16.08.01a.SPA.pkg Removed cat9k-espbase.16.08.01a.SPA.pkg Removed cat9k-guestshell.16.08.01a.SPA.pkg Removed cat9k-rpbase.16.08.01a.SPA.pkg Removed cat9k-rpboot.16.08.01a.SPA.pkg Removed cat9k-sipbase.16.08.01a.SPA.pkg Removed cat9k-sipspa.16.08.01a.SPA.pkg Removed cat9k-srdriver.16.08.01a.SPA.pkg Removed cat9k-webui.16.08.01a.SPA.pkg Removed cat9k-wlc.16.08.01a.SPA.pkg New files list: Added cat9k-cc_srdriver.16.09.02.SPA.pkg Added cat9k-espbase.16.09.02.SPA.pkg Added cat9k-guestshell.16.09.02.SPA.pkg Added cat9k-rpbase.16.09.02.SPA.pkg Added cat9k-rpboot.16.09.02.SPA.pkg Added cat9k-sipbase.16.09.02.SPA.pkg Added cat9k-sipspa.16.09.02.SPA.pkg Added cat9k-srdriver.16.09.02.SPA.pkg Added cat9k-webui.16.09.02.SPA.pkg Added cat9k-wlc.16.09.02.SPA.pkg Finished list of software package changes [2] Finished Activate on switch 2 Checking status of Activate on [1 2] Activate: Passed on [1 2] Finished Activate --- Starting Commit --- Performing Commit on all members [1] Finished Commit on switch 1 [2] Commit package(s) on switch 2 [2] Finished Commit on switch 2 Checking status of Commit on [1 2] Commit: Passed on [1 2] Finished Commit [1 2]: Performing MCU_Upgrade_Service SUCCESS: MCU_Upgrade_Service finished Install will reload the system now! SUCCESS: install_add_activate_commit Thu Feb 28 03:41:46 UTC 2019 Switch# *Feb 28 03:41:46.691: %INSTALL-5-INSTALL_COMPLETED_INFO: Switch 1 R0/0: install_engine: Completed install one-shot PACKAGE flash:cat9k_iosxe.16.09.02.SPA.bin Chassis 1 reloading, reason - Reload command Feb 28 03:41:51.033: %PMAN-5-EXITACTION: F0/0: pvp: Process manager is exiting: reload fp action requested
O switch vai reiniciar automaticamente, apenas espere.
6) Quando o switch terminar de reiniciar, confira que está usando o novo software.
Switch#show version <output omitido> Switch Ports Model SW Version SW Image Mode ------ ----- ----- ---------- ---------- ---- 1 64 C9300-48T 16.9.2 CAT9K_IOSXE INSTALL * 2 64 C9300-48T 16.9.2 CAT9K_IOSXE INSTALL <output omitido> Switch#
Versões anteriores (Install Mode)
Em switches com versões anteriores a 16.6.2, ao invés dos comandos install usamos os comandos request platform.
1) Confirmar o modo e a versão em uso.
Switch#show version
2) Liberar espaço.
Switch# request platform software package clean switch all
3) Copiar a imagem
Switch#copy tftp: flash:
4) Configurar o boot e conferir.
Switch(config)#boot system switch all flash:packages.conf Switch#sh run | in boot Switch#show boot system
5) Instalar o software novo.
Switch#request platform software package install switch all file flash:cat9k_iosxe.16.09.02.SPA.bin auto-copy
6) Depois que o switch reiniciar, confirme que está usando o novo software.
Switch#show version
Outra informações sobre upgrade no 9300, neste link.
Até a próxima.
11 Comments
Olá Andre, Qual a diferença de colocar o packages.conf ou o SPA.bin para bootar?
Olá Dominique.
Essas são os arquivos usados para cada modo (install ou bundle).
O modo install (que “quebra o arquivo .bin” em arquivos .pkg menores), é o modo mais novo e recomendado. Ele usa melhor a memória.
O modo bundle usa imagens monolíticas do IOS para inicializar o switch e usa mais memória porque os pacotes são extraídos do bundle e copiados para a RAM durante a inicialização.
olá bom dia! Normalmente quanto tempo demora a atualização?
Olá Paulo, em torno de 30 minutos.
Grande Ortega,
Parabéns pela postagem, realmente foi bem útil.
Só para validar, eu testei nos Switches da família C9300 e C9400 e foi sucesso!
Josinfo
Legal, obrigado pela informação.
Olá, boa tarde.
Muito bom o procedimento.
Estou com um C9300-24T em stack com mode Bundle. Posso realizar a instalação em stack mesmo ou preciso fazer um por vez?
Caso faça em stack mesmo, preciso copiar o IOS para flash de ambos switches?
Obrigado.
Olá Elvis,
Pode fazer estando em stack. Deixa a imagem apenas no switch active. Durante o processo a imagem é copiada para os demais membros da pilha.
Olá André.
#dir flash?
flash-1: flash-2: flash:
flash-1 e flash-2 seria referente ao switch 1 e 2, já que a pilha contém 2 switches?
E para qual flash é o correto realizar a copia?
Muito obrigado pelo apoio desde então!
Você precisa ver qual é o switch master da sua pilha. Flash1 e 2 são dos switches 1 e 2 respectivamente.
Olá André, consegui fazer na sexta feira, segui seu passo a passo, copiei para a flash: que acaba sendo para flash do Switch ativo, no meu caso que estava em bundle.
Show de bola esse procedimento, tudo certinho.
Muito obrigado pelo apoio.