CN111290880A - OSD data recovery method, device, equipment and medium - Google Patents

OSD data recovery method, device, equipment and medium Download PDF

Info

Publication number
CN111290880A
CN111290880A CN202010071050.4A CN202010071050A CN111290880A CN 111290880 A CN111290880 A CN 111290880A CN 202010071050 A CN202010071050 A CN 202010071050A CN 111290880 A CN111290880 A CN 111290880A
Authority
CN
China
Prior art keywords
osd
target
occupancy rate
space occupancy
target object
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.)
Withdrawn
Application number
CN202010071050.4A
Other languages
Chinese (zh)
Inventor
李彦博
孟祥瑞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Suzhou Inspur Intelligent Technology Co Ltd
Original Assignee
Suzhou Inspur Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Suzhou Inspur Intelligent Technology Co Ltd filed Critical Suzhou Inspur Intelligent Technology Co Ltd
Priority to CN202010071050.4A priority Critical patent/CN111290880A/en
Publication of CN111290880A publication Critical patent/CN111290880A/en
Withdrawn legal-status Critical Current

Links

Images

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/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1471Saving, restoring, recovering or retrying involving logging of persistent data for recovery

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The application discloses an OSD data recovery method, a device, equipment and a medium, wherein the method comprises the following steps: when the fault OSD is not automatically recovered within a preset time length, determining a target OSD so as to recover data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; if yes, one target object is recovered, and after the current target object is recovered, the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value is executed again until all the target objects in the target object list are recovered. Therefore, the OSD can recover the missing object, and the normal operation of the OSD is ensured, so that the normal operation of the distributed storage cluster is ensured, and the overall performance of the system is improved.

Description

OSD data recovery method, device, equipment and medium
Technical Field
The present application relates to the field of storage technologies, and in particular, to a method, an apparatus, a device, and a medium for recovering OSD data.
Background
In a distributed Storage cluster, when an OSD (Object-based Storage Device) fails, a corresponding data recovery process needs to be triggered so as to recover data lost in the failure process, if the OSD fails and the data cannot be automatically recovered within a preset time duration, a normal OSD needs to be selected for recovering the corresponding data in the failed OSD, a corresponding PG expering process is triggered, in the PG expering process, a list of objects missing from the normal OSD and positions of the missing objects are determined by comparing logs of the failed OSD and the normal OSD, after the PG expering is finished, reserved Object resource recovery is started, after the reservation is successful, Object recovery is started, in the Object recovery process, the missing Object list is traversed, the objects are recovered one by one until all the objects in the missing Object list are recovered, and in the case of a large number of missing objects, the data recovery cannot control the data writing amount, and the occupancy rate of the OSD partition reaches 100%, so that the OSD down is caused and the recovery cannot be performed, and the operation of the distributed storage cluster and the overall performance of the system are influenced.
Disclosure of Invention
In view of this, an object of the present application is to provide an OSD data recovery method, apparatus, device, and medium, so that an OSD can recover a missing object and ensure normal operation of the OSD, thereby ensuring normal operation of a distributed storage cluster and improving overall performance of a system. The specific scheme is as follows:
in a first aspect, the present application discloses an OSD data recovery method, including:
when the fault OSD is not automatically recovered within a preset time length, determining a target OSD so as to recover data in the fault OSD to the target OSD;
comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list;
judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not;
and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
Optionally, before determining whether the current control occupancy of the target OSD is smaller than a preset space occupancy threshold, the method further includes:
and making a target object recovery reservation.
Optionally, after determining whether the current space occupancy of the target OSD is smaller than a preset space occupancy threshold, the method further includes:
and if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
Optionally, before exiting and recovering the state of the target object, the method further includes:
and sending corresponding prompt information to the main PG.
In a second aspect, the present application discloses an OSD data recovery apparatus, including:
the OSD determining module is used for determining a target OSD when the fault OSD is not automatically recovered within a preset time length so as to recover the data in the fault OSD to the target OSD;
the target object determining module is used for comparing the first log of the fault OSD with the second log of the target OSD, determining a target object which needs to be recovered by the target OSD, and obtaining a target object list;
the judging module is used for judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not;
and the object recovery module is used for recovering one target object when the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
Optionally, the OSD data recovery apparatus further includes:
and the recovery reservation module is used for performing the target object recovery reservation.
Optionally, the OSD data recovery apparatus further includes:
and the recovery state exit module is used for exiting the recovery state of the target object when the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
Optionally, the recovery state exit module includes:
and the information sending submodule is used for sending corresponding prompt information to the main PG.
In a third aspect, the present application discloses an OSD data recovery apparatus, including:
a memory and a processor;
wherein the memory is used for storing a computer program;
the processor is configured to execute the computer program to implement the OSD data recovery method disclosed above.
In a fourth aspect, the present application discloses a computer readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the OSD data recovery method disclosed above.
Therefore, when the fault OSD is not automatically recovered within the preset time length, the method and the device determine the target OSD so as to recover the data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, when the fault OSD is automatically recovered within the preset time length, the method determines the target OSD, compares the first log of the fault OSD with the second log of the target OSD, determines the target object to be recovered by the target OSD, obtains a target object list, then judges whether the current space occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value, if so, one target object is recovered, and after the current target object is recovered, re-executes the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, the OSD can recover the missing object, and the normal operation of the OSD is ensured, so that the normal operation of the distributed storage cluster is ensured, and the overall performance of the system is improved.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, it is obvious that the drawings in the following description are only embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart illustrating an OSD data recovery method disclosed in the present application;
fig. 2 is a flowchart illustrating an exemplary OSD data recovery method disclosed herein;
fig. 3 is a schematic structural diagram of an OSD data recovery apparatus according to the present disclosure;
fig. 4 is a structural diagram of an OSD data recovery apparatus disclosed in the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
At present, in a distributed storage cluster, when OSD fails, corresponding data recovery needs to be performed, missing objects needing to be recovered are determined first, and are recovered one by one until all the missing objects are recovered, and under the condition that a large number of the missing objects exist, data write-in quantity cannot be controlled by data recovery, so that the occupancy rate of OSD partitions reaches 100%, therefore, OSD down is caused and recovery cannot be performed, and the operation of the distributed storage cluster and the overall performance of a system are affected. In view of this, the present application provides an OSD data recovery method, so that an OSD can recover a missing object, and normal operation of the OSD is ensured, thereby ensuring normal operation of a distributed storage cluster and improving overall performance of a system.
Referring to fig. 1, an embodiment of the present application discloses an OSD data recovery method, including:
step S11: and when the fault OSD is not automatically recovered within the preset time length, determining a target OSD so as to recover the data in the fault OSD to the target OSD.
In a specific implementation process, if a faulty OSD is not automatically recovered within a preset time period, a target OSD needs to be determined so as to recover data in the faulty OSD to the target OSD, wherein the target OSD is an OSD in a normal operation state and meeting a certain condition. For example, the OSD in the normal operation state and having the most remaining space in the current distributed storage cluster is determined as the target OSD.
Step S12: and comparing the first log of the fault OSD with the second log of the target OSD, and determining the target object which needs to be recovered by the target OSD to obtain a target object list.
After the target OSD is determined, the first log of the fault OSD and the second log of the target OSD are required to be compared, a target object which needs to be recovered by the target OSD is determined, a target object list is obtained, and the position of the target object is determined.
Step S13: and judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value.
In a specific implementation process, it is further required to determine whether the current space occupancy of the target OSD is smaller than a preset space occupancy so as to determine whether the target OSD currently supports recovery of the target object, if the current space occupancy of the target OSD is smaller than the preset space occupancy, the target OSD currently supports replying the target object, and if the current space occupancy of the target OSD is greater than or equal to the preset space occupancy, the target OSD currently does not support replying the target object.
Before whether the current control occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not, the method further comprises the following steps: and making a target object recovery reservation. That is, before starting to restore the target object, the target object restoration reservation needs to be made.
Step S14: and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current space occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
It can be understood that, after determining whether the current space occupancy of the target OSD is less than the preset space occupancy, if the current space occupancy of the target OSD is less than the preset space occupancy threshold, performing one target object recovery, and after the current target object recovery is completed, re-executing the step of determining whether the current space occupancy of the target OSD is less than the preset space occupancy threshold until all the target objects in the target object list are recovered. And if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval. For example, the step of judging whether the current control occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold is performed every 1 minute. After each target object is recovered, whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value is judged once, and corresponding steps are executed after the judgment, so that the operation efficiency of the target OSD can be guaranteed, and the normal data processing capacity of the target OSD is maintained.
Therefore, when the fault OSD is not automatically recovered within the preset time length, the method and the device determine the target OSD so as to recover the data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, when the fault OSD is automatically recovered within the preset time length, the method determines the target OSD, compares the first log of the fault OSD with the second log of the target OSD, determines the target object to be recovered by the target OSD, obtains a target object list, then judges whether the current space occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value, if so, one target object is recovered, and after the current target object is recovered, re-executes the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, the OSD can recover the missing object, and the normal operation of the OSD is ensured, so that the normal operation of the distributed storage cluster is ensured, and the overall performance of the system is improved.
Referring to fig. 2, an embodiment of the present application discloses a specific OSD data recovery method, including:
step S21: and when the fault OSD is not automatically recovered within the preset time length, determining a target OSD so as to recover the data in the fault OSD to the target OSD.
Step S22: and comparing the first log of the fault OSD with the second log of the target OSD, and determining the target object which needs to be recovered by the target OSD to obtain a target object list.
For the specific processes of step S21 and step S22, reference may be made to the corresponding contents disclosed in the foregoing embodiments, and details are not repeated here.
Step S23: and making a target object recovery reservation.
In a specific implementation process, after the target object is determined, the target object recovery reservation is also required to be performed, so that the target object recovery operation is performed subsequently.
Step S24: and judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value.
Step S25: and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
Step S26: and if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
It can be understood that, after determining whether the current space occupancy of the target OSD is less than the preset space occupancy threshold, if the current space occupancy of the target OSD is less than the preset space occupancy threshold, performing one target recovery, and after the current target recovery is completed, re-executing the step of determining whether the current control occupancy of the target OSD is less than the preset space occupancy threshold until all the target objects in the target object list are recovered. And if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval. Before the exiting restores the target object state, the method further comprises: and sending corresponding prompt information to a main PG (place Group). That is, if the current space occupancy of the target OSD is greater than or equal to the preset space occupancy threshold, sending corresponding prompt information to the primary PG, and after receiving the prompt information, the primary PG exits from the target object recovery state and executes the step of judging whether the current control occupancy of the target OSD is less than the preset space occupancy threshold according to a preset time interval.
Referring to fig. 3, an embodiment of the present application discloses an OSD data recovery apparatus, including:
the OSD determining module 11 is configured to determine a target OSD so as to restore data in a faulty OSD to the target OSD when the faulty OSD is not automatically restored within a preset time period;
a target object determining module 12, configured to compare the first log of the faulty OSD with the second log of the target OSD, and determine a target object that the target OSD needs to recover, so as to obtain a target object list;
the judging module 13 is configured to judge whether the current space occupancy of the target OSD is smaller than a preset space occupancy threshold;
the object recovery module 14 is configured to perform one target object recovery when the current space occupancy of the target OSD is smaller than a preset space occupancy threshold, and re-perform the step of determining whether the current control occupancy of the target OSD is smaller than the preset space occupancy threshold after the current target object recovery is completed until all target objects in the target object list are completely recovered.
Therefore, when the fault OSD is not automatically recovered within the preset time length, the method and the device determine the target OSD so as to recover the data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, when the fault OSD is automatically recovered within the preset time length, the method determines the target OSD, compares the first log of the fault OSD with the second log of the target OSD, determines the target object to be recovered by the target OSD, obtains a target object list, then judges whether the current space occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value, if so, one target object is recovered, and after the current target object is recovered, re-executes the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, the OSD can recover the missing object, and the normal operation of the OSD is ensured, so that the normal operation of the distributed storage cluster is ensured, and the overall performance of the system is improved.
Further, the OSD data recovery apparatus further includes:
and the recovery reservation module is used for performing the target object recovery reservation.
Further, the OSD data recovery apparatus further includes:
and the recovery state exit module is used for exiting the recovery state of the target object when the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
Specifically, the recovery state exit module includes:
and the information sending submodule is used for sending corresponding prompt information to the main PG.
Further, referring to fig. 4, an embodiment of the present application further discloses an OSD data recovery apparatus, including: a processor 21 and a memory 22.
Wherein the memory 22 is used for storing a computer program; the processor 21 is configured to execute the computer program to implement the OSD data recovery method disclosed in the foregoing embodiment.
For the specific process of the OSD data recovery method, reference may be made to the corresponding contents disclosed in the foregoing embodiments, and details are not repeated here.
Further, an embodiment of the present application also discloses a computer readable storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the following steps:
when the fault OSD is not automatically recovered within a preset time length, determining a target OSD so as to recover data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
Therefore, when the fault OSD is not automatically recovered within the preset time length, the method and the device determine the target OSD so as to recover the data in the fault OSD to the target OSD; comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list; judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not; and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, when the fault OSD is automatically recovered within the preset time length, the method determines the target OSD, compares the first log of the fault OSD with the second log of the target OSD, determines the target object to be recovered by the target OSD, obtains a target object list, then judges whether the current space occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value, if so, one target object is recovered, and after the current target object is recovered, re-executes the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered. Therefore, the OSD can recover the missing object, and the normal operation of the OSD is ensured, so that the normal operation of the distributed storage cluster is ensured, and the overall performance of the system is improved.
In this embodiment, when the computer subprogram stored in the computer-readable storage medium is executed by the processor, the following steps may be specifically implemented: and making a target object recovery reservation.
In this embodiment, when the computer subprogram stored in the computer-readable storage medium is executed by the processor, the following steps may be specifically implemented: and if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
In this embodiment, when the computer subprogram stored in the computer-readable storage medium is executed by the processor, the following steps may be specifically implemented: and sending corresponding prompt information to the main PG.
The embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same or similar parts among the embodiments are referred to each other. The device disclosed by the embodiment corresponds to the method disclosed by the embodiment, so that the description is simple, and the relevant points can be referred to the method part for description.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in Random Access Memory (RAM), memory, Read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Finally, it is further noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of other elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The OSD data recovery method, device, apparatus, and medium provided by the present application are introduced in detail above, and a specific example is applied in the present application to explain the principle and the implementation of the present application, and the description of the above embodiment is only used to help understand the method and the core idea of the present application; meanwhile, for a person skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. An OSD data recovery method, comprising:
when the fault OSD is not automatically recovered within a preset time length, determining a target OSD so as to recover data in the fault OSD to the target OSD;
comparing the first log of the fault OSD with the second log of the target OSD, and determining a target object to be recovered by the target OSD to obtain a target object list;
judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not;
and if the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, recovering one target object, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
2. The OSD data recovery method of claim 1, wherein before determining whether the current control occupancy of the target OSD is less than a preset space occupancy threshold, the method further comprises:
and making a target object recovery reservation.
3. The OSD data recovery method of claim 1, wherein after determining whether the current space occupancy of the target OSD is less than a preset space occupancy threshold, the method further comprises:
and if the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, quitting the target object recovery state, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
4. The OSD data recovery method of claim 3, wherein prior to the exiting recovering the target object state, further comprising:
and sending corresponding prompt information to the main PG.
5. An OSD data recovery apparatus comprising:
the OSD determining module is used for determining a target OSD when the fault OSD is not automatically recovered within a preset time length so as to recover the data in the fault OSD to the target OSD;
the target object determining module is used for comparing the first log of the fault OSD with the second log of the target OSD, determining a target object which needs to be recovered by the target OSD, and obtaining a target object list;
the judging module is used for judging whether the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value or not;
and the object recovery module is used for recovering one target object when the current space occupancy rate of the target OSD is smaller than a preset space occupancy rate threshold value, and after the current target object is recovered, re-executing the step of judging whether the current control occupancy rate of the target OSD is smaller than the preset space occupancy rate threshold value until all the target objects in the target object list are recovered.
6. The OSD data recovery apparatus of claim 5, further comprising:
and the recovery reservation module is used for performing the target object recovery reservation.
7. The OSD data recovery apparatus of claim 5, further comprising:
and the recovery state exit module is used for exiting the recovery state of the target object when the current space occupancy rate of the target OSD is greater than or equal to the preset space occupancy rate threshold value, and executing the step of judging whether the current control occupancy rate of the target OSD is less than the preset space occupancy rate threshold value according to a preset time interval.
8. The OSD data recovery apparatus of claim 7, wherein the recovery state exit module comprises:
and the information sending submodule is used for sending corresponding prompt information to the main PG.
9. An OSD data recovery apparatus comprising:
a memory and a processor;
wherein the memory is used for storing a computer program;
the processor is configured to execute the computer program to implement the OSD data recovery method according to any one of claims 1 to 4.
10. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the OSD data recovery method of any one of claims 1 to 4.
CN202010071050.4A 2020-01-21 2020-01-21 OSD data recovery method, device, equipment and medium Withdrawn CN111290880A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010071050.4A CN111290880A (en) 2020-01-21 2020-01-21 OSD data recovery method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010071050.4A CN111290880A (en) 2020-01-21 2020-01-21 OSD data recovery method, device, equipment and medium

Publications (1)

Publication Number Publication Date
CN111290880A true CN111290880A (en) 2020-06-16

Family

ID=71025614

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010071050.4A Withdrawn CN111290880A (en) 2020-01-21 2020-01-21 OSD data recovery method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN111290880A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113553216A (en) * 2021-06-28 2021-10-26 北京百度网讯科技有限公司 Data recovery method and device, electronic equipment and storage medium
CN113672435A (en) * 2021-07-09 2021-11-19 济南浪潮数据技术有限公司 Data recovery method, device, equipment and storage medium
CN113821377A (en) * 2021-08-27 2021-12-21 济南浪潮数据技术有限公司 Data recovery method, system and storage medium of distributed storage cluster

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113553216A (en) * 2021-06-28 2021-10-26 北京百度网讯科技有限公司 Data recovery method and device, electronic equipment and storage medium
CN113553216B (en) * 2021-06-28 2024-06-28 北京百度网讯科技有限公司 Data recovery method and device, electronic equipment and storage medium
CN113672435A (en) * 2021-07-09 2021-11-19 济南浪潮数据技术有限公司 Data recovery method, device, equipment and storage medium
CN113821377A (en) * 2021-08-27 2021-12-21 济南浪潮数据技术有限公司 Data recovery method, system and storage medium of distributed storage cluster
CN113821377B (en) * 2021-08-27 2023-12-22 济南浪潮数据技术有限公司 Data recovery method, system and storage medium of distributed storage cluster

Similar Documents

Publication Publication Date Title
CN111290880A (en) OSD data recovery method, device, equipment and medium
CN106776130B (en) Log recovery method, storage device and storage node
CN108847982B (en) Distributed storage cluster and node fault switching method and device thereof
CN110543386B (en) Data storage method, device, equipment and storage medium
CN110909394A (en) Configuration file monitoring method of server
CN110351313B (en) Data caching method, device, equipment and storage medium
CN107360025B (en) Distributed storage system cluster monitoring method and device
CN109491609B (en) Cache data processing method, device and equipment and readable storage medium
CN111104254A (en) Storage system data flashing method, device, equipment and readable storage medium
US20190227710A1 (en) Incremental data restoration method and apparatus
CN108089892B (en) Method and device for safely starting system, set top box and storage medium
CN111046024A (en) Data processing method, device, equipment and medium for sharing storage database
CN109165112B (en) Fault recovery method, system and related components of metadata cluster
CN108228789B (en) Synchronous abnormity recovery method and device triggered by slave node
CN103064759B (en) The method of data restore and device
CN112631839B (en) Method, device and equipment for realizing data backup
CN112650624B (en) Cluster upgrading method, device, equipment and computer readable storage medium
CN111813604B (en) Data recovery method, system and related device of fault storage equipment
CN111177104B (en) Log downloading and flushing method and device of NAS storage system
CN111124760B (en) Uboot-based embedded equipment starting method and apparatus
CN104184614A (en) Rollback configuration method and apparatus
CN109032536B (en) Data storage method, device, system and equipment based on distributed cluster system
CN107908370B (en) Data storage method and device
CN110879764A (en) Bitmap setting method, device and equipment and readable storage medium
CN107153589B (en) Reading and writing method of mirror image data

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20200616