CN104536852A - Data recovery method and device - Google Patents

Data recovery method and device Download PDF

Info

Publication number
CN104536852A
CN104536852A CN201410852339.4A CN201410852339A CN104536852A CN 104536852 A CN104536852 A CN 104536852A CN 201410852339 A CN201410852339 A CN 201410852339A CN 104536852 A CN104536852 A CN 104536852A
Authority
CN
China
Prior art keywords
data
snapshot
storage device
main storage
recovery
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.)
Granted
Application number
CN201410852339.4A
Other languages
Chinese (zh)
Other versions
CN104536852B (en
Inventor
钟延辉
张程伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN201410852339.4A priority Critical patent/CN104536852B/en
Publication of CN104536852A publication Critical patent/CN104536852A/en
Priority to PCT/CN2015/089974 priority patent/WO2016107219A1/en
Application granted granted Critical
Publication of CN104536852B publication Critical patent/CN104536852B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/16Error detection or correction of the data by redundancy in hardware

Abstract

The embodiment of the invention discloses a data recovery method and device. The method comprises the steps that main storage equipment receives a data recovery request sent by a host; according to an identifier of a snapshot where data needing to be recovered are located, a first snapshot in backup storage equipment is mounted; the main storage equipment determines a second snapshot stored in the main storage equipment according to the identifier of the snapshot where the data needing to be recovered are located, wherein the second snapshot is an available snapshot; the main storage equipment determines first recovery data of the data, shared in the first snapshot and the second snapshot, needing to be stored; the main storage equipment provides the first recovery data of the second snapshot and the second recovery data of the first snapshot for the host. According to the data recovery method and device, the host management complexity can be lowered, the data safety of the backup storage equipment can be improved, and the recovery speed can be increased.

Description

Data reconstruction method and device
Technical field
The present invention relates to data backup and recovery technology field, particularly relate to data reconstruction method and device.
Background technology
Along with the fast development of computer technology, the demand of data backup is also got more and more.Traditionally, people adopt the technology such as data Replica, backup, recovery to protect important data message always, regularly back up data or copy.Because data backup procedure can affect application performance, and very consuming time, therefore data backup be usually arranged on system load lighter time carry out (as night).
Obviously, there is a significant deficiency in this data backup mode, i.e. backup window problem.During data backup, business event needs temporary transient stopping externally providing service.Along with the quickening of business data amount and data growth rate, this window may require more and more longer, and this is unacceptable for critical operation system.Therefore, just need data backup window to reduce as much as possible, be even reduced into zero, data snapshot (Snapshot) is exactly the technology of data copy occurred to meet such demand.
Snapshot is the mirror image of certain data set in a certain particular moment, and it is a complete available read-only copy of this data set, therefore, also referred to as full dose snapshot.In order to reduce the storage space shared by snapshot, there has been proposed and write redirected (ROW, Redirect on Write) snapping technique.Specifically when using ROW snapping technique to carry out data backup, at main storage device, many parts of snapshots can be generated at different time points, in every part of snapshot, preserving the data mode of disk in the corresponding moment.Afterwards, according to the data of preserving in each part snapshot, can store in the data batchmove in each moment to backup storage device, in backup storage device, also create corresponding snapshot simultaneously.For the ease of distinguishing, the snapshot generated being called " main snapshot ", the snapshot generated in backup storage device is called " backup snapshots " in primary storage.Along with the generation of new main snapshot, and the execution of data transfer operation, the quantity of the backup snapshots stored in backup storage device increases gradually, several parts of main snapshots (such as, five parts) of then general only preservation generation recently in main storage device.
After the backup having carried out data in the manner described above, if to find in main storage device the phenomenons such as loss of data, then can utilize the data of backup, by the state of this date restoring to quarter in some time in the past.But, as mentioned before, the data mode of preserving in the main snapshot that some generated comparatively early stores owing to generally can be transferred in backup storage device, therefore, following situation may occur: when needing the data in main storage device to the state in certain moment, data corresponding to this moment have been saved in backup storage device.
For this situation, in the prior art, generally can carry out as follows: first, by the snapshots in backup storage device to main frame, main frame is made to perceive the existence of backup storage device, afterwards, read the data of backup snapshots in backup storage device again by main frame, and then carry out the recovery of data.
But this mode exists following problem to I haven't seen you for ages: due in the process of date restoring, main frame needs the existence of perception backup storage device, the management complexity of main frame can be increased on the one hand; On the other hand, the data security in backup storage device also may be made to be on the hazard, because once the more implanted rogue programs of main frame, then the generation of the phenomenon such as may cause the leakage of data in backup storage device or be tampered.Moreover the size due to the bandwidth at main frame and standby system two ends determines the speed of recovery, but the bandwidth at main frame and standby system two ends is very little in existing situation, distant, what therefore cause needed for recovering is chronic.
Therefore, how in the process of date restoring, reduce the management complexity of operation system, improve the data security in backup storage device, improve the speed recovered, become the technical matters needing those skilled in the art to solve.
Summary of the invention
Data reconstruction method and device is provided, to solve the problems of the prior art in the embodiment of the present invention.
In order to solve the problems of the technologies described above, the embodiment of the invention discloses following technical scheme:
First aspect, provides a kind of data reconstruction method, and described method is applied to standby system, and described standby system comprises main storage device and backup storage device, and described method comprises:
The data recovery request that described main storage device Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Described first snapshot in described main storage device backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Described main storage device determines according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
What described main storage device was determined to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
Described main storage device provides the described first recovery data of described second snapshot and second of described first snapshot to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
Second aspect, provides a kind of data reconstruction method, and described method is applied to standby system, and described standby system comprises main storage device and backup storage device, and described method comprises:
Described backup storage device receives the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
Described backup storage device determines the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device by described backup storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Described backup storage device receives the request of data that described main storage device sends;
Described backup storage device sends second according to described request of data to described main storage device and recovers data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
The third aspect, provides a kind of main storage device, and described main storage device is applied to standby system, and described standby system comprises described main storage device and backup storage device, and described main storage device comprises:
Receiving element, for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Carry unit, for described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Determining unit, for determining according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device; And describedly need in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot;
Providing unit, recovers second of data and described first snapshot for providing described first of described second snapshot to described main frame and recovers data; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
Fourth aspect, provides a kind of backup storage device, and described backup storage device is applied to standby system, and described standby system comprises main storage device and described backup storage device, and described backup storage device comprises:
Receiving element, for receiving the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
Determining unit, for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Carry unit, for determining the described first recovery data that need in the data recovered to described main storage device for described main storage device by described first snapshots; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores
Described receiving element is also for receiving the request of data that described main storage device sends;
Transmitting element, recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
5th aspect, a kind of main storage device is provided, described main storage device is applied to standby system, described standby system comprises described main storage device and backup storage device, described main storage device comprises processor and storer, described processor and described storer by bus communication, described processor perform computer instruction in described storer for:
The data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
That determines to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
The described first recovery data of described second snapshot and second of described first snapshot is provided to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
6th aspect, provide a kind of backup storage device, described backup storage device is applied to standby system, described standby system comprises main storage device and described backup storage device, described backup storage device comprises processor and storer, described processor and described storer by bus communication, described processor perform computer instruction in described storer for:
Receive the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
The first snapshot is determined according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Receive the request of data that described main storage device sends;
Send second according to described request of data to described main storage device and recover data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
7th aspect, additionally provides a kind of standby system, and described standby system comprises main storage device and backup storage device, wherein,
Described main storage device is used for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request; Snapshots request is sent to described backup storage device according to the described mark of the snapshot at the data place of recovering that needs;
Described backup storage device is used for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark; Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device;
Described main storage device is also for the first snapshot described in carry; The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
Described main storage device also describedly needs in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot; Request of data is sent to described backup storage device;
Described backup storage device also recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data;
Described main storage device also recovers data and the second recovery data for sending first to described main frame.
In the embodiment of the present invention, main frame only perceives the existence of main storage device, does not need to be mounted in operation system by backup storage device again, can realize the recovery of storage object, thus reduce the management complexity of operation system, improve the data security in backup storage device.In addition, because operation system and main storage device bandwidth are comparatively large, and close together between the two, need the data recovered to obtain from main storage device as far as possible, therefore, the speed of recovery can be improved.
Accompanying drawing explanation
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, below the accompanying drawing used required in describing embodiment is briefly described, apparently, for those of ordinary skills, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
Fig. 1 is the first embodiment process flow diagram of data reconstruction method of the present invention;
Fig. 2 is the primary storage and back-up storage structural representation that relate in data reconstruction method of the present invention;
Fig. 3 is another primary storage and back-up storage structural representation of relating in data reconstruction method of the present invention;
Fig. 4 is block data structure schematic diagram in the snapshot related in data reconstruction method of the present invention;
Fig. 5 is the second embodiment process flow diagram of data reconstruction method of the present invention;
Fig. 6 is the first embodiment block diagram of Data Recapture Unit of the present invention;
Fig. 7 is the second embodiment block diagram of Data Recapture Unit of the present invention.
Embodiment
Technical scheme in the embodiment of the present invention is understood better in order to make those skilled in the art person, and enable the above-mentioned purpose of the embodiment of the present invention, feature and advantage become apparent more, below in conjunction with accompanying drawing, technical scheme in the embodiment of the present invention is described in further detail.
In embodiments of the present invention, when needs carry out date restoring, will not be mounted in main frame by backup storage device, the data recovery request of main frame can be sent to primary storage, primary storage again and carry out mutual between backup storage device, obtain relevant data, after completing recovery, then return to main frame by primary storage.That is, can carry out data interaction by between primary storage and backup storage device, main frame need not the existence of perception backup storage device, like this, in the process of date restoring, the management complexity of main frame can be reduced, improve the data security in backup storage device.Wherein, in specific implementation process, in order to realize the data interaction between primary storage and back-up storage, preset program can be performed at main storage device and backup storage device respectively, by the execution of this program and cooperatively interact, realize concrete data recovery procedure.Below respectively from the angle of main storage device and backup storage device, concrete implementation is described in detail.
Embodiment one
See Fig. 1, be first embodiment of the invention process flow diagram, provide a kind of data reconstruction method, be applied to standby system, standby system comprises main storage device and backup storage device, and the method can comprise the following steps:
S101: the data recovery request that described main storage device Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
In embodiments of the present invention, in the process of carrying out date restoring, the data recovery request of operation system can be sent to main storage device, afterwards, then returns concrete data by main storage device, date restoring is carried out for operation system, during this period, carry out data interaction by main storage device and backup storage device, but, main frame perception less than, also without the need to this reciprocal process of perception.
Wherein, main frame sends in the data recovery request of main storage device to carry needs the data recovered (may be single file, or All Files under catalogue etc.) and the mark of snapshot at place, this mark of the data place snapshot recovered that needs can be inputted by user (such as being initiated by the mode of search), or, can also be selected from numerous data that can recover by user.Wherein, for the latter, before user selects, the snapshot that can recover preserved and other relevant informations of preserving which data can be supplied to user in standby system.
For this reason, in embodiments of the present invention, first main frame can send to main storage device and check request, main storage device receive main frame check request after, can first carry out with backup storage device alternately, now, the mark of each part backup snapshots can be returned to main storage device by backup storage device.In other words by backup snapshots carry to main storage device.When snapshot is file system snapshot, wherein, file system storage object can comprise the concrete form such as root directory, sub-directory at different levels, file, that is, now, the information that backup storage device returns to main storage device is the file name, directory name etc. that each part snapshot comprises, but does not comprise the concrete data of each file.Main storage device is after receiving above-mentioned information, can show in the user interface, now, user can view many parts of snapshots, namely can see icon and the title of catalogue at different levels and file etc., but in fact now the actual data storage of every part of file on backup storage device.In the embodiment of the present invention, data recovery request is specifically as follows data read request, because under embodiment of the present invention scene, the main storage device that impinges upon soon at the data place that data read request is asked is lost, and the process therefore performing data read request is also the process of asked date restoring.Hereinafter referred to as data recovery request.
For ease of understanding, below by illustrated mode, said process is introduced.
See Fig. 2, suppose the moment of the request of checking receiving main frame, the snapshot preserved in main storage device has snap10 to snap14, the snapshot preserved in backup storage device has snap1 to snap14, that is, the current several parts of snapshots only having this up-to-date generation of snap10 to snap14 of main storage device, these impinging upon in main storage device soon of comparatively early generating of snap1 to snap9 are lost.Therefore, first the identification information of the data comprised in each part snapshot preserved in backup storage device can be showed user by main storage device, therefrom selects the concrete data needing to recover for user.
Also be, after backup storage device returns the mark of the data of preserving in each part backup snapshots, main storage device can know in each part backup snapshots of backup storage device to preserve which data, as shown in Figure 3, bsnap1 to the bsnap14 that main storage device shows is the corresponding each part backup snapshots of difference just, after showing user, user can select to check concrete certain part of backup snapshots, now, just can show the mark of the data of preserving in this backup snapshots, comprise icon, title etc., wherein, icon can distinguish the type of each storage object, such as, belong to catalogue or file, when being file, concrete file type, etc..Like this, user just according to the demand of oneself, can therefrom select the concrete storage object needing to recover.
Because main storage device has got in backup storage device the mark obtaining the data of preserving in each part backup snapshots, therefore, user therefrom can select the concrete data needing to recover.Concrete, due in the selection course of user, generally can first select to check certain a backup snapshots, and then the data selecting concrete needs to recover from this part of snapshot, therefore, when determining the data needing to recover, the mark of the target backup snapshots at this data place can also be determined.Also namely, can determine in this step that user needs to which the concrete data in which part snapshot to recover, such as, determine and need the data in bsnap1 to recover, etc.Wherein, need the data recovered can be certain single file, or catalogue, can also be certain logical block (Logical Unit, LU) logical block is sometimes also referred to as LUN (Logical Unit Number). when the data that the needs selected recover are certain catalogue, then mean that needs recover all files under this catalogue, when catalogue is root directory, mean that needs all recover all files in selected snapshot.
S102: described first snapshot in described main storage device backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Owing to including the mark needing the data place snapshot recovered in the data recovery request that receives in step S101, therefore, when can determine that the data that needs recover are preserved in backup storage device further, the first corresponding snapshot, after determining this first snapshot, main storage device can by this in backup storage device first snapshots in main storage device.It should be noted that, by this operation in the first snapshots to main storage device, be equivalent to establish associating between main storage device with this first snapshot, main storage device can access the data in this first snapshot.
S103: described main storage device determines according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
May be saved in backup storage device although the snapshot at the data place that current needs recover is current, but, owing to also saving part snapshot in main storage device, and, also may there are the data that a part is relevant to the data that these needs recover in this part snapshot preserved in main storage device, therefore, this part snapshot that main storage device self stores may be also helpful for the recovery of data, therefore, available snapshot is called.Wherein, during specific implementation, the mark of each part snapshot that the mark and main storage device self that need the snapshot at the data place of recovering can be stored contrasts, can determine in each part snapshot that main storage device self stores by comparison, which snapshot is newer for needing the snapshot at the data place of recovering, and then, just these relatively new snapshots can be defined as the second snapshot.
S104: what described main storage device was determined to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
For a certain snapshot, the data of wherein preserving generally are preserved in multiple data block.For file system snapshot, file system generally safeguards the relation between each data block with tree structure.
Be saved in the process of backup storage device at the snapshot produced by each time point, also can store these snapshots in main storage device, identical impinging upon soon in main storage device and backup storage device has identical mark.Therefore, same snapshot may both exist at main storage device, also existed in backup storage device; In addition, for the snapshot do not produced in the same time, partial data block wherein may be had to be identical, such as, the snapshot that moment 1 generates comprises certain data block, and when the moment 2 backs up again, the data in this data block were not revised relative to the moment 1, then still can comprise this data block in the moment 2, and the mark of same data block in main snapshot and backup snapshots and concrete data content etc. are all identical.Comprehensive above 2 known: need to recover certain data and can recover completely in the snapshot of the backup storage device of backup, but also may partly exist in certain part of snapshot of main storage device preservation, now, if directly read this part data from main storage device, then can reduce the volume of transmitted data of backup storage device to main storage device, reach the effect improving further and recover efficiency.
Based on above-mentioned analysis, the implementation that the embodiment of the present invention provides can be: main storage device is when receiving the data recovery request that main frame sends, while by the first snapshots in backup storage device to main storage device, can also according to the current mark needing the snapshot at the data place of recovering, determine the second available snapshot stored in main storage device, afterwards, can determine and wherein whether have partial data block to be shared block between the first snapshot and the second snapshot, another part data block is difference block, wherein, so-called shared block is the data block simultaneously appeared in the first snapshot and the second snapshot, difference block is only appear at the data block in the first snapshot, if Storage sharing data block between the first snapshot and the second snapshot, then can be defined as the first recovery data by belonging in the second snapshot the data comprised in shared block.There is shared data block between first snapshot and the second snapshot, there are shared data also referred to as between the first snapshot and the second snapshot.
S105: described main storage device provides the described first recovery data of described second snapshot and second of described first snapshot to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
About the data in difference block, main storage device can be sent to by backup storage device, main storage device is after the data receiving difference block, data can be recovered as second, then, first recovery data and second are recovered data and is supplied to operation system main frame, like this, above-mentioned first just can be utilized to recover data for main frame and the second recovery data are recovered needing the data recovered, thus reduce the volume of transmitted data of backup storage device to main storage device, improve the efficiency recovered further.
For the ease of understanding said process, describe in detail below in conjunction with the example in accompanying drawing.
See Fig. 4, suppose that target data to be restored is arranged in snap1, the current snapshot simultaneously appeared in primary storage and back-up storage is snap10, wherein, the data block that snap1 has comprises A, B, C, D, E, F, G, the data block that snap10 has comprises H, I, J, B, C, D, F, then can determine that shared block is between the two B, C, D, F, and only appearing at the snap1 difference block do not appeared in snap10 is A, E, G.Suppose that the data block that current packet to be restored contains is A, B, D, E, G, then the data in data block A, E, G can be returned to main storage device by backup storage device, like this, the data in data block B, D are extracted the snapshot 10 that main storage device just can be preserved from self, then together with the data in the data block A received from backup storage device, E, G, be supplied to main frame, main frame can carry out date restoring accordingly.
It should be noted that, about the concrete relation needed between the data of recovery and the data block at place, and final rejuvenation of carrying out concrete data according to the data in data block, under file system snapshot scene, can carry out according to the implementation provided in concrete file system, owing to not relating to the inventive point of the application, therefore, no longer describe in detail here.
Above from the angle of main storage device, the data reconstruction method that the embodiment of the present invention provides is introduced, in the method, main storage device is after the data recovery request receiving main frame transmission, can by the communication between main storage device and backup storage device, get the concrete data for recovering, these data divisions come from main storage device, part comes from backup storage device, but, for main frame, only perceive the existence of main storage device, do not need again backup storage device to be mounted on main frame, the recovery of data can be realized, thus reduce the management complexity of main frame, improve the data security in backup storage device.In addition, due to main frame and main storage device bandwidth sum close together, need the data recovered to obtain from main storage device as far as possible, therefore, the speed of recovery can be improved.
Embodiment two
See Fig. 5, this embodiment two, from the angle of backup storage device, provides a kind of data reconstruction method, and the method can comprise the following steps:
S501: described backup storage device receives the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
S502: described backup storage device determines the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
S503: described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device by described backup storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
S504: described backup storage device receives the request of data that described main storage device sends;
S505: described backup storage device sends second according to described request of data to described main storage device and recovers data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
It should be noted that, above-described embodiment two, compared with embodiment one, is only that the angle of description is different, and relevant concrete technology realizes being all identical, and therefore, in embodiment two, non-detailed portion see the introduction in embodiment one, can repeat no more here.
Corresponding with the data reconstruction method that embodiments of the invention one provide, the embodiment of the present invention additionally provides a kind of storage object recovery device, and see Fig. 6, this device can comprise:
Receiving element 601, for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Carry unit 602, for described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Determining unit 603, for determining according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device; And describedly need in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot;
Providing unit 604, recovers second of data and described first snapshot for providing described first of described second snapshot to described main frame and recovers data; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
Corresponding with the data reconstruction method that embodiment two provides, the embodiment of the present invention additionally provides a kind of backup storage device, described backup storage device is applied to standby system, described standby system comprises main storage device and described backup storage device, see Fig. 7, backup storage device can comprise:
Receiving element 701, for receiving the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
Determining unit 702, for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Carry unit 703, for determining the described first recovery data that need in the data recovered to described main storage device for described main storage device by described first snapshots; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Described receiving element is also for receiving the request of data that described main storage device sends;
Transmitting element 704, recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
As seen from the above-described embodiment, in the process of date restoring, main frame only perceives the existence of main storage device, do not need again backup storage device to be mounted on main frame, the recovery of data can be realized, thus reduce the management complexity of main frame, improve the data security in backup storage device.In addition, due to main frame and main memory bandwidth and close together, need the data recovered to obtain from main storage device as far as possible, therefore, the speed of recovery can be improved.
In addition, the embodiment of the present invention additionally provides a kind of main storage device, described main storage device is applied to standby system, described standby system comprises described main storage device and backup storage device, described main storage device comprises processor and storer, and described processor and described storer pass through bus communication; Bus can be instruction set architecture instruction set architecture (ISA, InstructionSet Architecture) bus, Peripheral Component Interconnect standard (PCI, Peripheral Component Interconnec) bus or EISA (EISA, Extended Industry Standard Architecture) bus etc.Described bus can be divided into address bus, data bus, control bus etc.Described storer is for storing one section of computer instruction, and described processor for reading the computer instruction in described storer, and performs following steps:
The data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
That determines to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
The described first recovery data of described second snapshot and second of described first snapshot is provided to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
In addition, the embodiment of the present invention additionally provides a kind of backup storage device, described backup storage device is applied to standby system, described standby system comprises main storage device and described backup storage device, described backup storage device comprises processor and storer, and described processor and described storer pass through bus communication; Bus can be isa bus, pci bus or eisa bus etc.Described bus can be divided into address bus, data bus, control bus etc.Described storer is for storing one section of computer instruction, and described processor for performing the computer instruction in described storer, and performs following steps:
Receive the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
The first snapshot is determined according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Receive the request of data that described main storage device sends;
Send second according to described request of data to described main storage device and recover data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
In addition, this embodiment of the present invention additionally provides a kind of standby system, and described standby system comprises main storage device and backup storage device, wherein,
Described main storage device is used for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request; Snapshots request is sent to described backup storage device according to the described mark of the snapshot at the data place of recovering that needs;
Described backup storage device is used for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark; Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device;
Described main storage device is also for the first snapshot described in carry; The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
Described main storage device also describedly needs in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot; Request of data is sent to described backup storage device;
Described backup storage device also recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data;
Described main storage device also recovers data and the second recovery data for sending first to described main frame.
Those of ordinary skill in the art can recognize, in conjunction with unit and the algorithm steps of each example of embodiment disclosed herein description, can realize with the combination of electronic hardware or computer software and electronic hardware.These functions perform with hardware or software mode actually, depend on application-specific and the design constraint of technical scheme.Professional and technical personnel can use distinct methods to realize described function to each specifically should being used for, but this realization should not thought and exceeds scope of the present invention.
Those skilled in the art can be well understood to, and for convenience and simplicity of description, the specific works process of the system of foregoing description, device and unit, with reference to the corresponding process in preceding method embodiment, can not repeat them here.
In several embodiments that the application provides, should be understood that disclosed system, apparatus and method can realize by another way.Such as, device embodiment described above is only schematic, such as, the division of described unit, be only a kind of logic function to divide, actual can have other dividing mode when realizing, such as multiple unit or assembly can in conjunction with or another system can be integrated into, or some features can be ignored, or do not perform.Another point, shown or discussed coupling each other or direct-coupling or communication connection can be by some interfaces, and the indirect coupling of device or unit or communication connection can be electrical, machinery or other form.
The described unit illustrated as separating component or can may not be and physically separates, and the parts as unit display can be or may not be physical location, namely can be positioned at a place, or also can be distributed in multiple network element.Some or all of unit wherein can be selected according to the actual needs to realize the object of the present embodiment scheme.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, also can be that the independent physics of unit exists, also can two or more unit in a unit integrated.
If described function using the form of SFU software functional unit realize and as independently production marketing or use time, can be stored in a computer read/write memory medium.Based on such understanding, the part of the part that technical scheme of the present invention contributes to prior art in essence in other words or this technical scheme can embody with the form of software product, this computer software product is stored in a storage medium, comprising some instructions in order to make a computer equipment (can be personal computer, server, or the network equipment etc.) or processor (processor) perform all or part of step of method described in each embodiment of the present invention.And aforesaid storage medium comprises: USB flash disk, portable hard drive, ROM (read-only memory) (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD etc. various can be program code stored medium.
The above; be only the specific embodiment of the present invention, but protection scope of the present invention is not limited thereto, is anyly familiar with those skilled in the art in the technical scope that the present invention discloses; change can be expected easily or replace, all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should described be as the criterion with the protection domain of claim.

Claims (11)

1. a data reconstruction method, is characterized in that, described method is applied to standby system, and described standby system comprises main storage device and backup storage device, and described method comprises:
The data recovery request that described main storage device Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Described first snapshot in described main storage device backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Described main storage device determines according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
What described main storage device was determined to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
Described main storage device provides the described first recovery data of described second snapshot and second of described first snapshot to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
2. method according to claim 1, is characterized in that, the described data needing recovery are file.
3. method according to claim 1, is characterized in that, the described data needing recovery are logical block.
4. a data reconstruction method, is characterized in that, described method is applied to standby system, and described standby system comprises main storage device and backup storage device, and described method comprises:
Described backup storage device receives the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
Described backup storage device determines the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device by described backup storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Described backup storage device receives the request of data that described main storage device sends;
Described backup storage device sends second according to described request of data to described main storage device and recovers data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
5. method according to claim 4, is characterized in that, the described data needing recovery are file.
6. method according to claim 4, is characterized in that, the described data needing recovery are logical block.
7. a main storage device, is characterized in that, described main storage device is applied to standby system, and described standby system comprises described main storage device and backup storage device, and described main storage device comprises:
Receiving element, for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Carry unit, for described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
Determining unit, for determining according to the described mark of the snapshot at the data place of recovering that needs the second snapshot stored in described main storage device; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device; And describedly need in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot;
Providing unit, recovers second of data and described first snapshot for providing described first of described second snapshot to described main frame and recovers data; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
8. a backup storage device, is characterized in that, described backup storage device is applied to standby system, and described standby system comprises main storage device and described backup storage device, and described backup storage device comprises:
Receiving element, for receiving the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
Determining unit, for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Carry unit, for determining the described first recovery data that need in the data recovered to described main storage device for described main storage device by described first snapshots; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Described receiving element is also for receiving the request of data that described main storage device sends;
Transmitting element, recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
9. a main storage device, it is characterized in that, described main storage device is applied to standby system, described standby system comprises described main storage device and backup storage device, described main storage device comprises processor and storer, described processor and described storer by bus communication, described processor perform computer instruction in described storer for:
The data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request;
Described first snapshot in backup storage device according to the described mark carry needing the snapshot at the data place of recovering; The mark of described first snapshot is identical with the mark of the snapshot at the described data place needing to recover;
The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
That determines to share in described first snapshot and described second snapshot describedly needs in the data recovered first to recover data;
The described first recovery data of described second snapshot and second of described first snapshot is provided to recover data to described main frame; Wherein, described second data are the data in the data of the described needs recovery that described first snapshot comprises except described first recovery data.
10. a backup storage device, it is characterized in that, described backup storage device is applied to standby system, described standby system comprises main storage device and described backup storage device, described backup storage device comprises processor and storer, described processor and described storer by bus communication, described processor perform computer instruction in described storer for:
Receive the snapshots request that described main storage device sends; The mark that described main storage device needs the snapshot at the data place of recovering is carried in described snapshots request; The wherein said snapshot needing the data place of recovering is the snapshot that described main storage device is determined according to the data recovery request that main frame sends;
The first snapshot is determined according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark;
Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device; Wherein, described first recovers the data that data are the described needs recovery that the second snapshot and described first snapshot are shared; Described second snapshot is the available snapshot that described main storage device stores;
Receive the request of data that described main storage device sends;
Send second according to described request of data to described main storage device and recover data; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data.
11. 1 kinds of standby systems, is characterized in that, described standby system comprises main storage device and backup storage device, wherein,
Described main storage device is used for the data recovery request that Receiving Host sends; The mark of the snapshot needing the data place of recovering is carried in described data recovery request; Snapshots request is sent to described backup storage device according to the described mark of the snapshot at the data place of recovering that needs;
Described backup storage device is used for determining the first snapshot according to the described mark of the snapshot at the data place of recovering that needs; The snapshot that the data place needing to recover sent out by described first snapshot and described needs has identical mark; Described first snapshots is determined described the first recovery data needed in the data recovered to described main storage device for described main storage device;
Described main storage device is also for the first snapshot described in carry; The second snapshot stored in described main storage device is determined according to the described mark of the snapshot at the data place of recovering that needs; Wherein said second snapshot is available snapshot; And store the snapshot with described second snapshot with like-identified in described backup storage device;
Described main storage device also describedly needs in the data recovered first to recover data for what determine to share in described first snapshot and described second snapshot; Request of data is sent to described backup storage device;
Described backup storage device also recovers data for sending second according to described request of data to described main storage device; Wherein, described second recovery data are the described data needed in the data recovered except described first recovery data;
Described main storage device also recovers data and the second recovery data for sending first to described main frame.
CN201410852339.4A 2014-12-31 2014-12-31 Data recovery method and device Active CN104536852B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201410852339.4A CN104536852B (en) 2014-12-31 2014-12-31 Data recovery method and device
PCT/CN2015/089974 WO2016107219A1 (en) 2014-12-31 2015-09-18 Data recovery method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410852339.4A CN104536852B (en) 2014-12-31 2014-12-31 Data recovery method and device

Publications (2)

Publication Number Publication Date
CN104536852A true CN104536852A (en) 2015-04-22
CN104536852B CN104536852B (en) 2017-01-25

Family

ID=52852382

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410852339.4A Active CN104536852B (en) 2014-12-31 2014-12-31 Data recovery method and device

Country Status (2)

Country Link
CN (1) CN104536852B (en)
WO (1) WO2016107219A1 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016107219A1 (en) * 2014-12-31 2016-07-07 华为技术有限公司 Data recovery method and apparatus
CN106933700A (en) * 2015-12-31 2017-07-07 伊姆西公司 For the method and apparatus of the data backup between recovering
CN107038088A (en) * 2016-09-28 2017-08-11 阿里巴巴集团控股有限公司 A kind of data reconstruction method and device
CN113468103A (en) * 2020-03-30 2021-10-01 阿里巴巴集团控股有限公司 Method and device used in snapshot migration

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020083366A1 (en) * 2000-12-21 2002-06-27 Ohran Richard S. Dual channel restoration of data between primary and backup servers
CN103678039A (en) * 2013-12-05 2014-03-26 华为技术有限公司 Data recovery method and device
CN103761161A (en) * 2013-12-31 2014-04-30 华为技术有限公司 Method, server and system for data recovery

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8909882B2 (en) * 2009-11-22 2014-12-09 International Business Machines Corporation Concurrent data processing using snapshot technology
CN101777014A (en) * 2010-02-03 2010-07-14 华为终端有限公司 Backup processing method and device
CN104536852B (en) * 2014-12-31 2017-01-25 华为技术有限公司 Data recovery method and device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020083366A1 (en) * 2000-12-21 2002-06-27 Ohran Richard S. Dual channel restoration of data between primary and backup servers
CN103678039A (en) * 2013-12-05 2014-03-26 华为技术有限公司 Data recovery method and device
CN103761161A (en) * 2013-12-31 2014-04-30 华为技术有限公司 Method, server and system for data recovery

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016107219A1 (en) * 2014-12-31 2016-07-07 华为技术有限公司 Data recovery method and apparatus
CN106933700A (en) * 2015-12-31 2017-07-07 伊姆西公司 For the method and apparatus of the data backup between recovering
CN107038088A (en) * 2016-09-28 2017-08-11 阿里巴巴集团控股有限公司 A kind of data reconstruction method and device
CN113468103A (en) * 2020-03-30 2021-10-01 阿里巴巴集团控股有限公司 Method and device used in snapshot migration
CN113468103B (en) * 2020-03-30 2024-03-08 阿里巴巴集团控股有限公司 Method and device used in snapshot migration

Also Published As

Publication number Publication date
WO2016107219A1 (en) 2016-07-07
CN104536852B (en) 2017-01-25

Similar Documents

Publication Publication Date Title
CN103197990B (en) Automated priority restores and relevant apparatus and method
CN102902600B (en) Efficient application-aware disaster recovery
CN103778034B (en) Data backup disaster recovery method and system based on cloud storage
CN103064763B (en) A kind of data back up method and relevant device, system
US20170344433A1 (en) Apparatus and method for data migration
CN105302675A (en) Method and device for data backup
US20190227710A1 (en) Incremental data restoration method and apparatus
CN103473277A (en) Snapshot method and device for file systems
CN104536852A (en) Data recovery method and device
EP3051408A1 (en) Data operating method and device
CN104461687A (en) Virtual machine configuration information storage method and device
CN105095027A (en) Data backup method and apparatus
CN108255994A (en) A kind of database version management method based on database snapshot
CN105550071B (en) System file upgrades and detection method, communication equipment
CN113886143A (en) Virtual machine continuous data protection method and device and data recovery method and device
CN106201772A (en) The backup of a kind of operating system based on data center, restoration methods and device
CN112380067A (en) Metadata-based big data backup system and method under Hadoop environment
CN105373450A (en) Data backup method and apparatus
CN103440204B (en) A kind of method of updating file system and memory device
CN106502830B (en) A kind of method for restoring system backup based on Btrfs file system
US9760450B2 (en) Restoring a clone point-in-time copy
CN109710377B (en) Method for recovering kvm virtual machine from faulty distributed storage
CN106878063A (en) A kind of method for recovering network topological sum business configuration data from network element
CN106293996B (en) Method of data synchronization, main equipment, alternate device and system
CN111857560A (en) Method, apparatus and computer program product for managing data

Legal Events

Date Code Title Description
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant