A method and computer device for checking differential upgrade package

Through the automated differential upgrade package inspection method, the differential upgrade package to be tested is obtained and the user system is upgraded and inspected, which solves the problem of low efficiency and high error rate in the existing technology that differential upgrade package inspection relies on manual labor, and achieves efficient and accurate automated inspection.

CN113971035BActive Publication Date: 2025-03-11SHENZHEN TCL NEW-TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202010721976.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-07-24
Publication Date
2025-03-11
Estimated Expiration
2040-07-24

AI Technical Summary

Technical Problem

In the prior art, the inspection process of differential upgrade packages mainly relies on manual manual, which is time-consuming and labor-intensive and has a high error rate, which cannot effectively improve the inspection efficiency and accuracy.

Method used

By obtaining the differential upgrade package to be tested and upgrading the user system based on the package, if the upgrade is successful and the upgrade status of the target user system is successful, it is determined that the differential upgrade package is successfully inspected. This method does not require manual participation and realizes automated inspection.

Benefits of technology

The efficiency and accuracy of differential upgrade package inspection are improved, manual intervention is reduced, and inspection error rate is reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113971035B_ABST
    Figure CN113971035B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and computer device for verifying a differential upgrade package, the method comprising: obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package; upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained; if the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a successful status; if the upgrade status is a successful status, determining that the differential upgrade package is successfully verified. The present invention upgrades the user system according to the differential upgrade package, and if the target user system is obtained after the upgrade is completed, and the upgrade status of the target user system is a successful status, that is, the target user system can be upgraded next time, then determining that the differential upgrade package is successfully verified; the method provided by the present invention does not require manual participation, and improves the verification efficiency and accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of testing technology, and in particular to a method and computer equipment for checking a differential upgrade package. Background Art

[0002] Differential upgrade is a convenient way for users to update device firmware to repair the system. Differential upgrade is to upgrade the system based on the difference data of two different versions. Differential upgrade does not require downloading complete data packets, which can reduce the amount of network data transmission. It can also be upgraded based on the existing system, greatly saving users' upgrade time.

[0003] Before issuing the differential upgrade package, the tester needs to test the differential upgrade package to ensure that the upgrade function of the differential upgrade package is normal. At present, the test process of the differential upgrade package is basically carried out manually, which is time-consuming and labor-intensive, and the error rate of the test result is also relatively high.

[0004] Therefore, the prior art still needs to be improved and developed. Summary of the invention

[0005] In order to solve the above technical problems, the main purpose of the present invention is to provide a method for checking differential upgrade packages, which can be used to automatically check differential upgrade packages to improve the inspection efficiency and inspection accuracy.

[0006] In a first aspect, the present invention provides a method for verifying a differential upgrade package, the method comprising:

[0007] Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package;

[0008] Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained;

[0009] If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status;

[0010] If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0011] As a further improved technical solution, the step of obtaining the differential upgrade package to be checked and determining the user system to be upgraded corresponding to the differential upgrade package specifically includes:

[0012] Obtain the differential upgrade package to be tested, and read the initial version number corresponding to the differential upgrade package;

[0013] If the version number of the preset user system is inconsistent with the initial version number, obtaining a complete upgrade package corresponding to the initial version number;

[0014] The preset user system is upgraded according to the complete upgrade package to obtain the user system to be upgraded, wherein the version number of the user system to be upgraded is the initial version number.

[0015] As a further improved technical solution, the step of obtaining the differential upgrade package to be checked and determining the user system to be upgraded corresponding to the differential upgrade package further includes:

[0016] If the version number of the preset user system is consistent with the initial version number, the preset user system is used as the user system to be upgraded.

[0017] As a further improved technical solution, the step of upgrading the user system according to the differential upgrade package and detecting whether a target user system corresponding to the differential upgrade package is obtained specifically includes:

[0018] Clearing the user partition of the user system;

[0019] Based on the differential upgrade package, power-off upgrade is performed on the user system after clearing the user partition;

[0020] When the upgrade is completed, it is detected whether the upgraded user system is the target user system corresponding to the differential upgrade package.

[0021] As a further improved technical solution, when the upgrade is completed, detecting whether the upgraded user system is the target user system corresponding to the differential upgrade package, before that, it also includes:

[0022] Monitor upgrade reports;

[0023] If an upgrade report is monitored, the upgrade is determined to be complete.

[0024] As a further improved technical solution, when the upgrade is completed, detecting whether the upgraded user system is the target user system corresponding to the differential upgrade package specifically includes:

[0025] When the upgrade is complete, restart the upgraded user system;

[0026] If the upgraded user system is restarted successfully, the version number of the upgraded user system is obtained;

[0027] If the version number of the upgraded user system is consistent with the target version number corresponding to the differential upgrade package, it is determined that the target user system is obtained.

[0028] As a further improved technical solution, if the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a successful status specifically includes:

[0029] If the target user system is obtained, detecting whether the upgrade function of the target user system is in an available state;

[0030] If the upgrade function is in an available state, the upgrade state is determined to be an upgrade success state.

[0031] As a further improved technical solution, if the target user system is obtained, detecting whether the upgrade function of the target user system is in an available state specifically includes:

[0032] If the target user system is obtained, then checking whether the upgrade system can be entered;

[0033] Correspondingly, if the upgrade function is in an available state, determining that the upgrade state is an upgrade success state specifically includes:

[0034] If the entry into the upgrade system is successful, the upgrade status is determined to be an upgrade success status.

[0035] As a further improved technical solution, if the target user system is obtained, detecting whether the upgrade system can be entered specifically includes:

[0036] If the target user system is obtained, then the upgrade system is entered for the first time;

[0037] If the first entry into the upgrade system is successful, clear the data partition and restart the target user system;

[0038] If the target user system is successfully restarted, then checking whether it is possible to enter the upgraded system for a second time;

[0039] Correspondingly, if the upgrade system is successfully entered, determining that the upgrade status is an upgrade success status specifically includes:

[0040] If the second entry into the upgrade system is successful, the upgrade status is determined to be an upgrade success status.

[0041] In a second aspect, the present invention provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and wherein the processor implements the following steps when executing the computer program:

[0042] Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package;

[0043] Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained;

[0044] If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status;

[0045] If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0046] In a third aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:

[0047] Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package;

[0048] Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained;

[0049] If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status;

[0050] If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0051] Compared with the prior art, the embodiments of the present invention have the following advantages:

[0052] In an embodiment of the present invention, a differential upgrade package to be tested is obtained, and the user system to be upgraded corresponding to the differential upgrade package is determined; the user system is upgraded according to the differential upgrade package, and it is detected whether the target user system corresponding to the differential upgrade package is obtained; if the target user system corresponding to the differential upgrade package is obtained, it is detected whether the upgrade status of the target user system is a successful status; if the upgrade status is a successful status, it is determined that the differential upgrade package is successfully tested. The present invention upgrades the user system according to the differential upgrade package, and if the target user system is obtained after the upgrade is completed, and the upgrade status of the target user system is a successful status, that is, the target user system can be upgraded next time, it is determined that the differential upgrade package is successfully tested; the method provided by the present invention does not require manual participation, and improves the inspection efficiency and inspection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0053] Figure 1 is a schematic diagram of a method for checking a differential upgrade package in an embodiment of the present invention;

[0054] Figure 26 is a schematic diagram of a process of testing a plurality of differential upgrade packages according to a method for testing differential upgrade packages in an embodiment of the present invention;

[0055] Figure 3 1 is a diagram showing the internal structure of a computer device in an embodiment of the present invention. DETAILED DESCRIPTION

[0056] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0057] The inventor has found through research that before issuing the differential upgrade package, the tester needs to inspect the differential upgrade package to ensure that the upgrade function of the differential upgrade package is normal. At present, the inspection process of the differential upgrade package is basically carried out manually, which is time-consuming and labor-intensive, and the error rate of the inspection result is also relatively high.

[0058] In order to solve the above problems, in an embodiment of the present invention, a differential upgrade package to be tested is obtained, and the user system to be upgraded corresponding to the differential upgrade package is determined; the user system is upgraded according to the differential upgrade package, and it is detected whether the target user system corresponding to the differential upgrade package is obtained; if the target user system corresponding to the differential upgrade package is obtained, it is detected whether the upgrade status of the target user system is a successful status; if the upgrade status is a successful status, it is determined that the differential upgrade package is successfully tested. The present invention upgrades the user system according to the differential upgrade package, and if the target user system is obtained after the upgrade is completed, and the upgrade status of the target user system is a successful status, that is, the target user system can be upgraded next time, then it is determined that the differential upgrade package is successfully tested; the method provided by the present invention does not require manual participation, and improves the inspection efficiency and inspection accuracy.

[0059] A method for verifying a differential upgrade package provided in an embodiment of the present invention can be applied to a television device to verify a differential upgrade package for differentially upgrading a user system of the television device.

[0060] Various non-limiting embodiments of the present invention are described in detail below in conjunction with the accompanying drawings.

[0061] See also Figure 1 , shows a method for checking a differential upgrade package in an embodiment of the present invention, the method comprising:

[0062] S1. Obtain a differential upgrade package to be checked, and determine a user system to be upgraded corresponding to the differential upgrade package.

[0063] In an embodiment of the present invention, the differential upgrade package may be stored in a television device, and the differential upgrade package may be obtained from the television device to verify the obtained differential upgrade package. The differential upgrade package may be stored in an external device, and the television device is connected to the external device, and the television device may obtain the differential upgrade package from the external device to verify the obtained differential upgrade package.

[0064] In the embodiment of the present invention, the differential upgrade package is used to upgrade the user system to be upgraded, and the initial version number and the target version number can be determined according to the differential upgrade package, and the differential upgrade package is used to upgrade the user system corresponding to the initial version number to the user system corresponding to the target version number. For example, the initial version number corresponding to the differential upgrade package is A1, and the target version number corresponding to the differential upgrade package is Y. Based on the differential upgrade package, the user system corresponding to A1 can be upgraded to the user system corresponding to Y.

[0065] In an embodiment of the present invention, the version number of the user system to be upgraded is the initial version number corresponding to the differential upgrade package. In specific implementation, the user system to be upgraded is determined based on the acquired differential upgrade package. The specific process of acquiring the differential upgrade package to be tested and determining the user system to be upgraded corresponding to the differential upgrade package will be described in detail later.

[0066] S2. Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained.

[0067] In the embodiment of the present invention, the version number of the target user system is the target version number corresponding to the differential upgrade package. The initial version number corresponding to the differential upgrade package is A1, and the target version number corresponding to the differential upgrade package is Y. The differential upgrade package is recorded as A1toY, and the user system (version number A1) is upgraded according to A1toY, and it is detected whether the target user system with version number Y is obtained after the upgrade.

[0068] Specifically, before upgrading the user system, the user partition of the user system is first cleared to prevent the startup of the upgraded user system from being dependent on the data in the user partition; after clearing the user partition of the user system, the user system is upgraded according to the differential upgrade package.

[0069] After the upgrade, it is detected whether the upgraded system can be restarted successfully. If the upgraded system is successfully restarted, it is detected whether the version number of the upgraded system is consistent with the target version number. If the version number of the upgraded system is consistent with the target version number, it is determined that the target user system corresponding to the differential upgrade package is obtained. The specific process of upgrading the user system according to the differential upgrade package and detecting whether the target user system corresponding to the differential upgrade package is obtained will be described in detail later.

[0070] S3: If the target user system corresponding to the differential upgrade package is obtained, then detecting whether the upgrade status of the target user system is a success status.

[0071] In the embodiment of the present invention, the so-called detection of whether the upgrade status of the target user system is a successful status refers to detection of whether the upgrade function of the target user system is in an available status. If the upgrade function of the target user system is in an available status, it is determined that the upgrade status of the target user is a successful status; if the upgrade function of the target user system is not in an available status, it is determined that the upgrade status of the target user is not a successful status.

[0072] Specifically, if the upgrade system can be entered through the target user system, it is considered that the upgrade function of the target user system is in an available state. After entering the upgrade system, operations such as upgrading and clearing data can be selected. The user system of the television device can be upgraded next time through the upgrade system. In other words, if the target user system can be upgraded next time, it is considered that the upgrade function of the target user system is in an available state. If the target user system cannot be upgraded next time, it is considered that the upgrade function of the target user system is not in an available state. The specific process of detecting whether the upgrade state of the target user system is a successful state will be explained in detail later.

[0073] In the embodiment of the present invention, if the user system upgrade is completed, an upgrade report will be generated, that is, the user system upgrade completion can be determined according to the upgrade report. When the user system upgrade is completed, the upgraded user system is restarted for the first time.

[0074] S4. If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0075] In the embodiment of the present invention, if the upgraded user system is the target user system, and the upgrade status of the target user system is a success status, it is determined that the differential upgrade package verification is successful.

[0076] In an embodiment of the present invention, a differential upgrade package to be tested is obtained, and the user system to be upgraded corresponding to the differential upgrade package is determined; the user system is upgraded according to the differential upgrade package, and it is detected whether the target user system corresponding to the differential upgrade package is obtained; if the target user system corresponding to the differential upgrade package is obtained, it is detected whether the upgrade status of the target user system is a successful status; if the upgrade status is a successful status, it is determined that the differential upgrade package is successfully tested. The present invention upgrades the user system according to the differential upgrade package, and if the target user system is obtained after the upgrade is completed, and the upgrade status of the target user system is a successful status, that is, the target user system can be upgraded next time, it is determined that the differential upgrade package is successfully tested; the method provided by the present invention does not require manual participation, and improves the inspection efficiency and inspection accuracy.

[0077] Next, the specific process of obtaining the differential upgrade package to be checked and determining the user system to be upgraded corresponding to the differential upgrade package is introduced.

[0078] Specifically, step S1 includes:

[0079] S11. Obtain a differential upgrade package to be checked, and read an initial version number corresponding to the differential upgrade package.

[0080] In the embodiment of the present invention, the differential upgrade package to be tested is used to upgrade the user system corresponding to the initial version number to the user system corresponding to the target version number, that is, the differential upgrade package corresponds to an initial version number and a target version number, and the initial version number can be determined according to the differential upgrade package. For example, a differential upgrade package to be tested can be recorded as A1toY, the initial version number corresponding to the differential upgrade package is A1, and the target version number corresponding to the differential upgrade package is Y.

[0081] S12a. If the version number of the preset user system is inconsistent with the initial version number, obtain a complete upgrade package corresponding to the initial version number.

[0082] In an embodiment of the present invention, the preset user system is a user system that comes with the television device; the version number of the preset user system may be consistent with the initial version number, or may be consistent with the initial version number; in order to reduce repeated operations, it is first determined whether the version number of the preset user system is consistent with the initial version number. If the version number of the preset user system is inconsistent with the initial version number, it is necessary to upgrade the preset user system to obtain a user system with the initial version number.

[0083] In an embodiment of the present invention, the complete upgrade package corresponding to the initial version number is used to upgrade the preset user system to obtain the user system corresponding to the initial version number. The complete upgrade package may be stored in a television device, wherein multiple complete upgrade packages with different version numbers are stored in the television device, and the complete upgrade package corresponding to the initial version number is obtained from the multiple complete upgrade packages with different version numbers; the complete upgrade package may be stored in an external device, and the complete upgrade package corresponding to the initial version number may be first determined in the external device, and then the complete upgrade package corresponding to the initial version number is sent to the television device.

[0084] S13a. Upgrading the preset user system according to the complete upgrade package to obtain a user system to be upgraded, wherein the version number of the user system to be upgraded is the initial version number.

[0085] In the embodiment of the present invention, the complete upgrade package corresponding to the initial version number can upgrade any version of the user system to the user system corresponding to the initial version number. For example, the version number of the preset user system is A5, and the initial version number is A1. The complete upgrade package corresponding to A1 is obtained to upgrade the preset user system with version number A5 to the user system with version number A1.

[0086] S12b: If the version number of the preset user system is consistent with the initial version number, the preset user system is used as the user system to be upgraded.

[0087] In the embodiment of the present invention, step S12b and step S12a are parallel steps. In order to reduce repeated operations, if the version number of the preset user system is consistent with the initial version number corresponding to the complete upgrade package, there is no need to upgrade the preset user system, and the preset user system is directly used as the user system to be upgraded. For example, if the version number of the preset user system is A1 and the initial version number is A1, the preset user system is used as the user system to be upgraded.

[0088] Next, the specific process of upgrading the user system according to the differential upgrade package and detecting whether the target user system corresponding to the differential upgrade package is obtained is introduced.

[0089] Specifically, step S2 includes:

[0090] S21, clearing the user partition of the user system.

[0091] In an embodiment of the present invention, the data in the user partition is the user data generated by the user behavior when the TV device is running; clearing the user partition of the user system means clearing the data in the user partition. Specifically, the data in the user partition includes: data in the DATA partition, data in the system partition and data in the vendor partition. The data in the user partition does not include initial data. The initial data includes: data used to represent the identity of the TV device, such as the secret key, physical address and root certificate of the TV device. Clearing the data in the user partition includes: clearing the data in the DATA partition, the system partition and the vendor partition. After clearing the data in the user partition, it can be ensured that the startup of the upgraded user system does not depend on the data in the user partition.

[0092] S22: Power-off upgrade of the user system after clearing the user data based on the differential upgrade package.

[0093] In the embodiment of the present invention, since the user partition is cleared, the user system cannot be entered, so the user system is forcibly upgraded according to the differential upgrade package. Specifically, a forced upgrade instruction is received, and the user system is forcibly upgraded according to the differential upgrade package.

[0094] In an embodiment of the present invention, the conditions for triggering a forced upgrade instruction include: the power button of the television device is pressed and continues for a preset time, that is, when the power button of the television device is pressed and continues for a preset time, the user system is forcibly upgraded according to the differential upgrade package.

[0095] In an embodiment of the invention, the so-called "power-off upgrading the user system after clearing the user data based on the differential upgrade package" means: upgrading the user system after clearing the user data based on the differential upgrade package, and performing a power-off operation during the upgrading process; the number of times the power-off operation is performed is a preset number, and the preset number can be 5 times, or the preset number can be 3 times.

[0096] In specific implementation, if a power outage occurs during the upgrade process, it may be due to a user's misoperation that causes the system to lose power, or due to objective reasons, such as a power outage during the upgrade process; after the power is restored, the upgrade can be restarted or continued. If a power outage is performed during the upgrade process and the upgrade is still successful, it can be determined that the differential upgrade package can still complete the upgrade when a power outage occurs.

[0097] S23: When the upgrade is completed, detect whether the upgraded user system is the target user system corresponding to the differential upgrade package.

[0098] In the embodiment of the present invention, it is necessary to determine whether the upgrade is completed before step S23. Specifically, the process before step S23 includes: monitoring the upgrade report. If the upgrade report is monitored, it is determined that the user system upgrade is completed.

[0099] In the embodiment of the present invention, the upgrade report is generated by the upgrade system, and the upgrade system can be used to upgrade the user system. Enter the upgrade system (recovery) of the television device, and you can choose to upgrade, clear data and other operations in the upgrade system. If you choose to upgrade, you can upgrade the user system of the television device in the upgrade system. When the upgrade is completed, the recovery will generate an upgrade report. If the upgrade report is monitored, it is determined that the upgrade of the user system is completed.

[0100] In the embodiment of the present invention, if the upgrade report is monitored, it is determined that the upgrade is completed, and then it is detected whether the upgraded user system is the target user system corresponding to the differential upgrade package. Specifically, step S23 includes:

[0101] S231. When the upgrade is completed, restart the upgraded user system;

[0102] S232: If the restart of the upgraded user system is successful, the version number of the upgraded user system is obtained.

[0103] In an embodiment of the present invention, when the upgrade is completed, it is necessary to detect whether the upgraded user system can be started normally, and then restart the upgraded user system. Whether the upgraded user system is successfully started can be determined based on whether the power-on startup interface is entered, that is, if the power-on startup interface is entered, it is determined that the restart of the upgraded user system is successful, and if the power-on startup interface is not entered, it is determined that the restart of the upgraded user system is unsuccessful. Alternatively, it is also possible to determine whether the upgraded user system is successfully started based on whether the TV interface is entered to play the program, that is, if the TV interface is entered to play the program, it can be considered that the user system is successfully started. After determining that the restart of the upgraded user system is successful, the version number of the upgraded user system is obtained.

[0104] S233: If the version number of the upgraded user system is consistent with the target version number corresponding to the differential upgrade package, it is determined that the target user system is obtained.

[0105] In the embodiment of the present invention, it is further verified whether the differential upgrade package can upgrade the user system to the user system corresponding to the target version number. The version number of the upgraded user system is obtained to determine whether the user system is upgraded to the target version corresponding to the differential data package. For example, the initial version number corresponding to the differential upgrade package is A1, and the target version number corresponding to the differential upgrade package is A4. The user system corresponding to A1 is upgraded based on the differential upgrade package. If the upgraded user system version number is A4, it is determined that the target user system is obtained.

[0106] Next, the specific process of detecting whether the upgrade status of the target user system is a successful status if the target user system corresponding to the differential upgrade package is obtained is introduced.

[0107] Specifically, step S3 includes:

[0108] S31: If the target user system is obtained, then detect whether the upgrade function of the target user system is in an available state.

[0109] In the embodiment of the present invention, if the target user system can enter the upgrade system, it is considered that the upgrade function of the target user system is in an available state. After entering the upgrade system, operations such as upgrading and clearing data can be selected, and the user system of the television device can be upgraded next time through the upgrade system. In other words, if the target user system can perform the next upgrade, it is considered that the upgrade function of the target user system is in an available state, and if the target user system cannot perform the next upgrade, it is considered that the upgrade function of the target user system is not in an available state.

[0110] S32: If the upgrade function is in an available state, determine that the upgrade state is an upgrade success state.

[0111] In the embodiment of the present invention, if the upgrade function is in the enabled state, the upgrade state is determined to be the upgraded successful state. In step S2, it has been determined that the target user system corresponding to the differential upgrade package has been obtained, and then the upgrade state of the target user system is determined to be the upgraded successful state, that is, the user system is upgraded by the differential upgrade package, and the upgraded user system is the target version corresponding to the differential upgrade package, and the upgrade function of the upgraded user system is normal, and then it can be determined that the differential upgrade package is successfully verified.

[0112] Specifically, step S31 includes:

[0113] S311: If the target user system is obtained, then check whether it is possible to enter the upgrade system.

[0114] In the embodiment of the present invention, corresponding to step S311, in step S32, if the upgrade function is in an available state, determining that the upgrade state is an upgrade success state specifically includes:

[0115] S321: If the upgrade system is successfully entered, determine that the upgrade status is an upgrade success status.

[0116] In the embodiment of the present invention, whether the upgrade status is the upgrade success status is determined by detecting whether the upgrade system can be entered. That is, if the upgrade system can be entered, the upgrade status is determined to be the upgrade success status, that is, the target user system can be upgraded next time.

[0117] Specifically, step S311 includes:

[0118] S3111. If the target user system is obtained, then the upgrade system is entered for the first time.

[0119] In the embodiment of the present invention, if the target user system is obtained, it can be directly detected whether the upgrade system (recovery) can be entered. If the detection of whether the upgraded user system is the target user system is not performed when the upgraded user system is started up, the target user system can be restarted first (the upgrade system will be entered for the first time only after the upgraded user system is confirmed to be the target system), and then the upgrade system can be entered for the first time. In other words, the first entry into the upgrade system is entered through the user system.

[0120] S3112. If the first entry into the upgrade system is successful, clear the data partition and restart the target user system.

[0121] In the embodiment of the present invention, if the first entry into the upgrade system is successful, it is determined that the upgraded user system can be upgraded next time; after entering the upgrade system, operations such as upgrading and clearing data can be selected in the upgrade system.

[0122] Furthermore, entering the upgrade system may be related to the data in the target user system, or in other words, if there is no data in the user system, the upgrade system cannot be entered, and the data partition (DATA partition) is cleared in the upgrade system; clearing the DATA partition means clearing the data in the DATA partition. It should be noted that in step S21, before upgrading the user system according to the differential upgrade package, the data in the user partition has been cleared, and the data in the user partition includes: the data in the DATA partition, the data in the system partition, and the data in the vendor partition, that is, the data in the DATA partition has been cleared; however, between step S2 and this step, there may be data generated by user operations, and the generated data may make the first entry into the upgrade system successful.

[0123] In the embodiment of the present invention, if the first entry into the upgrade system is unsuccessful, the data partition is cleared and the target user system is restarted. However, between step S2 and this step, data may be generated by user operations, and the generated data may also cause the first entry into the upgrade system to be unsuccessful. In other words, whether the first entry into the upgrade system is successful or unsuccessful, it is necessary to clear the data partition and restart the target user system.

[0124] S3113: If the target user system is restarted successfully, then check whether the upgraded system can be entered for the second time.

[0125] In the embodiment of the present invention, it has been determined in step S232 that the upgraded user system is successfully restarted. In theory, the target user system (upgraded user system) will also be successfully restarted this time. After the target user system is successfully restarted, it is detected whether the upgraded system can be entered for the second time. In step S3112, the data partition is cleared. If the upgraded system is entered for the second time, it is determined that the upgraded system is not related to the data in the DATA partition, and the upgraded system is successfully entered.

[0126] In the embodiment of the present invention, after entering the upgrade system for the first time, the data of the user partition is not cleared. It is possible that the first entry into the upgrade system is successful, and the second entry into the upgrade system is successful and depends on the data of the user partition. After the target user system is successfully restarted, the data of the user partition is cleared. Specifically, step S3113 includes:

[0127] S31131. If the target user system is restarted successfully, the user partition is cleared and the upgrade system is entered for the second time.

[0128] In an embodiment of the present invention, if the target user system is successfully restarted, the user partition is cleared. The user partition includes partitions under the user system such as the data partition (DATA partition), the system partition (system partition), and the vendor partition. The upgraded user system may generate some data during the inspection process, and the generated data may not be completely present in the DATA partition. In an embodiment of the present invention, clearing the data in the user partition includes clearing the data of the DATA partition, the system partition, and the vendor partition, but does not include clearing the initial data, and the initial data includes: the secret key, physical address, and root certificate of the TV device, etc., which are used to represent the identity of the TV device.

[0129] In the embodiment of the present invention, if the user partition is cleared, the television device cannot start the upgraded user system. Therefore, the second entry into the upgraded system cannot be entered through the upgraded user system. After clearing the user partition, the upgraded system is directly entered.

[0130] In the embodiment of the present invention, corresponding to step S311 to step S323, in step S321, if the entry into the upgrade system is successful, determining that the upgrade status is an upgrade success status specifically includes:

[0131] S3211. If the second entry into the upgrade system is successful, determine that the upgrade status is an upgrade success status.

[0132] In the embodiment of the present invention, if the second entry into the upgrade system is successful, it means that the entry into the upgrade system does not rely on the data of the user partition, and the success of entering the upgrade system means that the upgraded user system can be upgraded next time (the upgrade function is available).

[0133] In an embodiment of the present invention, through the above-mentioned verification process, it can be ensured that the user system to be upgraded can be upgraded to the target version through the differential upgrade package, the startup of the upgraded user system does not depend on the data in the user partition, and the upgraded user system can perform the next upgrade, thereby determining that the differential upgrade package verification is successful.

[0134] In an embodiment of the present invention, there are several differential upgrade packages. When it is determined that one of the several differential upgrade packages has been successfully verified, for another differential upgrade package among the several differential upgrade packages, the steps of obtaining the differential upgrade package to be verified and determining the user system to be upgraded corresponding to the differential upgrade package are executed until it is determined that the several differential upgrade packages have been successfully verified.

[0135] Before the latest version of the user system is released, the TV device may have undergone multiple upgrades, but the version numbers of the user systems of multiple TV devices of the same model are not completely consistent. For the same model of TV devices, after the upgrade package is pushed by the server, the user chooses whether to upgrade. Some users may choose to upgrade, while others may choose not to upgrade. Therefore, there are differences in the version numbers of the user systems of the TV devices. To upgrade the user system of the TV device to the user system corresponding to the target version number, a differential upgrade package with a different initial version number is required. For example, the version numbers of the user system of the TV device may include: A1, A2, ..., An, and the target version number is Y. Then, it is necessary to deploy n differential upgrade packages such as A1toY differential upgrade package (upgrade the user system with version number A1 to the user system with version number Y), A2toY differential upgrade package (upgrade the user system with version number A2 to the user system with version number Y), and AntoY differential upgrade package (upgrade the user system with version number An to the user system with version number Y). Before the differential upgrade package is issued, it is necessary to verify the differential upgrade package, that is, there are several differential upgrade packages to be verified.

[0136] In an embodiment of the present invention, each differential upgrade package has its corresponding initial version number and target version number. The initial version numbers corresponding to any two differential upgrade packages among a number of differential upgrade packages are inconsistent, and the target version numbers corresponding to each differential upgrade package among a number of differential upgrade packages are consistent.

[0137] In an embodiment of the present invention, each of the plurality of differential upgrade packages needs to be verified, and the plurality of differential upgrade packages can be verified in sequence. Specifically, the differential upgrade packages are sorted according to the initial version numbers corresponding to the differential upgrade packages, and the plurality of differential upgrade packages are verified in sequence. The differential upgrade packages are sorted according to the initial version numbers corresponding to the differential upgrade packages, and the differential upgrade packages with smaller initial version numbers can be arranged before the differential upgrade packages with larger initial version numbers.

[0138] For example, the initial version number corresponding to the first differential upgrade package of the two differential upgrade packages is A1, and the initial version number corresponding to the second differential upgrade package of the two differential upgrade packages is A2. If the initial version number A1 is smaller than the initial version number A2, the first differential upgrade package is arranged before the second differential upgrade package. During the inspection, the first differential upgrade package is first inspected. After it is determined that the first differential upgrade package has been successfully verified, the second differential upgrade package is inspected, until it is determined that several differential upgrade packages have been successfully verified.

[0139] See also Figure 2 A method for checking a differential upgrade package provided by an embodiment of the present invention includes the following steps of checking a plurality of differential upgrade packages:

[0140] Step 1, set i=1;

[0141] Step 2: Obtain the differential upgrade package AitoY to be tested, where 1≤i≤n;

[0142] Step 3: Upgrade the entire user system package to the Ai version;

[0143] Step 4. Clear the user partition of the Ai version of the user system;

[0144] Step 5: Upgrade the user system corresponding to the Ai version number according to the differential upgrade package AitoY, and randomly cut off the power for a preset number of times during the upgrade process;

[0145] Step 6: Check whether the user system has been upgraded;

[0146] Step 7: If the user system upgrade is completed, check whether the upgraded user system can be started;

[0147] Step 8: If the upgraded user system can be started, check whether the version number of the upgraded user system is Y;

[0148] Step 9: If the version number of the upgraded user system is Y, restart the user system corresponding to Y and check whether the upgraded system can be entered;

[0149] Step 10. If you can enter the upgrade system, clear the DATA partition and check whether you can enter the user system corresponding to Y after restarting;

[0150] Step 11: If the user system corresponding to Y can be entered after restart, it is determined that the differential upgrade package verification is successful;

[0151] Step 12: Determine whether i is equal to n. If i is not equal to n, assign i+1 to i and go to step 2; if i is equal to n, end the test.

[0152] Before the differential upgrade package is issued, multiple differential upgrade packages need to be verified. In the prior art, the differential upgrade packages are all verified manually. It takes 2 hours or even more to verify one differential upgrade package. It takes several days to verify multiple differential upgrade packages, and the manual verification has a high error rate. The present invention optimizes the verification process and provides a method for verifying differential upgrade packages, which does not require manual participation and improves the inspection efficiency and inspection accuracy.

[0153] The embodiment of the present invention also provides a computer device, which may be a terminal, and the internal structure is as follows: Figure 3 . The computer device includes a processor, a memory, a network interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a method for checking a differential upgrade package is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a key, trackball or touchpad provided on the computer device housing, or an external keyboard, touchpad or mouse, etc.

[0154] Those skilled in the art will understand that Figure 3 What is shown is only a block diagram of a partial structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0155] An embodiment of the present invention provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and wherein the processor implements the following steps when executing the computer program:

[0156] Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package;

[0157] Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained;

[0158] If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status;

[0159] If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0160] The embodiment of the present invention further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:

[0161] Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package;

[0162] Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained;

[0163] If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status;

[0164] If the upgrade status is a success status, it is determined that the differential upgrade package verification is successful.

[0165] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0166] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

[0167] It should be understood that the application of the present invention is not limited to the above examples. For ordinary technicians in this field, improvements or changes can be made based on the above description. All these improvements and changes should fall within the scope of protection of the claims attached to the present invention.

Claims

1. A method for testing a differential upgrade package, characterized in that: The method comprises: Obtaining a differential upgrade package to be verified, and determining a user system to be upgraded corresponding to the differential upgrade package; Upgrading the user system according to the differential upgrade package, and detecting whether a target user system corresponding to the differential upgrade package is obtained; If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status; If the upgrade status is a success status, determining that the differential upgrade package verification is successful; If the target user system corresponding to the differential upgrade package is obtained, detecting whether the upgrade status of the target user system is a success status specifically includes: If the target user system is obtained, detecting whether the upgrade function of the target user system is in an available state; If the upgrade function is in an available state, determining that the upgrade state is an upgrade success state; If the target user system is obtained, detecting whether the upgrade function of the target user system is in an available state specifically includes: If the target user system is obtained, then checking whether the upgrade system can be entered; Correspondingly, if the upgrade function is in an available state, determining that the upgrade state is an upgrade success state specifically includes: If entering the upgrade system is successful, determining that the upgrade status is an upgrade success status; If the target user system is obtained, detecting whether the upgrade system can be entered specifically includes: If the target user system is obtained, then the upgrade system is entered for the first time; If the first entry into the upgrade system is successful, clear the data partition and restart the target user system; If the target user system is successfully restarted, then checking whether it is possible to enter the upgraded system for a second time; Correspondingly, if the upgrade system is successfully entered, determining that the upgrade status is an upgrade success status specifically includes: If the second entry into the upgrade system is successful, the upgrade status is determined to be an upgrade success status.

2. The method for checking a differential upgrade package according to claim 1, characterized in that: The obtaining of the differential upgrade package to be checked and determining the user system to be upgraded corresponding to the differential upgrade package specifically includes: Obtain the differential upgrade package to be tested, and read the initial version number corresponding to the differential upgrade package; If the version number of the preset user system is inconsistent with the initial version number, obtaining a complete upgrade package corresponding to the initial version number; The preset user system is upgraded according to the complete upgrade package to obtain the user system to be upgraded, wherein the version number of the user system to be upgraded is the initial version number.

3. The method for checking a differential upgrade package according to claim 2, characterized in that: The step of obtaining the differential upgrade package to be checked and determining the user system to be upgraded corresponding to the differential upgrade package further includes: If the version number of the preset user system is consistent with the initial version number, the preset user system is used as the user system to be upgraded.

4. The method for checking a differential upgrade package according to claim 1, characterized in that: The step of upgrading the user system according to the differential upgrade package and detecting whether a target user system corresponding to the differential upgrade package is obtained specifically includes: Clearing the user partition of the user system; Based on the differential upgrade package, power-off upgrade is performed on the user system after clearing the user partition; When the upgrade is completed, it is detected whether the upgraded user system is the target user system corresponding to the differential upgrade package.

5. The method for checking a differential upgrade package according to claim 4, characterized in that: When the upgrade is completed, detecting whether the upgraded user system is the target user system corresponding to the differential upgrade package, before that, further comprising: Monitor upgrade reports; If an upgrade report is monitored, the upgrade is determined to be complete.

6. The method for checking a differential upgrade package according to claim 4, characterized in that: When the upgrade is completed, detecting whether the upgraded user system is the target user system corresponding to the differential upgrade package specifically includes: When the upgrade is complete, restart the upgraded user system; If the upgraded user system is restarted successfully, the version number of the upgraded user system is obtained; If the version number of the upgraded user system is consistent with the target version number corresponding to the differential upgrade package, it is determined that the target user system is obtained.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Upgrading method and device of Android system

    CN106790247A

  • Module upgrading method in unmanned aerial vehicle system and module to be upgraded

    CN108958774A