WO2016037314A1 - 软件版本升级方法、装置及设备 - Google Patents

软件版本升级方法、装置及设备 Download PDF

Info

Publication number
WO2016037314A1
WO2016037314A1 PCT/CN2014/086133 CN2014086133W WO2016037314A1 WO 2016037314 A1 WO2016037314 A1 WO 2016037314A1 CN 2014086133 W CN2014086133 W CN 2014086133W WO 2016037314 A1 WO2016037314 A1 WO 2016037314A1
Authority
WO
WIPO (PCT)
Prior art keywords
file
software version
link address
patch
running
Prior art date
Application number
PCT/CN2014/086133
Other languages
English (en)
French (fr)
Inventor
朱湘毅
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to CN201480049719.2A priority Critical patent/CN105594184B/zh
Priority to PCT/CN2014/086133 priority patent/WO2016037314A1/zh
Publication of WO2016037314A1 publication Critical patent/WO2016037314A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Definitions

  • the present application relates to the field of communications technologies, and in particular, to a software version upgrade method, apparatus, and device.
  • the software version developer will release a patch file for the software version after the software version is released.
  • the client that installed the software version can download the patch file and use the patch file to upgrade the software version to fix the vulnerability in the software version or optimize the software version.
  • the application provides a software version upgrade method, device and device for reducing the impact on the service during the software version upgrade process.
  • a software version upgrade method including:
  • the process of triggering the running of the software version is executed, and the corresponding file linked by the link address of each file is run according to the link address of each file.
  • the process of triggering running the software version, after running the corresponding file of the link address link of each file according to the link address of each file also includes:
  • the process is triggered to run the file in the software version.
  • the method before the determining the patch file package for the software version, the method further includes:
  • a configuration file is further included in the patch file package, The configuration file is used to indicate the process running the patch file.
  • the process of triggering the running of the software version, according to the link address of each file, running the corresponding file of the link address link of each file includes:
  • the process of running the patch file indicated by the configuration file is triggered, and corresponding files of the link address links of the respective files are run according to the link address of the respective files.
  • the triggering the process of running the software version, according to the The link address of each file, the corresponding file of the link address link running the respective file includes:
  • the plug-in process is triggered to uninstall a plug-in that runs a file in the software version, and loads a plug-in that runs the file linked by the link address.
  • a software version upgrade apparatus including:
  • a first file determining module configured to determine a patch file package for the software version
  • a second file determining module configured to determine, according to the patch file in the patch file package, a file that is not required to be updated in the software version
  • An address determining module configured to determine a link address of each file included in an upgraded version of the software version, where a link address of each file includes a link address of the patch file and a link address of the file that does not need to be updated ;
  • An upgrade module configured to trigger a process of running the software version, according to a link of each file Address, the corresponding file that runs the link address link for each file.
  • the method further includes:
  • the rollback module is configured to trigger the process to run the file in the software version when the patch back command is detected.
  • the method further includes:
  • a patch installation module for downloading and installing the patch file.
  • the upgrading module is specifically configured to:
  • the process of running the patch file indicated by the configuration file is triggered, and corresponding files of the link address links of the respective files are run according to the link address of the respective files.
  • the upgrading module is specifically configured to:
  • the plug-in process is triggered to uninstall a plug-in that runs a file in the software version, and loads a plug-in that runs the file linked by the link address.
  • a software version upgrade device including a processor and a memory.
  • the memory user stores a set of program instructions
  • the processor is configured to invoke the program instruction of the memory, and perform the following operations:
  • the process of triggering the running of the software version is executed, and the corresponding file linked by the link address of each file is run according to the link address of each file.
  • the file that is not required to be updated in the software version is determined according to the patch file in the patch file package, and the link address of the file that is not to be updated and the patch file in the patch file package are determined.
  • Link address determine the link address of each file to be included in the upgrade version after the software version is upgraded, and then trigger the process running the software version, run the The corresponding file of the link address of each file, because the file linked by the link address includes the patch file and the file that is not required to be updated in the software version, the purpose of running the upgrade version file by the process is realized, thereby realizing the software version upgrade.
  • the process only needs to switch to the file corresponding to the running link address, without stopping for a long time, so the impact on the business can be reduced.
  • FIG. 1 is a schematic flowchart of a method for upgrading a software version according to an embodiment of the present disclosure
  • FIG. 2 is a schematic diagram of a directory of multiple files included in a software version V1.0.1.0.0 provided by an embodiment of the present application;
  • FIG. 3 is a schematic diagram of a directory of a patch file in a patch file package for software version V1.0.1.0.0 according to an embodiment of the present application;
  • FIG. 4 is a schematic diagram of a link relationship between a software version and an upgrade version according to an embodiment of the present application
  • FIG. 5 is a schematic structural diagram of an apparatus for upgrading a software version according to an embodiment of the present disclosure
  • FIG. 6 is a schematic structural diagram of an embodiment of a software version upgrading device according to an embodiment of the present disclosure.
  • FIG. 1 a flow chart of an embodiment of a software version upgrade method of the present application is shown.
  • the method of this embodiment may include:
  • the patch file in the patch file package may be a file that needs to be added to the software version, that is, a file included in the patch file package and not included in the software version; or a file that is updated in the software version, that is, the file
  • the software version and the patch file contain the same file name, but the data content contained in the file is different.
  • the link address of each file includes a link address of the patch file in the patch file package and a link address of the file that is not required to be updated in the software version.
  • the link address may specifically refer to location information of each file and the like.
  • the link addresses of the individual files that make up the upgrade version can be determined.
  • the process that originally runs the file in the software version triggers the corresponding file running the link of the link address.
  • the file linked by the link address includes the patch file (including the software version that needs to be updated).
  • the patch file corresponding to the file) and the file that is not required to be updated in the software version thus realizing the purpose of running the upgrade version file for the process, thereby implementing the software version upgrade.
  • the process only needs to switch to the file corresponding to the running link address. There is no need to stop for a long time, so the impact on the business corresponding to the process can be reduced. It also eliminates the need for complicated operations such as backing up files and overwriting files, saving upgrade time and improving upgrade efficiency.
  • a process may not need to run all the files in the software version, so you can run the corresponding file of the link address of each file according to your needs.
  • an upgrade command can be sent directly to the process running the file in the software version.
  • the process running the file in the software version responds to the upgrade instruction, and the corresponding file linked by the link address of each file may be run according to the link address of each file. That is, the implementation process is switched from the file that needs to be updated in the software version to the patch file in the patch file package, so that the files that need to be updated in the software version are upgraded to the patch file in the patch file package.
  • the method further includes:
  • the process is triggered to run the file in the software version.
  • the patch rollback command may be generated when the patch file is abnormally detected.
  • the patch file package and the software version are two separate software packages, and the link address of each file in the determined upgrade version is actually established in the patch file package and the software version does not need to be updated.
  • the link relationship of the files is two separate software packages, and the link address of each file in the determined upgrade version is actually established in the patch file package and the software version does not need to be updated. The link relationship of the files.
  • the file that is not required to be updated in the software version and the patch file in the patch file package may be first determined as a file included in the upgrade version after the software version is upgraded, and then the link address of the file that does not need to be updated is determined.
  • the link address of the patch file in the patch package which will not need to be updated.
  • the link address of the file and the link address of the patch file are combined to obtain the link address of each file in the upgraded version.
  • the software version contains the program file software, including: file1 to filen.
  • the software version also includes a plurality of data files date generated in the running software version, specifically including date1 to schemes, where n is a natural number greater than 1.
  • n is a natural number greater than 1.
  • FIG. 2 it is a directory diagram of files included in the software version V1.0.1.0.0.
  • the patch file for the software version V1.0.1.0.0 includes the patch files file3 and fileX, wherein the patch file file3 is an update file of the file file3 included in the software version V1.0.1.0.0, and the fileX is new. program files.
  • FIG. 3 a directory diagram of a patch file in a patch file package is shown, that is, the patch file package includes a patch file file3 and a patch file fileX.
  • the software version and the link address of each file in the patch file package are determined, and the link address of the file and the patch file of the software version that are not required to be updated are determined.
  • FIG. 4 it is a schematic diagram of the relationship between the files that need not be updated in the software version and the patch files in the patch file package. It can be seen that the files in the upgraded version include the patch file and the files that need to be updated in the linked software version.
  • the file in the software version of the process may not need to be updated.
  • the process can run the file in the software version without running the corresponding file linked by the link address.
  • the corresponding file of the link may specifically be a process of running a file that needs to be updated in the software version, and according to the link address of the respective file, running a corresponding file linked by the link address of each file.
  • the process that needs to run the upgraded version can be the process that runs the file that needs to be updated in the software version.
  • the process can continue to run the software version of the file.
  • the patch file package may further include a configuration file, where the configuration file includes process information for indicating each patch file in the patch file package.
  • the patch file includes the patch files file3 and fileX.
  • the configuration file it can be indicated that the patch file file3 is run by the process A of the file3 running the original software version, and the fileX is run by the process B.
  • the process of triggering the running of the software version, according to the link address of each file, running the corresponding file of the link address link of each file includes:
  • the process of running the patch file indicated by the configuration file is triggered, and corresponding files of the link address links of the respective files are run according to the link address of the respective files.
  • the process running the files in the software version is a normal process
  • the normal process may be triggered to terminate the operation, and at the same time The normal process is restarted in the corresponding file of the link address of each file.
  • the plug-in process is composed of multiple plug-ins or modules, each plug-in can be started, stopped, uninstalled, installed, etc. independently. Therefore, a plugin of the plugin process is upgraded and patched, which only affects the plugin. It is therefore possible to determine whether or not to insert the upgrade for the files in the software version inserted into the run.
  • FIG. 5 is a schematic structural diagram of an apparatus for upgrading a software version according to an embodiment of the present disclosure, where the apparatus may include:
  • the first file determining module 501 is configured to determine a patch file package for the software version.
  • the second file determining module 502 is configured to determine, according to the patch file in the patch file package, a file that is not required to be updated in the software version.
  • the patch file in the patch file package may be a file that needs to be added to the software version, that is, a file included in the patch file package and not included in the software version; or a file that is updated in the software version, that is, the file
  • the software version and the patch file contain the same file name, but the data content contained in the file is different.
  • the address determining module 503 is configured to determine a link address of each file included in the upgraded version of the software version.
  • the link address of each file includes a link address of the patch file and a link address of the file that does not need to be updated.
  • the link address may specifically refer to location information of each file and the like.
  • the patch file and the files in the software version it can be determined that the software version is upgraded after the upgrade.
  • the files included in the level version it can be determined that the software version is upgraded after the upgrade.
  • the link addresses of the individual files that make up the upgrade version can be determined.
  • the upgrading module 501 is configured to trigger a process of running the software version, and run a corresponding file linked by the link address of each file according to the link address of each file.
  • the process that originally runs the file in the software version triggers the corresponding file running the link of the link address.
  • the file linked by the link address includes the patch file (including the software version that needs to be updated).
  • the patch file corresponding to the file) and the file that is not required to be updated in the software version thus realizing the purpose of running the upgrade version file for the process, thereby implementing the software version upgrade.
  • the process only needs to switch to the file corresponding to the running link address, without stopping for a long time, so the impact on the business can be reduced. It also eliminates the need for complicated operations such as backing up files and overwriting files, saving upgrade time and improving upgrade efficiency.
  • a process may not need to run all the files in the software version, so you can run the corresponding file of the link address of each file according to your needs.
  • the original software version is not covered by the patch file, so that the original software version is still completely stored in the device, so that when the patch file package is abnormal, , you can directly switch the process back to the file in the running software version. Therefore, there is no need to back up files, and there is no need to interrupt the service when the patch is rolled back.
  • the device may further include:
  • the rollback module is configured to trigger the process to run the file in the software version when the patch back command is detected.
  • the patch rollback command may be generated when the patch file is abnormally detected.
  • the device may further comprise:
  • a patch installation module for downloading and installing the patch file.
  • the patch file package and the software version are two separate software packages, and the link address of each file in the determined upgrade version is actually established in the patch file package and the software version does not need to be updated.
  • the link relationship of the files is two separate software packages, and the link address of each file in the determined upgrade version is actually established in the patch file package and the software version does not need to be updated. The link relationship of the files.
  • the file in the software version of the process may not need to be updated.
  • the process can run the file in the software version without running the corresponding file linked by the link address.
  • the upgrade module when it is determined that there is a file that needs to be updated in the software version according to the patch file, the upgrade module may be specifically a process of running a file that needs to be updated in the software version, according to the The link address, the corresponding file that runs the link address link of each file.
  • the process that needs to run the upgraded version can be the process that runs the file that needs to be updated in the software version.
  • the process can continue to run the software version of the file.
  • the patch file package may further include a configuration file, where the configuration file includes process information for indicating each patch file in the patch file package. Therefore, the upgrade module can be specifically used for:
  • the process of running the patch file indicated by the configuration file is triggered, and corresponding files of the link address links of the respective files are run according to the link address of the respective files.
  • the upgrade module may trigger the normal process to terminate the operation, and restart the corresponding file in the corresponding file of the link address of the respective file.
  • the upgrade module may be the plug-in process uninstalling the plug-in that runs the file in the software version, and reloading the link address link running the respective file.
  • the plugin for the corresponding file may be the plug-in process uninstalling the plug-in that runs the file in the software version, and reloading the link address link running the respective file.
  • the plug-in process is composed of multiple plug-ins or modules, each plug-in can be started independently, Stop, uninstall, install, etc. Therefore, a plugin of the plugin process is upgraded and patched, which only affects the plugin. It is therefore possible to determine whether or not to insert the upgrade for the files in the software version inserted into the run.
  • the software version upgrade device described in the foregoing embodiment may be integrated into the software version upgrade device, and the software version upgrade device may be a network element device with a software version upgrade requirement.
  • the software version of the software version upgrade device of the embodiment of the present application is upgraded, and the process does not need to be stopped for a long time. Therefore, the service interruption time of the process can be detected, and the impact on the service is reduced. It also eliminates the need for complicated operations such as backing up files and overwriting files, saving upgrade time and improving upgrade efficiency.
  • the embodiment of the present application further provides a software version upgrading device, where the software version upgrading device includes at least a processor 601 and a memory 602.
  • the memory 602 stores a set of program instructions, which may be a high speed RAM memory or a non-volatile memory such as at least one disk memory or the like.
  • the processor 601 is configured to invoke the program instructions stored in the memory 602, and perform the following operations:
  • the process of triggering the running of the software version is executed, and the corresponding file linked by the link address of each file is run according to the link address of each file.
  • the processor may be a central processing unit CPU, or an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present invention.
  • CPU central processing unit
  • ASIC application specific integrated circuit
  • the software version upgrade device may be used to perform the example provided in the embodiment of the present application.
  • the steps of a method or algorithm described in connection with the embodiments disclosed herein can be implemented directly in hardware, a software module executed by a processor, or a combination of both.
  • the software module can be placed in random access memory (RAM), memory, read only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or technical field. Any other form of storage medium known.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

本申请实施例提供了一种软件版本升级方法和装置,所述方法包括:确定针对所述软件版本的补丁文件包;依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。本申请实施例降低了软件版本升级时,对业务造成的影响。

Description

软件版本升级方法、装置及设备 技术领域
本申请涉及通信技术领域,尤其涉及一种软件版本升级方法、装置及设备。
背景技术
为了对软件版本进行完善,软件版本的开发者在软件版本发布后,还会发布针对该软件版本的补丁文件。安装了该软件版本的客户端可以下载该补丁文件,并利用该补丁文件对该软件版本进行升级,以修复该软件版本中的漏洞或实现对该软件版本的优化。
现有技术中,利用补丁文件对软件版本进行升级的过程中,首先确定出该软件版本中需要更新的待修改文件,并对该待修改文件进行备份;然后,停止运行该待修改文件的进程,利用补丁文件覆盖该待修改文件;之后,重新启动进程。
可见,在软件版本的升级过程中,需要先停止进程,使得运行该软件版本的进程需要中断一段时间,从而会影响该进程对应的业务的运行。
发明内容
本申请提供一种软件版本升级方法、装置及设备,用于在软件版本升级过程,降低对业务造成的影响。
第一方面,提供了一种软件版本升级方法,包括:
确定针对所述软件版本的补丁文件包;
依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
在所述第一方面的第一种可能实现方式中,所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件之后,所述方法还包括:
检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
在所述第一方面的第二种可能实现方式中,在所述确定针对所述软件版本的补丁文件包之前,还包括:
下载并安装所述补丁文件。
结合所述第一方面或所述第一方面的上述任一种可能实现方式,在所述第一方面的第三种可能实现方式中,在所述补丁文件包中还包括配置文件,所述配置文件用于指示运行补丁文件的进程。
所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件包括:
触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
结合所述第一方面或所述第一方面的上述任一种可能实现方式,在所述第一方面的第四种可能实现方式中,所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件包括:
当运行所述软件版本的进程为插件进程时,触发所述插件进程卸载运行所述软件版本中的文件的插件,并加载运行所述链接地址链接的文件的插件。
第二方面,提供了一种软件版本升级装置,包括:
第一文件确定模块,用于确定针对所述软件版本的补丁文件包;
第二文件确定模块,用于依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
地址确定模块,用于确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
升级模块,用于触发运行所述软件版本的进程,依据所述各个文件的链接 地址,运行所述各个文件的链接地址链接的相应文件。
在所述第二方面的第一种可能实现方式中,还包括:
回退模块,用于检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
在所述第二方面的第二种可能实现方式中,还包括:
补丁安装模块,用于下载并安装所述补丁文件。
结合所述第二方面或所述第二方面的上述任一种可能实现方式,在所述第二方面的第三种可能实现方式中,所述升级模块具体用于:
触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
结合所述第二方面或所述第二方面的上述任一种可能实现方式,在所述第二方面的第四种可能实现方式中,所述升级模块具体用于:
当运行所述软件版本的进程为插件进程时,触发所述插件进程卸载运行所述软件版本中的文件的插件,并加载运行所述链接地址链接的文件的插件。
第三方面,提供了一种软件版本升级设备,包括处理器以及存储器,
所述存储器用户存储一组程序指令;
所述处理器用于调用所述存储器的所述程序指令,执行如下操作:
确定针对所述软件版本的补丁文件包;
依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
由上述的技术方案可知,确定了补丁文件包之后,依据该补丁文件包中补丁文件确定该软件版本中无需更新的文件,并基于该无需更新的文件的链接地址和该补丁文件包中补丁文件的链接地址,确定该软件版本升级之后的升级版本中需包含的各个文件的链接地址,然后触发运行该软件版本的进程,运行该 各个文件的链接地址链接的相应文件,由于链接地址链接的文件包括补丁文件以及软件版本中无需更新的文件,因此即实现了将进程运行升级版本文件的目的,从而实现了软件版本升级。进程只需切换到运行链接地址对应的文件即可,无需停止较长的时间,因此可以减少对业务的影响。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为本申请实施例提供的一种软件版本升级方法一个实施例的流程示意图;
图2为本申请实施例提供的软件版本V1.0.1.0.0中包含的多个文件的目录示意图;
图3为本申请实施例提供的针对软件版本V1.0.1.0.0的补丁文件包中的补丁文件的目录示意图;
图4为本申请实施例提供的软件版本与升级版本之间的链接关系示意图;
图5为本申请实施例提供的一种软件版本升级装置一个实施例的结构示意图;
图6为本申请实施例提供的一种软件版本升级设备一个实施例的结构示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
参见图1,其示出了本申请一种软件版本升级方法一个实施例的流程示意 图,本实施例的方法可以包括:
101,确定针对软件版本的补丁文件包。
当需要对网元设备中的软件版本进行更新时,可以在下载并安装该补丁文件包后,利用该网元设备中存在的该补丁文件包中的补丁文件对软件版本进行升级。
102,依据补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件。
补丁文件包中补丁文件可以是需要向该软件版本中增加的文件,即补丁文件包中包含且该软件版本中不包含的文件;也可以是对软件版本中的文件进行更新的文件,即该软件版本和补丁文件包中包含的文件名称相同的文件,但是该文件中包含的数据内容不同。
通过将该补丁文件包中的补丁文件与该软件版本中包含的文件进行比较,可以确定出该软件版本中不需要更新的文件和/或需要更新的文件。
103,确定该软件版本的升级版本中包含的各个文件的链接地址。
其中,该各个文件的链接地址包括该补丁文件包中补丁文件的链接地址以及该软件版本中无需更新的文件的链接地址。
链接地址可以具体是指各个文件的位置信息等。
根据补丁文件以及软件版本中的文件,可以确定出软件版本升级之后的升级版本中包含的文件。
由于软件版本中文件的位置,以及补丁文件包中补丁文件的位置已知,因此可以确定出构成升级版本的各个文件的链接地址。
104,触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
本申请实施例中,无需利用补丁文件更新软件版本的文件,也无需备份该软件版本中的文件。只需确定出升级版本中各个文件的链接地址,将原来运行软件版本中文件的进程,触发运行该链接地址链接的相应文件,由于链接地址链接的文件包括补丁文件(包括软件版本中需要更新的文件对应的补丁文件)以及软件版本中无需更新的文件,因此即实现了将进程运行升级版本文件的目的,从而实现了软件版本升级。进程只需切换到运行链接地址对应的文件即可, 无需停止较长的时间,因此可以减少对进程对应的业务的影响。且也无需备份文件、覆盖文件等复杂的操作,节省了升级时间,提高了升级效率。
一个进程可能并不需要运行该软件版本中的全部文件,因此,可以根据自身需求,运行各个文件的链接地址链接的相应文件。
其中,在利用补丁文件进行升级时,可以直接向运行该软件版本中文件的进程发送升级指令。运行该软件版本中文件的进程响应该升级指令,即可依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。即实现进程由运行该软件版本中需要更新的文件切换到补丁文件包中的补丁文件,从而使得软件版本中需要更新的文件均升级到补丁文件包中的补丁文件。
可以理解的是,由于本申请实施例在对软件版本进行升级的过程中,并没有利用补丁文件对原来的软件版本进行覆盖,使得原来的软件版本仍然完整保存在该设备中,这样当该补丁文件包出现异常时,可以直接将进程重新切换到运行软件版本中的文件。因此无需备份文件,也无需在补丁回退时由于先停止进程而导致业务中断时间较长,对业务造成的影响。
因此本申请实施例,在触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件之后,所述方法还包括:
检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
其中,该补丁回退指令,可以是指检测到补丁文件运行异常等情况时生成的。
可以理解的是,在实际应用中,确定针对该软件版本的补丁文件之前需要下载补丁文件包并安装。
补丁文件包安装后,该补丁文件包与该软件版本是两个独立的软件包,而确定的升级版本中各个文件的链接地址,实际上是建立了该补丁文件包与该软件版本中无需更新的文件的链接关系。
可选的,可以先将该软件版本中无需更新的文件以及该补丁文件包中的补丁文件确定为该软件版本升级之后的升级版本中包含的文件,然后确定该无需更新的文件的链接地址以及补丁文件包中补丁文件的链接地址,将该无需更新 的文件的链接地址以及补丁文件的链接地址进行组合,得到升级版本中各个文件的链接地址。
下面以一个实例来进行介绍。假设网元设备当前安装并运行为软件版本V1.01.0.0,需要利用补丁文件包中的补丁文件将该软件版本升级为升级版本V1.01.0.1。其中可以理解的是,包含能够被运行的程序文件以及运行所述程序文件过程中所产生的数据文件。在软件版本升级的过程中数据文件不会发生改变,而程序文件则可能会存在更新。
假设该软件版本中包含有程序文件software,具体包括:file1至filen。同时,该软件版本中还包括运行软件版本中产生的多个数据文件date,具体包括date1至daten,其中n为大于1的自然数。如图2所示,为该软件版本V1.0.1.0.0中包含的文件的目录示意图。
假设针对该软件版本V1.0.1.0.0的补丁文件包括补丁文件file3和fileX,其中,补丁文件file3是该软件版本V1.0.1.0.0中包含的文件file3的更新文件,而该fileX为新增的程序文件。如图3所示,示出了补丁文件包中的补丁文件的目录示意图,即该补丁文件包中包括补丁文件file3和补丁文件fileX。
将图2和图3的文件目录进行对比可以看出,原来的软件版本V1.0.1.0.0中除了程序文件file3需要发生更新外,其他文件均不需要更新。根据软件版本V1.0.1.0.0中包含的文件目录以及补丁文件包中包含的补丁文件目录,可以确定出利用该补丁文件包对该软件版本V1.0.1.0.0进行升级后,升级版本中包含的文件包括该软件版本V1.0.1.0.0中无需更新的文件,即,程序文件file1、file2、file4至filen,以及该软件版本V1.0.1.0.0中所有的数据文件;同时,升级软件版本中还包括:补丁文件包中的补丁文件file3和新增文件filex。当网元设备中安装了软件版本和该补丁文件包后,该软件版本以及补丁文件包中各个文件的链接地址便是确定的,将该软件版本中无需更新的文件的链接地址以及补丁文件的链接地址进行组合,便可以得到升级后的升级版本中包含的各个文件的链接地址。如图4所示,为软件版本中无需更新的文件与该补丁文件包中补丁文件之间的关系示意图,可知升级版本中的文件包括补丁文件以及链接的软件版本中无需更新的文件。
由以上过程也可以看出,本申请对软件版本进行升级的过程中,无需利用补丁文件覆盖该软件版本中需要更新的文件,即无需构建一个完整的升级版本,从而使得原来的该软件版本得到保留,这样在补丁文件包存在异常的情况,无需重新构建升级之前的版本,可以直接将进程切换到运行原软件版本中的文件。
其中,由于进程运行的软件版本中的文件可能无需更新,此时,该进程则可以不需要运行链接地址链接的相应文件,直接运行软件版本中的文件即可。
需要运行升级版本的进程的确定可以有多种实现方式。
在一种可能实现方式中,当根据补丁文件确定软件版本中存在需要更新的文件时,则触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件具体可以是运行所述软件版本中需要更新的文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
也即需要运行升级版本的进程可以是运行的文件为软件版本中需要更新的文件的进程。
若进程运行的软件版本中的文件无需更新,则进程可以继续运行该软件版本的文件。
当然,作为另一种可能的实现方式,在该补丁文件包中还可以有包含配置文件,该配置文件中包括用于指示运行该补丁文件包中各个补丁文件的进程信息。如,在补丁文件包中包含有补丁文件file3和fileX,在该配置文件中可以指示出由运行原来的软件版本中file3的进程A运行该补丁文件file3,由进程B运行fileX。
因此,所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件包括:
触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
在以上任意一个实施例中,当运行软件版本中的文件的进程为普通进程 时,则在触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件时,可以是触发所述普通进程终止运行,同时在所述各个文件的链接地址链接的相应文件中,重新启动所述普通进程。
当运行软件版本中的文件的进程为插进进程时,则在触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件时,可以是所述插件进程卸载运行所述软件版本中的文件的插件,并重新加载运行所述各个文件的链接地址链接的相应文件的插件。
其中,插件进程就是由多个插件或者模块组成,每个插件可以独立启动、停止、卸载、安装等。因此插件进程的一个插件升级、打补丁,只对这个插件有影响。因此可以针对插进运行的软件版本中的文件是否需要更新,来确定是否对插进进行升级。
图5为本申请实施例提供的一种软件版本升级装置一个实施例的结构示意图,该装置可以包括:
第一文件确定模块501,用于确定针对所述软件版本的补丁文件包。
第二文件确定模块502,用于依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件。
补丁文件包中补丁文件可以是需要向该软件版本中增加的文件,即补丁文件包中包含且该软件版本中不包含的文件;也可以是对软件版本中的文件进行更新的文件,即该软件版本和补丁文件包中包含的文件名称相同的文件,但是该文件中包含的数据内容不同。
通过将该补丁文件包中的补丁文件与该软件版本中包含的文件进行比较,可以确定出该软件版本中不需要更新的文件和/或需要更新的文件。
地址确定模块503,用于确定所述软件版本的升级版本中包含的各个文件的链接地址。其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址。
链接地址可以具体是指各个文件的位置信息等。
根据补丁文件以及软件版本中的文件,可以确定出软件版本升级之后的升 级版本中包含的文件。
由于软件版本中文件的位置,以及补丁文件包中补丁文件的位置已知,因此可以确定出构成升级版本的各个文件的链接地址。
升级模块501,用于触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
本申请实施例中,无需利用补丁文件更新软件版本的文件,也无需备份该软件版本中的文件。只需确定出升级版本中各个文件的链接地址,将原来运行软件版本中文件的进程,触发运行该链接地址链接的相应文件,由于链接地址链接的文件包括补丁文件(包括软件版本中需要更新的文件对应的补丁文件)以及软件版本中无需更新的文件,因此即实现了将进程运行升级版本文件的目的,从而实现了软件版本升级。进程只需切换到运行链接地址对应的文件即可,无需停止较长的时间,因此可以减少对业务的影响。且也无需备份文件、覆盖文件等复杂的操作,节省了升级时间,提高了升级效率。
一个进程可能并不需要运行该软件版本中的全部文件,因此,可以根据自身需求,运行各个文件的链接地址链接的相应文件。
由于本申请实施例在对软件版本进行升级的过程中,并没有利用补丁文件对原来的软件版本进行覆盖,使得原来的软件版本仍然完整保存在该设备中,这样当该补丁文件包出现异常时,可以直接将进程重新切换到运行软件版本中的文件。因此无需备份文件,也无需在补丁回退时由于先停止进程而导致业务中断,对业务造成的影响。
因此本申请实施例,该装置还可以包括:
回退模块,用于检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
其中,该补丁回退指令,可以是指检测到补丁文件运行异常等情况时生成的。
在实际应用中,确定针对该软件版本的补丁文件之前需要下载补丁文件包并安装。因此,该装置还可以包括:
补丁安装模块,用于下载并安装所述补丁文件。
补丁文件包安装后,该补丁文件包与该软件版本是两个独立的软件包,而确定的升级版本中各个文件的链接地址,实际上是建立了该补丁文件包与该软件版本中无需更新的文件的链接关系。
其中,由于进程运行的软件版本中的文件可能无需更新,此时,该进程则可以不需要运行链接地址链接的相应文件,直接运行软件版本中的文件即可。
需要运行升级版本的进程的确定可以有多种实现方式。
在一种可能实现方式中,当根据补丁文件确定软件版本中存在需要更新的文件时,则所述升级模块具体可以是运行所述软件版本中需要更新的文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
也即需要运行升级版本的进程可以是运行的文件为软件版本中需要更新的文件的进程。
若进程运行的软件版本中的文件无需更新,则进程可以继续运行该软件版本的文件。
当然,作为另一种可能的实现方式,在该补丁文件包中还可以有包含配置文件,该配置文件中包括用于指示运行该补丁文件包中各个补丁文件的进程信息。因此,所述升级模块可以具体用于:
触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
在上述描述中,当运行软件版本中的文件的进程为普通进程时,则升级模块可以是触发所述普通进程终止运行,同时在所述各个文件的链接地址链接的相应文件中,重新启动所述普通进程。
当运行软件版本中的文件的进程为插进进程时,则所述升级模块可以是所述插件进程卸载运行所述软件版本中的文件的插件,并重新加载运行所述各个文件的链接地址链接的相应文件的插件。
其中,插件进程就是由多个插件或者模块组成,每个插件可以独立启动、 停止、卸载、安装等。因此插件进程的一个插件升级、打补丁,只对这个插件有影响。因此可以针对插进运行的软件版本中的文件是否需要更新,来确定是否对插进进行升级。
上述实施例所述的软件版本升级装置,在实际应用中,可以集成到软件版本升级设备中,该软件版本升级设备可以是指安装软件版本,具有软件版本升级需求的网元设备等。部署本申请实施例软件版本升级装置的软件版本升级设备,进程无需停止较长的时间,因此可以检测进程对应的业务的中断时间,减少对业务的影响。且也无需备份文件、覆盖文件等复杂的操作,节省了升级时间,提高了升级效率。
通过以上描述可知,本领域的技术人员可以清楚地了解到本申请可借助软件加必需的通用硬件平台的方式来实现。因此,参见图6,本申请实施例还提供了一种软件版本升级设备,该软件版本升级设备至少包括处理器601和存储器602。
该存储器602存储一组程序指令,该存储器可以是是高速RAM存储器,也可能是非易失性存储器(non-volatile memory),例如至少一个磁盘存储器等。
该处理器601,用于调用该存储器602存储的程序指令,执行如下操作:
确定针对所述软件版本的补丁文件包;
依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
其中,该处理器可能是一个中央处理器CPU,或者是特定集成电路ASIC(Application Specific Integrated Circuit),或者是被配置成实施本发明实施例的一个或多个集成电路。
可选地,该软件版本升级设备可以用于执行本申请实施例提供的如图1 所示的软件版本升级方法。
本说明书中各个实施例采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似部分互相参见即可。对于实施例公开的装置而言,由于其与实施例公开的方法相对应,所以描述的比较简单,相关之处参见方法部分说明即可。
专业人员还可以进一步意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、计算机软件或者二者的结合来实现,为了清楚地说明硬件和软件的可互换性,在上述说明中已经按照功能一般性地描述了各示例的组成及步骤。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
结合本文中所公开的实施例描述的方法或算法的步骤可以直接用硬件、处理器执行的软件模块,或者二者的结合来实施。软件模块可以置于随机存储器(RAM)、内存、只读存储器(ROM)、电可编程ROM、电可擦除可编程ROM、寄存器、硬盘、可移动磁盘、CD-ROM、或技术领域内所公知的任意其它形式的存储介质中。
对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本申请。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本申请的精神或范围的情况下,在其它实施例中实现。因此,本申请将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。

Claims (11)

  1. 一种软件版本升级方法,其特征在于,包括:
    确定针对所述软件版本的补丁文件包;
    依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
    确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
    触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
  2. 根据权利要求1所述的方法,其特征在于,所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件之后,所述方法还包括:
    检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
  3. 根据权利要求1所述的方法,其特征在于,在所述确定针对所述软件版本的补丁文件包之前,还包括:
    下载并安装所述补丁文件。
  4. 根据权利要求1~3任一项所述的方法,其特征在于,在所述补丁文件包中还包括配置文件,所述配置文件用于指示运行补丁文件的进程;
    所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件包括:
    触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
  5. 根据权利要求1~3任一项所述的方法,其特征在于,所述触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件包括:
    当运行所述软件版本的进程为插件进程时,触发所述插件进程卸载运行所述软件版本中的文件的插件,并加载运行所述链接地址链接的文件的插件。
  6. 一种软件版本升级装置,其特征在于,包括:
    第一文件确定模块,用于确定针对所述软件版本的补丁文件包;
    第二文件确定模块,用于依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
    地址确定模块,用于确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件的链接地址;
    升级模块,用于触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
  7. 根据权利要求6所述的装置,其特征在于,还包括:
    回退模块,用于检测到补丁回退指令时,触发所述进程运行所述软件版本中的文件。
  8. 根据权利要求6所述的装置,其特征在于,还包括:
    补丁安装模块,用于下载并安装所述补丁文件。
  9. 根据权利要求6~8任一项所述的装置,其特征在于,所述升级模块具体用于:
    触发所述配置文件指示的运行所述补丁文件的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
  10. 根据权利要求6~8任一项所述的装置,其特征在于,所述升级模块具体用于:
    当运行所述软件版本的进程为插件进程时,触发所述插件进程卸载运行所述软件版本中的文件的插件,并加载运行所述链接地址链接的文件的插件。
  11. 一种软件版本升级设备,其特征在于,包括处理器以及存储器,
    所述存储器用户存储一组程序指令;
    所述处理器用于调用所述存储器的所述程序指令,执行如下操作:
    确定针对所述软件版本的补丁文件包;
    依据所述补丁文件包中的补丁文件,确定所述软件版本中无需更新的文件;
    确定所述软件版本的升级版本中包含的各个文件的链接地址,其中,所述各个文件的链接地址包括所述补丁文件的链接地址以及所述无需更新的文件 的链接地址;
    触发运行所述软件版本的进程,依据所述各个文件的链接地址,运行所述各个文件的链接地址链接的相应文件。
PCT/CN2014/086133 2014-09-09 2014-09-09 软件版本升级方法、装置及设备 WO2016037314A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201480049719.2A CN105594184B (zh) 2014-09-09 2014-09-09 软件版本升级方法、装置及设备
PCT/CN2014/086133 WO2016037314A1 (zh) 2014-09-09 2014-09-09 软件版本升级方法、装置及设备

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2014/086133 WO2016037314A1 (zh) 2014-09-09 2014-09-09 软件版本升级方法、装置及设备

Publications (1)

Publication Number Publication Date
WO2016037314A1 true WO2016037314A1 (zh) 2016-03-17

Family

ID=55458239

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2014/086133 WO2016037314A1 (zh) 2014-09-09 2014-09-09 软件版本升级方法、装置及设备

Country Status (2)

Country Link
CN (1) CN105594184B (zh)
WO (1) WO2016037314A1 (zh)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109976794A (zh) * 2019-03-31 2019-07-05 联想(北京)有限公司 更新方法、更新***以及电子设备
CN112073994A (zh) * 2020-09-03 2020-12-11 百度在线网络技术(北京)有限公司 用于空中升级的方法、装置、电子设备及可读存储介质

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2009081502A1 (ja) * 2007-12-26 2009-07-02 Fujitsu Limited 通信端末
CN102724308A (zh) * 2012-06-13 2012-10-10 腾讯科技(深圳)有限公司 软件更新方法及软件更新***
CN103631629A (zh) * 2013-12-17 2014-03-12 江苏名通信息科技有限公司 获取远程更新文件自动更新方法

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1107907C (zh) * 2000-02-21 2003-05-07 英业达股份有限公司 借由增量的方式来使数据文件升级的方法

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2009081502A1 (ja) * 2007-12-26 2009-07-02 Fujitsu Limited 通信端末
CN102724308A (zh) * 2012-06-13 2012-10-10 腾讯科技(深圳)有限公司 软件更新方法及软件更新***
CN103631629A (zh) * 2013-12-17 2014-03-12 江苏名通信息科技有限公司 获取远程更新文件自动更新方法

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109976794A (zh) * 2019-03-31 2019-07-05 联想(北京)有限公司 更新方法、更新***以及电子设备
CN112073994A (zh) * 2020-09-03 2020-12-11 百度在线网络技术(北京)有限公司 用于空中升级的方法、装置、电子设备及可读存储介质

Also Published As

Publication number Publication date
CN105594184A (zh) 2016-05-18
CN105594184B (zh) 2019-05-24

Similar Documents

Publication Publication Date Title
US10114653B2 (en) Multiple-stage bootloader and firmware for baseboard manager controller and primary processing subsystem of computing device
JP5444368B2 (ja) アプリケーション復元ポイント
US8495615B2 (en) Method, system and computer program for distributing software patches
US7703090B2 (en) Patch un-installation
US10114630B2 (en) Management of software and operating system updates required for the process of creating a virtual machine facsimile of an existing physical or virtual machine
US20130055231A1 (en) System and method for incremental software installation
EP2840492A1 (en) Method and apparatus for modifying a computer program in a trusted manner
WO2013078951A1 (zh) 软件升级方法和***
CN107783776B (zh) 固件升级包的处理方法及装置、电子设备
WO2012116637A1 (zh) ***拯救的方法及装置
US7627866B2 (en) Systems and methods for dynamic application patching
US20160328227A1 (en) Dynamically Applying A Software Patch To A Computer Program
US20110119434A1 (en) System And Method For Safely Updating Thin Client Operating System Over A Network
US20160162278A1 (en) System and method for applying an update to a device system via a system snapshot
WO2020029967A1 (zh) 一种操作***故障的修复方法和装置
US8806477B2 (en) Space efficient software package management
JP2023505844A (ja) パッケージベースリモートファームウェアアップデート
US8453141B1 (en) High performance install update
WO2016037314A1 (zh) 软件版本升级方法、装置及设备
US7555679B2 (en) System and method for computer system rejuvenation
US8132047B2 (en) Restoring application upgrades using an application restore point
TWI514279B (zh) 伺服器系統與韌體更新方法
US9348849B1 (en) Backup client zero-management
US8312472B2 (en) Program startup apparatus and method
JP2003330719A (ja) アプリケーションのバージョン/リリースコントロール方法及びシステム、クライアントpcにインストールするアプリケーションのバージョン/リリースコントロールを行なうためのコンピュータソフトウエアプログラム

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14901765

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14901765

Country of ref document: EP

Kind code of ref document: A1