CN115878386A - Disaster recovery method and device, electronic equipment and storage medium - Google Patents

Disaster recovery method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115878386A
CN115878386A CN202310075824.4A CN202310075824A CN115878386A CN 115878386 A CN115878386 A CN 115878386A CN 202310075824 A CN202310075824 A CN 202310075824A CN 115878386 A CN115878386 A CN 115878386A
Authority
CN
China
Prior art keywords
data
instance
real
backup
time
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310075824.4A
Other languages
Chinese (zh)
Inventor
谢锶瑜
郑钊彪
陈金曈
李山根
方轶
蒋凯
刘小平
毛宁瑜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianyi Cloud Technology Co Ltd
Original Assignee
Tianyi Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianyi Cloud Technology Co Ltd filed Critical Tianyi Cloud Technology Co Ltd
Priority to CN202310075824.4A priority Critical patent/CN115878386A/en
Publication of CN115878386A publication Critical patent/CN115878386A/en
Pending legal-status Critical Current

Links

Images

Abstract

The invention provides a disaster recovery method, a disaster recovery device, electronic equipment and a storage medium, and relates to the technical field of communication. The method is applied to a data management system, and the data management system comprises the following steps: a main instance, the method comprising: periodically backing up the data of the main example according to a first preset period to obtain a timed backup example; receiving a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required; and covering the main instance with the timing backup instance corresponding to the time needing rollback. In the embodiment of the invention, the data of the main instance is backed up periodically according to a first preset period to obtain the timed backup instance, the version rollback instruction including the time needing to be rolled back is received, and then the timed backup instance corresponding to the time needing to be rolled back is used for covering the main instance, so that the version rollback function of the main instance is realized efficiently and conveniently, and the instance-level disaster tolerance capability is provided.

Description

Disaster recovery method and device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of communications technologies, and in particular, to a disaster recovery method and apparatus, an electronic device, and a storage medium.
Background
The data management system undertakes basic data storage service, and the disaster tolerance performance of the data management system can affect the availability, consistency, reliability and the like of the system.
At present, the disaster recovery performance of a data management system mainly focuses on improving data backup efficiency from a main example to a backup example.
However, in the existing data management system, the function of version rollback of the main instance is not realized, which brings inconvenience to the use of the data management system.
Disclosure of Invention
The invention provides a disaster recovery method, a disaster recovery device, electronic equipment and a storage medium, and aims to solve the problem that the version rollback function of a main instance is not realized in the conventional data management system.
In a first aspect, the present invention provides a disaster recovery method, which is applied to a data management system, where the data management system includes: a main example, the method comprising:
periodically backing up the data of the main example according to a first preset period to obtain a timed backup example;
receiving a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required;
and covering the main instance with the timing backup instance corresponding to the time needing rollback.
In a second aspect, the present invention provides a disaster recovery device for a data management system, where the data management system includes: the main example, the disaster recovery device includes:
the timing backup module is used for regularly backing up the data of the main example according to a first preset period to obtain a timing backup example;
a version rollback instruction receiving module, configured to receive a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required;
and the version rollback module is used for covering the main example by the timing backup example corresponding to the time needing rollback.
In a third aspect, the present invention provides an electronic device comprising: the disaster recovery method comprises a processor, a memory and a computer program which is stored on the memory and can run on the processor, wherein the processor realizes the disaster recovery method when executing the program.
In a fourth aspect, the present invention provides a readable storage medium, wherein instructions of the storage medium, when executed by a processor of an electronic device, enable the electronic device to execute the disaster recovery method.
In the embodiment of the invention, the data of the main instance is backed up periodically according to a first preset period to obtain the timed backup instance, the version rollback instruction including the time needing to be rolled back is received, and then the timed backup instance corresponding to the time needing to be rolled back is used for covering the main instance, so that the version rollback function of the main instance is realized efficiently and conveniently, and the instance-level disaster tolerance capability is provided.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a flowchart illustrating steps of a disaster recovery method according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating steps of another disaster recovery method according to an embodiment of the present invention;
fig. 3 is a flowchart illustrating steps of a disaster recovery method according to an embodiment of the present invention;
fig. 4 is a structural diagram of a disaster recovery device according to an embodiment of the present invention;
fig. 5 is a schematic diagram of information interaction in disaster recovery according to an embodiment of the present invention;
fig. 6 is a block diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be obtained by a person skilled in the art without inventive step based on the embodiments of the present invention, are within the scope of protection of the present invention.
The invention provides a disaster recovery method, which is applied to a data management system, wherein the data management system comprises: a main instance. The primary instance refers to the primary instance that provides the data access service. The data management system may include a database system or the like. Optionally, the data management system may include: distributed File System (DFS). DFS means that the physical storage resources managed by the file system are not necessarily directly connected to the local node, but are connected to a node (which can be understood as a computer simply) through a computer network; or a complete hierarchical file system formed by combining several different logical disk partitions or volume labels. DFS provides a logical tree file system structure for resources distributed at any position on the network, so that users can access shared files distributed on the network more conveniently. The role of individual DFS shared folders is relative to access points through other shared folders on the network.
Fig. 1 is a flowchart of steps of a disaster recovery method according to an embodiment of the present invention, where the present invention may be applied in scenarios such as cloud computing, big data, artificial Intelligence (AI), a block chain, internet of things/vehicle networking, a service platform, video communication, an interactive Internet Protocol Television (IPTV), and a novel Information and Communication Technology (ICT). Referring to fig. 1, the method may include the following steps.
Step 101, periodically backing up the data of the main instance according to a first preset period to obtain a timed backup instance.
The first preset period may be set according to actual needs, and may be one year, half a year, one month, 10 days, 5 days, 1 day, and the like, and the first preset period is not specifically limited.
And periodically backing up the data of the main instance according to a first preset period to obtain timed backup instances, wherein each timed backup instance is a snapshot or a copy of the main instance at the backup moment.
Step 102, receiving a version rollback instruction for the main instance; the version rollback instruction comprises: the time of need for rollback.
The version rollback instruction for the primary instance is an instruction that requires the primary instance to perform a version rollback. The version rollback instruction includes the time at which rollback is required, i.e., the version of the primary instance that needs to be rolled back to that time or version.
For example, the time when rollback is required in the version rollback instruction for the main instance is 2022, 5 months, 31 days, 23:59, then, it is necessary to roll back the version of the main instance to 2022, 5/31/23: 59.
It should be noted that, the time needing to go back here may specifically refer to a certain year, a certain month of a certain year, a certain day of a certain month of a certain year, or a specific certain time of a certain day of a certain month of a certain year. The granularity of the time is not limited here.
Step 103, the timing backup instance corresponding to the time needing rollback is used for covering the main instance.
In this step, the time required to rollback in the version rollback instruction, the corresponding timed backup instance, may be searched for or determined from all the timed backup instances corresponding to the primary instance. And then, the time needing rollback in the version rollback instruction and the corresponding timing backup instance are used for covering the main instance. The time required to be backed-off in the version backing-off instruction and the corresponding timing backup instance are taken as the backing-off version corresponding to the backing-off instruction and are backed-off to the main instance, so that the version backing-off of the main instance is conveniently and efficiently realized, and the instance-level disaster tolerance capability is provided.
For example, for the foregoing example, the time when rollback is required in the version rollback instruction for the main instance is 2022, 5, 31, 23:59:59. Then, from all the timed backup instances corresponding to the main instance, the backup instance is found to be 23: 59. Then, the ratio of 2022 year 5 month 31 day 23:59 timed backup instance, overriding the primary instance, rolling back the version of the primary instance to 23/31/5/2022: 59, thereby realizing version rollback for the main instance and providing disaster tolerance capability at the instance level.
Fig. 2 is a flowchart of steps of another disaster recovery method according to an embodiment of the present invention, where the disaster recovery method is also applicable to the data management system, and the data management system includes: a main example, as shown with reference to fig. 2, the method may include the following steps.
Step 201, periodically backing up the data of the main instance according to a first preset period to obtain a timed backup instance.
Step 202, receiving a version rollback instruction for the main instance; the version rollback instruction comprises: the time of need for rollback.
Step 203, the timed backup instance corresponding to the time needing to be backed off is used for covering the main instance.
The foregoing steps 201 to 203 may be referred to as the foregoing steps 101 to 103, and may achieve the same or similar beneficial effects, and are not repeated herein for avoiding repetition.
Step 204, receiving a deletion and recovery error instruction for the main example; the mistaken deletion retrieval instruction comprises the following steps: the identification of the data to be retrieved is required.
During the use of the main instance, there may be a false deletion of the data of the main instance. Receiving a mis-delete retrieve instruction for the primary instance, the mis-delete retrieve instruction may include: the identification of the data to be retrieved is required.
Step 205, migrating the data corresponding to the data identifier in the timed backup instance to the main instance.
The data corresponding to the data identification in the timed backup example is used as the mistakenly deleted data and is migrated to the main example, so that the mistakenly deleted data in the main example can be conveniently and efficiently retrieved, and the mistakenly deleted data is the data of the timed backup example, so that the recovery source of the data has good reliability.
Here, the size or the amount of the erroneously deleted data is not particularly limited. For example, if the data to be retrieved in the delete-and-retrieve command is identified as data of a certain subdirectory, in this step, the data of the subdirectory in the timed backup instance is migrated to the main instance.
Optionally, the step may include: and migrating the data which is closest to the receiving time of the mistaken deletion retrieval instruction and corresponds to the data identifier in the timed backup example to the main example. That is, after the mistaken deletion retrieval instruction is received, the timed backup instance closest to the receiving time of the mistaken deletion retrieval instruction is determined from all timed backup instances corresponding to the main instance, and the data corresponding to the data identifier in the timed backup instance is migrated to the main instance, that is, the mistaken deletion data is found from the latest timed backup instance and migrated to the main instance, so that the consistency with the mistaken deletion data is maintained as much as possible.
Fig. 3 is a flowchart of steps of another disaster recovery method according to an embodiment of the present invention, where the disaster recovery method is also applicable to the data management system, and the data management system includes: a main example, as shown with reference to fig. 3, the method may include the following steps.
Step 301, periodically backing up the data of the main instance according to a first preset period to obtain a timed backup instance.
Step 302, receiving a version rollback instruction for the main instance; the version rollback instruction comprises: the time of need for rollback.
Step 303, the timed backup instance corresponding to the time needing rollback is used to cover the main instance.
The foregoing steps 301 to 303 may refer to the foregoing steps 101 to 103, and may achieve the same or similar beneficial effects, and therefore, the details are not repeated herein for the sake of avoiding repetition.
And step 304, backing up the data of the main example in real time to obtain a real-time backup example.
Compared with the aforementioned timing backup example, the real-time backup example is a real-time backup, so that the real-time backup example is more consistent with the main example. The live backup instance is a live snapshot or a live copy of the primary instance.
Step 305, receive a data read instruction for the master instance.
The read operation instruction for the main instance is here to read data from the main instance. The read operation command here may be a random read operation command or the like.
Step 306, in case of a failure of the main instance, the real-time backup instance returns data corresponding to the data read instruction.
And under the condition that the main instance fails, the main instance can not provide data service, the real-time backup instance with better consistency with the main instance returns the tape data corresponding to the data reading operation instruction, and under the condition that the main instance fails, the data reading service with good consistency with the main instance is conveniently provided, so that the disaster recovery capability of preventing single-point reading is realized.
It should be noted that, under the condition that neither the main instance nor the real-time backup instance fails, data corresponding to the data read instruction may be returned by the main instance, or data corresponding to the data read instruction may be returned by the real-time backup instance.
Optionally, the foregoing step 304 may include: the following substeps. Substep 3041, performing quasi real-time backup on the data of the main example according to a second preset period to obtain a quasi real-time backup example; the second preset period is less than the first preset period. Sub-step 3042, receiving a data manipulation instruction for the master instance; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction. Substep 3043, performing corresponding data operation on the quasi real-time backup instance based on the data operation instruction located between the adjacent quasi real-time backup moments to obtain the real-time backup instance.
The second preset period is smaller than or shorter than the first preset period, so that the consistency between the quasi-real-time backup instance and the main instance is still better than that between the timing backup instance and the main instance. The second preset period may be set according to actual needs, and may be 1 hour, half an hour, and the like, and the second preset period is not specifically limited. The magnitude of the difference between the first preset period and the second preset period is also not particularly limited. And performing quasi-real-time backup on the data of the main instance according to a second preset period to obtain quasi-real-time backup instances, wherein each quasi-real-time backup instance is a snapshot or a copy of the main instance at the backup moment. Receiving a data operation instruction for a master instance, the data operation instruction comprising: a data writing operation instruction and/or a data deleting operation instruction. The data operation instruction may change the main instance, and the data read instruction may not change the main instance, and thus, is not limited. Based on the data operation instruction between the adjacent quasi-real-time backup moments, the data operation instruction is aligned to the real-time backup instance to perform corresponding data operation, and after the operation, the data synchronization between the quasi-real-time instance and the main instance is realized, so that the real-time backup instance is obtained. In this way, a real-time backup instance with better consistency with the main instance is obtained.
Optionally, before the sub-step 3043, the method may further include: and storing the data operation instruction between the adjacent quasi-real-time backup moments to a message queue. And the quasi-real-time backup instance acquires data operation instructions between adjacent quasi-real-time backup moments from the message queue. The data operation instructions between the adjacent quasi-real-time backup moments are stored in the message queue, so that the data operation instructions can be prevented from being covered, and the consistency of the real-time backup instance and the main instance can be improved.
Optionally, the foregoing step 304 may include: the following substeps. Substep 3044, performing quasi-real-time backup on the data of the main example according to a second preset period to obtain a quasi-real-time backup example; the second preset period is less than the first preset period. Substep 3045, obtaining an operation record of the data operation instruction between the adjacent quasi real-time backup moments of the main instance; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction. Substep 3046, performing corresponding data operation on the quasi real-time backup instance based on the operation record of the data operation instruction between the adjacent quasi real-time backup moments to obtain the real-time backup instance.
Sub-step 3044 can be referred to the aforementioned sub-step 3041, and is not described herein for avoiding repetition. Relevant portions of sub-step 3045 may refer to relevant portions of sub-step 3042 previously described, the main instance may modify the main instance with respect to data manipulation instructions, such as data write manipulation instructions, and/or data delete manipulation instructions. And acquiring the operation record of the main instance aiming at the data operation instruction between the adjacent quasi-real-time backup moments. The operation record records the time at which the operation is performed on the main instance. The method comprises the steps of obtaining a main instance, operation records of data operation instructions and quasi-real-time backup instances, wherein the operation records are located between adjacent quasi-real-time backup moments, and executing corresponding data operation based on the operation records located between the adjacent quasi-real-time backup moments, namely, real-time synchronization with the main instance is realized, and then the real-time backup instances are obtained. In this way, a real-time backup instance with better consistency with the main instance is also obtained.
Optionally, before the aforementioned sub-step 3046, the method may include: the operation records are stored in a message queue, and the quasi-real-time backup instance acquires the operation records from the message queue, so that the operation records can be prevented from being covered, and the consistency of the real-time backup instance and the main instance can be improved.
It should be noted that, the process of obtaining the real-time backup instance may also be: and backing up the data of the main example only once to obtain a real-time backup example at the backup moment, subsequently obtaining the data operation instruction aiming at the main example and/or the operation record of the data operation instruction, and performing corresponding data operation on the real-time backup example to obtain real-time backup examples at different moments. For example, after the main instance is started, the data of the main instance is backed up to obtain the real-time backup instance at the backup time. And then, acquiring the data operation instruction for the main instance and/or an operation record of the data operation instruction, and performing corresponding data operation on the real-time backup instance based on the data operation instruction and/or the operation record of the data operation instruction to obtain a new-version real-time backup instance. The data operation instructions may also include data write operation instructions, and/or data delete operation instructions that modify the operation instructions of the host instance.
Optionally, after the step 304, the method may further include: under the condition that a real-time backup instance fails, copying data of the main instance to the real-time backup instance within a time period when the main instance does not execute a data operation instruction; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction. The main instance is not changed in the time period when the main instance does not execute the data operation instruction, and under the condition that the real-time backup instance fails, the data of the main instance is copied to the real-time backup instance in the time period when the main instance does not execute the data operation instruction, so that the consistency of the main instance and the real-time backup instance can be ensured as much as possible, and the disaster tolerance from the main instance to the real-time backup instance is conveniently realized.
Optionally, after the step 304, the method may further include: the real-time backup instance is covered by the timing backup instance corresponding to the time needing to be backed up, and then the version back-up of the real-time backup instance is conveniently and efficiently realized.
Optionally, after the step 304, the method may further include: receiving a deletion retrieval instruction aiming at the main example; the mistaken deletion retrieval instruction comprises the following steps: the identification of the data to be retrieved is required. And migrating the data corresponding to the data identification in the timed backup example to the real-time backup example. The method adopts a mode similar to that of the main example for preventing the error deletion and the recovery, takes the timing backup example as the version for preventing the error deletion and the recovery, finds the data corresponding to the data identification from the timing backup example, and migrates the data to the real-time backup example, thereby conveniently and efficiently realizing the operation for preventing the error deletion and the recovery of the real-time backup example.
It should be noted that, in the error deletion recovery prevention operation of the real-time backup example, the data corresponding to the data identifier may also be searched or determined from the timing backup example closest to the receiving time of the error deletion recovery instruction, and the data is migrated to the real-time backup main example, so that the consistency with the error deletion data is maintained as much as possible.
Optionally, after the step 304, the method may further include: under the condition that one of the main instance and the real-time backup instance fails and the other instance does not fail, the instance which does not fail is used for covering the instance which fails, so that the mutual disaster tolerance of the main instance and the real-time backup instance is realized conveniently.
It should be noted that, a disaster tolerance protocol may be set in advance, where the disaster tolerance protocol is used to implement the disaster tolerance logic and the like, and this is not particularly limited in the embodiment of the present invention. The data reading instruction, the data writing operation instruction and the data deleting operation instruction can be received through the route access interface.
Fig. 4 is a structural diagram of a disaster recovery device according to an embodiment of the present invention. The invention also provides a disaster recovery device, which is applied to a data management system, wherein the data management system comprises: a main example, as shown with reference to fig. 4, the apparatus comprises: the timing backup module 401 is configured to periodically backup data of the main instance according to a first preset period to obtain a timing backup instance; a version rollback instruction receiving module 402, configured to receive a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required; the version rollback module 403, overriding the primary instance with the timed backup instance corresponding to the time that needs rollback.
Optionally, the disaster recovery device further includes: the mistaken deletion retrieval instruction receiving module is used for receiving a mistaken deletion retrieval instruction aiming at the main example; the mistaken deletion retrieval instruction comprises the following steps: data identification needing to be retrieved; and the first migration module is used for migrating the data corresponding to the data identification in the timed backup instance to the main instance.
Optionally, the first migration module includes: and the first migration submodule is used for migrating the data which is closest to the receiving time of the mistaken deletion retrieval instruction and corresponds to the data identifier in the timed backup example to the main example.
Optionally, the disaster recovery device further includes: the real-time backup module is used for backing up the data of the main example in real time to obtain a real-time backup example; a data read instruction receiving module, configured to receive a data read instruction for the main instance; and the return module is used for returning the data corresponding to the data reading instruction by the real-time backup instance under the condition that the main instance fails.
Optionally, the real-time backup module includes: the quasi-real-time backup submodule is used for performing quasi-real-time backup on the data of the main example according to a second preset period to obtain a quasi-real-time backup example; the second preset period is less than the first preset period; the receiving submodule is used for receiving a data operation instruction aiming at the main example; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction; and the real-time backup first sub-module is used for carrying out corresponding data operation on the quasi real-time backup example based on the data operation instruction between the adjacent quasi real-time backup moments to obtain the real-time backup example.
Optionally, the disaster recovery device further includes: the first storage module is used for storing the data operation instruction between adjacent quasi-real-time backup moments to a message queue; and the first acquisition module is used for acquiring the data operation instruction between the adjacent quasi real-time backup moments by the quasi real-time backup instance from the message queue.
Optionally, the real-time backup module includes: the quasi-real-time backup submodule is used for carrying out quasi-real-time backup on the data of the main example according to a second preset period to obtain a quasi-real-time backup example; the second preset period is less than the first preset period; the acquisition submodule is used for acquiring the operation record of the data operation instruction, positioned between adjacent quasi-real-time backup moments, of the main example; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction; and the real-time backup second submodule is used for carrying out corresponding data operation on the quasi-real-time backup example based on the operation record of the data operation instruction between the adjacent quasi-real-time backup moments to obtain the real-time backup example.
Optionally, the disaster recovery device further includes: the second storage module is used for storing the operation records to a message queue; and the second acquisition module is used for acquiring the operation record from the message queue by the quasi real-time backup instance.
Optionally, the disaster recovery device further includes: the copying module is used for copying the data of the main instance to the real-time backup instance in a period when the main instance does not execute a data operation instruction under the condition that the real-time backup instance fails; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction.
Optionally, the disaster recovery device further includes: and the first covering module is used for covering the real-time backup instance by using the timing backup instance corresponding to the time needing rollback.
Optionally, the disaster recovery device further includes: the mistaken deletion retrieval instruction receiving module is used for receiving a mistaken deletion retrieval instruction aiming at the main example; the mistaken deletion retrieval instruction comprises the following steps: data identification needing to be retrieved; and the second migration module is used for migrating the data corresponding to the data identification in the timed backup instance to the real-time backup instance.
Optionally, the disaster recovery device further includes: and the second covering module is used for covering the failed instance by the non-failed instance under the condition that one instance of the main instance and the real-time backup instance fails and the other instance does not fail.
For the apparatus embodiment, since it is substantially similar to the method embodiment, the description is relatively simple, and reference may be made to the partial description of the method embodiment for relevant points.
It should be noted that various information and data acquired in the embodiment of the present invention are acquired under the authorization of the information/data holder.
The present application is further illustrated below with reference to specific examples.
Fig. 5 is a schematic diagram of information interaction in disaster recovery according to an embodiment of the present invention. The main instance, the real-time backup instance, and the timed backup instance are first started. And periodically backing up the data of the main example according to a first preset period to obtain a timed backup example. The timed backup example illustrated in fig. 5 includes versions at three timed backup moments, namely, a timed backup example 1, a timed backup example 2, and a timed backup example 3, and the data of the main example is backed up in a quasi-real-time manner according to a second preset period, so as to obtain a quasi-real-time backup example, where the second preset period is smaller than the first preset period.
And the access or the instruction and the like aiming at the main instance, the real-time backup instance and the timing backup instance are realized through a routing access interface. And after receiving the write operation and the delete operation aiming at the main example through the route access interface, carrying out corresponding operation by the main example. And storing the data operation instruction between the adjacent quasi-real-time backup moments into a message queue, and acquiring the data operation instruction, the data writing operation instruction and/or the data deleting operation instruction between the adjacent quasi-real-time backup moments from the message queue by the quasi-real-time backup example. And aligning the real-time backup instance based on the data operation instruction, and performing corresponding data operation to obtain the real-time backup instance. Or storing the operation records of the data operation instructions between adjacent quasi-real-time backup moments into a message queue, storing the operation records into the message queue, acquiring the operation records from the message queue by the quasi-real-time backup example, and performing corresponding data operation on the quasi-real-time backup example based on the operation records to obtain the real-time backup example.
And the versions of the main instance, the real-time backup instance and the timing backup instance are started one month later, and the versions are expected to fall back to a certain historical time point. Receiving a version rollback instruction aiming at the main instance through a routing access interface, wherein the version rollback instruction comprises the historical time point needing to be rolled back, and covering the main instance by using a timing backup instance corresponding to the historical time point needing to be rolled back so as to achieve the function of version rollback.
The method comprises the steps that one day after a main example, a real-time backup example and a timing backup example are started, one file in the main example is deleted through a routing access interface, the file is found to be deleted by mistake after deletion, under the condition that a mistaken deletion retrieval instruction is received, data corresponding to a data identifier in the mistaken deletion retrieval instruction are retrieved in the timing backup example closest to the receiving time of the mistaken deletion retrieval instruction, the data corresponding to the data identifier in the timing backup example are migrated to the main example, and retrieval of the mistaken deletion data is achieved.
And under the condition that the main instance fails, backing up the instance in real time, and returning data corresponding to the data reading instruction aiming at the data reading operation of the main instance to realize the disaster recovery function of preventing single-point reading.
In this embodiment, a disaster tolerance protocol may be set in advance, and the disaster tolerance protocol is used to implement the disaster tolerance logic and the like.
Fig. 6 is a structural diagram of an electronic device according to an embodiment of the present invention, and the present invention further provides an electronic device, which includes, referring to fig. 6: a processor 901, a memory 902 and a computer program 9021 stored in and executable on said memory, said processor implementing the disaster recovery method of the previous embodiments when executing said program.
The present invention also provides a readable storage medium, wherein when the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the disaster recovery method of the foregoing embodiment.
The algorithms and displays presented herein are not inherently related to any particular computer, virtual machine, or other apparatus. Various general purpose systems may also be used with the teachings herein. The required structure for constructing such a system will be apparent from the description above. Moreover, the present invention is not directed to any particular programming language. It is appreciated that a variety of programming languages may be used to implement the teachings of the present invention as described herein, and any descriptions of specific languages are provided above to disclose the best mode of the invention.
In the description provided herein, numerous specific details are set forth. It is understood, however, that embodiments of the invention may be practiced without these specific details. In some instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.
Similarly, it should be appreciated that in the foregoing description of exemplary embodiments of the invention, various features of the invention are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the invention and aiding in the understanding of one or more of the various inventive aspects. However, the disclosed method should not be construed to reflect the intent: that the invention as claimed requires more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the detailed description are hereby expressly incorporated into this detailed description, with each claim standing on its own as a separate embodiment of this invention.
Those skilled in the art will appreciate that the modules in the device in an embodiment may be adaptively changed and disposed in one or more devices different from the embodiment. The modules or units or components of the embodiments may be combined into one module or unit or component, and furthermore they may be divided into a plurality of sub-modules or sub-units or sub-components. All of the features disclosed in this specification (including any accompanying claims, abstract and drawings), and all of the processes or elements of any method or apparatus so disclosed, may be combined in any combination, except combinations where at least some of such features and/or processes or elements are mutually exclusive. Each feature disclosed in this specification (including any accompanying claims, abstract and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise.
The various component embodiments of the invention may be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It will be appreciated by those skilled in the art that a microprocessor or Digital Signal Processor (DSP) may be used in practice to implement some or all of the functions of some or all of the components in a sequencing device according to the present invention. The present invention may also be embodied as an apparatus or device program for carrying out a part or all of the methods described herein. Such programs implementing the present invention may be stored on a computer readable medium or may be in the form of one or more signals. Such a signal may be downloaded from an internet website or provided on a carrier signal or in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and that those skilled in the art will be able to design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses shall not be construed as limiting the claim. The word "comprising" does not exclude the presence of elements or steps not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements. The invention may be implemented by means of hardware comprising several distinct elements, and by means of a suitably programmed computer. In the unit claims enumerating several means, several of these means may be embodied by one and the same item of hardware. The usage of the words first, second and third, etcetera do not indicate any ordering. These words may be interpreted as names.
The user information (including but not limited to the device information of the user, the personal information of the user, etc.), the related data, etc. related to the present invention are all information authorized by the user or authorized by each party.
It can be clearly understood by those skilled in the art that, for convenience and simplicity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The above description is intended to be illustrative of the preferred embodiment of the present invention and should not be taken as limiting the invention, but rather, the intention is to cover all modifications, equivalents, and alternatives falling within the spirit and scope of the invention.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and all the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (15)

1. A disaster recovery method is applied to a data management system, and the data management system comprises: a main example, the method comprising:
periodically backing up the data of the main example according to a first preset period to obtain a timed backup example;
receiving a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required;
and covering the main instance with the timing backup instance corresponding to the time needing rollback.
2. The disaster recovery method according to claim 1, wherein the method further comprises:
receiving a deletion retrieval instruction aiming at the main example; the mistaken deletion retrieval instruction comprises the following steps: data identification needing to be retrieved;
and migrating the data corresponding to the data identification in the timed backup instance to the main instance.
3. The disaster recovery method according to claim 2, wherein the migrating the data corresponding to the data identifier in the timed backup instance to the primary instance comprises:
and migrating the data which is closest to the receiving time of the mistaken deletion retrieval instruction and corresponds to the data identification in the timed backup example to the main example.
4. The disaster recovery method according to claim 1, wherein said method further comprises:
backing up the data of the main example in real time to obtain a real-time backup example;
receiving a data read instruction for the primary instance;
and under the condition that the main instance fails, the real-time backup instance returns the data corresponding to the data reading instruction.
5. The disaster recovery method according to claim 4, wherein the backing up the data of the primary instance in real time to obtain a real-time backup instance comprises:
according to a second preset period, carrying out quasi-real-time backup on the data of the main example to obtain a quasi-real-time backup example; the second preset period is less than the first preset period;
receiving a data operation instruction for the main instance; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction;
and performing corresponding data operation on the quasi-real-time backup instance based on the data operation instruction between the adjacent quasi-real-time backup moments to obtain the real-time backup instance.
6. The disaster recovery method according to claim 5, wherein said performing, based on the data operation instruction located between adjacent quasi-real-time backup moments, corresponding data operation on the quasi-real-time backup instance further includes:
storing the data operation instruction between adjacent quasi-real-time backup moments to a message queue;
and the quasi real-time backup instance acquires the data operation instruction between the adjacent quasi real-time backup moments from the message queue.
7. The disaster recovery method according to claim 4, wherein said backing up the data of the primary instance in real time to obtain a real-time backup instance comprises:
according to a second preset period, carrying out quasi-real-time backup on the data of the main example to obtain a quasi-real-time backup example; the second preset period is less than the first preset period;
acquiring operation records of data operation instructions of the main example between adjacent quasi-real-time backup moments; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction;
and performing corresponding data operation on the quasi-real-time backup instance based on the operation record of the data operation instruction between the adjacent quasi-real-time backup moments to obtain the real-time backup instance.
8. The disaster recovery method according to claim 7, wherein before the quasi-real-time backup instance is obtained by performing corresponding data operation on the quasi-real-time backup instance based on the operation record of the data operation instruction between the adjacent quasi-real-time backup moments, the method further comprises:
storing the operation record to a message queue;
and the quasi real-time backup instance acquires the operation record from the message queue.
9. The disaster recovery method according to any one of claims 4 to 8, wherein the method further comprises:
under the condition that the real-time backup instance fails, copying the data of the main instance to the real-time backup instance within a period when the main instance does not execute a data operation instruction; the data operation instruction comprises: a data writing operation instruction and/or a data deleting operation instruction.
10. The disaster recovery method according to any one of claims 4 to 8, wherein the method further comprises:
and covering the real-time backup instance by using the timing backup instance corresponding to the time needing to be backed off.
11. The disaster recovery method according to any one of claims 4 to 8, wherein the method further comprises:
receiving a deletion and retrieval error instruction aiming at the main example; the mistaken deleting and retrieving instruction comprises the following steps: data identification needing to be retrieved;
and migrating the data corresponding to the data identification in the timed backup example to the real-time backup example.
12. The disaster recovery method according to any one of claims 4 to 8, wherein the method further comprises:
in the event that one of the primary instance and the live backup instance fails and the other fails, overriding the failed instance with the non-failed instance.
13. A disaster recovery apparatus, applied to a data management system, the data management system comprising: a primary instance, the disaster recovery device comprising:
the timing backup module is used for regularly backing up the data of the main example according to a first preset period to obtain a timing backup example;
a version rollback instruction receiving module, configured to receive a version rollback instruction for the primary instance; the version rollback instruction comprises: the time when rollback is required;
and the version rollback module is used for covering the main example by the timing backup example corresponding to the time needing rollback.
14. An electronic device, comprising:
processor, memory and computer program stored on said memory and executable on said processor, said processor implementing, when executing said program, a disaster recovery method as claimed in any one of claims 1 to 12.
15. A readable storage medium, wherein instructions in the storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the disaster recovery method of any one of claims 1 to 12.
CN202310075824.4A 2023-02-07 2023-02-07 Disaster recovery method and device, electronic equipment and storage medium Pending CN115878386A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310075824.4A CN115878386A (en) 2023-02-07 2023-02-07 Disaster recovery method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310075824.4A CN115878386A (en) 2023-02-07 2023-02-07 Disaster recovery method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115878386A true CN115878386A (en) 2023-03-31

Family

ID=85760804

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310075824.4A Pending CN115878386A (en) 2023-02-07 2023-02-07 Disaster recovery method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115878386A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117478510A (en) * 2023-12-28 2024-01-30 深圳市丰润达科技有限公司 Configuration backup method of network equipment, network equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101635638A (en) * 2008-07-25 2010-01-27 中兴通讯股份有限公司 Disaster tolerance system and disaster tolerance method thereof
CN103853634A (en) * 2014-02-26 2014-06-11 北京优炫软件股份有限公司 Disaster recovery system and disaster recovery method
CN108632067A (en) * 2017-03-21 2018-10-09 华为技术有限公司 Disaster tolerance dispositions method, apparatus and system
CN112380053A (en) * 2020-10-22 2021-02-19 中科热备(北京)云计算技术有限公司 Rollback technology application method based on any time point
CN114218013A (en) * 2021-12-13 2022-03-22 北京字节跳动网络技术有限公司 Searching method, searching device and electronic equipment storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101635638A (en) * 2008-07-25 2010-01-27 中兴通讯股份有限公司 Disaster tolerance system and disaster tolerance method thereof
CN103853634A (en) * 2014-02-26 2014-06-11 北京优炫软件股份有限公司 Disaster recovery system and disaster recovery method
CN108632067A (en) * 2017-03-21 2018-10-09 华为技术有限公司 Disaster tolerance dispositions method, apparatus and system
CN112380053A (en) * 2020-10-22 2021-02-19 中科热备(北京)云计算技术有限公司 Rollback technology application method based on any time point
CN114218013A (en) * 2021-12-13 2022-03-22 北京字节跳动网络技术有限公司 Searching method, searching device and electronic equipment storage medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
张龙;张博;: "电网企业信息系统容灾备份关键技术研究" *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117478510A (en) * 2023-12-28 2024-01-30 深圳市丰润达科技有限公司 Configuration backup method of network equipment, network equipment and storage medium

Similar Documents

Publication Publication Date Title
JP5254611B2 (en) Metadata management for fixed content distributed data storage
US8250033B1 (en) Replication of a data set using differential snapshots
CA2929776C (en) Client-configurable security options for data streams
US20130138616A1 (en) Synchronizing updates across cluster filesystems
CN111078667B (en) Data migration method and related device
CA2929777A1 (en) Managed service for acquisition, storage and consumption of large-scale data streams
CA2930026A1 (en) Data stream ingestion and persistence techniques
US9971821B1 (en) Search and analytics for a storage systems
CN108255638B (en) Snapshot rollback method and device
CN106899654A (en) A kind of sequence value generation method, apparatus and system
JP2009251853A (en) Memory database, memory database system, and memory database update method
CN106686095A (en) Data storage method and device based on erasure code technology
CN113448938A (en) Data processing method and device, electronic equipment and storage medium
CN115878386A (en) Disaster recovery method and device, electronic equipment and storage medium
CN108572888B (en) Disk snapshot creating method and disk snapshot creating device
US20080040368A1 (en) Recording notations per file of changed blocks coherent with a draining agent
CN110795416A (en) File copying method, device, equipment and readable storage medium
US11436089B2 (en) Identifying database backup copy chaining
US20210303594A1 (en) Recovering from a failure of an asynchronous replication node
CN109522177A (en) A kind of task daily record processing system, method and device
CN115421856A (en) Data recovery method and device
US11341159B2 (en) In-stream data load in a replication environment
US11531642B2 (en) Synchronous object placement for information lifecycle management
CN114328018A (en) Snapshot creating method, computing device and storage medium
CN108959501B (en) Method and device for deleting ES index

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20230331