Summary of the invention
The purpose of the embodiment of the invention is to provide file memory method, file restoration methods, system and server, and is long release time to solve existing OSN data when the fault, even the problem that is difficult to recover.
For solving the problems of the technologies described above, the invention provides following technical scheme:
A kind of file memory method comprises:
After file to be stored is divided at least two obj ect file, each obj ect file is corresponded to a dummy storage node; Create at least two object sets in each object storage nodes, each dummy storage node is mapped at least two object sets, described at least two object sets belong to different object storage nodes, and described at least two object sets are used for storing the obj ect file of the dummy storage node correspondence of shining upon; Preserve the mapping relations table between described dummy storage node, described object storage nodes and described object set;
Wherein, described object set is the set of a group objects; At least two described object sets are combined, be mapped as a described dummy storage node.
A kind of file restoration methods, the file that the application of aforementioned file memory method is stored recovers, and comprising:
Receive the file recovery request;
When comprising the information that object storage nodes breaks down in the described file recovery request, search the mapping relations table between dummy storage node, object storage nodes and object set and the described object storage nodes corresponding virtual memory node that breaks down;
Obtain the object storage nodes except the described object storage nodes that breaks down that described each dummy storage node that finds is shone upon;
According to the object set on the described object storage nodes of obtaining the object set on the described object storage nodes that breaks down is recovered;
Upgrade the mapping relations table between described dummy storage node, object storage nodes and object set.
A kind of document storage system comprises: meta data server and at least two object storage nodes, wherein,
Described meta data server, after file to be stored is divided at least two obj ect file, each obj ect file is corresponded to a dummy storage node, create at least two object sets in each object storage nodes, each dummy storage node is mapped at least two object sets, and described at least two object sets belong to different object storage nodes; Preserve the mapping relations table between described dummy storage node, described object storage nodes and described object set;
Described object storage nodes is for the obj ect file of the dummy storage node correspondence of shining upon by the object set storage;
Wherein, described object set is the set of a group objects; At least two described object sets are combined, be mapped as a described dummy storage node.
A kind of file recovery system, the file that the application of aforementioned document storage system is stored recovers, and comprising: meta data server and at least two object storage nodes, wherein,
Described meta data server, be used for receiving the file recovery request, when comprising the information that object storage nodes breaks down in the described file recovery request, from dummy storage node, search in the mapping relations table between object storage nodes and object set and the described object storage nodes corresponding virtual memory node that breaks down, obtain the object storage nodes except the described object storage nodes that breaks down that described each dummy storage node that finds is shone upon, according to the object set on the described object storage nodes of obtaining the object set on the described object storage nodes that breaks down is recovered, and upgrade described dummy storage node, mapping relations table between object storage nodes and object set.
A kind of server is used for file is stored, and comprising:
Division unit is used for file to be stored is divided at least two obj ect file;
Corresponding unit is used for each obj ect file is corresponded to a dummy storage node;
Creating unit is used for creating at least two object sets in each object storage nodes;
Map unit is used for each dummy storage node is mapped at least two object sets, and described at least two object sets belong to different object storage nodes, and described at least two object sets are used for storing the obj ect file of the dummy storage node correspondence of shining upon;
Wherein, described object set is the set of a group objects; At least two described object sets are combined, be mapped as a described dummy storage node.
A kind of server, the file of application of aforementioned server stores recovers, and comprising:
Receiving element is used for receiving the file recovery request;
Search the unit, be used for when described file recovery request comprises the information that object storage nodes breaks down, searching the mapping relations table between dummy storage node, object storage nodes and object set and the described object storage nodes corresponding virtual memory node that breaks down;
Acquiring unit is used for obtaining the object storage nodes except the described object storage nodes that breaks down that described each dummy storage node that finds is shone upon;
Recovery unit is used for according to the object set on the described object storage nodes of obtaining the object set on the described object storage nodes that breaks down being recovered, and upgrades the mapping relations table between described dummy storage node, object storage nodes and object set.
The technical scheme that is provided by the above embodiment of the invention as seen, after in the embodiment of the invention file to be stored being divided at least two obj ect file, each obj ect file is corresponded to a dummy storage node, create at least two object sets in each object storage nodes, each dummy storage node is mapped at least two object sets, the obj ect file of the dummy storage node correspondence of shining upon by the storage of at least two object sets, at least two object sets belong to different object storage nodes; Obj ect file is not directly to be stored on the object storage nodes in the embodiment of the invention that hence one can see that, but by the mapping relations between dummy storage node and the object set, for the storage of obj ect file provide one in the middle of key-course, therefore receive when comprising the recovery request that object storage nodes breaks down, search the object storage nodes corresponding virtual memory node that breaks down with this, obtain the object storage nodes except the object storage nodes that breaks down that each dummy storage node of finding is shone upon, according to the object set on the object storage nodes of obtaining the object set on the object storage nodes that breaks down is recovered; Because when object storage nodes breaks down, only needing to safeguard with this object storage nodes has corresponding mapping relations on the dummy storage node of the relation of depositing, therefore is convenient to the recovery of file, has improved the speed that file recovers.
Embodiment
The embodiment of the invention provides file memory method, file restoration methods, system and server.
In order to make those skilled in the art person understand the present invention program better, and above-mentioned purpose of the present invention, feature and advantage can be become apparent more, the present invention is further detailed explanation below in conjunction with the drawings and specific embodiments.
Referring to Fig. 1, be the embodiment process flow diagram of file memory method of the present invention:
Step 101: file to be stored is divided at least two obj ect file.
In advance, comprise at least two object storage nodes in the system, create at least two object sets in each object storage nodes, object set at least two object storage nodes is made up, the object set of each described combination is corresponding with a dummy storage node, is about to a dummy storage node and is mapped on the different object sets of at least two different object storage nodes.
Operate requirement for the concurrent reading and writing to file in the realization system, usually a file is divided at least two obj ect file and stores, in order to read while write obj ect file, reduce the time of file processing.
Step 102: each obj ect file is corresponded to a dummy storage node.
In the embodiment of the invention, obj ect file is not directly to be stored on the different object storage nodes, but each obj ect file corresponds on the dummy storage node, and namely obj ect file and dummy storage node are the relations of shining upon one by one.
Step 103: create at least two object sets in each object storage nodes, each dummy storage node is mapped at least two object sets, at least two object sets belong to different object storage nodes.
What in the embodiment of the invention obj ect file is stored is object set on the object storage nodes, each dummy node shines upon mutually with different object sets at least two object storage nodes, all are mapped to the identical obj ect file of object centralized stores of a dummy storage node, backup mutually is convenient to file is recovered between these object sets.
Step 104: the obj ect file of the dummy storage node correspondence of shining upon by the storage of at least two object sets, finish current flow process.
Further, determine main object storage nodes according to the storage capacity of described at least two object storage nodes and from object storage nodes.In addition, can also regularly monitor the memory capacity of each dummy storage node, when memory capacity surpasses the threshold value set in advance, create new object set in object storage nodes, and be mapped to new dummy storage node after new object set made up.
Object set in the embodiment of the invention (Object Set is called for short Objset) refers to the set of a group objects, and two real object sets are combined, and is mapped as a vOSN (virtual OSN, virtual OSN).In the prior art, do not have the concept of object set, a file is mapped to 3 objects, and each object leaves on the OSN node, and this file is safeguarded by a table to the mapping relations unification of object.Need carry out file when recovering when certain OSN node damages, then all therewith OSN have the description information of files of the relation of depositing all will write again one time, when number of files was very big, the index word that relates to was also very big; The concept of embodiment of the invention application collection, a file is mapped to 3 objects, and each object leaves on the vOSN, and a vOSN is mapped to again on two different OSN, by above-mentioned two-layer mapping relations.Need carry out file when recovering when certain OSN node damages, then only need to rewrite all therewith OSN the descriptor of the vOSN of the relation of depositing is arranged, do not need to change the information of the file of enormous amount, so index word is less relatively.
Referring to Fig. 2, be the applied a kind of file storage organization synoptic diagram of the embodiment of the invention.
Among Fig. 2, MDS is meta data server, is responsible for providing to client the metadata of total system, the bibliographic structure of management total system, the data consistency of user right and maintenance system; OSN is object storage nodes, is used for the form storage object file with object set.Comprised two-layer mapping relations in the file storage organization shown in Fig. 2, File-1 is example with storage, wherein:
The ground floor mapping relations are the mapping relations between file and the dummy storage node, comprising:
File-1---------><vOSN_1,Object_1>,<vOSN_2,Object_1>,<vOSN_3,Object_1>
Above-mentioned mapping relations are interpreted as, and File-1 is divided into three obj ect file, and each obj ect file corresponds on the dummy storage node, and namely three obj ect file correspond to dummy storage node vOSN_1, vOSN_2 and vOSN_3 respectively;
Second layer mapping relations are the mapping relations between the object set of dummy storage node and object storage nodes:
vOSN_1---------><OSN_1,Objset_1>,<OSN_2,Objset_1>
vOSN_2---------><OSN_1,Objset_2>,<OSN_3,Objset_1>
vOSN_3---------><OSN_2,Objset_2>,<OSN_3,Objset_2>
Above-mentioned mapping relations are interpreted as, dummy storage node vOSN_1 is mapped to the object set Objset_1 of object storage nodes OSN_1 respectively, and the object set Objset_1 of object storage nodes OSN_2, namely the obj ect file of a dummy storage node correspondence is stored in respectively in the object set of two mutually redundant object storage nodes; In like manner, dummy storage node vOSN_2 is mapped to the object set Objset_2 of object storage nodes OSN_1 respectively, and the object set Objset_1 of object storage nodes OSN_3, dummy storage node vOSN_3 is mapped to the object set Objset_2 of object storage nodes OSN_2 respectively, and the object set Objset_2 of object storage nodes OSN_3.
According to above-mentioned two-layer mapping relations, then the final mapping relations of File-1 and obj ect file are as follows:
File-1--------->
<OSN_1,Objset_1,Object_1>,<OSN_2,Objset_1,Object_1>
<OSN_1,Objset_2,Object_1>,<OSN_3,Objset_1,Object_1>
<OSN_2,Objset_2,Object_1>,<OSN_3,Objset_2,Object_1>
In addition, need to prove, it is example that file storage organization illustrated in fig. 2 is stored in two object sets with each obj ect file, if desired each obj ect file is stored in the plural object set, for example, be stored in three object sets, then a vOSN can be mapped as 3 Objset.
In the embodiment of the invention, be mapped between two Objset on the same vOSN and be regardless of order, but MDS can be according to the master slave relation between definite two Objset of certain strategy.A common object set Objset belongs to certain OSN, and this OSN is an object storage nodes on the network, can measure object storage nodes by processing power, processing power comprises cpu busy percentage, the network bandwidth, hard disk I/O, memory usage, uses amount of capacity etc.MDS is when choosing two Objset on the different OSN and make up, be a unified metric with a plurality of metrics of OSN according to the different switching of its shared weight, this metric is more big to show that then the load of corresponding OSN is more high, so can be with the object set among this OSN as from object set, and the object set on the less relatively OSN of metric be as main object set.
Maximum storage capacity on configurable each vOSN of system is such as 800G.When system initialization, be combined into some vOSN in advance by the Objset that has created on the object storage nodes, in use, when the use amount of finding certain vOSN had reached 80%, then the vOSN that the Objset combination can be made new advances was used for the storage object file.
Corresponding with the embodiment of file memory method of the present invention, the present invention also shows the embodiment of file restoration methods, when breaking down for the file of storing as application file storage means embodiment, these files is recovered.
Participate in Fig. 3, be the first embodiment process flow diagram of file restoration methods of the present invention, this embodiment shows the file rejuvenation when certain object storage nodes breaks down:
Step 301: receive the file recovery request.
Step 302: when comprising the information that object storage nodes breaks down in the file recovery request, search and the object storage nodes corresponding virtual memory node that breaks down.
Step 303: obtain the object storage nodes except the object storage nodes that breaks down that each dummy storage node of finding is shone upon.
Step 304: the object set on the described object storage nodes that breaks down is recovered according to the object set on the object storage nodes of obtaining.
Concrete, the object set on the object storage nodes of obtaining is copied in the object set of object storage nodes of a free time, store the corresponding relation between the object set of object storage nodes of described dummy storage node and described free time.
Below in conjunction with file storage organization shown in Figure 2, describe by the recovery of a concrete application example to the OSN memory node:
The recovery of OSN recovers the Objset on the OSN in fact exactly, and the capacity of Objset can be configured by MDS, so the recovery of obj ect file can be that unit carries out with Objset.After finding certain OSN node collapse, MDS traversal vOSN finds all Objset on this OSN to the mapping table of Objset, finds corresponding backup (antithesis) Objset simultaneously.For each Objset that will recover, MDS creates new Objset at certain idle OSN, and by sending the whole backup of instruction indication OSN copy Objset to idle OSN.OSN reports for the reproduction process of Objset, and MDS gathers current returning to form, and after certain Objset finished recovery, vOSN was to the corresponding relation of new Objset in the updating form.
According to file storage organization shown in Figure 2, suppose to have three files, each file is divided into three obj ect file, and is then corresponding, and file and the corresponding relation between dummy storage node and the file object of the last maintenance of MDS are as shown in table 1 below:
Table 1
File name |
The description of obj ect file |
File-1 |
<vOSN_1,Object_1>,<vOSN_2,Object_1>,<vOSN_3,Object_1> |
File-2 |
<vOSN_1,Object_2>,<vOSN_2,Object_2>,<vOSN_3,Object_2> |
File-3 |
<vOSN_1,Object_3>,<vOSN_2,Object_3>,<vOSN_3,Object_3> |
Dummy storage node and the corresponding relation between the object set of the last maintenance of MDS are as shown in table 2 below:
Table 2
The vOSN numbering |
Two corresponding object sets are described |
vOSN_1 |
<OSN_1,Objset_1>,<OSN_2,Objset_1> |
vOSN_2 |
<OSN_1,Objset_2>,<OSN_3,Objset_1> |
vOSN_3 |
<OSN_2,Objset_2>,<OSN_3,Objset_2> |
Suppose object memory node OSN_3 breaks down, and searches the corresponding vOSN of item that all comprise OSN_3 so from the secondary series of table 2, and the result who searches is vOSN_2 and vOSN_3, and the idle object storage nodes in the supposing the system is OSN_4.
At first recover object set<OSN_3, Objset_1 〉, according to table 2 as can be known with<OSN_3, Objset_1 corresponding backup object collection is<OSN_1 Objset_2.Therefore create an object set<OSN_4 at OSN_4, Objset_1 〉, and to OSN_1 transmission instruction, indicate it on OSN_4, to write object set, perhaps send instruction to OSN_4, indicate it to go up the reading object collection from OSN_1, according to above-mentioned instruction with the object set<OSN_1 on the OSN_1, Objset_2〉copy to<OSN_4 Objset_1 〉.Copy finish after, only need the mapping relations of vOSN_2 in the updating form 2, and need not the fileinfo in the updating form 1, the mapping relations of vOSN_2 are as shown in table 3 below in the table 2 after the renewal:
Table 3
The vOSN numbering |
Two corresponding object sets are described |
vOSN_2 |
<OSN_1,Objset_2>,<OSN_4,Objset_1> |
Secondly, recover object set<OSN_3, Objset_2 〉, according to table 2 as can be known with<OSN_3, Objset_2 corresponding backup object collection is<OSN_2 Objset_2.Therefore create an object set<OSN_4 at OSN_4, Objset_2 〉, and to OSN_2 transmission instruction, indicate it on OSN_4, to write object set, perhaps send instruction to OSN_4, indicate it to go up the reading object collection from OSN_2, according to above-mentioned instruction with the object set<OSN_2 on the OSN_2, Objset_2〉copy to<OSN_4 Objset_2 〉.Copy finish after, only need the mapping relations of vOSN_3 in the updating form 2, and need not the fileinfo in the updating form 1, the mapping relations of vOSN_3 are as shown in table 4 below in the table 2 after the renewal:
Table 4
The vOSN numbering |
Two corresponding object sets are described |
vOSN_3 |
<OSN_2,Objset_2>,<OSN_4,Objset_2> |
Above-mentioned rejuvenation to object storage nodes copies the process of object set exactly.Copying the instruction of object set can be sent by the recovery scheduler program on the MDS, and finished by the synchronization program that copies on the OSN, the synchronization program that copies on the OSN is carried out in the process of duplicate instructions, can copy progress to the MDS report, equally finish copy after, also can copy the information of finishing to MDS report.
Participate in Fig. 4, be the second embodiment process flow diagram of file restoration methods of the present invention, this embodiment shows the file rejuvenation when certain object set of certain object storage nodes breaks down:
Step 401: receive the file recovery request.
Step 402: when comprising the information that the object set on the object storage nodes breaks down in the file recovery request, search the object storage nodes corresponding virtual memory node with the object set place of breaking down.
Step 403: obtain the object storage nodes except the object storage nodes at the object set place of breaking down that the dummy storage node that finds is shone upon.
Step 404: according to the object set on the object storage nodes of obtaining the object set that breaks down is recovered, finish current flow process.
Below in conjunction with file storage organization shown in Figure 2, describe by the recovery of a concrete application example to the object set on the OSN memory node:
When certain OSN finds that record of certain Objset is destroyed on it, perhaps owing to other reason can't Objset of local access the time, then can send to MDS to recovery request by this OSN, trigger recovery for this fault Objset by MDS; Perhaps also can seek another OSN that stores this Objset by OSN and hold consultation, the Objset of fault is recovered out, then restoration result be reported MDS, upgrade corresponding list item information by MDS.After MDS receives recovery request, can do a simple checking earlier, such as the read/write data of fault Objset once, according to the checking result, judge whether to need to send the instruction that recovers to this Objset.Owing to have redundancy relationship between two object sets when the storage object file on two object storage nodes, so rejuvenation is exactly according to this redundancy relationship, obtains another Objset corresponding with fault Objset and copies.
According to file storage organization shown in Figure 2, suppose to have three files, each file is divided into three obj ect file, and is then corresponding, and file and the corresponding relation between dummy storage node and the file object of the last maintenance of MDS allow so as shown in table 1:
Suppose object memory node OSN_3 finds internal object collection<OSN_3, Objset_2〉break down, then OSN_3 can be to MDS query object collection<OSN_3, Objset_2〉pair relationhip, MDS checks that table 2 as can be known, with<OSN_3, Objset_2〉corresponding backup object collection is<OSN_2 Objset_2 〉; MDS can be according to the load distribution situation, it is less to choose an offered load, the OSN that active volume is bigger, such as choosing object storage nodes OSN_4, MDS returns to OSN_3 to relevant information then, relevant information comprises backup object collection<OSN_2, Objset_2 〉, for the destination object memory node OSN_4 that recovers object set.Recovering object set<OSN_3, Objset_2〉process in, at first create an object set<OSN_4, Objset_2 at OSN_4 〉, send instruction to OSN_2 then, indicate it on OSN_4, to write object set, perhaps send instruction to OSN_4, indicate it to go up the reading object collection from OSN_2, according to above-mentioned instruction with the object set<OSN_2 on the OSN_2, Objset_2〉copy to<OSN_4 Objset_2 〉.Copy finish after, only need the mapping relations of vOSN_3 in the updating form 2, and need not the fileinfo in the updating form 1, the mapping relations of vOSN_3 are consistent with table 4 in the table 2 after the renewal, do not repeat them here.
Participate in Fig. 5, be the 3rd embodiment process flow diagram of file restoration methods of the present invention, this embodiment shows the file rejuvenation when the obj ect file in certain object set of certain object storage nodes breaks down:
Step 501: receive the file recovery request.
Step 502: when information that the object in the object set that comprises in the file recovery request on the object storage nodes breaks down, search the object storage nodes corresponding virtual memory node with the object place of breaking down.
Step 503: obtain the object storage nodes except the object storage nodes at the object place of breaking down that the dummy storage node that finds is shone upon.
Step 504: according to the object in the object set of the object storage nodes of obtaining the object that breaks down is recovered, finish current flow process.
Still in conjunction with file storage organization shown in Figure 2, describe by the recovery of a concrete application example to certain object in the object set of OSN memory node below:
When MDS receives the information that certain object in the object set breaks down on the OSN, MDS can confirm further whether the object on this OSN damages, after the affirmation recovery information is hung into the recovery tasks formation, when recovering the formation long enough, after perhaps surpassing Preset Time, by the recovery of MDS startup to all objects.In addition, MDS holds after receiving recovery request, can carry out simple authentication to recovery request, such as a bit of data of this object of read/write, behind the demonstration validation, then sends the instruction that recovers this fault object.
According to file storage organization shown in Figure 2, suppose that client finds object<OSN_3 when reading file File-1, Objset_2, Object_1〉read error, then client reports MDS with this error message, MDS is from this object<OSN_3, Objset_2, Object_1〉middle picked at random one piece of data, read checking, if find data mistake appears really, then at object set<OSN_3 of OSN_3, Objset_2〉in create new object<OSN_3, Objset_2, Object_9〉(it is 9 that suppose object is concentrated maximum object number), simultaneously at object set<OSN_3, Objset_2〉backup object collection<OSN_2, Objset_2〉the new object<OSN_2 of middle establishment, Objset_2, Object_9 〉, the object number between the object set of two antithesis is consistent.MDS sends object to the OSN_3 node and recovers instruction, and the OSN_3 node copies object<OSN_2, Objset_2, Object_1 after receiving object recovery instruction〉to<OSN_3, Objset_2, Object_9 〉; Copy finish after, with the object<OSN_3 on the OSN_3, Objset_2, Object_1〉be labeled as unavailable, simultaneously with the object<OSN_2 on the OSN_2, Objset_2, Object_9〉be mapped to<OSN_2 Objset_2, Object_1.Owing in recovering the process of object, object number is adjusted, so the corresponding relation between file File-1 and dummy storage node and the file object in the updating form 1, as shown in table 5 below:
Table 5
File name |
The description of obj ect file |
File-1 |
<vOSN_1,Object_1>,<vOSN_2,Object_1>,<vOSN_3,Object_9> |
In addition, when the one piece of data in certain object in the object set of certain object storage nodes breaks down, then can return to this failure message the OSN at fault data place, be equivalent to remind the OSN node, the data division of certain object damages.By this OSN node processing, can attempt earlier redistributing one section space at the OSN intra-node, new storage space as this object, fault data place object tools is arrived new space, but do not copy fault data, concentrate from the backup object of this object place object set then fault data is copied, thereby recover the object at fault data and place thereof; Can certainly be according to the description of previous embodiment, directly the object to the fault data place recovers, and does not repeat them here.
Corresponding with the embodiment of file memory method of the present invention and file restoration methods, the present invention also provides the embodiment of document storage system, file recovery system and server.
Referring to Fig. 6, be system embodiment block diagram of the present invention, comprise in this system embodiment block diagram: meta data server 610 and at least two object storage nodes 620, convenient for example, only show three object storage nodes 620 among Fig. 6.
When this system embodiment block diagram is used for the file storage, described meta data server 610, after file to be stored is divided at least two obj ect file, each obj ect file is corresponded to a dummy storage node, create at least two object sets in each object storage nodes, each dummy storage node is mapped to the object set of at least two object storage nodes 620, and described at least two object sets belong to different object storage nodes; Described object storage nodes 620 is for the obj ect file of the dummy storage node correspondence of shining upon by the object set storage.
When this system embodiment block diagram is used for the file recovery, described meta data server 610, be used for receiving the file recovery request, when comprising the information that object storage nodes breaks down in the described file recovery request, search and the described object storage nodes corresponding virtual memory node that breaks down, obtain the object storage nodes 620 except the described object storage nodes that breaks down that described each dummy storage node that finds is shone upon, according to the object set on the described object storage nodes of obtaining 620 object set on the described object storage nodes that breaks down 620 is recovered.
Referring to Fig. 7, be an embodiment block diagram of server of the present invention, this server is used for file is stored.
This server comprises: division unit 710, corresponding unit 720, creating unit 730 and map unit 740.
Division unit 710 is used for file to be stored is divided at least two obj ect file;
Corresponding unit 720 is used for each obj ect file is corresponded to a dummy storage node;
Creating unit 730 is used for creating at least two object sets in each object storage nodes;
Map unit 740, be used for each dummy storage node is mapped to the object set of at least two object storage nodes, described at least two object sets belong to different object storage nodes, and described at least two object sets are used for storing the obj ect file of the dummy storage node correspondence of shining upon.
Further, this server can also comprise (not shown among Fig. 7): assembled unit, be used for the object set at least two object storage nodes is made up, and the object set of each described combination is corresponding with a dummy storage node.
Further, this server can also comprise (not shown among Fig. 7): monitoring unit, for the memory capacity of each dummy storage node of monitoring; Performance element is used for creating new object set in object storage nodes when described memory capacity surpasses the threshold value that sets in advance, and described new object set is made up.
Referring to Fig. 8, be another embodiment block diagram of server of the present invention, this server is used for file is recovered.
This server comprises: receiving element 810, search unit 820, acquiring unit 830 and recovery unit 840.
Wherein, receiving element 810 is used for receiving the file recovery request;
Search unit 820, be used for when described file recovery request comprises the information that object storage nodes breaks down, searching and the described object storage nodes corresponding virtual memory node that breaks down;
Acquiring unit 830 is used for obtaining the object storage nodes except the described object storage nodes that breaks down that described each dummy storage node that finds is shone upon;
Recovery unit 840 is used for according to the object set on the described object storage nodes of obtaining the object set on the described object storage nodes that breaks down being recovered.
Concrete, recovery unit 840 can comprise (not shown among Fig. 8): copied cells, in the object set for the object storage nodes that the object set on the described object storage nodes of obtaining is copied to a free time; Storage unit is for the corresponding relation between the object set of the described dummy storage node of storage and the object storage nodes of described free time.
Further, the described unit 820 of searching also is used for searching the object storage nodes corresponding virtual memory node with described object set place of breaking down when described file recovery request comprises the information that the object set on the object storage nodes breaks down;
Described acquiring unit 830 also is used for obtaining the object storage nodes except the object storage nodes at described object set place of breaking down that the described dummy storage node that finds is shone upon;
Described recovery unit 840 also is used for according to the object set on the described object storage nodes of obtaining the described object set that breaks down being recovered.
Further, the described unit 820 of searching, also be used for when described file recovery request comprises the information that the object in the object set on the object storage nodes breaks down, searching the object storage nodes corresponding virtual memory node with described object place of breaking down;
Described acquiring unit 830 also is used for obtaining the object storage nodes except the object storage nodes at described object place of breaking down that the described dummy storage node that finds is shone upon;
Described recovery unit 840 also is used for according to the object of the object set of the described object storage nodes of obtaining the described object that breaks down being recovered.
As seen through the above description of the embodiments, after in the embodiment of the invention file to be stored being divided at least two obj ect file, each obj ect file is corresponded to a dummy storage node, create at least two object sets in each object storage nodes, each dummy storage node is mapped at least two object sets, the obj ect file of the dummy storage node correspondence of shining upon by the storage of object set at least, at least two object sets belong to different object storage nodes; Obj ect file is not directly to be stored on the object storage nodes in the embodiment of the invention that hence one can see that, but by the mapping relations between dummy storage node and the object set, for the storage of obj ect file provide one in the middle of key-course, therefore receive when comprising the recovery request that object storage nodes breaks down, search the object storage nodes corresponding virtual memory node that breaks down with this, obtain the object storage nodes except the object storage nodes that breaks down that each dummy storage node of finding is shone upon, according to the object set on the object storage nodes of obtaining the object set on the object storage nodes that breaks down is recovered; Because when object storage nodes breaks down, only needing to safeguard with this object storage nodes has corresponding mapping relations on the dummy storage node of the relation of depositing, therefore is convenient to the recovery of file, has improved the speed that file recovers.
Those skilled in the art can be well understood to the present invention and can realize by the mode that software adds essential general hardware platform.Based on such understanding, the part that technical scheme of the present invention contributes to prior art in essence in other words can embody with the form of software product, this computer software product can be stored in the storage medium, as ROM/RAM, magnetic disc, CD etc., comprise that at least two instructions are with so that a computer equipment (can be personal computer, server, the perhaps network equipment etc.) carry out the described method of some part of each embodiment of the present invention or embodiment.
Above-described embodiment of the present invention does not constitute the restriction to protection domain of the present invention.Any modification of doing within the spirit and principles in the present invention, be equal to and replace and improvement etc., all should be included within protection scope of the present invention.