Cisco Catalyst 3650系列交换机有两种操作模式:安装模式和捆绑包模式。
这两种模式之间有一些细微的差别。有关详情,请参阅配置指南。
思科建议在操作时使用安装模式,因为此模式可以提供更完善的功能,引导时所需的资源也更少。
这是交换机的默认模式。安装模式使用名为 packages.conf 的软件包调配文件来引导交换机。此外,闪存中还有.pkg文件。
如果您对使用传统的单片IOS®映像来启动交换机感到满意,那么BUNDLE模式可能比较熟悉。
捆绑包模式消耗的内存比安装模式要多,因为升级时会从捆绑包中解压软件包,并复制到 RAM 中。
要执行模式验证,请输入 show version 命令:
3650-stack#show version Switch Ports Model SW Version SW Image Mode ------ ----- ----- ---------- ---------- ---- * 1 52 WS-C3650-48TD 03.06.04.E cat3k_caa-universalk9 INSTALL 2 52 WS-C3650-48TD 03.06.04.E cat3k_caa-universalk9 INSTALL
要开始升级过程,请从Cisco网站下载IOS® XE .bin文件,并将其通过TFTP上传至交换机中。
在将 .bin 文件复制到单个交换机时,安装进程会自动将该文件复制到同一堆叠中的其他交换机。复制好文件后,输入如下命令:
3650-stack# software install file flash:cat3k_caa-universalk9.SPA.03.07.04.SE.152-3.E4.bin switch 1-2
当升级过程开始时,交换机将.bin文件推送到堆叠成员对等体。
zb-3650-stack#software install file flash:cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin switch 1-2
Preparing install operation ...
[2]: Copying software from active switch 2 to switch 1
[2]: Finished copying software to switch 1
[1 2]: Starting install operation
[1 2]: Expanding bundle flash:cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin
[2]: Finished copying software to switch 1
[1 2]: Starting install operation
[1 2]: Expanding bundle flash:cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin
[1 2]: Copying package files
[1 2]: Package files copied
[1 2]: Finished expanding bundle flash:cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin
[1 2]: Verifying and copying expanded package files to flash:
[1 2]: Verified and copied expanded package files to flash:
[1 2]: Starting compatibility checks
[1 2]: Finished compatibility checks
[1 2]: Starting application pre-installation processing
[1 2]: Finished application pre-installation processing
[1]: Old files list:
Removed cat3k_caa-base.SPA.03.06.04.E.pkg
Removed cat3k_caa-drivers.SPA.03.06.04.E.pkg
Removed cat3k_caa-infra.SPA.03.06.04.E.pkg
Removed cat3k_caa-iosd-universalk9.SPA.152-2.E4.pkg
Removed cat3k_caa-platform.SPA.03.06.04.E.pkg
Removed cat3k_caa-wcm.SPA.10.2.140.0.pkg
[2]: Old files list:
Removed cat3k_caa-base.SPA.03.06.04.E.pkg
Removed cat3k_caa-drivers.SPA.03.06.04.E.pkg
Removed cat3k_caa-infra.SPA.03.06.04.E.pkg
Removed cat3k_caa-iosd-universalk9.SPA.152-2.E4.pkg
Removed cat3k_caa-platform.SPA.03.06.04.E.pkg
Removed cat3k_caa-wcm.SPA.10.2.140.0.pkg
[1]: New files list:
Added cat3k_caa-base.SPA.03.07.04E.pkg
Added cat3k_caa-drivers.SPA.03.07.04E.pkg
Added cat3k_caa-infra.SPA.03.07.04E.pkg
Added cat3k_caa-iosd-universalk9.SPA.152-3.E4.pkg
Added cat3k_caa-platform.SPA.03.07.04E.pkg
Added cat3k_caa-wcm.SPA.10.3.141.0.pkg
[2]: New files list:
Added cat3k_caa-base.SPA.03.07.04E.pkg
Added cat3k_caa-drivers.SPA.03.07.04E.pkg
Added cat3k_caa-infra.SPA.03.07.04E.pkg
Added cat3k_caa-iosd-universalk9.SPA.152-3.E4.pkg
Added cat3k_caa-platform.SPA.03.07.04E.pkg
Added cat3k_caa-wcm.SPA.10.3.141.0.pkg
最后,交换机将更新并提交 packges.conf 文件。
[1 2]: Creating pending provisioning file
[1 2]: Finished installing software. New software will load on reboot.
[1 2]: Committing provisioning file
[1 2]: Do you want to proceed with reload? [yes/no]: yes
重新加载交换机,确认升级流程是否正确完成。
Switch Ports Model SW Version SW Image Mode
------ ----- ----- ---------- ---------- ----
1 52 WS-C3650-48TD 03.07.04E cat3k_caa-universalk9 INSTALL
* 2 52 WS-C3650-48TD 03.07.04E cat3k_caa-universalk9 INSTALL
升级完成后,旧版本的残留文件会保留在闪存中。要清除剩余文件,请输入software clean命令,而不是手动删除文件。此操作会清除交换机不再需要的文件。
zb-3650-stack#software clean
Preparing clean operation ...
[1 2]: Cleaning up unnecessary package files
[1 2]: No path specified, will use booted path flash:packages.conf
[1 2]: Cleaning flash:
[1]: Preparing packages list to delete ...
In use files, will not delete:
cat3k_caa-base.SPA.03.07.04E.pkg
cat3k_caa-drivers.SPA.03.07.04E.pkg
cat3k_caa-infra.SPA.03.07.04E.pkg
cat3k_caa-iosd-universalk9.SPA.152-3.E4.pkg
cat3k_caa-platform.SPA.03.07.04E.pkg
cat3k_caa-wcm.SPA.10.3.141.0.pkg
packages.conf
[2]: Preparing packages list to delete ...
In use files, will not delete:
cat3k_caa-base.SPA.03.07.04E.pkg
cat3k_caa-drivers.SPA.03.07.04E.pkg
cat3k_caa-infra.SPA.03.07.04E.pkg
cat3k_caa-iosd-universalk9.SPA.152-3.E4.pkg
cat3k_caa-platform.SPA.03.07.04E.pkg
cat3k_caa-wcm.SPA.10.3.141.0.pkg
packages.conf
[1]: Files that will be deleted:
cat3k_caa-base.SPA.03.06.04.E.pkg
cat3k_caa-drivers.SPA.03.06.04.E.pkg
cat3k_caa-infra.SPA.03.06.04.E.pkg
cat3k_caa-iosd-universalk9.SPA.152-2.E4.pkg
cat3k_caa-platform.SPA.03.06.04.E.pkg
cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin
cat3k_caa-wcm.SPA.10.2.140.0.pkg
packages.conf.00-
y
[2]: Files that will be deleted:
cat3k_caa-base.SPA.03.06.04.E.pkg
cat3k_caa-drivers.SPA.03.06.04.E.pkg
cat3k_caa-infra.SPA.03.06.04.E.pkg
cat3k_caa-iosd-universalk9.SPA.152-2.E4.pkg
cat3k_caa-platform.SPA.03.06.04.E.pkg
cat3k_caa-universalk9.SPA.03.07.04.E.152-3.E4.bin
cat3k_caa-wcm.SPA.10.2.140.0.pkg
packages.conf.00-
[1 2]: Do you want to proceed with the deletion? [yes/no]: yes
[1 2]: Clean up completed
下面显示的是执行闪存清除后,dir flash 命令的输出内容:
zb-3650-stack# dir flash
Mar 22 2023 02:22:22 BJ: %STACKMGR-6-STANDBY_ELECTED: 2 stack-mgr: Switch 1 has been elected STANDBY. :
Directory of flash:/
46478 -rw- 1236 Mar 22 2023 02:11:51 +08:00 packages.conf
69697 drwx 4096 Mar 22 2023 02:19:43 +08:00 dc_profile_dir
46474 -rw- 2097152 Mar 22 2023 02:20:31 +08:00 nvram_config
46475 -rw- 916 Feb 22 2023 02:16:36 +08:00 vlan.dat
46476 drwx 4096 Feb 22 2023 03:41:26 +08:00 virtual-instance
11 drwx 4096 Feb 22 2023 03:44:53 +08:00 wnweb_store
46479 -rw- 81992100 Mar 22 2023 02:11:44 +08:00 cat3k_caa-base.SPA.03.07.04E.pkg
46480 -rw- 5667516 Mar 22 2023 02:11:44 +08:00 cat3k_caa-drivers.SPA.03.07.04E.pkg
46481 -rw- 36656136 Mar 22 2023 02:11:44 +08:00 cat3k_caa-infra.SPA.03.07.04E.pkg
46482 -rw- 46349632 Mar 22 2023 02:11:45 +08:00 cat3k_caa-iosd-universalk9.SPA.152-3.E4.pkg
46483 -rw- 28904332 Mar 22 2023 02:11:45 +08:00 cat3k_caa-platform.SPA.03.07.04E.pkg
46484 -rw- 128582464 Mar 22 2023 02:11:45 +08:00 cat3k_caa-wcm.SPA.10.3.141.0.pkg
至此交换机升级版本完毕