CN109936609B - Terminal chain type upgrading method and device and upgrading management server - Google Patents

Terminal chain type upgrading method and device and upgrading management server Download PDF

Info

Publication number
CN109936609B
CN109936609B CN201711371086.9A CN201711371086A CN109936609B CN 109936609 B CN109936609 B CN 109936609B CN 201711371086 A CN201711371086 A CN 201711371086A CN 109936609 B CN109936609 B CN 109936609B
Authority
CN
China
Prior art keywords
terminal
upgrading
upgraded
upgrade
management server
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN201711371086.9A
Other languages
Chinese (zh)
Other versions
CN109936609A (en
Inventor
黄诚
关春天
鲍荣
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Uniview Technologies Co Ltd
Original Assignee
Zhejiang Uniview Technologies Co Ltd
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 Zhejiang Uniview Technologies Co Ltd filed Critical Zhejiang Uniview Technologies Co Ltd
Priority to CN201711371086.9A priority Critical patent/CN109936609B/en
Publication of CN109936609A publication Critical patent/CN109936609A/en
Application granted granted Critical
Publication of CN109936609B publication Critical patent/CN109936609B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)
  • Stored Programmes (AREA)

Abstract

The embodiment of the invention provides a terminal chain type upgrading method and device and an upgrading management server. Wherein the method comprises the following steps: after the terminal equipment receives the description information sent by the upgrade management server, the terminal equipment matched with the description information is used as a terminal to be upgraded to feed back first response information to the upgrade management server, so that the upgrade management server determines a preferred equipment cluster comprising at least two terminals to be upgraded. And the upgrading management server distributes the plurality of upgrading components in the upgrading package to each terminal to be upgraded in the preferred equipment cluster. And after the terminal to be upgraded receives an upgrading instruction sent by the upgrading management server, requesting an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list. All terminals to be upgraded can finally obtain all upgrading components, and the success rate of upgrading is further improved. The influence on the transmission process caused by network fluctuation is improved.

Description

Terminal chain type upgrading method and device and upgrading management server
Technical Field
The invention relates to the technical field of Internet of things, in particular to a terminal chain type upgrading method and device and an upgrading management server.
Background
The Internet of things is an important component of a new generation of information technology and is also an important development stage of the 'informatization' era. The increasing intellectualization of the internet of things cannot be updated every time, and software upgrading is the most important link. The internet of things is a network connected with objects, and a large number of devices are connected in the network, so that batch upgrading becomes a main upgrading mode.
In the related art, the batch upgrade mode is that an upgrade management server sends an upgrade package to one device for preferential upgrade. And then other devices which are not upgraded are informed to use the multicast upgrade. All the devices which are not upgraded are added into the upgrading multicast group, and the device which is preferentially upgraded sends an upgrading packet to the multicast group, so that all other devices which are not upgraded receive the upgrading version file through the multicast message. However, this method is not reliable, and once network fluctuation occurs or the device that is preferentially upgraded is disconnected, the remaining devices that are not upgraded cannot receive the complete version file, resulting in upgrade failure. Meanwhile, the equipment with the priority upgrading can not know the specific situation, and can not retransmit the upgrading packet. So that the upgrade package transmission efficiency is low and the final upgrade is not high in power.
Disclosure of Invention
The invention aims to provide a terminal chain type upgrading method, a device and an upgrading management server, which are used for solving the problems of low transmission efficiency of upgrading packets, low upgrading success rate and the like when a plurality of terminal devices are upgraded in batches.
In order to achieve the above purpose, the embodiment of the present invention adopts the following technical solutions:
in a first aspect, an embodiment of the present invention provides a terminal chain type upgrade method, which is applied to a version update system, where the system includes an upgrade management server and a plurality of terminal devices that are in communication connection with each other, and the method includes: the upgrade management server sends description information corresponding to an upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list; after receiving the description information, the terminal equipment detects whether the terminal equipment is matched with the version description information; when the terminal equipment is matched with the upgrade management server, the terminal equipment serves as a terminal to be upgraded to feed back first response information to the upgrade management server; the upgrade management server determines an optimal equipment cluster comprising at least two terminals to be upgraded according to the received first response information; the upgrade management server distributes a plurality of upgrade components corresponding to the upgrade component list in the upgrade package to each terminal to be upgraded in the preferred equipment cluster; and after the terminal to be upgraded receives the upgrading instruction sent by the upgrading management server, requesting an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list so as to upgrade the software.
In a second aspect, an embodiment of the present invention provides a terminal chain type upgrade method, which is applied to an upgrade management server, where the upgrade management server is in communication connection with a plurality of terminal devices, and the method includes: sending description information corresponding to an upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list; receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; determining a preferred equipment cluster comprising at least two terminals to be upgraded according to the received first response information; distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster; and sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required by upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list to upgrade software.
In a third aspect, an embodiment of the present invention provides a terminal chain type upgrade apparatus, which is applied to an upgrade management server, where the upgrade management server is in communication connection with a plurality of terminal devices, and the apparatus includes: the sending module is used for sending description information corresponding to the upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list; the receiving module is used for receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; a determining module, configured to determine, according to the received first response information, a preferred device cluster including at least two terminals to be upgraded; the distribution module is used for distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster; and the sending module is further used for sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list, and software upgrading is performed.
In a fourth aspect, an embodiment of the present invention provides an upgrade management server, where the upgrade management server is in communication connection with a plurality of terminal devices, and the upgrade management server includes: a memory; a processor; and a terminal chain upgrade device installed in the memory and including one or more software function modules executed by the processor, the terminal chain upgrade device including: the sending module is used for sending description information corresponding to the upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list; the receiving module is used for receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; a determining module, configured to determine, according to the received first response information, a preferred device cluster including at least two terminals to be upgraded; the distribution module is used for distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster; and the sending module is further used for sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list, and software upgrading is performed.
Compared with the prior art, the terminal chain type upgrading method provided by the invention. The method comprises the steps that the upgrade management server sends description information corresponding to an upgrade package to each terminal device, a preferred device cluster comprising at least two terminals to be upgraded is determined according to received first response information fed back by the terminals to be upgraded and matched with version description information of the description information, a plurality of upgrade components corresponding to an upgrade component list in the upgrade package are distributed to each terminal to be upgraded in the preferred device cluster, and upgrade failure caused by disconnection of a single terminal device with priority is avoided. And after the terminal to be upgraded receives the upgrading instruction sent by the upgrading management server, requesting an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list so as to upgrade the software. And each terminal to be upgraded requests other terminal equipment for the required upgrading component according to the condition of the actually obtained upgrading component so as to ensure that all the terminals to be upgraded can finally obtain all the upgrading components, thereby improving the success rate of upgrading. Meanwhile, the upgrade package is distributed in a mode of dividing the upgrade package into upgrade components, so that the occupation of bandwidth during the transmission of the upgrade components between terminal devices is reduced, and the influence on the transmission process caused by network fluctuation is also improved.
In order to make the aforementioned and other objects, features and advantages of the present invention comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained according to the drawings without inventive efforts.
Fig. 1 is a schematic structural diagram of a version updating system according to an embodiment of the present invention.
Fig. 2 is a schematic structural diagram of the upgrade management server shown in fig. 1.
Fig. 3 is a flowchart illustrating steps of a method for upgrading a chain of terminals according to an embodiment of the present invention.
Fig. 4 is a timing diagram of a method for upgrading a chain of terminals according to an embodiment of the present invention.
Fig. 5 is a flowchart of steps of a terminal chain upgrade method applied to an upgrade management server according to an embodiment of the present invention.
Fig. 6 is a schematic diagram of a terminal chain upgrade device according to an embodiment of the present invention.
Icon: 100-upgrade management server; 111-a memory; 112-a processor; 113-a communication unit; 200-a terminal device; 300-version update system; 400-terminal chain upgrade device; 401-a sending module; 402-a receiving module; 403-a determination module; 404-distribution module.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present invention, presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present invention without making any creative effort, shall fall within the protection scope of the present invention.
In the related art, when equipment in the same updating system is upgraded in batch, an upgrading packet is mainly sent to one equipment through an upgrading server for preferential upgrading. And then other devices which are not upgraded and the device components which are preferentially upgraded are notified to multicast the group. And sending the upgrade package to the non-upgraded equipment by the equipment with the priority upgrade, so that all other non-upgraded equipment receive the upgrade package through the multicast message. However, this approach is not reliable since multicast messages are transmitted in UDP format on the one hand. On the other hand, once network fluctuation occurs or the device which is preferentially upgraded is disconnected, the device which is not upgraded cannot receive the complete version file, and upgrading fails. Meanwhile, the equipment with the priority upgrading can not know the specific situation and can not retransmit the upgrading packet, so that the efficiency of the whole upgrading process is low. Therefore, the invention provides a terminal chain type upgrading method and device and an upgrading management server, which can improve the transmission efficiency and upgrading success rate of the upgrading packet, reduce the performance pressure of the upgrading management server, and realize quick, safe and controllable upgrading process.
Referring to fig. 1, an embodiment of a version updating system 300 is provided. The version-up system 300 includes an upgrade management server 100 and a plurality of terminal apparatuses 200 which are communicatively connected to each other. Specifically, the upgrade management server 100 is communicatively connected to each terminal apparatus 200, and each terminal apparatus 200 is communicatively connected to the other terminal apparatuses 200 in the terminal apparatuses 200 to which the upgrade management server 100 is communicatively connected.
The terminal device 200 may be a device having data acquisition and data processing functions and requiring the upgrade package to be obtained from the upgrade management server 100 for upgrading. For convenience of description, in the embodiment of the present invention, the terminal device 200 may be a video camera IPC or a video recorder NVR.
Referring to fig. 2, a block diagram of the upgrade management server 100 is shown. The upgrade management server 100 includes a terminal chain upgrade apparatus 400, a memory 111, a processor 112, and a communication unit 113.
The memory 111, the processor 112 and the communication unit 113 are electrically connected to each other directly or indirectly to realize data transmission or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines. The terminal chain upgrade apparatus 400 includes at least one software function module that may be stored in the memory 111 in the form of software or Firmware (Firmware) or solidified in an Operating System (OS) of the upgrade management server 100. The processor 112 is used for executing executable modules stored in the memory 111, such as software functional modules and computer programs included in the terminal chain upgrading device 400.
The Memory 111 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like. The memory 111 is used to store programs or data. The communication unit 113 is used to establish a communication connection between the upgrade management server 100 and other communication terminals through the network, and to transceive data through the network.
It should be understood that the structure shown in fig. 2 is only a schematic structural diagram of the upgrade management server 100, and the upgrade management server 100 may further include more or less components than those shown in fig. 2, or have a different configuration from that shown in fig. 2. The components shown in fig. 2 may be implemented in hardware, software, or a combination thereof.
First embodiment
Referring to fig. 3, fig. 3 is a flowchart of a method for upgrading a chain of terminals according to a preferred embodiment of the present invention. Applied to the version update system 300 shown in fig. 1. The terminal chain type upgrading method comprises the following steps:
in step S101, the upgrade management server 100 transmits description information corresponding to the upgrade package to each terminal device 200.
In an embodiment of the present invention, the description information includes version description information and an upgrade component list corresponding to the upgrade package. The version description information includes version number information, applicable model, digital signature and other information. The upgrade component list includes information of a plurality of upgrade components constituting the upgrade package, for example, the number of upgrade components, a name of each upgrade component, verification data, and the like. Alternatively, the description information may be transmitted to all the terminal apparatuses 200 communicatively connected to the upgrade management server 100 by means of multicast.
Step S102, after receiving the description information, the terminal device 200 detects whether the terminal device 200 matches the version description information.
In the embodiment of the present invention, each terminal apparatus 200 that receives the description information checks the version description information, for example, checks whether the version number information is higher than the current version number, checks whether the applicable model is consistent with itself, and checks whether the digital signature is still valid. If the verification is passed, it indicates that the version description information matches the terminal device 200. That is, the upgrade package corresponding to the description information is applicable to the terminal device 200.
Step S103, when the matching is successful, the terminal device 200 serves as the terminal to be upgraded and feeds back the first response information to the upgrade management server 100.
In the embodiment of the present invention, the terminal device 200 that is successfully matched with the version description information feeds back the first response information to the upgrade management server 100 as the terminal to be upgraded. Preferably, the terminal to be upgraded may generate the corresponding first response information according to the current load data. The load data may include, but is not limited to, a threshold number of currently connectable resources, a threshold remaining capacity, etc. of the device.
The terminal device 200 that has not successfully matched the version description information ignores the description information and does not respond.
Step S104, the upgrade management server 100 determines a preferred device cluster including at least two terminals to be upgraded according to the received first response information.
In the embodiment of the present invention, the upgrade management server 100 calculates a priority parameter corresponding to each response of the terminal to be upgraded according to each received first response information and the response speed corresponding to the first response information. As a fact, the priority parameter may be calculated according to the weight values previously given to the response time and the first response information, and the sum of the weight values of ownership is 1. For example, if the response speed is set to 50% in advance, the number-of-connectable-resources threshold value is set to 30% in advance, and the remaining-capacity threshold value is set to 20% in advance, the corresponding priority parameter is 30% × number-of-connectable-resources threshold value + 20% × remaining-capacity threshold value + 50% × response speed.
And sequencing the terminals to be upgraded according to the priority parameters from high to low, and taking the terminals to be upgraded before the arranged appointed name as a pre-equipment cluster. The specified ranking can be determined according to the total number of the terminals to be upgraded and a preset proportion, and is not less than two. For example, if the total number of the terminals to be upgraded is 100 and the preset proportion is 30%, the name is designated to be 30, that is, the terminals to be upgraded are arranged in the first 30 terminals to be upgraded according to the priority parameter to form the preferred device cluster. It should be noted that, if the designated rank is determined to be less than 2 according to the total number of the terminals to be upgraded and the preset ratio, the value is determined to be 2. Therefore, even if one terminal to be upgraded in the preferred equipment cluster fails, the whole upgrading process cannot be influenced.
Step S105, the upgrade management server 100 distributes a plurality of upgrade components corresponding to the upgrade component list in the upgrade package to each terminal to be upgraded in the preferred device cluster.
In the present embodiment, the upgrade package exists in the form of a plurality of upgrade components. The manner of distributing the plurality of upgrade components to each terminal to be upgraded in the preferred device cluster may be: and distributing the upgrading component corresponding to the upgrading packet to each terminal to be upgraded in the preferred equipment cluster according to a preset rule, so that each terminal to be upgraded in the preferred equipment cluster receives at least one upgrading component, and the same upgrading component is at least sent to two different terminals to be upgraded in the preferred equipment cluster. The preset rule may be, but is not limited to, conditional polling, conditional randomization, and allocation according to the number of receivable resources of each terminal to be upgraded in the preferred device cluster. For example, a plurality of upgrade components may be transmitted to each terminal to be upgraded in the preferred device cluster in a polling manner according to the corresponding number of receivable resources, and the transmission may be repeated at least 2 times.
Step S106, the upgrade management server 100 sends an upgrade instruction to the terminal to be upgraded.
In the embodiment of the present invention, after the upgrade management server 100 completes distribution of the plurality of upgrade components in the upgrade package, an upgrade instruction may be sent to the terminal to be upgraded.
Step S107, after the terminal to be upgraded receives the upgrade instruction sent by the upgrade management server 100, requesting an upgrade component required for upgrading from other terminal devices 200 communicatively connected to the terminal to be upgraded according to the upgrade component list.
In the embodiment of the present invention, the upgrade component required for the upgrade may be an upgrade component that is not yet upgraded corresponding to the description information of the terminal to be upgraded. For the terminal to be upgraded, the upgrade component required for upgrading is the upgrade component which is recorded in the description information but is not obtained.
As an embodiment, after the terminal to be upgraded receives the upgrade instruction sent by the upgrade management server 100, whether all corresponding upgrade components are obtained may be checked according to the upgrade component list. If the terminal to be upgraded does not obtain all the corresponding upgrading components, determining the upgrading components required by the upgrade according to the upgrading component list, and generating an obtaining request corresponding to each upgrading component required by the upgrade. For example, the obtaining request may be generated according to verification data corresponding to the upgrade component required by the upgrade in the description information. The terminal to be upgraded sequentially sends each acquisition request to all other terminal devices 200 in communication connection with the terminal to be upgraded. Specifically, the information is transmitted to the other terminal device 200 by means of multicast.
After receiving the obtaining request, the other terminal devices 200 communicatively connected to the terminal to be upgraded inquire whether the other terminal devices themselves have the upgrade components corresponding to the obtaining request, for example, compare the upgrade components that have been obtained by the other terminal devices themselves in turn. And if so, generating second response information according to the number of the connectable resources per se, and feeding back the second response information to the terminal to be upgraded which sends the acquisition request. If not, the acquisition request is ignored.
After receiving the second response information, the terminal to be upgraded determines a corresponding target request terminal from the terminal device 200 that feeds back the second response information according to the obtained second response information. Specifically, the corresponding threshold values are divided according to different grades by using the response speed and the number of connectable resources corresponding to each second response message as reference factors, and the second priority parameter is obtained by performing weight calculation. And determines the terminal device 200 corresponding to the second response information with the largest second priority parameter as the target request terminal. And the terminal to be upgraded acquires the upgrading components required by upgrading corresponding to the acquisition request from the target request terminal until all the upgrading components of the upgrading package corresponding to the description information are acquired. And upgrading is performed in sequence. Specifically, the terminal to be upgraded establishes point-to-point upgrade component transmission by using a TCP connection, and when transmission is started, the number of connectable resources of the two devices establishing connection is reduced by one. After the transmission is completed, the number of the remaining connectable resources is increased by one. In the embodiment, the upgrade component transmission adopts TCP connection, and the instruction is sent in UDP form, which not only ensures efficiency, but also increases transmission reliability.
It should be noted that, when the terminal to be upgraded receives the upgrade component, the upgrade component is verified by using the corresponding verification data in the upgrade component list. And if the verification is passed, upgrading by using the corresponding upgrading component. And if the upgrade module fails to pass the verification, deleting the corresponding upgrade module, and requesting other terminal equipment 200 in communication connection with the terminal to be upgraded to acquire the corresponding upgrade module until all correct upgrade modules are acquired.
In the embodiment of the present invention, the terminal to be upgraded acquires an upgrade component, upgrades the component according to the upgrade component, and sends a completion message to the upgrade management server 100 after upgrading all the upgrade components is completed. The transmission and the upgrading process between the upgrading components are independent, and the upgrading can be carried out without depending on the fact that the whole upgrading packet is transmitted. Thereby improving the upgrading speed. And with the gradual expansion of the upgrading process, more and more terminals to be upgraded can be provided with upgrading components, so that the overall transmission speed and the upgrading speed are faster and faster.
Further, the method may further include sending a completion message to the upgrade management server 100 when the terminal to be upgraded completes upgrading of all the upgrade components corresponding to the description information. When the upgrade management server 100 receives the completion packet fed back by all the terminals to be upgraded, it sends a deletion instruction corresponding to the upgrade packet to all the terminals to be upgraded. And the terminal to be upgraded deletes the corresponding upgrade package according to the received deletion instruction.
Taking an upgrade management server 100, a version update system 300 composed of a plurality of cameras IPC and a hard disk recorder NVR as an example, the present embodiment is described, as shown in fig. 4, the method includes:
step S1: the upgrade management server 100 sends description information to IPC1, IPC2, IPC3, IPC4 and NVR in a multicast mode, and the version description information corresponding to the description information comprises an applicable model of IPC. The upgrade package comprises three upgrade components of Config, Media and Basic.
Step S2: IPC1, IPC2, IPC3, and IPC4 generate first response information according to their own load data and feed back to the upgrade management server 100, and NVR ignores the description information.
Step S3: the upgrade management server 100 calculates priority parameters corresponding to IPC1, IPC2, IPC3 and IPC4 according to the received first response information, arranges the priority parameters from high to low, selects the top 3 IPC2, IPC3 and IPC4 as preferred equipment clusters, and sends Config and Media to the IPC 2; sending Media and Basic to IPC 3; config and Basic are sent to IPC 4.
Step S4: the upgrade management server 100 sends an upgrade instruction to IPC1, IPC2, IPC3, and IPC 4.
Step S5: and the IPC2 determines that the upgrade component required by the upgrade is Basic according to the upgrade component list in the description information, and sends an acquisition request corresponding to the Basic to the IPC1, the IPC3, the IPC4 and the NVR in a multicast mode.
Step S6: IPCs 3 and 4 have Basic, and generate a second response message to IPC 2.
Step S7: the IPC2 selects the IPC3 as a target request terminal according to the second response information sent by the IPC3 and the IPC4, and establishes connection to obtain Basic. IPC1, IPC3 and IPC4 also obtain three upgrading components of Config, Media and Basic and complete upgrading in the manner of steps S5-S7.
Step S8: IPC1, IPC2, IPC3, and IPC4 feed back a completion message to the upgrade management server 100.
Step S9: the upgrade management server 100 sends a delete instruction to IPCs 1, 2, 3 and 4, and controls IPCs 1, 2, 3 and 4 to delete the Config, Media and Basic upgrade components.
Second embodiment
Referring to fig. 5, fig. 5 is a flowchart illustrating a method for upgrading a chain of terminals according to a preferred embodiment of the present invention. Applied to the upgrade management server 100 shown in fig. 1, the method includes:
step S201, sending description information corresponding to an upgrade package to each of the terminal devices 200, where the description information includes version description information and an upgrade component list corresponding to the upgrade package.
In an embodiment of the present invention, the description information includes version description information and an upgrade component list corresponding to the upgrade package. The version description information includes version number information, applicable model, digital signature and other information. The upgrade component list includes information of a plurality of upgrade components constituting the upgrade package, for example, the number of upgrade components, a name of each upgrade component, verification data, and the like. Alternatively, the description information may be transmitted to all the terminal apparatuses 200 communicatively connected to the upgrade management server 100 by means of multicast.
Step S202, receiving first response information fed back by the terminal to be upgraded in the terminal device 200.
In the embodiment of the invention, the terminal to be upgraded is matched with the version description information. Each terminal apparatus 200 that has received the description information checks the version description information, for example, whether the version number information is higher than the current version number, whether the applicable model is consistent with itself, and whether the digital signature is still valid. If the verification is passed, it indicates that the version description information matches the terminal device 200. That is, the upgrade package corresponding to the description information is applicable to the terminal device 200.
Step S203, determining a preferred device cluster including at least two terminals to be upgraded according to the received first response information.
In the embodiment of the present invention, the upgrade management server 100 calculates a priority parameter corresponding to each response of the terminal to be upgraded according to each received first response information and the response speed corresponding to the first response information. As a fact, the priority parameter may be calculated according to the weight values previously given to the response time and the first response information, and the sum of the weight values of ownership is 1. And sequencing the terminals to be upgraded according to the priority parameters from high to low, and taking the terminals to be upgraded before the arranged appointed name as a pre-equipment cluster. The specified ranking can be determined according to the total number of the terminals to be upgraded and a preset proportion, and is not less than two.
Step S204, distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster.
In an embodiment of the present invention, the upgrade package exists in the form of a plurality of upgrade components. The manner of distributing the plurality of upgrade components to each terminal to be upgraded in the preferred device cluster may be: and distributing the upgrading component corresponding to the upgrading packet to each terminal to be upgraded in the preferred equipment cluster according to a preset rule, so that each terminal to be upgraded in the preferred equipment cluster receives at least one upgrading component, and the same upgrading component is at least sent to two different terminals to be upgraded in the preferred equipment cluster.
Step S205, sending an upgrade instruction to the terminal to be upgraded, so that the terminal to be upgraded requests an upgrade component required for upgrading from other terminal devices 200 communicatively connected to the terminal to be upgraded according to the upgrade component list, so as to perform software upgrade.
Third embodiment
Referring to fig. 6, a terminal chain upgrade apparatus 400 according to a preferred embodiment of the present invention is provided. Applied to the upgrade management server 100 shown in fig. 1, the terminal chain upgrade apparatus 400 includes: a sending module 401, a receiving module 402, a determining module 403 and a distributing module 404.
A sending module 401, configured to send description information corresponding to the upgrade package to each terminal device 200, where the description information includes version description information and an upgrade component list corresponding to the upgrade package.
A receiving module 402, configured to receive first response information fed back by a terminal to be upgraded in the terminal device 200, where the terminal to be upgraded is matched with the version description information.
A determining module 403, configured to determine, according to the received first response information, a preferred device cluster including at least two terminals to be upgraded.
A distributing module 404, configured to distribute, to each terminal to be upgraded in the preferred device cluster, the plurality of upgrade components in the upgrade package corresponding to the upgrade component list.
The sending module 401 is further configured to send an upgrade instruction to the terminal to be upgraded, so that the terminal to be upgraded requests an upgrade component required for upgrading from other terminal devices 200 communicatively connected to the terminal to be upgraded according to the upgrade component list, so as to perform software upgrade.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working process of the apparatus described above may refer to the corresponding process in the foregoing method embodiment, and is not described herein again.
In summary, the invention provides a terminal chain type upgrading method and device and an upgrading management server. Wherein the method comprises the following steps: the upgrade management server sends description information corresponding to an upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list; after receiving the description information, the terminal equipment detects whether the terminal equipment is matched with the version description information; when the terminal equipment is matched with the upgrade management server, the terminal equipment serves as a terminal to be upgraded to feed back first response information to the upgrade management server; the upgrade management server determines an optimal equipment cluster comprising at least two terminals to be upgraded according to the received first response information; the upgrade management server distributes a plurality of upgrade components corresponding to the upgrade component list in the upgrade package to each terminal to be upgraded in the preferred equipment cluster; and after the terminal to be upgraded receives the upgrading instruction sent by the upgrading management server, requesting an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list so as to upgrade the software. Thereby reducing the performance pressure of the server and avoiding single point failures. The terminal devices mutually acquire the upgrading components and are unfolded in a chain mode, point-to-point transmission is achieved, and reliability, transmission efficiency and success rate are improved. Meanwhile, the upgrade patch is disassembled into components, the transmission and upgrade processes are independent, the upgrade can be performed after the transmission of the whole file is completed, and the upgrade speed is improved. With the gradual expansion of the upgrading process, more and more devices can transmit the component packages, and the overall transmission speed and the upgrading speed can be faster and faster. The establishment model considers factors such as network conditions, the number of connectable resources and the like, establishes reasonable connection dynamically according to the performance of each device and the network conditions, balances the load pressure of each device and enables the upgrading process to be smoother.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus embodiments described above are merely illustrative, and for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, the functional modules in the embodiments of the present invention may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (8)

1. A terminal chain type upgrading method is characterized in that the method is applied to a version updating system, the system comprises an upgrading management server and a plurality of terminal devices which are in communication connection with each other, and the method comprises the following steps:
the upgrade management server sends description information corresponding to an upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list;
after receiving the description information, the terminal equipment detects whether the terminal equipment is matched with the version description information;
when the terminal equipment is matched with the upgrade management server, the terminal equipment serves as a terminal to be upgraded to feed back first response information to the upgrade management server; the first response information is generated by the terminal to be upgraded according to current load data, and the load data comprises: the current connectable resource number threshold and the residual capacity threshold of the terminal equipment to be upgraded; the upgrade management server generates a corresponding priority parameter of the terminal to be upgraded according to the response speed corresponding to the first response information, the threshold value of the number of connectable resources and the respective weight value of the threshold value of the residual capacity;
determining at least two corresponding terminals to be upgraded as preferred equipment clusters according to the priority parameters;
the upgrade management server distributes a plurality of upgrade components corresponding to the upgrade component list in the upgrade package to each terminal to be upgraded in the preferred equipment cluster;
and after the terminal to be upgraded receives the upgrading instruction sent by the upgrading management server, requesting an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list so as to upgrade the software.
2. The method of claim 1, wherein the step of the upgrade management server distributing a plurality of upgrade components corresponding to the upgrade component list in the upgrade package to each terminal to be upgraded in the preferred device cluster comprises:
and distributing the upgrading component corresponding to the upgrading packet to each terminal to be upgraded in the preferred equipment cluster according to a preset rule, so that each terminal to be upgraded in the preferred equipment cluster receives at least one upgrading component, and the same upgrading component is at least sent to two different terminals to be upgraded in the preferred equipment cluster.
3. The method of claim 2, wherein after the terminal to be upgraded receives the upgrade instruction sent by the upgrade management server, the step of requesting an upgrade component required for upgrading from other terminal devices communicatively connected to the terminal to be upgraded according to the upgrade component list comprises:
after the terminal to be upgraded receives an upgrade instruction sent by the upgrade management server, checking whether all corresponding upgrade components are obtained or not according to the upgrade component list;
if all the corresponding upgrading components are not obtained, determining the upgrading components required by upgrading according to the upgrading component list, and generating an obtaining request corresponding to each upgrading component required by upgrading;
the terminal to be upgraded sequentially sends each acquisition request to other terminal equipment in communication connection with the terminal to be upgraded so as to acquire second response information, wherein the second response information is generated and fed back by the terminal equipment which receives the acquisition request and is provided with an upgrading assembly required by upgrading corresponding to the acquisition request;
the terminal equipment determines a corresponding target request terminal from the terminal equipment which feeds back the second response information according to the acquired second response information;
and the terminal to be upgraded acquires an upgrading component required by upgrading corresponding to the acquisition request from the target request terminal so as to finish upgrading.
4. The method of claim 3, wherein the method further comprises:
when the terminal to be upgraded receives the upgrading component, verifying the upgrading component by using corresponding checking data in the upgrading component list;
if the verification is passed, upgrading by using the corresponding upgrading component;
and if the upgrade module does not pass the verification, deleting the corresponding upgrade module, and requesting other terminal equipment in communication connection with the terminal to be upgraded to acquire the corresponding upgrade module.
5. The method of claim 3, wherein the method comprises:
when the terminal to be upgraded finishes the upgrading of all the upgrading components corresponding to the description information, sending a completion message to the upgrading management server;
when the upgrade management server receives the completion messages fed back by all the terminals to be upgraded, sending a deletion instruction corresponding to the upgrade package to all the terminals to be upgraded;
and the terminal to be upgraded deletes the corresponding upgrade package according to the received deletion instruction.
6. A terminal chain type upgrading method is applied to an upgrading management server which is in communication connection with a plurality of terminal devices, and comprises the following steps:
sending description information corresponding to an upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list;
receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; the first response information is generated by the terminal to be upgraded according to current load data, and the load data comprises: the current connectable resource number threshold and the residual capacity threshold of the terminal equipment to be upgraded;
generating a priority parameter of the corresponding terminal to be upgraded according to the response speed corresponding to the first response information, the threshold value of the number of connectable resources and the respective weight value of the threshold value of the residual capacity;
determining at least two corresponding terminals to be upgraded as preferred equipment clusters according to the priority parameters; distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster;
and sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required by upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list to upgrade software.
7. A terminal chain upgrading device is applied to an upgrading management server which is in communication connection with a plurality of terminal devices, and comprises:
the sending module is used for sending description information corresponding to the upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list;
the receiving module is used for receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; the first response information is generated by the terminal to be upgraded according to current load data, and the load data comprises: the current connectable resource number threshold and the residual capacity threshold of the terminal equipment to be upgraded; a determining module, configured to generate a corresponding priority parameter of the terminal to be upgraded according to a response speed corresponding to the first response information, the threshold of the number of connectable resources, and a weight value of each of the threshold of the remaining capacity; determining at least two corresponding terminals to be upgraded as preferred equipment clusters according to the priority parameters;
the distribution module is used for distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster;
and the sending module is further used for sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list, and software upgrading is performed.
8. An upgrade management server, wherein the upgrade management server is communicatively connected to a plurality of terminal devices, the upgrade management server comprising:
a memory;
a processor; and
a terminal chain upgrade device installed in the memory and including one or more software function modules executed by the processor, the terminal chain upgrade device comprising:
the sending module is used for sending description information corresponding to the upgrade package to each terminal device, wherein the description information comprises version description information corresponding to the upgrade package and an upgrade component list;
the receiving module is used for receiving first response information fed back by a terminal to be upgraded in the terminal equipment, wherein the terminal to be upgraded is matched with the version description information; the first response information is generated by the terminal to be upgraded according to current load data, and the load data comprises: the current connectable resource number threshold and the residual capacity threshold of the terminal equipment to be upgraded; a determining module, configured to generate a corresponding priority parameter of the terminal to be upgraded according to a response speed corresponding to the first response information, the threshold of the number of connectable resources, and a weight value of each of the threshold of the remaining capacity; determining at least two corresponding terminals to be upgraded as preferred equipment clusters according to the priority parameters;
the distribution module is used for distributing a plurality of upgrading components corresponding to the upgrading component list in the upgrading package to each terminal to be upgraded in the preferred equipment cluster;
and the sending module is further used for sending an upgrading instruction to the terminal to be upgraded so that the terminal to be upgraded requests an upgrading component required for upgrading from other terminal equipment in communication connection with the terminal to be upgraded according to the upgrading component list, and software upgrading is performed.
CN201711371086.9A 2017-12-19 2017-12-19 Terminal chain type upgrading method and device and upgrading management server Active CN109936609B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711371086.9A CN109936609B (en) 2017-12-19 2017-12-19 Terminal chain type upgrading method and device and upgrading management server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711371086.9A CN109936609B (en) 2017-12-19 2017-12-19 Terminal chain type upgrading method and device and upgrading management server

Publications (2)

Publication Number Publication Date
CN109936609A CN109936609A (en) 2019-06-25
CN109936609B true CN109936609B (en) 2021-11-16

Family

ID=66983192

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711371086.9A Active CN109936609B (en) 2017-12-19 2017-12-19 Terminal chain type upgrading method and device and upgrading management server

Country Status (1)

Country Link
CN (1) CN109936609B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110875850B (en) * 2019-09-27 2022-07-29 深圳市中电数通智慧安全科技股份有限公司 Firmware upgrading method and system, readable storage medium and terminal equipment
CN113141267B (en) * 2020-01-19 2023-06-20 阿里巴巴集团控股有限公司 Firmware upgrading and information processing method, device and equipment
CN111399886A (en) * 2020-04-13 2020-07-10 上海依图网络科技有限公司 Method and system for rapidly upgrading equipment

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101447884B (en) * 2007-11-26 2011-08-03 华为技术有限公司 Method for achieving software upgrade by cooperation among network elements, equipment and system therefor
CN101478556B (en) * 2007-12-31 2014-12-17 突触计算机系统(上海)有限公司 Method and apparatus for downloading peer-to-peer transmitted data slice
US8209220B2 (en) * 2008-06-27 2012-06-26 Microsoft Corporation Online services offer management
CN102694674A (en) * 2011-03-25 2012-09-26 华为技术有限公司 Upgrading method in access network, apparatus and access network thereof
CN104199679A (en) * 2014-08-01 2014-12-10 百度在线网络技术(北京)有限公司 Method and device used for obtaining updating
CN104468697B (en) * 2014-10-10 2018-05-04 浙江广播电视集团 A kind of radio station data transfer loads distribution method
CN104994265B (en) * 2015-07-06 2019-02-15 浙江宇视科技有限公司 A kind of web camera batch upgrading method and system
CN107040399B (en) * 2016-02-04 2022-03-15 京东方科技集团股份有限公司 Method, device and system for downloading upgrade file
CN106657383B (en) * 2017-01-12 2021-03-19 腾讯科技(深圳)有限公司 Data downloading method and related equipment

Also Published As

Publication number Publication date
CN109936609A (en) 2019-06-25

Similar Documents

Publication Publication Date Title
CN108833521B (en) Message pushing method, device, system, computer equipment and storage medium
CN107483627B (en) File distribution method, file download method, distribution server, client and system
CN109995866B (en) Distributed file verification method and device, computer device and storage medium
CN107465548A (en) The dispositions method and device of code
WO2019076037A1 (en) Firmware updating method and device
CN109862101B (en) Cross-platform application starting method and device, computer equipment and storage medium
CN108055157B (en) Service node acquisition method and device
CN109936609B (en) Terminal chain type upgrading method and device and upgrading management server
EP3076290B1 (en) Method and device for remotely updating application program
CN110532077B (en) Task processing method and device and storage medium
RU2554570C2 (en) Method and system for executing services on server and client of client-server architecture
CN112000355A (en) Method and device for firmware upgrading and household appliance
CN113504922B (en) Robot software upgrading method and device, bridge server and upgrading server
WO2015127850A1 (en) Data upgrading method and central server
CN112069154B (en) etcd distributed database automatic operation and maintenance method and related device
CN110855746A (en) Middleware management method, electronic device and storage medium
CN111654399A (en) Networking method, device and equipment based on SD-WAN and storage medium
CN114070733A (en) Consensus method, device and system based on block chain network
CN109150981B (en) Block chain network networking method, device, equipment and computer readable storage medium
US20130227162A1 (en) Management of Data Upload Speed
CN111147585A (en) Equipment upgrading method, device, storage medium and system
CN115174389A (en) Upgrading method, device, equipment and readable storage medium
CN110474954B (en) Block chain-based file sharing method and device, computer equipment and readable storage medium
CN113268278A (en) Configuration verification synchronization method and device, electronic device and storage medium
CN111880864A (en) Model calling method, system, computer equipment and storage medium based on HTTP

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant