Storage system fault recovery methods, systems, computer equipment and storage media
By setting dirty data markers and periodic checks in the storage system, the problem of time-consuming metadata recovery during storage system disasters is solved, enabling fast and effective fault recovery.
Patent Information
- Application Number
- CN202210910718.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-29
- Publication Date
- 2026-01-30
- Estimated Expiration
- 2042-07-29
AI Technical Summary
Existing storage systems suffer from time-consuming metadata recovery during disasters, leading to a decline in user experience, and caching can reduce system stability.
By setting dirty data markers in the superblock of the storage volume, dirty data in memory is periodically detected, and different recovery processes are selected based on the markers, either by directly obtaining the starting address or starting a verification recovery process, thus avoiding a full disk scan.
It improves the recovery efficiency after storage system failures, reduces the impact of disaster failures on customer businesses, and enables rapid recovery.
Smart Images

Figure CN115373882B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of computer data processing, in particular to a storage system fault recovery method and system, computer equipment and storage medium. BACKGROUND
[0002] Currently, many storage systems providing data reduction function need metadata for support. Each time data is written to disk, a logical address (L) is generated to point to a fixed physical address (P), and P is allocated in an appending manner (sequential allocation). When data is read, P is found through L, and the real data of the corresponding physical address of P is read. Reliable metadata is required for effective data reading.
[0003] In order to improve the response speed of the storage system and reduce the host latency, the storage system usually provides cache hit function. The existence of cache greatly improves the performance of the storage system, but also reduces the stability of the storage system. When a disaster fault occurs (memory is preserved without BBU in the case of power failure), data loss will occur. In the past technical practice, if the system does not have power failure protection when the system power failure is monitored, metadata recovery is needed through full disk scanning of metadata, so as to realize data recovery. However, full disk scanning of metadata is extremely time-consuming, which greatly reduces the user experience. SUMMARY
[0004] The purpose of the present application is to provide a storage system fault recovery method, system, computer equipment and storage medium.
[0005] The technical solution of the present application is as follows: in a first aspect, the present application provides a storage system fault recovery method, which is applied to storage system fault restart, and the method comprises the following steps:
[0006] reading a dirty data flag in a target superblock corresponding to a target storage volume, the dirty data flag being used to indicate whether there is dirty data in the memory;
[0007] if the dirty data flag is a first identifier, obtaining a first address stored in the target superblock;
[0008] recovering corresponding metadata according to the first address;
[0009] if the dirty data flag is a second identifier, starting a check recovery process.
[0010] In a preferred embodiment, before reading the dirty data flag in the target superblock corresponding to the target storage volume, the method further comprises:
[0011] periodically determining whether there is metadata write in the target storage volume within a preset time based on a preset timer;
[0012] If yes, recording a dirty data mark as a second identification in the target super block;
[0013] If no, recording a dirty data mark as a first identification in the target super block; the preset timer periodically checks whether there is dirty data in the system memory, which is simple and efficient.
[0014] In a preferred embodiment, before the periodically determining whether there is metadata write in the target storage volume within a preset time based on a preset timer, the method further comprises:
[0015] starting the preset timer when the storage system starts; starting the preset timer when the system starts ensures that the dirty data in the system memory can be completely detected during the operation of the storage system, avoiding detection omission.
[0016] In a preferred embodiment, after the recording a dirty data mark as a second identification in the target super block, the method further comprises:
[0017] performing host IO service based on the target storage volume;
[0018] After the recording a dirty data mark as a first identification in the target super block, the method further comprises: writing the first address of the current write data into the target super block corresponding to the target storage volume; saving the first address of the write data after data write, which facilitates data recovery according to the first address after failure.
[0019] In a preferred embodiment, before the periodically determining whether there is dirty data in the storage system based on the preset timer, the method further comprises:
[0020] creating the target storage volume;
[0021] setting a dirty data mark in the target super block corresponding to the target storage volume, and initializing the dirty data mark as a first identification; when the target storage volume is created and no data is written, there is no dirty data in the system memory, the dirty data mark is initialized as the first identification indicating no dirty data, and the dirty data mark can be modified when dirty data is detected later, without the need for re-creation;
[0022] Before the periodically determining whether there is dirty data in the storage system based on the preset timer, the method further comprises:
[0023] writing data into the target storage volume.
[0024] In a preferred embodiment, the target storage volume contains data blocks that store metadata information.
[0025] The metadata includes a set of logical-to-physical LP address information and a set of physical-to-logical PL address information. The LP address information set contains at least two LP values, and the PL address information set contains at least two PL values.
[0026] In a preferred embodiment, the startup verification and recovery process includes:
[0027] Locate the target data block from the target storage volume;
[0028] The metadata information in the target data block is repaired based on the LP address information set and the PL address information set in the target data block.
[0029] Secondly, the present invention also provides a storage system fault recovery device, the device comprising:
[0030] The read module is used to read dirty data markers from the target superblock corresponding to the target storage volume;
[0031] The acquisition module is used to acquire the starting address stored in the target superblock when the dirty data is marked as the first identifier;
[0032] The first recovery module is used to recover the corresponding metadata based on the starting address;
[0033] The second recovery module is used to initiate a verification and recovery process if the dirty data is marked with a second identifier.
[0034] Thirdly, the present invention also provides a computer device, comprising:
[0035] One or more processors; and
[0036] A memory associated with the one or more processors, the memory being used to store program instructions that, when read and executed by the one or more processors, perform the method as described in any one of the first aspects.
[0037] Fourthly, the present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of any of the methods described in the first aspect.
[0038] The application has the advantages that a storage system failure recovery method, device, computer equipment and computer readable storage medium are provided, and the method comprises the following steps: reading a dirty data mark in a target super block corresponding to a target storage volume, the dirty data mark being used to indicate whether there is dirty data in the memory; if the dirty data mark is a first mark, obtaining a first address stored in the target super block; recovering corresponding metadata according to the first address; if the dirty data mark is a second mark, starting a check recovery process; and setting a dirty data mark reflecting whether there is dirty data in the memory in a super block corresponding to the storage volume, so that different recovery processes are adopted according to whether there is the dirty data mark, the influence of a disaster failure on a customer's business is effectively reduced, and the customer's host business can be recovered faster. BRIEF DESCRIPTION OF DRAWINGS
[0039] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiment description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0040] Figure 1 The storage system failure recovery method flowchart provided by the first embodiment of the present application;
[0041] Figure 2 The storage system failure recovery device structure diagram provided by the second embodiment of the present application;
[0042] Figure 3 The computer equipment architecture diagram provided by the third embodiment of the present application. DETAILED DESCRIPTION
[0043] In order to make the purpose, technical solutions and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are only some embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the scope of protection of the present application.
[0044] As described in the background, in order to improve the response speed of the storage system and reduce the host latency, the storage system will provide the function of cache hit in the prior art. The existence of cache greatly improves the performance of the storage system, and on the other hand, reduces the stability of the storage system. When a disaster failure occurs (no BBU in the case of power failure), it will cause data loss. In the past technical practice, if the system detects that the system is not powered off when it is powered off, it needs to recover the metadata by full disk scanning of the metadata, so as to realize the recovery of the data, but the full disk scanning of the metadata is extremely time-consuming, which will greatly reduce the user experience.
[0045] To solve the above problems, the present application creatively provides a storage system failure recovery method, system, computer device and computer readable storage medium. When recovering after failure, it is judged whether there is dirty data in the system memory. If there is no dirty data, it is not necessary to perform verification and recovery, and the system can be directly recovered by obtaining the rootAddr, thereby effectively improving the recovery efficiency of the storage system after failure. The scheme of the present application will be described in detail below in combination with the drawings and various embodiments.
[0046] Embodiment one: the present embodiment provides a storage system failure recovery method, as shown in Figure 1 The method is applied to storage system failure restart, and the method comprises the following steps:
[0047] SA10, creating a target storage volume.
[0048] Specifically, the storage volume (Persistent Volume) is a piece of storage space in the cluster, which is managed by the cluster administrator or automatically managed by the storage class (Storage Class). The storage volume is a resource in the cluster like the node (node). The storage volume describes the detailed information of how to provide storage (the specific parameters of NFS, cephfs and other storage).
[0049] The target storage volume contains a plurality of data blocks, each data block has corresponding metadata information, the metadata includes a logical-to-physical (LP) address information set and a physical-to-logical (PL) address information set, the LP address information set contains at least two LP values, and the PL address information set contains at least two PL values. The physical address P is the address of storing information in the memory in byte units, and each byte unit is given a unique memory address for correct storage or retrieval of information, and the logical address L refers to the offset address part related to the segment generated by the program. Each time a data write is generated, a logical address L is used to point to a fixed physical address P, and the physical address P is always allocated in an appended manner (sequential allocation), and when data is read, the physical address P corresponding to the real data is found through the logical address L, and the effective reading of the data depends on the reliable metadata.
[0050] SA20, setting a dirty data flag in the target super block corresponding to the target storage volume, and setting the dirty data flag to a first identifier.
[0051] Specifically, the dirty data flag is used to indicate whether there is dirty data in the memory. A small fixed area (superBlock) is allocated on the disk to record whether there is dirty data in the memory and the root address of the current metadata, and the dirty data flag isClean is set. Initially, no data is written, and there is no dirty data in the memory, and the dirty data flag is set to the first identifier, that is, isClean is set to True.
[0052] Dirty read refers to data in the source system that is not within a given range or is meaningless for actual business, or data format is illegal, and there are non-standard coding and ambiguous business logic in the source system.
[0053] SA30, starting a preset timer when the storage system starts.
[0054] Specifically, the timer is used to determine whether there is dirty data in the system memory.
[0055] The timer is started when the storage system starts, and the timer periodically determines whether there is dirty data in the system memory.
[0056] SA40, writing data to the target storage volume.
[0057] Specifically, in response to a write request, the write request carries a start address (start address Addr), a data length size and data content, the start address is used to mark that the data content of the write request is written to the storage location of the physical space corresponding to the storage volume, and the data length is the length of the data content.
[0058] The data requested to be written by the write request, i.e., data content, is obtained, the data requested to be written is cached, and the cached data requested to be written is written into a target storage volume. The target storage volume is divided into a plurality of intervals, i.e., a plurality of data blocks, according to a preset capacity. The metadata includes a logical-to-physical (LP) address information set and a physical-to-logical (PL) address information set, the LP address information set contains at least two LP values, and the PL address information set contains at least two PL values.
[0059] In the data writing process, the timer periodically determines whether there is dirty data in the system memory. If there is dirty data in the system memory, the timer determines that the result is yes, and the dirty data in the target super block is marked and modified to a second identification. In this embodiment, the second identification is False, i.e., the value of isClean is modified to False when it is determined that there is dirty data in the system memory. If it is determined that there is no dirty data in the system memory, the value of isClean remains True.
[0060] SA50, determining whether there is metadata writing in the target storage volume within a preset time.
[0061] If yes, the dirty data mark in the target super block is recorded as a second identification, and SA60 is entered.
[0062] If no, the dirty data mark in the target super block is recorded as a first identification, and SA70 is entered.
[0063] SA60, writing the current first address into the target super block corresponding to the target storage volume.
[0064] SA70, performing a host IO service based on the target storage volume.
[0065] The above steps all occur in the running before the failure of the storage system. After the failure of the storage system, S110 is entered.
[0066] S110, reading the dirty data mark in the target super block corresponding to the target storage volume. The dirty data mark is used to indicate whether there is dirty data in the memory.
[0067] Specifically, after the failure of the storage system, the dirty data mark in the target super block corresponding to the storage volume in which data is written before the failure, i.e., the target storage volume, is first read. Whether there is dirty data in the system memory is determined by reading the value of the dirty data mark in the target super block, so as to determine whether the verification process needs to be started.
[0068] If the dirty data mark is the first identifier, S120 is entered, in this embodiment, the value of isClean is True, S120 is entered; if the dirty data mark is the second identifier, S140 is entered; in this embodiment, the value of isClean is False, S140 is entered.
[0069] S120, acquiring the first address stored in the target super block.
[0070] Specifically, after data is written, the first address of the data stored in the corresponding target super block is stored. This facilitates subsequent data recovery.
[0071] S130, recovering the corresponding metadata according to the first address.
[0072] S140, starting a check recovery process.
[0073] Specifically, the original host I / O check recovery process is started.
[0074] Preferably, starting the check recovery process includes:
[0075] S141, searching for a target data block from the target storage volume;
[0076] S142, repairing metadata information in the target data block according to the set of LP address information and the set of PL address information in the target data block.
[0077] The storage system failure recovery method provided in this embodiment includes: reading a dirty data mark in a target super block corresponding to a target storage volume, the dirty data mark being used to indicate whether there is dirty data in the memory; if the dirty data mark is a first identifier, acquiring a first address stored in the target super block; recovering corresponding metadata according to the first address; if the dirty data mark is a second identifier, starting a check recovery process; and setting a dirty data mark reflecting whether there is dirty data in the memory in a super block corresponding to the storage volume. Thus, different recovery processes are adopted according to whether there is a dirty data mark, the impact of a disaster failure on a customer's business is effectively reduced, and the customer's host business is recovered faster.
[0078] Embodiment two: corresponding to the above-mentioned embodiment one, the storage system failure recovery device provided in this application will be introduced below. The system can be realized in the form of hardware or software, or realized in the form of a combination of software and hardware, and the application does not limit it.
[0079] In one example, the application provides a storage system failure device, which includes:
[0080] The reading module 210 is configured to read a dirty data mark in a target super block corresponding to a target storage volume.
[0081] The acquisition module 220 is configured to acquire a first address stored in the target super block when the dirty data flag is the first identification.
[0082] The first recovery module 230 is configured to recover corresponding metadata according to the first address.
[0083] The second recovery module 240 is configured to start a check recovery process if the dirty data flag is the second identification.
[0084] In a preferred embodiment, the system further comprises:
[0085] The judgment module 250 is configured to periodically determine whether there is metadata writing in the target storage volume within a preset time based on a preset timer.
[0086] If the judgment module 250 determines that there is metadata writing in the target storage volume within the preset time, the system enters the first recording unit 261 in the recording module 260, and the first recording unit 261 is configured to record the dirty data flag as the second identification in the target super block.
[0087] If the judgment module 250 determines that there is no metadata writing in the target storage volume within the preset time, the system enters the second recording unit 262 in the recording module 260, and the second recording unit 262 is configured to record the dirty data flag as the first identification in the target super block.
[0088] Preferably, the system further comprises:
[0089] The start module 270 is configured to start the timer when the storage system starts before the judgment module 250 periodically determines whether there is metadata writing in the target storage volume within a preset time based on the preset timer.
[0090] More preferably, the system further comprises:
[0091] The execution module 280 is configured to execute host IO services based on the target storage volume after the first recording unit 261 records the dirty data flag as the second identification in the target super block.
[0092] The first writing module 290 is configured to write a first address of current writing data into a target super block corresponding to the target storage volume after the second recording unit 262 records the dirty data flag as the first identification in the target super block.
[0093] More preferably, the system further comprises:
[0094] The creation module 2A0 is configured to create the target storage volume before the start module 270 starts the timer when the storage system starts.
[0095] The setting module 2B0 is configured to set a dirty data mark in a target super block corresponding to the target storage volume, and initialize the dirty data mark as a first identifier;
[0096] The second writing module 2C0 is configured to write data into the target storage volume before the judging module 250 periodically judges whether there is dirty data in the storage system based on a preset timer.
[0097] The second recovery module 240 includes:
[0098] The searching unit 241 is configured to search for a target data block from the target storage volume;
[0099] The repairing unit 242 is configured to repair metadata information in the target data block according to the set of LP address information and the set of PL address information in the target data block.
[0100] Embodiment Three: Corresponding to the above-mentioned embodiments one to two, the following will be combined with Figure 3 , the computer device provided in the present application is introduced. In one example as Figure 3 shown, the present application provides a computer device, which comprises:
[0101] one or more processors; and
[0102] a memory associated with the one or more processors, the memory being configured to store program instructions, the program instructions being configured to perform the following steps when read and executed by the one or more processors:
[0103] reading a dirty data mark in a target super block corresponding to a target storage volume, the dirty data mark being configured to indicate whether there is dirty data in the memory;
[0104] if the dirty data mark is a first identifier, obtaining a first address stored in the target super block;
[0105] recovering corresponding metadata according to the first address;
[0106] if the dirty data mark is a second identifier, starting a check recovery process.
[0107] The program instructions, when read and executed by the one or more processors, can also perform operations corresponding to each step in the above-mentioned method embodiments, and reference can be made to the description in the foregoing, which will not be described here again.
[0108] Reference Figure 3An exemplary architecture of the computer device is shown, which can specifically include a processor 310, a video display adapter 311, a disk drive 312, an input / output interface 313, a network interface 314, and a memory 320. The processor 310, the video display adapter 311, the disk drive 312, the input / output interface 313, the network interface 314, and the memory 320 can be communicatively connected through a communication bus 330.
[0109] The processor 310 can be implemented in a general-purpose central processing unit (CPU), a microprocessor, an application specific integrated circuit (ASIC), or one or more integrated circuits, etc., for executing relevant programs to implement the technical solutions provided in the present application.
[0110] The memory 320 can be implemented in a read only memory (ROM), a random access memory (RAM), a static storage device, a dynamic storage device, etc. The memory 320 can store an operating system 321 for controlling the operation of the computer device 300, a basic input / output system (BIOS) 322 for controlling the low-level operation of the computer device 300. In addition, a web browser 323, a data storage management 324, and an icon font processing system 325, etc. can also be stored. The icon font processing system 325 can be an application program for implementing the foregoing steps in the embodiments of the present application. In summary, when the technical solutions provided in the present application are implemented by software or firmware, the relevant program codes are stored in the memory 320 and executed by the processor 310.
[0111] The input / output interface 313 is used to connect input / output modules to realize information input and output. The input / output modules can be configured as components in the device (not shown in the figure) or externally connected to the device to provide corresponding functions. The input devices can include a keyboard, a mouse, a touch screen, a microphone, various sensors, etc., and the output devices can include a display, a speaker, a vibrator, an indicator light, etc.
[0112] The network interface 314 is used to connect a communication module (not shown in the figure) to realize the communication interaction between the device and other devices. The communication module can realize communication through wired means (such as USB, network cable, etc.) or through wireless means (such as mobile network, WIFI, Bluetooth, etc.).
[0113] The bus 330 includes a path for transferring information between the various components of the device (e.g., the processor 310, the video display adapter 311, the disk drive 312, the input / output interface 313, the network interface 314, and the memory 320).
[0114] In addition, the computer device 300 can also obtain information of the specific obtaining condition from the virtual resource object obtaining condition information database 341, for use in condition judgment, etc.
[0115] It should be noted that although the above computer device 300 only shows the processor 310, the video display adapter 311, the disk drive 312, the input / output interface 313, the network interface 314, the memory 320, the bus 330, etc., in the specific implementation process, the computer device can also include other components necessary for normal operation. In addition, those skilled in the art can understand that the above device can also only contain the components necessary to implement the scheme of the present application, and does not have to contain all the components shown in the figure.
[0116] From the above description of the embodiments, those skilled in the art can clearly understand that the present application can be implemented by means of software and the necessary general hardware platform. Based on such understanding, the technical solutions of the present application can be embodied in the form of a software product, which can be stored in a storage medium, such as a ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for causing a computer device (which can be a personal computer, a cloud server, or a network device, etc.) to execute the methods described in various embodiments or some parts of the embodiments.
[0117] Each of the embodiments in the specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiments, since they are basically similar to the method embodiments, they are described more simply, and the relevant parts can be referred to the part of the method embodiments. The above-described device embodiments are only illustrative, and the modules described as separate components can be or can not be physically separated, and the components shown as modules can be or can not be physical modules, i.e., they can be located in one place, or can be distributed on multiple network modules. Part or all of the modules can be selected to achieve the purpose of the present embodiment scheme according to actual needs. Those skilled in the art can understand and implement without creative labor.
[0118] Of course, the above embodiments are only for illustrating the technical concept and characteristics of the present application, and the purpose is to enable those skilled in the art to understand the content of the present application and implement it, and cannot limit the protection scope of the present application. Any modification made according to the spirit and essence of the main technical solution of the present application should be covered within the protection scope of the present application.
[0119] Embodiment four: corresponding to embodiments one to three, the present embodiment also provides a computer readable storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the following steps:
[0120] Read the dirty data flag in the target superblock corresponding to the target storage volume, the dirty data flag being used to indicate whether there is dirty data in the memory;
[0121] If the dirty data flag is the first identification, obtain the first address stored in the target superblock;
[0122] Restore the corresponding metadata according to the first address;
[0123] If the dirty data flag is the second identification, start the check and recovery process.
[0124] In a preferred embodiment, the program instructions, when read and executed by the one or more processors, further perform the following steps:
[0125] Periodically determine whether there is metadata writing in the target storage volume within a preset time based on a preset timer;
[0126] If yes, record the dirty data flag as the second identification in the target superblock;
[0127] If no, record the dirty data flag as the first identification in the target superblock.
[0128] In a preferred embodiment, the program instructions, when read and executed by the one or more processors, further perform the following steps:
[0129] Start the timer when the storage system is started.
[0130] In a preferred embodiment, the program instructions, when read and executed by the one or more processors, further perform the following steps:
[0131] Perform host IO services based on the target storage volume;
[0132] After recording the dirty data flag as the first identification in the target superblock, the method further comprises: writing the first address of the current writing data into the target superblock corresponding to the target storage volume.
[0133] In a preferred embodiment, the program instructions, when read by the one or more processors, further perform the following steps:
[0134] creating the target storage volume;
[0135] setting a dirty data flag in a target super block corresponding to the target storage volume and initializing the dirty data flag to a first identification;
[0136] Before the periodically judging whether there is dirty data in the storage system based on the preset timer, the method further comprises:
[0137] writing data into the target storage volume.
[0138] In a preferred embodiment, the program instructions, when read by the one or more processors, further perform the following steps:
[0139] finding a target data block from the target storage volume;
[0140] repairing metadata information in the target data block according to the set of LP address information and the set of PL address information in the target data block.
[0141] It should be understood that the terms "first", "second" are only for descriptive purposes and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined with "first", "second" can explicitly or implicitly include one or more of the features.
[0142] Of course, the above embodiments are only for illustrating the technical concept and characteristics of the present application, and the purpose is to enable those skilled in the art to understand the content of the present application and implement it, and cannot limit the protection scope of the present application. Any modification made according to the spirit and essence of the main technical solution of the present application should be covered within the protection scope of the present application.
Claims
1. A storage system failure recovery method characterized by comprising: The method is applied to a storage system failure restart, and the method comprises: reading a dirty data mark in a target superblock corresponding to a target storage volume, the dirty data mark being used to indicate whether there is dirty data in the memory; if the dirty data mark is a first mark, obtaining a first address stored in the target superblock; retrieving corresponding metadata according to the first address; if the dirty data mark is a second mark, starting a check recovery process; wherein, before reading the dirty data mark in the target superblock corresponding to the target storage volume, the method further comprises: creating the target storage volume; setting a dirty data mark in a target superblock corresponding to the target storage volume and initializing the dirty data mark as the first mark; starting a preset timer when the storage system starts; in response to a write request, obtaining data requested to be written in the write request, caching the data requested to be written and writing the cached data requested to be written into the target storage volume, wherein the write request carries a first address, a data length and data content, the first address is used to mark that the write request is to write the data content to a storage location of a physical space corresponding to the target storage volume, and the data length is the length of the data content; periodically judging whether there is metadata written in the target storage volume within a preset time based on the preset timer; if yes, recording the dirty data mark as the second mark in the target superblock and performing host IO business based on the target storage volume; if no, recording the dirty data mark as the first mark in the target superblock and writing a first address of currently written data into the target superblock corresponding to the target storage volume.
2. The storage system failure recovery method according to claim 1, characterized by, The target storage volume is provided with a data block, and the data block stores metadata information. The metadata comprises a logical-to-physical (LP) address information set and a physical-to-logical (PL) address information set, the LP address information set contains at least two LP values, and the PL address information set contains at least two PL values.
3. The storage system failure recovery method according to claim 2, wherein, The starting of the check recovery process comprises: finding a target data block from the target storage volume; repairing the metadata information in the target data block according to the LP address information set and the PL address information set in the target data block.
4. A storage system failure recovery apparatus for implementing the storage system failure recovery method according to claim 1, characterized by, The device comprises: a reading module configured to read a dirty data mark in a target superblock corresponding to a target storage volume; an obtaining module configured to, when the dirty data mark is a first mark, obtain a first address stored in the target superblock; a first recovery module configured to retrieve corresponding metadata according to the first address; a second recovery module configured to, when the dirty data mark is a second mark, start a check recovery process.
5. A computer device, comprising: comprise: one or more processors; and a memory associated with the one or more processors, the memory being used to store program instructions, the program instructions being read and executed by the one or more processors to perform the method of any one of claims 1-3. The computer program is executed by the processor to implement the steps of the method of any one of claims 1-3.
6. A computer readable storage medium having stored thereon a computer program, wherein, The computer program is executed by the processor to implement the steps of the method of any one of claims 1-3.
Citation Information
Patent Citations
Method and device for supporting hot plug of cache disk
CN111198786A
Metadata recovery method, device and system and computer readable storage medium
CN113742133A