System updating method and device, electronic equipment and storage medium

By pre-stored the initial data and incremental snapshot data of the system update in the terminal device, and merging these data during the system update process to free up storage space, the system update failure problem caused by insufficient storage space is solved, and the efficiency and user experience of system updates are improved.

CN119597538APending Publication Date: 2025-03-11XIAN WINGTECH INFORMATION TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411584039.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-07
Publication Date
2025-03-11

AI Technical Summary

Technical Problem

During the system update process, due to the space occupied by the upgrade package and intermediate data, the remaining space of the UserData partition is insufficient, and the problem of being stuck in the startup logo or loop restart occurs, and there is a lack of effective means to avoid this situation.

Method used

The terminal device pre-stores the initial data used for system updates and the incremental snapshot data generated during the system update process. By obtaining target operation instructions, the initial data and incremental snapshot data are merged to generate update data, and the incremental snapshot data is deleted to free up storage space.

Benefits of technology

It effectively solves the problem of system update failure caused by insufficient storage space, improves system update efficiency, and improves users' experience and satisfaction during system update.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119597538A_ABST
    Figure CN119597538A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a system updating method and device, electronic equipment and a storage medium, the method is applied to terminal equipment, and the terminal equipment stores initial data used for system updating and incremental snapshot data generated in the system updating process in advance. The method comprises the steps of obtaining a target operation instruction when it is detected that the terminal equipment is in a system updating state; in response to the target operation instruction, combining the initial data with the incremental snapshot data to obtain update data for system update, and deleting the incremental snapshot data; and completing the system updating according to the updating data. By implementing the embodiment of the invention, the problem of system updating failure of the terminal equipment caused by insufficient storage space in the prior art can be solved, the system updating failure rate is reduced, and the experience and satisfaction of a user in the system updating process are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminal technology, and in particular to a system updating method, device, electronic device and storage medium. Background Art

[0002] With the continuous development of science and technology, the system updates of terminal devices are becoming more and more frequent. At present, OTA (Over-the-Air Technology) air download upgrade is one of the most widely used system upgrade methods. Generally speaking, users only need to click the "Upgrade" button to automatically download and install the new version of the system or application. Compared with traditional manual upgrades, OTA upgrades are more efficient and convenient. First, it allows users to update vulnerabilities or errors in the device in a timely manner to ensure the stability and security of the device. Secondly, OTA upgrades can also enable devices to have new functions or features, further improving user experience. In addition, OTA upgrades can also promote the development of related industrial chains and enhance the competitiveness and innovation capabilities of the entire smart hardware industry.

[0003] However, in the actual operation of system updates, the update process is prone to get stuck at a certain step, such as getting stuck at the boot logo interface of the desktop of the new system or having a cyclic restart problem, resulting in reduced system update efficiency. However, current technology lacks effective means to avoid this situation, and there is no proper solution when stuck in this dilemma.

[0004] The upgrade package downloaded by the system update will occupy the user's UserData partition space. In addition, some intermediate data will be generated during the upgrade process, which will also occupy the data of the UserData partition.

[0005] In actual use, users may store a large amount of data in the UserData partition, such as photos taken by taking photos, audio files produced by recording, and music downloaded by music apps. This results in the UserData partition having very little remaining space due to the space occupied by the upgrade package and intermediate data during the system upgrade. When this happens, during the process of upgrading and restarting to enter the new system, the device may not meet the startup conditions due to insufficient space, and may become stuck at the boot logo or restart in a loop. However, current technology lacks effective means to avoid this situation, and there is no proper solution when stuck in this dilemma. Summary of the invention

[0006] The embodiments of the present application disclose a system update method, device, electronic device and storage medium, which can improve the problem of low system update efficiency during the system update process and improve the user experience and satisfaction during the system update process.

[0007] In a first aspect, an embodiment of the present application discloses a system update method, which is applied to a terminal device, wherein the terminal device pre-stores initial data for system update and incremental snapshot data generated during the system update process, and the method includes:

[0008] When it is detected that the terminal device is in a system update state, obtaining a target operation instruction;

[0009] In response to the target operation instruction, merging the initial data with the incremental snapshot data to obtain update data for system update, and deleting the incremental snapshot data;

[0010] The system update is completed according to the update data.

[0011] As an optional implementation manner, in the first aspect of this embodiment, the acquiring the target operation instruction includes:

[0012] Detect preset trigger operations;

[0013] In response to the preset trigger operation, displaying a target interface in a recovery mode, wherein the target interface includes a target control for generating the target operation instruction;

[0014] Detecting a selection operation on the target control and acquiring the target operation instruction.

[0015] As an optional implementation manner, in the first aspect of this embodiment, the acquiring the target operation instruction includes:

[0016] The target operation instruction sent from an associated electronic device is acquired, where the associated electronic device is an electronic device that establishes a communication connection with the terminal device.

[0017] As an optional implementation, in the first aspect of this embodiment, the preset trigger operation includes: a pressing operation on a target physical button included in the terminal device; and / or an access operation of other electronic devices through a universal serial bus USB interface.

[0018] As an optional implementation manner, in the first aspect of this embodiment, the incremental snapshot data is the incremental snapshot data generated before the target step of the system update;

[0019] The obtaining target operation instruction comprises:

[0020] In the case where an abnormality occurs in a target step, generating the target operation instruction, wherein the target step is any one of the multiple steps in the system update process;

[0021] The step of completing the system update according to the update data includes:

[0022] According to the update data, the system update is continued from the target step.

[0023] As an optional implementation manner, in the first aspect of this embodiment, the target step is a step of restarting to a desktop after the system update, the incremental snapshot data generated during the system update process is the incremental snapshot data generated before the step of restarting to the desktop after the system update, and the completing the system update according to the update data includes:

[0024] According to the update data, reboot to the desktop after the system update to complete the system update.

[0025] As an optional implementation, in the first aspect of this embodiment, the abnormality of the target step includes that the execution time of the target step exceeds a preset time period or at least part of the preset interface content cannot be displayed.

[0026] A second aspect of an embodiment of the present application discloses a system update device, in which initial data for system update and incremental snapshot data generated during the system update process are pre-stored, and the device includes:

[0027] An acquisition module, used to acquire a target operation instruction when detecting that the terminal device is in a system update state;

[0028] an execution module, configured to, in response to the target operation instruction, merge the initial data with the incremental snapshot data to obtain update data for system update, and delete the incremental snapshot data;

[0029] An updating module is used to complete the system update according to the update data.

[0030] A third aspect of an embodiment of the present application discloses an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the processor implements the method described above.

[0031] A fourth aspect of an embodiment of the present application discloses a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the method described above when executed by a processor.

[0032] Compared with the related art, the embodiments of the present application include at least the following beneficial effects:

[0033] When the terminal device detects that the terminal device is in a system update state, it obtains a target operation instruction, and in response to the target operation instruction, merges the initial data used for the system update and the incremental snapshot data generated during the system update process to obtain the update data for the system update, and deletes the incremental snapshot data, thereby freeing up user storage space, so that there is storage space for the incremental snapshot files generated during the system update process, thereby effectively improving the problem of getting stuck in a certain update link due to insufficient space during the upgrade process, resulting in update failure, improving system update efficiency, and improving user experience and satisfaction during the system update process. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0035] Figure 1 A flow chart of a system updating method in one embodiment;

[0036] Figure 2 A flow chart of a method for obtaining a target operation instruction in one embodiment;

[0037] Figure 3 A schematic diagram of a target interface in a recovery mode in an embodiment;

[0038] Figure 4 A schematic diagram of a system update process in an embodiment;

[0039] Figure 5 is a block diagram of a system updating device in one embodiment;

[0040] Figure 6 FIG. 4 is a structural block diagram of an electronic device in an embodiment. DETAILED DESCRIPTION

[0041] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0042] In order to facilitate the clear description of the technical solutions of the embodiments of the present application, in the embodiments of the present application, the words "first" and "second" are used to distinguish the same items or similar items with substantially the same functions and effects. For example, the first instruction and the second instruction are to distinguish different user instructions, and their order is not limited. Those skilled in the art can understand that the words "first" and "second" do not limit the quantity and execution order, and the words "first" and "second" do not necessarily limit them to be different.

[0043] It should be noted that, in this application, words such as "exemplarily" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplarily" or "for example" in this application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present related concepts in a specific way.

[0044] In addition, "at least one" means one or more, and "plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b and c can mean: a, or b, or c, or a and b, or a and c, or b and c, or a, b and c, where a, b, c can be single or multiple.

[0045] In addition, the terms "including" and "having" and any variations thereof in the embodiments of the present application and the accompanying drawings are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units that are inherent to these processes, methods, products, or devices.

[0046] There are two main ways to update the user system. One is OTA upgrade, which is to download the upgrade package data file to the terminal device through WIFI or data channel to start the system update process. The other is SD card upgrade, which is to download the new version of the SD card upgrade package on the electronic device provider's website through the network on the computer, and then copy the upgrade package to the electronic device to start the system update process.

[0047] OTA upgrade is a convenient and fast way to upgrade devices through wireless networks. Generally speaking, users only need to click the "Upgrade" button to automatically download and install the new version of the system or application. Compared with traditional manual upgrades, OTA upgrades are more efficient and convenient. OTA upgrades bring many benefits to users. First, it allows users to update vulnerabilities or errors in the device in a timely manner to ensure the stability and security of the device. Secondly, OTA upgrades can also enable devices to have new functions or features, further improving the user experience. In addition, OTA upgrades can also promote the development of related industrial chains and enhance the competitiveness and innovation capabilities of the entire smart hardware industry.

[0048] During the system update process, it is common to create snapshots to back up the current state of the system so that it can be restored to the state before the update if there is a problem with the update. During the system update process, the upgrade data is read into the content. This process usually involves incremental updates of the data, that is, incremental snapshot data is generated. Incremental update is a data synchronization mechanism that only updates or inserts data that has changed since the last update, rather than the entire data set. The benefits of this are that it can save time and resources, reduce database load, and avoid data conflicts.

[0049] However, during the OTA upgrade process, if the user has stored a large amount of photos, videos, music, documents and other data in the user data storage space (UserData partition), and the upgrade process takes up some space to save the data required for the upgrade, such as the upgrade package and the intermediate data generated during the upgrade process (such as the incremental snapshot files mentioned above), it may cause insufficient storage space in the terminal device system, and thus fail to meet the requirements of the upgrade and restart, causing the system update to be stuck at a certain step, such as the step of restarting to the desktop of the new system, ultimately leading to the failure of the system update.

[0050] The embodiments of the present application provide a system update method, device, electronic device and storage medium, which can improve the problem of system update failure caused by insufficient storage space during the system update process, reduce the system update failure rate, and improve the user experience and satisfaction during the system update process.

[0051] See also Figure 1 , Figure 1 is a flow chart of a system updating method in an embodiment, which can be applied to a terminal device. Figure 1 In the corresponding embodiment scenario, the terminal device has started a system update operation, and during the update process, incremental snapshot data generated during the update process is created and stored. Therefore, the terminal device pre-stores initial data for the system update and the incremental snapshot data generated during the system update process, such as Figure 1 As shown, the method may include the following steps:

[0052] Step 101, when it is detected that the terminal device is in a system update state, a target operation instruction is obtained.

[0053] The terminal devices involved in the embodiments of the present application may include general handheld electronic terminals, such as mobile phones, smart phones, portable terminals, terminals, personal digital assistants (PDA), portable multimedia players (Personal Media Player, PMP) devices, laptop computers, notebooks (Note Pad), wireless broadband (Wireless Broadband, Wibro) terminals, tablet computers (personal computers, PC), smart PCs, sales terminals (Point of Sales, POS) and vehicle-mounted computers, etc.

[0054] In some embodiments, the terminal device will automatically check whether there are available system updates when connected to the network. If an available system update is detected, the device will notify the user. The notification method may include a pop-up window, a system notification bar prompt, or an update logo displayed in the settings menu. The user can also manually trigger the system update detection. Usually, there will be an option of "system update" or "software update" in the device's settings menu. After the user clicks this option, the device will immediately start checking whether there are available updates. Alternatively, the terminal device will automatically start checking for new versions after entering the system update interface. When a new version is found, the version number of the new version, the size of the upgrade package file, and the update content of the new version are displayed, and a button operation is given to the user to start the update. The user clicks the install button to start the update process.

[0055] During the system update process, users can initiate update requests through the system update tool, or the system can connect to the server and check for available updates. After the update is identified, the upgrade package is downloaded from the network to the terminal. After the download is complete, the system verifies the data integrity and security of the upgrade package, which is usually done through the digital signature and hash value of the upgrade package to ensure that the file has not been tampered with. After the verification is complete, the data in the upgrade package is read and used to start updating the programs and data on the terminal. The data of the upgrade package is updated to the snapshot file to be restored to the state before the update when the update fails. During the update process, the system will verify the correctness of the update data written to each partition of the terminal in real time. If an error is found, the system may roll back to the previous state to avoid system damage. After the system update is completed, the terminal device attempts to restart to the desktop with the new system. If it can successfully restart to the desktop, it means that the new system can be used and the user is reminded that the upgrade is successful. Otherwise, the user is reminded that the upgrade failed. After the upgrade is successful, the upgrade data and the incremental snapshot data will be merged.

[0056] The system update state is the state of any step in the above-mentioned system update process. The inventor has found in his research that when the system is detected to be in the update state, if a system update failure occurs, a target operation instruction can be sent to the terminal device by optimizing the upgrade. The target operation instruction instructs the terminal device to release storage space by merging data to meet the space requirements of the system update. The name of the target operation instruction can be freely set, for example: an instruction to optimize the upgrade data, which is not limited in the embodiment of the present invention. In system operation, recovery mode usually exists as an independent option in the operating system startup menu. It is a special startup option of the operating system, which allows the user to troubleshoot and repair the system when problems occur. In recovery mode, the system usually runs in a limited mode, loading only the most basic services and drivers so that the user can access the file system, repair damaged files or reinstall the operating system. The user can choose to enter normal mode or recovery mode when the system starts. Therefore, the terminal device obtains the target operation instruction. In some embodiments, the user can trigger the entry into the recovery mode by clicking a specific button, menu option or touch gesture on the screen of the terminal device. In the recovery mode, the option control of the target operation instruction is presented to the user, and the user can trigger a specific operation instruction through a combination of physical buttons, such as long pressing the power button and the volume button to confirm the system update or enter the recovery mode. In addition, for terminal devices that support voice assistants, users can also issue target operation instructions through voice commands. In addition, target operation instructions can also be triggered through other terminal devices, which are not specifically limited in the embodiments of the present application.

[0057] Step 102 : In response to the target operation instruction, the initial data and the incremental snapshot data are merged to obtain update data for system update, and the incremental snapshot data is deleted.

[0058] In some embodiments, the initial data is the basic data for system update pre-stored by the terminal device, which usually includes the basic files and configuration information of the system, and is the stable state data of the system under a specific version. The incremental snapshot data is generated during the system update process, and it records the difference data between the current system version and the target update version. For example, the specific data changes corresponding to the addition of new functions and the repair of vulnerabilities. In response to the target operation instruction, the terminal device performs a merge operation of the snapshot data. The process of merging the initial data with the latest incremental snapshot data is usually achieved by overwriting the data in the same position as the incremental snapshot in the initial data. For example, if a data block in the incremental snapshot is in the same position as a data block in the initial data, then the data block in the initial data will be overwritten by the data block in the incremental snapshot. After the merge is completed, the system will delete the original incremental snapshot data and automatically release the corresponding storage space. The merged data contains all the contents of the initial data and all changes in the incremental snapshot data, that is, the updated data for system update.

[0059] In an embodiment of the present application, before the initial data and the incremental snapshot data are merged, the terminal device has downloaded the upgrade package and updated the data of the upgrade package into the snapshot file, and calculated the target checksum based on the incremental snapshot data written to the terminal and the current snapshot data, and compared this target checksum result with the expected checksum in the upgrade package. When the target checksum is the same as the expected checksum, it is determined that the incremental data verification is successful, and a prompt message indicating that the data verification is successful is output.

[0060] In some embodiments, the checksum is usually a value obtained by calculating the data through a specific algorithm. Common checksum algorithms include CRC (cyclic redundancy check), MD5 (message digest algorithm 5), SHA (secure hash algorithm), etc. The expected checksum in the upgrade package is an expected checksum calculated by the developer using the same checksum algorithm when making the upgrade package. By comparing the target checksum calculated by the terminal device with the expected checksum in the upgrade package, it can be determined whether the updated data is complete and correct. If the two checksums are the same, it means that the data extracted from the upgrade package has no errors or damage in the process of updating to the snapshot file, and the incremental data verification is successful. When it is determined that the incremental data verification is successful, the terminal device will output a prompt message that the data verification is successful. The prompt message can be presented in various forms, such as displaying a message on the screen, issuing a sound prompt, recording in the system log, etc. After the data verification is successful, the terminal device can continue with the next step of the system update, such as installing the update, restarting the system, etc. At the same time, the user can also decide whether to continue the system update based on the prompt message.

[0061] Step 103, completing the system update according to the update data.

[0062] In some embodiments, once the initial data and the incremental snapshot data are successfully merged into the update data, the terminal device can start to apply the update data to complete the system update. This usually involves writing the update data to the system's storage device, replacing old files and data, and updating the system configuration. In the process of applying the update data, the system may need to restart or perform some specific initialization steps to ensure that the new system state can take effect correctly. After the system update is completed, the terminal device can provide the user with a prompt message indicating that the update is complete.

[0063] By adopting the above embodiment, the terminal device can, when in a system update state, respond to the target operation instruction, merge the initial data used for system update and the incremental snapshot data generated during the system update process to obtain the update data for system update, and delete the incremental snapshot data, thereby freeing up user storage space, solving the problem of terminal device system update failure due to insufficient storage space in the prior art, reducing the system update failure rate, and improving the user experience and satisfaction during the system update process.

[0064] During the process of upgrading and restarting the terminal device, the system update may be stuck in one of the update steps due to insufficient user storage space. For example, the restart condition cannot be met during the restart and the system is stuck in the boot interface. The embodiment of the present application provides a system update method. There are many ways for the terminal device to obtain the target operation instruction. The embodiment of the present invention enters the recovery mode to present the selection control of the target operation instruction to the user. In response to the target operation instruction, the initial data and the incremental snapshot data are merged in the recovery mode, and the incremental snapshot data is deleted to solve the above problem. The following is a detailed description of this process.

[0065] See also Figure 2 , Figure 2 FIG. 1 is a flow chart of a method for obtaining a target operation instruction in an embodiment. Figure 2 As shown, the method may include the following steps:

[0066] Step 201: Detect a preset trigger operation.

[0067] In an embodiment of the present application, the preset trigger operation includes: a pressing operation on a target physical button included in the terminal device; and / or an access operation of other electronic devices through a universal serial bus USB interface. The target physical button can be a combination of existing buttons on the device, such as a power button, a volume button, etc., or it can be an independent specific button. The pressing operation of the target physical button can be a simultaneous pressing operation of the power button and the volume up and down buttons. The user can also press the power button, the volume up button, the volume down button and other buttons in a specific order to trigger system update-related operations. In addition, you can also use a long press of a button combined with other buttons. For example, after long pressing the power button for a period of time, press the volume up button or the volume down button to trigger a specific function.

[0068] Other electronic devices access operations through the universal serial bus USB interface. In practice, specific operations can be triggered by short-circuiting signals on the USB data line, booting of other USB plug-in device drivers, or booting of specific landmark files, executable programs, or images in the file system of the USB device. For example, when a user short-circuits the USB data line, a specific pin in the USB data line can be short-circuited, so that the terminal device detects a specific signal change, thereby triggering a corresponding operation or starting a corresponding interface; when a specific USB device is inserted, the driver of the device can interact with the system of the terminal device, send specific instructions to the terminal device, trigger specific events, or put the terminal device into a specific mode; in addition, if there are specific landmark files, executable programs, or images in the file system of the USB device, when the terminal device is connected to this USB device, it can detect these specific contents and respond according to preset rules. For example, a file with a specific name is placed in the USB storage device. When the terminal device recognizes this file, it will trigger the terminal to enter the restart or recovery mode interface. Alternatively, a specially designed executable program can be automatically run when the terminal device is connected to the USB device and guide the terminal device into a specific mode. Similarly, a specific image file can also be recognized by the terminal device and used to start a specific interface.

[0069] Step 202, in response to a preset trigger operation, displaying a target interface in a recovery mode, wherein the target interface includes a target control for generating a target operation instruction;

[0070] As mentioned above, recovery mode is a special operating mode of a terminal device. When the operating system of a terminal device fails, crashes, or cannot start normally, recovery mode can provide some tools and options to repair the system. For example, you can check and repair system files, clear cache and temporary files, repair damaged partitions, etc., which helps to restore the stability and normal operation of the system and avoid data loss or device unusability due to system failure.

[0071] In the embodiment of the present application, the target interface schematic diagram in the recovery mode is as follows Figure 3 As shown, it can be understood that the recovery mode may include multiple interfaces, each of which may include multiple controls, such as restart system controls, clear data controls, backup data controls, hardware diagnostic controls, etc., wherein the interface that includes the target control for generating the target operation instruction is the target interface, and the specific arrangement and type of the multiple controls in the recovery mode interface are not specifically limited here. The user can switch between different interfaces of the recovery mode interface by sliding a finger on the touch screen or using an input device such as a mouse. This sliding operation can be horizontal sliding, vertical sliding or diagonal sliding, or the user can use a mouse wheel or touchpad to perform a sliding operation.

[0072] In some embodiments, the target control may be a menu item of "optimize and upgrade data". When the user slides to the interface containing the target control, the target control will be highlighted or have a special visual effect. The user can select the target control by clicking or touching, and then the terminal device performs the corresponding operation. In some other embodiments, the user can also select the target control by pressing a physical button. For example, the user can switch between different interfaces in the recovery mode and select the target control by pressing the volume up / down button of the terminal device in conjunction with the power button. In the terminal device, the physical buttons may also include direction keys, confirmation keys, return keys, etc. After the terminal device enters the recovery mode, the system will automatically set the focus on the first control. The user can use the direction keys to move the focus between different controls, and then press the confirmation key to select the target control. The return key can be used to return to the previous menu or cancel the current operation.

[0073] Step 203: Detect a selection operation on a target control and obtain a target operation instruction.

[0074] In some embodiments, when the terminal device enters the recovery mode interface, the system will continue to detect the user's selection operation on the target control, which can be achieved in a variety of ways, such as monitoring mouse click events, keyboard input events or touch screen touch events, and physical button pressing operations. When the user interacts with the target control, the system will immediately detect this operation and obtain the corresponding target operation instruction. As an optional implementation, the user can also select the target control and perform operations through voice instructions. The system needs to detect voice input and convert it into corresponding selection operations and operation instructions. In addition to traditional mouse, keyboard and touch operations, the system can also detect user gestures and actions through devices such as cameras, select target controls and interact through specific gestures, and the embodiments of this application are not specifically limited here. For each control, the system predefines a set of corresponding operation instructions. When the terminal device detects the selection operation of the control, the system obtains the corresponding operation instruction according to the pre-set mapping relationship. For example, in an embodiment of the present application, once the terminal device detects the user's selection operation on the target control, the system obtains the target operation instruction for performing the merge of initial data and incremental snapshot data, and deleting the incremental snapshot data.

[0075] Using the above embodiment, the user can obtain the target operation instruction by selecting the target control in the recovery mode interface. This method provides the user with an intuitive and efficient operation method, and the operation in the recovery mode is relatively independent of the normal system operating environment, which provides additional protection for data security operations.

[0076] In the embodiment of the present application, the method for obtaining the target operation instruction is not limited to the form of selecting the target control in the target interface of the recovery mode, but can also be to obtain the target operation instruction sent from the associated electronic device, and the associated electronic device is an electronic device that establishes a communication connection with the terminal device. The communication connection between the terminal device and the associated electronic device can be realized by a variety of technologies, such as Bluetooth connection, Wi-Fi direct connection, USB cable connection, sound wave connection, infrared communication connection, NFC (near field communication) and other short-distance communication technologies. For the case where the distance is far or the connection needs to be made through the network, the Internet communication protocol, such as TCP / IP, can also be used to achieve cross-network device connection. The associated electronic device may include but is not limited to general handheld electronic terminals, such as mobile phones, smart phones, portable terminals, tablet computers, smart watches, smart bracelets, laptops, etc. After the communication connection is established, the associated electronic device can generate and send the target operation instruction to the terminal device according to the user's operation, the state change of the device itself, or the preset rules. After receiving these instructions, the terminal device will parse and process them, and then perform the corresponding operation. For example, after the terminal device receives the target operation instruction sent by the associated electronic device, it performs the merge operation of the initial data and the incremental snapshot data, and deletes the incremental snapshot data.

[0077] By adopting the above-mentioned embodiment, the associated electronic device can send target operation instructions to the terminal device through a variety of connection methods, providing users with more operation methods. Especially when the terminal device itself fails and cannot display the target interface normally, the user can use the associated electronic device to send target operation instructions, thereby improving the convenience and flexibility of system upgrades.

[0078] See also Figure 4 , Figure 4 FIG. 1 is a schematic diagram of a system update process in an embodiment. Figure 4 As shown, when it is detected that the terminal device is in a system update state, a target operation instruction is obtained; when an abnormality occurs in the target step, a target operation instruction is generated, wherein the target step is any one of multiple steps in the system update process; in response to the target operation instruction, the initial data and the incremental snapshot data are merged to obtain update data for the system update, and the incremental snapshot data is deleted; according to the update data, the system update is continued from the target step.

[0079] In an embodiment of the present application, the terminal device will continuously monitor whether there is a specific instruction requirement during the system update process. If an abnormality occurs in any of the multiple steps in the system update process, the terminal device will respond to a preset trigger operation and display a target interface in recovery mode. The target interface includes a target control for generating target operation instructions. The terminal device detects the selection operation of the target control and generates a target operation instruction in recovery mode, or receives a target operation instruction sent by an associated electronic device.

[0080] In some embodiments, the incremental snapshot data is the incremental snapshot data generated before the target step of the system update, and the terminal device responds to the target operation instruction by merging the initial data with the incremental snapshot data generated before the target step of the system update to obtain the update data for the system update, and deletes the incremental snapshot data. In some other embodiments, the target step may be a step of restarting to the desktop after the system update, and the incremental snapshot data generated during the system update process is the incremental snapshot data generated before the step of restarting to the desktop after the system update.

[0081] During the system update process, the target step may have an exception, including the target step execution time exceeding the preset time or failing to display at least part of the preset interface content. For example, when restarting, the computer is stuck at the boot interface and cannot be successfully restarted, or the desktop after the system update cannot be displayed. The terminal device completes the merge operation of the initial data and the incremental snapshot data according to the target operation instruction, deletes the incremental snapshot data, and then continues to complete the system update from the target step according to the obtained update data, for example, restarts to the desktop after the system update to complete the system update according to the obtained update data.

[0082] In some embodiments, before the terminal device merges the initial data with the incremental snapshot data, it compares the initial data with the incremental snapshot data to determine the location that needs to be merged, and integrates the initial data with the incremental snapshot data based on the comparison result. For the file system, the updated file needs to replace the old file, or the incremental part needs to be added to the original file. For the system configuration, the new parameter value needs to be merged with the old configuration to ensure that the system can run normally after the update.

[0083] By adopting the above embodiment, during the system update process, abnormal situations can be discovered in time through real-time monitoring of the target step, and by obtaining the target operation instruction and executing the target operation, a merge operation of the initial data and the incremental snapshot data is performed in the recovery mode. After the data is merged, the incremental snapshot data is deleted in time, thereby avoiding data redundancy and freeing up the user's storage space, so that the system update process can be completed smoothly. After the target operation is completed, the system can restart the update from the target step, reducing the probability of update failure due to insufficient user storage space.

[0084] It should be understood that, although the steps in the above-mentioned flowcharts are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the above-mentioned flowcharts may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these sub-steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.

[0085] See also Figure 5 , Figure 5 is a block diagram of a system updating device in an embodiment. The system updating device 500 pre-stores initial data for system updating and incremental snapshot data generated during the system updating process. The system updating device can be applied to terminal electronic devices, such as Figure 5 As shown, the system updating device 500 may include an acquisition module 510 , an execution module 520 and an updating module 530 .

[0086] The acquisition module 510 is used to acquire the target operation instruction when it is detected that the terminal device is in the system update state;

[0087] An execution module 520, configured to, in response to the target operation instruction, merge the initial data with the incremental snapshot data to obtain update data for system update, and delete the incremental snapshot data;

[0088] The updating module 530 is used to complete the system updating according to the updating data.

[0089] In some embodiments, the acquisition module 510 is specifically configured to:

[0090] Detect preset trigger operations;

[0091] In response to the preset trigger operation, displaying a target interface in a recovery mode, wherein the target interface includes a target control for generating the target operation instruction;

[0092] Detecting a selection operation on the target control and acquiring the target operation instruction.

[0093] In some embodiments, the acquisition module 510 is specifically configured to:

[0094] Acquire the target operation instruction sent from an associated electronic device, where the associated electronic device is an electronic device that establishes a communication connection with the terminal device;

[0095] Detecting a pressing operation on a target physical key included in the terminal device; and / or an access operation of other electronic devices through a universal serial bus USB interface.

[0096] In some embodiments, the incremental snapshot data is the incremental snapshot data generated before the target step of the system update, and the acquisition module 510 is specifically used to:

[0097] In the event that an abnormality occurs in a target step, the target operation instruction is generated, wherein the target step is any one of the multiple steps in the system update process.

[0098] The updating module 530 is specifically used for:

[0099] According to the update data, the system update is continued from the target step.

[0100] In some embodiments, the target step is a step of restarting to a desktop after the system update, and the incremental snapshot data generated during the system upgrade process is the incremental snapshot data generated before the step of restarting to a desktop after the system update. The update module 530 is specifically used to:

[0101] According to the update data, reboot to the desktop after the system update to complete the system update.

[0102] In an embodiment of the present application, the terminal device can, when in a system update state, respond to a target operation instruction, merge the initial data used for the system update and the incremental snapshot data generated during the system update process to obtain update data for the system update, and delete the incremental snapshot data, thereby freeing up user storage space, solving the problem of terminal device system update failure due to insufficient storage space in the prior art, reducing the system update failure rate, and improving the user experience and satisfaction during the system update process.

[0103] See also Figure 6 , Figure 6 is a structural block diagram of an electronic device in an embodiment, such as Figure 6 As shown, the electronic device 600 may include: a memory 610, a processor 620, a network interface 630 and other components. Those skilled in the art will understand that Figure 6 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.

[0104] The memory 610 can be used to store software programs and modules, and the processor 620 executes various functional applications and data processing of the electronic device by running the software programs and modules stored in the memory 610. The memory 610 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device (such as audio data, a phone book, etc.), etc. In addition, the memory 610 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0105] The processor 620 is the control center of the electronic device. It uses various interfaces and lines to connect various parts of the entire electronic device. By running or executing software programs and / or modules stored in the memory 610, and calling data stored in the memory 610, it performs various functions of the electronic device and processes data, thereby monitoring the electronic device as a whole. Optionally, the processor 620 may include one or more processing units; preferably, the processor 620 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface, and application programs, and the modem processor mainly processes wireless communications. It is understandable that the above-mentioned modem processor may not be integrated into the processor 620.

[0106] The network interface 630 is a component in an electronic device that is responsible for data exchange and communication, so that the device can communicate data with other devices or networks. In an embodiment of the present application, the network interface 630 is used to download an upgrade package from the network to a terminal device, and to establish a communication connection with an associated electronic device, and to receive a target operation instruction sent from an associated electronic device. The network interface 630 may include a wired network interface, such as an Ethernet interface, and may also include a wireless network interface, such as a WIFI interface, a Bluetooth interface, a USB network interface, a mobile network interface, an NFC (near field communication) interface, etc. In addition, the network interface 630 may also support a variety of communication protocols and standards to ensure seamless connection with different types of devices and networks. For example, it may support common network protocols such as TCP / IP, HTTP, FTP, and specific communication protocols such as Bluetooth, ZigBee, and LoRa. At the same time, the network interface 630 may also perform protocol conversion and adaptation so that devices of different protocols can also communicate with each other.

[0107] In some embodiments, the electronic device 600 can communicate with other electronic devices or servers through a communication network. The communication network can be a wired network or a wireless network. For example, the communication network can be a local area network (LAN) or a wide area network (WAN), such as the Internet. When the communication network is a local area network, exemplarily, the communication network can be a short-range communication network such as a wireless fidelity (Wi-Fi) hotspot network, a Wi-Fi P2P network, a Bluetooth network, a zigbee network, or a near field communication (NFC) network. When the communication network is a wide area network, exemplarily, the communication network can be a third generation wireless telephone technology (3G) network, a fourth generation mobile communication technology (4G) network, a fifth generation mobile communication technology (5G) network, a future-evolved public land mobile network (PLMN) or the Internet, etc.

[0108] In one embodiment, when the computer program stored in the memory 610 is executed by the processor 620, the processor 620 implements the methods described in the above embodiments.

[0109] An embodiment of the present application discloses a computer-readable storage medium storing a computer program, wherein the computer program implements the methods described in the above embodiments when executed by a processor.

[0110] An embodiment of the present application discloses a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program can be executed by a processor to implement the methods described in the above embodiments.

[0111] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing related hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium, and when the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The storage medium can be a disk, an optical disk, a ROM, etc.

[0112] As used herein, any reference to memory, storage, database, or other medium may include nonvolatile and / or volatile memory. Suitable nonvolatile memory may include ROM, programmable ROM (Programmable ROM, PROM), erasable PROM (Erasable PROM, EPROM), electrically erasable PROM (Electrically Erasable PROM, EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which is used as an external cache memory. By way of illustration and not limitation, RAM may be in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), memory bus direct RAM (RDRAM) and direct memory bus dynamic RAM (DRDRAM).

[0113] It should be understood that "one embodiment" or "an embodiment" mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. Those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily required by the present application. It should be noted that "multiple" in the present application includes "two or more".

[0114] In the various embodiments of the present application, it should be understood that the size of the serial numbers of the above-mentioned processes does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0115] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0116] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0117] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described 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.

[0118] The above is a detailed introduction to a system update method, device, electronic device and storage medium disclosed in the embodiments of the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method and core idea of ​​the present application. At the same time, for those of ordinary skill in the art, according to the idea of ​​the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A system updating method, characterized in that: Applied to a terminal device, the terminal device pre-stores initial data for system update and incremental snapshot data generated during the system update process, the method comprising: When it is detected that the terminal device is in a system update state, obtaining a target operation instruction; In response to the target operation instruction, merging the initial data with the incremental snapshot data to obtain update data for system update, and deleting the incremental snapshot data; The system update is completed according to the update data.

2. The method according to claim 1, characterized in that The obtaining target operation instruction comprises: Detect preset trigger operations; In response to the preset trigger operation, displaying a target interface in a recovery mode, wherein the target interface includes a target control for generating the target operation instruction; Detecting a selection operation on the target control and acquiring the target operation instruction.

3. The method according to claim 1, characterized in that The obtaining target operation instruction comprises: The target operation instruction sent from an associated electronic device is acquired, where the associated electronic device is an electronic device that establishes a communication connection with the terminal device.

4. The method according to claim 2, characterized in that: The preset trigger operation includes: a pressing operation on a target physical key included in the terminal device; and / or an access operation of other electronic devices through a universal serial bus USB interface.

5. The method according to any one of claims 1 to 4, characterized in that: The incremental snapshot data is the incremental snapshot data generated before the target step of the system update; The obtaining target operation instruction comprises: In the case where an abnormality occurs in a target step, generating the target operation instruction, wherein the target step is any one of the multiple steps in the system update process; The step of completing the system update according to the update data includes: According to the update data, the system update is continued from the target step.

6. The method according to claim 5, characterized in that The target step is a step of restarting to a desktop after the system update, the incremental snapshot data generated during the system update process is the incremental snapshot data generated before the step of restarting to a desktop after the system update, and completing the system update according to the update data includes: According to the update data, reboot to the desktop after the system update to complete the system update.

7. The method according to claim 5, characterized in that The abnormality of the target step includes that the execution time of the target step exceeds the preset time length or at least part of the preset interface content cannot be displayed.

8. A system updating device, characterized in that: The system update device pre-stores initial data for system update and incremental snapshot data generated during the system update process, and the device includes: An acquisition module, used to acquire a target operation instruction when detecting that the terminal device is in a system update state; an execution module, configured to, in response to the target operation instruction, merge the initial data with the incremental snapshot data to obtain update data for system update, and delete the incremental snapshot data; An updating module is used to complete the system update according to the update data.

9. A terminal electronic device, characterized in that: The terminal electronic device comprises a memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the processor implements the method according to any one of claims 1 to 7.

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

Citation Information

Cited By

  • OSTree rollback method and device and storage medium

    CN119883302A