Data backup method and device, equipment and storage medium

By monitoring the storage space's preset directory and automatically backup, the problem of manual operation and low efficiency in the existing technology is solved, and efficient and accurate data backup is achieved.

CN119690739APending Publication Date: 2025-03-25BEIJING KINGSOFT CLOUD NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311238256.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-09-22
Publication Date
2025-03-25

AI Technical Summary

Technical Problem

The existing data backup method needs to be manually performed by users, which takes a long time, is inefficient, and is prone to backup errors and data loss, resulting in poor backup accuracy.

Method used

By monitoring whether new target data appears in each preset directory of the storage space, obtain the identification of the target directory when new data appears, and automatically backup the target data based on the preset backup strategy to obtain the first backup data.

Benefits of technology

Automatic backup of data is realized according to preset backup strategies, improving the efficiency and integrity of data backup and improving the accuracy of backup data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119690739A_ABST
    Figure CN119690739A_ABST
Patent Text Reader

Abstract

The invention relates to a data backup method and device, equipment and a storage medium. The method comprises the following steps: monitoring whether newly-added target data appears in each preset directory of a storage space or not; in response to newly added target data in the at least one preset directory, taking the preset directory to which the target data belongs as a target directory, and obtaining a target directory identifier of the target directory; based on a preset mapping relationship between the target directory identifier and a data backup strategy, determining a target backup strategy corresponding to the target directory identifier; and backing up the target data based on the target backup strategy to obtain the first backup data corresponding to the target data, so that the data can be automatically backed up according to the preset backup strategy, manual participation in the backup process is not needed, the data backup efficiency and the backup data integrity are improved, and the data backup accuracy is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of data processing technology, and in particular to a data backup method, device, equipment and storage medium. Background Art

[0002] Nowadays, in order to prevent data loss, it is very important to back up data.

[0003] In the related data backup methods, users are usually required to perform backup manually. The backup process is time-consuming, inefficient, and prone to backup errors and data loss. The accuracy of data backup is poor. Summary of the invention

[0004] In order to solve the above technical problems, the present disclosure provides a data backup method, device, equipment and storage medium.

[0005] A first aspect of the present disclosure provides a data backup method, comprising:

[0006] Monitor whether newly added target data appears in each preset directory of the storage space;

[0007] In response to newly added target data appearing in at least one preset directory, taking the preset directory to which the target data belongs as the target directory, and obtaining a target directory identifier of the target directory;

[0008] Determine the target backup strategy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup strategy;

[0009] The target data is backed up based on the target backup strategy to obtain first backup data corresponding to the target data.

[0010] A second aspect of the present disclosure provides a data backup device, comprising:

[0011] The first monitoring module is used to monitor whether newly added target data appears in each preset directory of the storage space;

[0012] A first acquisition module is used for, in response to the presence of newly added target data in at least one preset directory, taking the preset directory to which the target data belongs as a target directory, and acquiring a target directory identifier of the target directory;

[0013] A first determination module, configured to determine a target backup policy corresponding to the target directory identifier based on a preset mapping relationship between the target directory identifier and the data backup policy;

[0014] The first backup module is used to back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0015] A third aspect of the present disclosure provides a computer 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 data backup method of the first aspect can be implemented.

[0016] A fourth aspect of the present disclosure provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the data backup method of the first aspect can be implemented.

[0017] Compared with the prior art, the technical solution provided by the present invention has the following advantages:

[0018] The present invention monitors whether new target data appears in each preset directory of the storage space; in response to the appearance of the new target data in at least one preset directory, takes the preset directory to which the target data belongs as the target directory, and obtains the target directory identifier of the target directory; based on the preset mapping relationship between the target directory identifier and the data backup strategy, determines the target backup strategy corresponding to the target directory identifier; backs up the target data based on the target backup strategy to obtain the first backup data corresponding to the target data, and can automatically back up the data according to the preset backup strategy without manual participation in the backup process, thereby improving the backup efficiency and integrity of the backup data and improving the accuracy of the data backup. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0020] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0021] Figure 1 is a flow chart of a data backup method provided by an embodiment of the present disclosure;

[0022] Figure 2 is a flow chart of another data backup method provided by an embodiment of the present disclosure;

[0023] Figure 3 is a flow chart of another data backup method provided by an embodiment of the present disclosure;

[0024] Figure 4 is a flow chart of another data backup method provided by an embodiment of the present disclosure;

[0025] Figure 5is a flow chart of another data backup method provided by an embodiment of the present disclosure;

[0026] Figure 6 is a structural schematic diagram of a data backup device provided by an embodiment of the present disclosure;

[0027] Figure 7 It is a structural diagram of a computer device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0028] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.

[0029] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.

[0030] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.

[0031] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0032] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".

[0033] The data backup method provided by the embodiments of the present disclosure may be executed by a computer device, which may be understood as any device with processing and computing capabilities, and may include but is not limited to mobile terminals such as smart phones, laptops, personal digital assistants (PDAs), tablet computers (PADs), portable multimedia players (PMPs), vehicle-mounted terminals, wearable devices, etc., as well as fixed electronic devices such as digital TVs, desktop computers, smart home devices, etc.

[0034] In order to better understand the inventive concept of the embodiments of the present disclosure, the technical solutions of the embodiments of the present disclosure are described below in conjunction with exemplary embodiments.

[0035] Figure 1 is a flow chart of a data backup method provided by an embodiment of the present disclosure, such as Figure 1 As shown, the data backup method provided in this embodiment includes the following steps:

[0036] Step 110: monitor whether newly added target data appears in each preset directory of the storage space.

[0037] In the embodiment of the present disclosure, a plurality of preset directories are pre-set in the storage space of the computer device, each directory can be understood as a general folder, each directory can also include a plurality of subfolders, each folder includes a plurality of data. The computer device monitors whether the newly added target data appears in each preset directory of the storage space.

[0038] Step 120: In response to the presence of newly added target data in at least one preset directory, the preset directory to which the target data belongs is used as a target directory, and a target directory identifier of the target directory is obtained.

[0039] In an embodiment of the present disclosure, when new target data appears in at least one preset directory, the computer device can respond to the new target data appearing in at least one preset directory by taking the preset directory to which the target data belongs as the target directory and obtaining a target directory identifier of the target directory.

[0040] The directory identifier can be understood as identification information that can uniquely identify a directory, and can be set as needed, for example, it can be a directory name, which is not limited here.

[0041] Step 130: Determine the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy.

[0042] In the embodiment of the present disclosure, a mapping relationship between a directory identifier and a data backup strategy is pre-stored in the computer device, that is, a data backup strategy corresponding to each directory identifier. After obtaining the target directory identifier of the target directory, the computer device can determine the target backup strategy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup strategy.

[0043] The data backup strategy may include backup methods such as the data backup location and backup duration. The backup location may be understood as the storage address of the data after the backup, and the backup duration may be understood as the storage duration of the data after the backup.

[0044] Step 140: Back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0045] In the disclosed embodiment, after obtaining the target backup policy corresponding to the target directory identifier, the computer device may back up the target data based on the target backup policy to obtain first backup data corresponding to the target data.

[0046] In some embodiments, backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data may include steps 1401-1402:

[0047] Step 1401: Obtain the backup location and backup duration of target data from the target backup policy.

[0048] In the disclosed embodiment, the computer device may obtain the backup location and backup duration of the target data from the target backup strategy.

[0049] Step 1402: Copy and move the target data to a backup location to obtain first backup data corresponding to the target data, and save the first backup data in the backup location for a backup duration.

[0050] In the disclosed embodiment, the computer device may copy and move the target data to a backup location, obtain first backup data corresponding to the target data, and save the first backup data at the backup location for a backup period of time.

[0051] In an embodiment of the present disclosure, whether new target data appears in each preset directory of the storage space is monitored; in response to the appearance of new target data in at least one preset directory, the preset directory to which the target data belongs is used as the target directory, and a target directory identifier of the target directory is obtained; based on a preset mapping relationship between the target directory identifier and the data backup strategy, a target backup strategy corresponding to the target directory identifier is determined; based on the target backup strategy, the target data is backed up to obtain first backup data corresponding to the target data, and the data can be automatically backed up according to the preset backup strategy without manual participation in the backup process, thereby improving the backup efficiency and integrity of the data and improving the accuracy of the data backup.

[0052] In some embodiments of the present disclosure, during the process of backing up target data based on a target backup strategy, a computer device may obtain the backup progress status of the target data and then display a status indicator corresponding to the backup progress status. For example, the status indicator may be displayed on a display interface of the computer device.

[0053] The backup progress status may include states such as starting backup, backing up, and backup completed, and the status identifier may include a symbol identifier, a text identifier, a pattern identifier, etc. corresponding to the backup progress status.

[0054] In other embodiments of the present disclosure, after backing up the target data based on the target backup strategy and obtaining the first backup data corresponding to the target data, when the backup of the target data is completed, the computer device can generate a backup log of the target data in response to the completion of the backup of the target data, and then display the backup log. The backup log can include at least one of the target backup strategy of the target data and the backup completion time.

[0055] In other embodiments of the present disclosure, after backing up the target data based on the target backup strategy and obtaining the first backup data corresponding to the target data, when the backup of the target data is completed, the computer device can, in response to the completion of the backup of the target data, extend the backup completion time of the target data by the backup duration corresponding to the target backup strategy, calculate the backup deadline time of the first backup data, and then display the backup deadline time of the first backup data. For example, if the backup completion time of the target data is 12:00 on September 1, 2023, and the backup duration corresponding to the target backup strategy is 7 days, then the backup deadline time of the first backup data of the target data is 12:00 on September 8, 2023.

[0056] Figure 2 is a flow chart of a data backup method provided by an embodiment of the present disclosure, such as Figure 2 As shown, the data backup method provided in this embodiment includes the following steps:

[0057] Step 210: monitor whether newly added target data appears in each preset directory of the storage space.

[0058] Step 220: In response to the presence of newly added target data in at least one preset directory, the preset directory to which the target data belongs is used as a target directory, and a target directory identifier of the target directory is obtained.

[0059] Step 230: Determine the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy.

[0060] Step 240: Back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0061] Step 250: Obtain the backup frequency of the target directory from the target backup policy. The backup frequency is the time interval between two adjacent backup actions.

[0062] In the disclosed embodiment, after obtaining the first backup data corresponding to the target data, the computer device can obtain the backup frequency of the target directory from the target backup strategy. The backup frequency can be understood as the time interval between two adjacent backup actions, that is, a data backup action is performed every certain time interval.

[0063] Step 260: In response to the time interval corresponding to the backup frequency arriving, the data in the target directory is backed up again to obtain the backed-up data of the target directory.

[0064] In the embodiment of the present disclosure, in response to the time interval corresponding to the backup frequency arriving, the computer device may re-backup the data in the target directory to obtain the re-backup data of the target directory.

[0065] Step 270: Replace the current backup data of the target directory with the newly backed-up data of the target directory to obtain the directory backup data of the target directory.

[0066] In the disclosed embodiment, the computer device may replace the current backup data of the target directory with the new backup data of the target directory to obtain the directory backup data of the target directory.

[0067] In this way, the data in the target directory can be automatically backed up at regular intervals, which can improve the data backup efficiency and the integrity of the backup data and improve the accuracy of the data backup.

[0068] Figure 3 is a flow chart of a data backup method provided by an embodiment of the present disclosure, such as Figure 3 As shown, the data backup method provided in this embodiment includes the following steps:

[0069] Step 310: monitor whether newly added target data appears in each preset directory of the storage space;

[0070] Step 320: In response to the presence of newly added target data in at least one preset directory, taking the preset directory to which the target data belongs as the target directory, and obtaining a target directory identifier of the target directory;

[0071] Step 330: Determine the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy;

[0072] Step 340: Back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0073] Step 350: monitor whether the first backup data is in an abnormal state.

[0074] In the embodiment of the present disclosure, after obtaining the first backup data corresponding to the target data, the computer device may monitor whether the first backup data is in an abnormal state. The abnormal state may include a state in which the backup data is damaged or lost.

[0075] Step 360: In response to the first backup data being in an abnormal state, identifying first data corresponding to the abnormal state in the first backup data.

[0076] In the embodiment of the present disclosure, when the first backup data is in an abnormal state, the computer device may identify the first data corresponding to the abnormal state in the first backup data in response to the first backup data being in the abnormal state, that is, the first data may include damaged data or lost data in the first backup data.

[0077] Step 370: Delete the first data.

[0078] In the embodiment of the present disclosure, after determining the first data corresponding to the abnormal state in the first backup data, the computer device may delete the first data.

[0079] Step 380: Back up the first data based on the target backup strategy to obtain second backup data corresponding to the target data.

[0080] In the disclosed embodiment, the computer device may re-backup the first data based on the target backup strategy to obtain second backup data corresponding to the target data.

[0081] In this way, data can be automatically backed up according to the preset backup strategy without human participation in the backup process, thereby improving data backup efficiency and accuracy, and re-backing up abnormal data when the backup data is abnormal, thereby improving the integrity of the backup data.

[0082] Figure 4is a flow chart of a data backup method provided by an embodiment of the present disclosure, such as Figure 4 As shown, the data backup method provided in this embodiment includes the following steps:

[0083] Step 410, monitoring whether newly added target data appears in each preset directory of the storage space;

[0084] Step 420: In response to the presence of newly added target data in at least one preset directory, taking the preset directory to which the target data belongs as the target directory, and obtaining a target directory identifier of the target directory;

[0085] Step 430: Determine the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy;

[0086] Step 440: Back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0087] Step 450: monitor whether the first backup data is in an abnormal state.

[0088] Step 460: In response to the first backup data being in an abnormal state, delete the first backup data.

[0089] In the embodiment of the present disclosure, when the first backup data is in an abnormal state, the computer device may delete the first backup data in response to the first backup data being in the abnormal state.

[0090] Step 470: re-back up the target data based on the target backup policy to obtain second backup data corresponding to the target data.

[0091] In the embodiment of the present disclosure, after deleting the first backup data, the computer device may re-backup the target data based on the target backup strategy to obtain second backup data corresponding to the target data.

[0092] In this way, data can be automatically backed up according to the preset backup strategy without human participation in the backup process, thereby improving data backup efficiency and accuracy, and re-backing up data when backup data is abnormal, thereby improving the integrity of backup data.

[0093] Figure 5 is a flow chart of a data backup method provided by an embodiment of the present disclosure, such as Figure 5 As shown, the data backup method provided in this embodiment includes the following steps:

[0094] Step 510: monitor whether newly added target data appears in each preset directory of the storage space.

[0095] Step 520: In response to the presence of newly added target data in at least one preset directory, the preset directory to which the target data belongs is used as a target directory, and a target directory identifier of the target directory is obtained.

[0096] Step 530: Determine the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy.

[0097] Step 540: When the target data is being backed up off-site, monitor the operating status of the target network used in the backup process.

[0098] In the embodiments of the present disclosure, off-site backup can be understood as target data needing to be backed up to an electronic device other than a computer device, and the off-site backup needs to be performed through a network.

[0099] When the target data is backed up off-site, the computer device may monitor the operating status of the target network used in the backup process, and the operating status may include a connection status and a disconnection status.

[0100] Step 550: In response to the running state being the disconnected state, suspending the backup, and recording the starting data of the unbacked-up data in the target data when the backup is suspended.

[0101] In the disclosed embodiment, when the target network is in a disconnected state, the computer device may suspend the backup of the target data in response to the disconnected state, and record the starting data of the unbacked up data in the target data when the backup is suspended.

[0102] Step 560 , in response to the running state being the connected state, starting from the initial data, continue to back up the unbacked up data in the target data based on the target backup policy to obtain first backup data corresponding to the target data.

[0103] In an embodiment of the present disclosure, when the operating state of the target network is a connected state, the computer device can respond to the operating state being a connected state, start from the starting data of the unbacked up data in the target data, and continue to back up the unbacked up data in the target data based on the target backup strategy to obtain the first backup data corresponding to the target data.

[0104] In this way, data can be automatically backed up according to the preset backup strategy without the need for human participation in the backup process, thereby improving data backup efficiency and accuracy. During the backup period, breakpoint resumption can be implemented as a resident process. When a network abnormality occurs, the breakpoint can be recorded, and after the network is restored, the data can be resumed and backed up, thereby improving the integrity of the backup data.

[0105] In some embodiments of the present disclosure, before determining the target backup policy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup policy, the computer device can determine the backup policy corresponding to the directory identifier of each preset directory in response to the user's backup policy configuration operation on each preset directory; and construct a mapping relationship between each directory identifier and the backup policy based on the backup policy corresponding to the directory identifier of each preset directory.

[0106] Specifically, the computer device may provide directory options and backup policy options corresponding to each directory option, the directory options including directory identifiers of multiple preset directories, the backup policy options including multiple backup policies, the user may select a directory identifier of any preset directory from the directory options, and then select a backup policy from the backup policy options corresponding to the preset directory as the backup policy corresponding to the directory identifier, and perform a backup policy configuration operation on the preset directory, thereby performing a backup policy configuration operation on each preset directory, and the computer device may determine the backup policy corresponding to the directory identifier of each preset directory in response to the user's backup policy configuration operation on each preset directory, and then construct a mapping relationship between each directory identifier and the backup policy based on the backup policy corresponding to the directory identifier of each preset directory.

[0107] Figure 6 Schematic diagram of a data backup device provided by an embodiment of the present disclosure. The device can be understood as the above-mentioned computer device or a part of the functional modules in the above-mentioned computer device. Figure 6 As shown, the data backup device 600 includes:

[0108] The first monitoring module 610 is used to monitor whether there is newly added target data in each preset directory of the storage space;

[0109] A first acquisition module 620 is configured to, in response to the presence of newly added target data in at least one preset directory, take the preset directory to which the target data belongs as a target directory and acquire a target directory identifier of the target directory;

[0110] A first determination module 630, configured to determine a target backup policy corresponding to the target directory identifier based on a preset mapping relationship between the target directory identifier and the data backup policy;

[0111] The first backup module 640 is configured to back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

[0112] Optionally, the first backup module 640 includes:

[0113] The acquisition submodule is used to obtain the backup location and backup duration of the target data from the target backup policy;

[0114] The saving submodule is used to copy and move the target data to a backup location, obtain first backup data corresponding to the target data, and save the first backup data in the backup location for a backup period.

[0115] Optionally, the data backup device 600 includes:

[0116] The second acquisition module is used to acquire the backup frequency of the target directory from the target backup strategy, where the backup frequency is the time interval between two adjacent backup actions;

[0117] A re-backup module, used for re-backing up the data in the target directory in response to the time interval corresponding to the backup frequency, to obtain the re-backed-up data of the target directory;

[0118] The replacement module is used to replace the current backup data of the target directory with the new backup data of the target directory to obtain the directory backup data of the target directory.

[0119] Optionally, the data backup device 600 includes:

[0120] a generating module, configured to generate a backup log of the target data in response to completion of the backup of the target data, wherein the backup log includes at least one of a target backup strategy of the target data and a backup completion time;

[0121] The first display module is used to display the backup log.

[0122] and / or, an extension module, configured to, in response to completion of the backup of the target data, extend the backup completion time of the target data by the backup duration corresponding to the target backup policy, to obtain the backup deadline time of the first backup data;

[0123] The second display module is used to display the backup period of the first backup data.

[0124] Optionally, the data backup device 600 includes:

[0125] A second monitoring module is used to monitor whether the first backup data is in an abnormal state;

[0126] an identification module, configured to identify, in response to the first backup data being in an abnormal state, first data corresponding to the abnormal state in the first backup data;

[0127] A first deletion module, used for deleting first data;

[0128] A second backup module, used to re-backup the first data based on the target backup strategy to obtain second backup data corresponding to the target data;

[0129] or, a second deleting module, configured to delete the first backup data in response to the first backup data being in an abnormal state;

[0130] The third backup module is used to re-back up the target data based on the target backup strategy to obtain second backup data corresponding to the target data.

[0131] Optionally, the first backup module 640 includes:

[0132] A monitoring submodule, for monitoring the operation status of the target network used in the backup process when the target data is in a remote backup;

[0133] A pause submodule, used for pausing the backup in response to the running state being the disconnected state, and recording the starting data of the unbacked-up data in the target data when the backup is paused;

[0134] The backup submodule is used for, in response to the running state being the connection state, starting from the initial data, continuing to back up the unbacked up data in the target data based on the target backup strategy to obtain the first backup data corresponding to the target data.

[0135] Optionally, the data backup device 600 includes:

[0136] A second determination module, configured to determine a backup strategy corresponding to a directory identifier of each preset directory in response to a user's backup strategy configuration operation on each preset directory;

[0137] The construction module is used to construct a mapping relationship between each directory identifier and the backup strategy based on the backup strategy corresponding to the directory identifier of each preset directory.

[0138] The data backup device provided in the embodiments of the present disclosure can implement the method of any of the above embodiments, and its execution method and beneficial effects are similar, which will not be repeated here.

[0139] The embodiments of the present disclosure also provide a computer device, which includes a processor and a memory, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, the method of any of the above embodiments can be implemented, and its execution method and beneficial effects are similar and will not be repeated here.

[0140] The computer device in the embodiments of the present disclosure may be understood as any device with processing and computing capabilities, and the device may include but is not limited to mobile terminals such as smart phones, laptops, personal digital assistants (PDAs), tablet computers (PADs), portable multimedia players (PMPs), vehicle-mounted terminals, wearable devices, etc., as well as fixed electronic devices such as digital TVs, desktop computers, smart home devices, etc.

[0141] Figure 7 is a schematic diagram of the structure of a computer device provided by an embodiment of the present disclosure, such as Figure 7As shown, the computer device 700 may include a processor 710 and a memory 720, wherein the memory 720 stores a computer program 721, and when the computer program 721 is executed by the processor 710, the method provided by any of the above embodiments can be implemented, and its execution method and beneficial effects are similar, which will not be repeated here.

[0142] Of course, to simplify, Figure 7 Only some of the components related to the present invention in the computer device 700 are shown, and components such as a bus, an input / output interface, an input device, and an output device are omitted. In addition, according to specific application conditions, the computer device 700 may also include any other appropriate components.

[0143] An embodiment of the present disclosure provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a processor, the method of any of the above embodiments can be implemented. The execution method and beneficial effects are similar and will not be repeated here.

[0144] The above-mentioned computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0145] The computer program may be written in any combination of one or more programming languages ​​to write program codes for performing the operations of the disclosed embodiments, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer device, partially on the user's device, as a separate software package, partially on the user's computer device and partially on a remote computer device, or entirely on a remote computer device or server.

[0146] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.

[0147] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.

[0148] The above description is only a specific embodiment of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A data backup method, characterized in that: include: Monitor whether newly added target data appears in each preset directory of the storage space; In response to the presence of newly added target data in at least one of the preset directories, taking the preset directory to which the target data belongs as a target directory, and acquiring a target directory identifier of the target directory; Determine the target backup policy corresponding to the target directory identifier based on a preset mapping relationship between the target directory identifier and the data backup policy; The target data is backed up based on the target backup strategy to obtain first backup data corresponding to the target data.

2. The method according to claim 1, characterized in that The backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data includes: Obtaining the backup location and backup duration of the target data from the target backup strategy; The target data is copied and moved to the backup location to obtain first backup data corresponding to the target data, and the first backup data is stored in the backup location for the backup duration.

3. The method according to claim 1, characterized in that After backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data, the method further includes: Acquire the backup frequency of the target directory from the target backup strategy, where the backup frequency is the time interval between two adjacent backup actions; In response to the time interval corresponding to the backup frequency arriving, re-backing up the data in the target directory to obtain the re-backed-up data of the target directory; The current backup data of the target directory is replaced with the new backup data of the target directory to obtain the directory backup data of the target directory.

4. The method according to claim 1, characterized in that: After backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data, the method further includes: In response to completion of the backup of the target data, generating a backup log of the target data, the backup log including at least one of a target backup strategy and a backup completion time of the target data; Displaying the backup log; and / or, in response to completion of the backup of the target data, extending the backup completion time of the target data by the backup duration corresponding to the target backup policy to obtain a backup deadline of the first backup data; The backup period of the first backup data is displayed.

5. The method according to claim 1, characterized in that After backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data, the method further includes: monitoring whether the first backup data is in an abnormal state; In response to the first backup data being in an abnormal state, identifying first data corresponding to the abnormal state in the first backup data; deleting the first data; Re-backing up the first data based on the target backup strategy to obtain second backup data corresponding to the target data; or, in response to the first backup data being in an abnormal state, deleting the first backup data; The target data is backed up again based on the target backup strategy to obtain second backup data corresponding to the target data.

6. The method according to claim 1, characterized in that The backing up the target data based on the target backup strategy to obtain first backup data corresponding to the target data includes: When the target data is backed up off-site, monitoring the operating status of the target network used in the backup process; In response to the running state being the disconnected state, pausing the backup, and recording the starting data of the unbacked-up data in the target data when the backup is paused; In response to the running state being the connected state, starting from the starting data, the unbacked-up data in the target data is continuously backed up based on the target backup policy to obtain first backup data corresponding to the target data.

7. The method according to claim 1, characterized in that Before determining the target backup strategy corresponding to the target directory identifier based on the preset mapping relationship between the target directory identifier and the data backup strategy, the method further includes: In response to the user's backup strategy configuration operation on each preset directory, determining the backup strategy corresponding to the directory identifier of each preset directory; Based on the backup strategy corresponding to the directory identifier of each preset directory, a mapping relationship between each directory identifier and the backup strategy is constructed.

8. A data backup device, characterized in that: include: The first monitoring module is used to monitor whether newly added target data appears in each preset directory of the storage space; A first acquisition module is configured to, in response to the presence of newly added target data in at least one of the preset directories, take the preset directory to which the target data belongs as a target directory and acquire a target directory identifier of the target directory; A first determination module, configured to determine a target backup policy corresponding to the target directory identifier based on a preset mapping relationship between the target directory identifier and the data backup policy; The first backup module is used to back up the target data based on the target backup strategy to obtain first backup data corresponding to the target data.

9. A computer device, characterized in that: include: 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 data backup method according to any one of claims 1 to 7 is implemented.

10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by the processor, the data backup method according to any one of claims 1 to 7 is implemented.