06-软件升级命令
本章节下载: 06-软件升级命令 (142.63 KB)
【命令】
分布式设备:
boot-loader file file-url slot slot-number { main | backup }
分布式IRF设备:
boot-loader file file-url chassis chassis-number slot slot-number { main | backup }
【视图】
用户视图
【缺省级别】
3:管理级
【参数】
file file-url:文件名,为1~63个字符的字符串,如果用户输入的是相对路径,则执行命令时系统会自动将相对路径转换为绝对路径,同时要求绝对路径最多不能超过63个字符,否则,命令执行失败。格式为[drive:/]file-name,其中,
l [ ]表示该参数可选,
l drive用来指定文件在设备的哪个存储介质上,取值为存储介质的名称。如果设备上只有一个存储介质,可以不用输入该参数。
l file-name表示文件的名称,一般以.app作为后缀名。
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:用来设置指定成员设备上指定单板的下次启动文件为指定文件。chassis-number表示设备在IRF中的成员编号,slot-number表示单板所在的槽位号。(分布式IRF设备)
main:指定该文件为主用启动文件。
backup:指定该文件为备用启动文件。备用启动文件只用于异常情况下,当主用启动文件不可用时,引导、启动设备。
【描述】
(1) 分布式设备
boot-loader命令用来指定主用主控板或者备用主控板的下次启动文件。
需要注意的是:
l 必须先将下次启动文件保存到相应主控板存储介质的根目录下,boot-loader命令才能执行成功。
l 主用主控板上的存储介质直接用存储介质的名称表示,比如flash;备用主控板的存储介质需要使用slotslot-number#存储介质的名称(slot-number表示备用主控板所在的槽位号),比如slot1#flash。
l 设置主用主控板的下次启动文件时,file-url参数不能携带槽位号,slot-number为主用主控板所在的槽位号;设置备用主控板的下次启动文件时,file-url参数需要携带备用主控板所在的槽位号(形如slot1#flash:/test.app),slot-number为备用主控板所在的槽位号。
l 主用主控板和备用主控板的下次启动文件名称可以不同,但是版本必须一致,否则,可能会导致设备不能正常启动。
相关配置可参考命令display boot-loader。
(2) 分布式IRF设备
boot-loader命令用来指定IRF中某个主控板的下次启动文件。
需要注意的是:
l 必须先将下次启动文件保存到相应成员设备某个主控板存储介质的根目录下,boot-loader命令才能执行成功。
l 全局主用主控板(Master设备的主用主控板)的存储介质直接用存储介质的名称表示,比如flash;全局备用主控板(IRF中全局主用主控板外的其它主控板)的存储介质需要使用chassischassis-number#slotslot-number#存储介质的名称,比如chassis2#slot1#flash。
l 设置全局主用主控板的下次启动文件时,file-url参数不能携带成员编号和单板编号,chassis-number参数指定为Master设备的成员编号,slot-number参数指定为全局主用主控板所在的槽位号;设置全局备用主控板的下次启动文件时,file-url参数必须携带该主控板所在设备的成员编号和单板的槽位号(形如chassis3#slot1#flash:/test.app),chassis-number和slot-number指定为设备的成员编号和单板所在的槽位号。
l 全局主用主控板和全局备用主控板的下次启动文件名称可以不同,但是版本最好一致,否则,可能会导致备用主控板不能加入IRF。
相关配置可参考命令display boot-loader。
【举例】
# 指定主用主控板(所在槽位为0)的主用下次启动文件为test.app(请先保证test.app已经存储在主用主控板的存储介质中,否则系统会提示错误,命令执行失败)。(分布式设备)
<Sysname> boot-loader file test.app slot 0 main
This command will set the boot file of the specified board. Continue? [Y/N]:y
The specified file will be used as the main boot file at the next reboot on slot 0!
# 指定备用主控板(所在槽位为1)的主用下次启动文件为test.app(请先保证test.app已经存储在备用主控板的存储介质中,否则系统会提示错误,命令执行失败)。(分布式设备)
<Sysname> boot-loader file slot1#flash:/test.app slot 1 main
This command will set the boot file of the specified board. Continue? [Y/N]:y
The specified file will be used as the main boot file at the next reboot on slot 1!
# 指定全局主用主控板(所在设备的成员编号为1,槽位号为0)的主用下次启动文件为test.app(请先保证test.app已经存储在该单板的存储介质中,否则系统会提示错误,命令执行失败)。(分布式IRF设备)
<Sysname> boot-loader file test.app chassis 1 slot 0 main
This command will set the boot file of the specified board. Continue? [Y/N]:y
The specified file will be used as the main boot file at the next reboot on chassis 1 slot 0!
# 指定全局备用主控板(所在设备的成员编号为1,槽位号为1)的主用下次启动文件为test.app(请先保证test.app已经存储在该单板的存储介质中,否则系统会提示错误,命令执行失败)。(分布式IRF设备)
<Sysname> boot-loader file chassis1#slot1#flash:/test.app chassis 1 slot 1 main
This command will set the boot file of the specified board. Continue? [Y/N]:y
The specified file will be used as the main boot file at the next reboot on chassis 1 slot 1!
【命令】
boot-loader update slot slot-number
【视图】
用户视图
【缺省级别】
3:管理级
【参数】
slot slot-number:表示备用主控板所在的槽位号。(分布式设备)
【描述】
boot-loader update slot命令用来同步升级备用主控板的主用下次启动文件。
同步升级备用主控板的启动文件之前,请确保备用主控板的存储介质有足够的空间存放待升级的启动文件。
【举例】
# 同步升级备用主控板(编号为1)的下次启动文件。
<Sysname> boot-loader update slot 1
【命令】
分布式设备:
bootrom { backup | read | restore | update file file-url } slot slot-number-list [ all | part ]
分布式IRF设备:
bootrom { backup | read | restore | update file file-url } chassis chassis-number slot slot-number-list [ all | part ]
【视图】
用户视图
【缺省级别】
3:管理级
【参数】
read:读取Bootrom,即将Bootrom程序从Bootrom存储器的Normal区读取到Flash中以作备份。当Bootrom存储器损坏,可以重新运行Flash上的Bootrom文件来恢复Bootrom。
restore:恢复Bootrom,即将Bootrom代码从Bootrom存储器的Backup区恢复到Normal区。如果当前的Bootrom被损坏,并且在损坏前备份了Bootrom,可以用restore操作来恢复Bootrom。
backup:备份Bootrom,即将Bootrom代码从Bootrom存储器的Normal区备份到Backup区,以便Normal区损坏时,可以从Backup区恢复Bootrom程序。建议在升级Bootrom前备份Bootrom。
update file file-url:升级Bootrom,file-url表示用于升级的文件名,为1~63个字符的字符串。file-url参数的详细介绍请参见1.1.1 boot-loader。
slot slot-number-list:单板的槽位号列表,表示多个单板。表示方式为slot-number-list = { slot-number [ to slot-number ] }&<1-7>。其中,slot-number表示单板所在的槽位号。&<1-7>表示前面的参数最多可以输入7次。(分布式设备)
slot slot-number-list:设备的成员编号列表,表示多个成员设备。表示方式为slot-number-list = { slot-number [ to slot-number ] }&<1-7>。其中,slot-number表示设备在IRF中的成员编号。(集中式IRF设备)
chassis chassis-number:表示设备在IRF中的成员编号。不指定该参数时,表示所有成员设备。(分布式IRF设备)
slot slot-number-list:单板的槽位号列表,表示多个单板。表示方式为slot-number-list = { slot-number [ to slot-number ] }&<1-7>。其中,slot-number表示单板所在的槽位号。&<1-7>表示前面的参数最多可以输入7次。(分布式IRF设备)
all:操作Bootrom的全部内容。不指定all和part参数时,默认使用all。
part:只操作Bootrom的扩展内容(Bootrom分两部分:常规部分和扩展部分,常规部分提供Bootrom的基本操作项,扩展部分提供更多的Bootrom操作项)。不指定all和part参数时,默认使用all。
【描述】
(1) 分布式设备
bootrom命令用来读取、恢复、备份或升级指定单板或子卡的Bootrom程序。
需要注意的是:
l 必须先将Bootrom程序保存到相应单板存储介质的根目录下,bootrom命令用来才能执行成功。
l 主用主控板上的存储介质直接用存储介质的名称表示,比如flash;备用主控板和接口板的存储介质需要使用slotslot-number#存储介质的名称(slot-number表示备用主控板或接口板所在的槽位号),比如slot1#flash。
l 升级主用主控板的Bootrom程序时,file-url参数不能携带槽位号,slot-number参数指定为主用主控板所在的槽位号,subslot-number-list参数指定为主用主控板上子卡所在的槽位号;升级备用主控板或接口板的Bootrom程序时,file-url参数需要携带该板的槽位号(形如slot1#flash:/test.app),slot-number参数指定为该板所在的槽位号。
l 设备上各单板的Bootrom程序名称可以不同,但是版本必须兼容,否则,可能会导致单板不能正常启动。
(2) 分布式IRF设备
bootrom命令用来读取、恢复、备份或升级指定成员设备上指定单板或子卡的Bootrom程序。
需要注意的是:
l 必须先将Bootrom程序保存到相应成员设备指定单板存储介质的根目录下,bootrom命令才能执行成功。
l 全局主用主控板的存储介质直接用存储介质的名称表示,比如flash;全局备用主控板的存储介质需要使用chassischassis-number#slotslot-number#存储介质的名称,比如chassis3#slot1#flash。
l 升级全局主用主控板以及Master上接口板的Bootrom程序时,file-url参数不能携带成员编号和单板的槽位号,chassis-number参数指定为Master的成员编号,slot-number参数指定为单板所在的槽位号;升级IRF中其它单板的Bootrom程序时,file-url参数必须携带该单板所在设备的成员编号以及单板所在的槽位号(形如chassis3#slot1#flash:/test.app),chassis-number参数指定为该单板所在设备的成员编号,slot-number参数指定为该单板所在的槽位号。chassis-number和slot-number指定为该单板所在设备的成员编号以及单板的槽位号。
【举例】
# 使用a.btm文件升级主用主控板(所在槽位号为0)的Bootrom程序。(分布式设备)
<Sysname> bootrom update file a.btm slot 0
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
Start accessing bootflash chip...
Bootrom update succeeded in slot 0.
# 使用a.btm文件升级备用主控板(所在槽位号为1)的Bootrom程序。(分布式设备)
<Sysname> bootrom update file slot1#flash:/a.btm slot 1
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
Start accessing bootflash chip...
Bootrom update succeeded in slot 1.
# 使用a.btm文件升级全局主用主控板(所在设备的成员编号为1,槽位号为0)的Bootrom程序。(分布式IRF设备)
<Sysname> bootrom update file a.btm chassis 1 slot 0
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
Start accessing bootflash chip...
Bootrom update succeeded in slot 0.
# 使用a.btm文件升级Master上接口板(所在设备的成员编号为1,槽位号为3)的Bootrom程序。(分布式IRF设备)
<Sysname> bootrom update file a.btm chassis 1 slot 3
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
User 2 update Bootrom of chassis 1 slot 3 with flash:/a.btm success, type is all
# 使用a.btm文件升级全局备用主控板(所在设备的成员编号为1,槽位号为1)的Bootrom程序。(分布式IRF设备)
<Sysname> bootrom update file chassis1#slot1#flash:/a.btm chassis 1 slot 1
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
User 2 update Bootrom of chassis 1 slot 1 with flash:/a.btm success, type is all
# 使用a.btm文件升级Slave设备接口板(所在设备的成员编号为2,槽位号为5)的Bootrom程序。(分布式IRF设备)
<Sysname> bootrom update file chassis2#slot5#flash:/a.btm chassis 2 slot 5
This command will update bootrom file on the specified board(s), Continue? [Y/N]:y
Now updating bootrom, please wait...
User 2 update Bootrom of chassis 2 slot 5 with flash:/a.btm success, type is all
【命令】
分布式设备:
display boot-loader [ slot slot-number ] [ | { begin | exclude | include } regular-expression ]
分布式IRF设备:
display boot-loader [ chassis chassis-number [ slot slot-number ] ] [ | { begin | exclude | include } regular-expression ]
【视图】
任意视图
【缺省级别】
2:系统级
【参数】
slot slot-number:显示指定单板的启动文件的信息。slot-number表示单板所在的槽位号。(分布式设备)
chassis chassis-number:显示指定成员设备的启动文件的信息。chassis-number表示设备在IRF中的成员编号。不使用该参数时,表示所有成员设备。(分布式IRF设备)
slot slot-number:显示指定单板的启动文件的信息。slot-number表示单板所在的槽位号。不使用该参数时,表示该成员设备的所有主控板。(分布式IRF设备)
|:使用正则表达式对显示信息进行过滤。有关正则表达式的详细介绍,请参见“基础配置指导”中的“CLI配置”。
begin:从包含指定正则表达式的行开始显示。
exclude:只显示不包含指定正则表达式的行。
include:只显示包含指定正则表达式的行。
regular-expression:表示正则表达式,为1~256个字符的字符串,区分大小写。
【描述】
display boot-loader命令用来显示启动文件信息。
相关配置可参考命令boot-loader。
【举例】
# 显示本次启动和下次启动所采用的启动文件。(分布式设备)
<Sysname> display boot-loader
The primary app to boot of board 0 at this time is: flash:/test.app
The primary app to boot of board 0 at next time is: flash:/test.app
The slave app to boot of board 0 at next time is: flash:/test.app
The primary app to boot of board 1 at this time is: flash:/test.app
The primary app to boot of board 1 at next time is: flash:/test.app
The slave app to boot of board 1 at next time is: flash:/test.app
表1-1 display boot-loader命令显示信息描述表
字段 |
描述 |
The primary app to boot of board slot-number at this time is |
单板(slot-number表示单板所在的槽位号)本次启动时使用的启动文件 |
The primary app to boot of board slot-number at next time is |
单板(slot-number表示单板所在的槽位号)下次启动时使用的主用启动文件 |
The slave app to boot of board slot-number at next time is |
单板(slot-number表示单板所在的槽位号)下次启动时使用的备用启动文件 |
# 显示本次启动和下次启动所采用的启动文件(注意:本命令的显示信息与设备型号有关,请以设备的实际情况为准)。(分布式IRF设备)
<Sysname> display boot-loader
The primary app to boot of chassis 1 board 0 at this time is: flash:/test.app
The primary app to boot of chassis 1 board 0 at next time is: flash:/test.app
The slave app to boot of chassis 1 board 0 at next time is: flash:/test.app
The primary app to boot of chassis 2 board 0 at this time is: flash:/test.app
The primary app to boot of chassis 2 board 0 at next time is: flash:/test.app
The slave app to boot of chassis 2 board 0 at next time is: flash:/test.app
表1-2 display boot-loader命令显示信息描述表
字段 |
描述 |
The primary app to boot of chassis 1 board 0 at this time is |
成员设备1上的0号单板本次启动时使用的启动文件 |
The primary app to boot of chassis 1 board 0 at next time is |
成员设备1上的0号单板下次启动时使用的主用启动文件 |
The slave app to boot of chassis 1 board 0 at next time is |
成员设备1上的0号单板下次启动时使用的备用启动文件 |
【命令】
display patch information [ | { begin | exclude | include } regular-expression ]
【视图】
任意视图
【缺省级别】
3:管理级
【参数】
|:使用正则表达式对显示信息进行过滤。有关正则表达式的详细介绍,请参见“基础配置指导”中的“CLI配置”。
begin:从包含指定正则表达式的行开始显示。
exclude:只显示不包含指定正则表达式的行。
include:只显示包含指定正则表达式的行。
regular-expression:表示正则表达式,为1~256个字符的字符串,区分大小写。
【描述】
display patch information命令用来显示热补丁的信息。
【举例】
# 显示热补丁的信息。(分布式设备)
<Sysname> display patch information
The location of patches: flash:
Slot Version Temporary Common Current Active Running Start-Address
----------------------------------------------------------------------
1 MPU001 0 1 1 1 0 0x83c0314c
2 LPB001 0 1 1 1 0 0x828e8310
# 显示热补丁的信息。(分布式IRF设备)
<Sysname> display patch information
The location of patches: flash:
Chassis Slot Version Temporary Common Current Active Running Start-Address
----------------------------------------------------------------------
1 0 MPU001 0 1 1 1 0 0x83c0314c
1 2 LPB001 0 1 1 1 0 0x828e8310
1 3 LPR001 0 1 1 1 0 0x84a68ea4
1 3.1 OAM 0 0 0 0 0 0x8093da00
1 4 LPR001 0 1 1 1 0 0x84a68ea4
1 4.1 OAM 0 0 0 0 0 0x8093da0c
表1-3 display patch information命令显示信息描述表
字段 |
描述 |
The location of patches |
补丁文件的加载路径,可以通过patch location命令设置 |
Chassis |
设备的成员编号 |
Slot |
单板所在的槽号,如果单板上只有一个CPU,则直接显示slot-number,如果单板上有多个CPU,则主CPU显示为slot-number,辅助CPU显示为slot-number.cpu-id(分布式设备) |
Version |
补丁版本号。该字段的前3个字符表示PATCH-FLAG的后缀,比如某单板的PATCH-FLAG为PATCH-RPE,则该字段会显示为RPE,后面的数字00x表示补丁的编号(只有补丁加载后,系统才能读取到补丁的编号信息) |
Temporary |
临时补丁数目 |
Common |
正式补丁数目 |
Current |
当前补丁总数目 |
Running |
处于运行状态的补丁数目 |
Active |
处于激活状态的补丁数目 |
Start-Address |
内存补丁区在内存中的起始地址 |
【命令】
分布式设备:
patch active patch-number slot slot-number
分布式IRF设备:
patch active patch-number chassis chassis-number slot slot-number
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-number:补丁序号。该参数的有效值与使用的补丁文件有关,请以实际情况为准。
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:表示指定成员设备上的指定单板。(分布式IRF设备)
【描述】
patch active命令用来激活指定补丁,即运行该补丁。
执行该命令,补丁序号之前(包括该序号)的所有处于未激活状态的补丁将被激活,进入激活状态。
需要注意的是:
l 激活补丁前,必须先加载该补丁,否则,激活操作失败。
l 系统重启后,原处于激活状态的补丁会变成未激活状态,不再生效。如果想再次使用该补丁,需要再次激活。
【举例】
# 激活备用板(所在槽位号为1)上3号及3号之前的补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch active 3 slot 1
# 激活成员设备1的2号单板上的3号及3号之前的补丁。(分布式IRF设备)
<Sysname> system-view
[Sysname] patch active 3 chassis 1 slot 2
【命令】
分布式设备:
patch deactive patch-number slot slot-number
分布式IRF设备:
patch deactive patch-number chassis chassis-number slot slot-number
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-number:补丁序号。该参数的有效值与使用的补丁文件有关,请以实际情况为准。
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:表示指定成员设备上的指定单板。(分布式IRF设备)
【描述】
patch deactive命令用来停止运行指定补丁,恢复原版本软件的运行。
执行该命令,在此补丁序号之后(包括该序号)处于激活状态的补丁全部进入未激活状态。
对于处于运行状态的补丁,本命令无效。
【举例】
# 停止运行备用板(所在槽位号为1)上3号及3号之后的补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch deactive 3 slot 1
# 停止运行成员设备1的5号单板上的3号及3号之后的补丁。(分布式IRF设备)
<Sysname> system-view
[Sysname] patch deactive 3 chassis 1 slot 5
【命令】
分布式设备:
patch delete patch-number slot slot-number
分布式IRF设备:
patch delete patch-number chassis chassis-number slot slot-number
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-number:补丁序号。该参数的有效值与使用的补丁文件有关,请以实际情况为准。
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:表示指定成员设备上的指定单板。(分布式IRF设备)
【描述】
patch delete命令用来将补丁从内存补丁区中删除,补丁序号之后(包括该序号)的所有补丁被删除。
执行该命令,只是将补丁从内存补丁区中删除,并不会将补丁从存储介质中删除,补丁回到初始状态(IDLE)。
【举例】
# 删除备用板(所在槽位号为1)上3号及3号之后的补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch delete 3 slot 1
# 删除成员设备1的5号单板上的3号及3号之后的补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch delete 3 chassis 1 slot 5
【命令】
patch install patch-location
undo patch install
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-location:表示补丁文件所在的路径,为1~64个字符的字符串,缺省为“flash:”。
【描述】
patch install命令用来一步式完成补丁的安装。undo patch install命令用来卸载补丁。
在执行patch install命令时,系统会提示“Do you want to continue running patches after reboot? [Y/N]:”,
l 如果输入<Y>或者<y>,则会安装指定路径下的所有补丁,设备或单板重启后这些补丁继续生效,补丁状态从IDLE转换到RUNNING。相当于依次执行了patch location、patch load、patch active和patch run命令。
l 如果输入<N>或者<n>,则会安装指定路径下的所有补丁,设备或单板重启后这些补丁不再继续生效,补丁状态从IDLE转换到ACTIVE。相当于依次执行了patch location、patch load和patch active命令。
需要注意的是:
l 执行该命令前,请将主用板和接口板的补丁文件保存到主用板存储介质的根目录下,备用板的补丁文件保存到备用板存储介质的根目录下,如果存储介质是支持分区的CF卡,则补丁文件必须放在CF卡第一个分区的根目录下。
l 执行补丁安装操作后,系统会将补丁文件的加载路径修改成“patch install patch-location”中patch-location参数所指向的位置。比如,先配置了patch location xxx,再执行patch install yyy,此时系统会自动将补丁文件的加载路径从xxx改为yyy。
【举例】
# 加载Flash上的补丁文件,并且要求设备重启后补丁继续生效。
<Sysname> system-view
[Sysname] patch install flash:
Patches will be installed. Continue? [Y/N]:y
Do you want to run patches after reboot? [Y/N]:y
Installing patches…
Installation completed, and patches will continue to run after reboot.
[Sysname]
【命令】
分布式设备:
patch load slot slot-number
分布式IRF设备:
patch load chassis chassis-number slot slot-number
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:表示指定成员设备上的指定单板。(分布式IRF设备)
【描述】
patch load命令用来将补丁文件从存储介质(比如Flash、CF卡)加载到内存补丁区中。
如果设备上配备了多个存储介质,系统默认会从Flash上加载补丁文件,如果加载失败再尝试从CF卡加载。
l 执行该命令前,请将主用板和接口板的补丁文件保存到主用板存储介质的根目录下,备用板的补丁文件保存到备用板存储介质的根目录下。(分布式设备)
l 执行该命令前,请将补丁文件保存到所有成员设备存储介质的根目录下。各成员设备主用板和接口板的补丁文件保存到本设备主用板存储介质的根目录下,备用板的补丁文件保存到本设备备用板存储介质的根目录下。(分布式IRF设备)
【举例】
# 为备用板(所在槽位号为1)加载补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch load slot 1
# 为成员设备1的3号单板加载补丁文件。(分布式IRF设备)
<Sysname> system-view
[Sysname] patch load chassis 1 slot 3
【命令】
patch location patch-location
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-location:表示补丁文件所在的路径,为1~64个字符的字符串,缺省为“flash:”。
【描述】
patch location命令用来设置补丁文件的加载路径。
缺省情况下,补丁文件的加载路径为flash:。
当设备支持多个存储介质时,用户可以将补丁文件保存到Flash外的其它存储介质。此时,需要使用该命令告知系统补丁文件的位置,执行补丁加载操作时,系统会将该路径下指定后缀的补丁加载到对应的单板。
需要注意的是,执行patch install命令会修改补丁文件的加载路径。比如,先配置了patch location xxx,再执行patch install yyy,此时系统会自动将补丁文件的加载路径从xxx改为yyy。
【举例】
# 设置补丁文件加载路径为flash的根目录。
<Sysname> system-view
[Sysname] patch location flash:
【命令】
分布式设备:
patch run patch-number [ slot slot-number ]
分布式IRF设备:
patch run patch-number [ chassis chassis-number slot slot-number ]
【视图】
系统视图
【缺省级别】
3:管理级
【参数】
patch-number:补丁序号。该参数的有效值与使用的补丁文件有关,请以实际情况为准。
slot slot-number:表示单板所在的槽位号。(分布式设备)
chassis chassis-number slot slot-number:表示指定成员设备上的指定单板。(分布式IRF设备)
【描述】
patch run命令用来确认运行指定补丁,补丁序号之前(包括该序号)的激活状态补丁全部进入运行状态。
l 如果指定slot参数,则确认运行该单板上的所有补丁(包括辅助CPU的补丁);如果不指定slot参数,表示确认运行所有单板上的所有补丁。(分布式设备)
l 如果指定chassis和slot参数,则确认运行某成员设备指定单板上的所有补丁(包括辅助CPU的补丁);如果不指定chassis和slot参数,表示确认运行IRF中所有单板上的所有补丁。(分布式IRF设备)
该命令只对处于激活状态的补丁有效,对于处于其它状态的补丁,该命令无效。
确认运行的补丁,在系统重启后,会继续生效。
【举例】
# 确认运行备用板(所在槽位号为1)上3号及3号之前的补丁。(分布式设备)
<Sysname> system-view
[Sysname] patch run 3 slot 1
# 确认运行成员设备1的5号单板上的3号及3号之前的补丁。(分布式IRF设备)
<Sysname> system-view
[Sysname] patch run 3 chassis 1 slot 5
不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!