Method, electronic device and computer program product for storage management

By detecting historical access information during disk failure recovery in the storage system, the storage units that need to be rebuilt are determined, and only the necessary units are rebuilt. This solves the problem of system performance degradation and data loss caused by full reconstruction in the traditional method, and achieves a more complete system. Efficient storage management.

CN113391937BActive Publication Date: 2024-09-06EMC IP HLDG CO LLC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202010172700.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-03-12
Publication Date
2024-09-06
Estimated Expiration
2040-03-12

AI Technical Summary

Technical Problem

Existing storage systems perform full reconstruction when a disk fails, resulting in a slow reconstruction process, increased system overhead, and possible data loss. Especially when the disk failure is transient, traditional methods cannot effectively distinguish storage units that need to be rebuilt.

Method used

By detecting when the disk changes from an unavailable state to an available state, the historical access information of the relevant storage units is obtained to determine whether there is a write request, and only the required storage units are reconstructed to avoid unnecessary reconstruction processes.

Benefits of technology

It significantly reduces system overhead, avoids data loss, improves reconstruction efficiency and system reliability, reduces unnecessary scanning of the user data layer, and improves system performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113391937B
    Figure CN113391937B
Patent Text Reader

Abstract

Embodiments of the present disclosure and methods, devices and computer program products for storage management. The method includes, in response to detecting that a disk changes from an unavailable state to an available state, determining at least one candidate storage unit associated with the disk; obtaining historical access information about the at least one candidate storage unit, the historical information including information related to write requests for the at least one candidate storage unit during the period when the disk is in the unavailable state; determining a target storage unit from the at least one candidate storage unit based on the historical access information; and performing reconstruction of the target storage unit. In this way, a low-cost method is provided to improve the reconstruction efficiency and reliability of a storage system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present disclosure generally relate to the field of data storage, and more particularly, to methods, electronic devices, and computer program products for storage management. Background Art

[0002] It has been noted that disk failures in storage systems are sometimes not permanent but temporary. For example, a disk may be online initially, but then briefly go offline and then return to normal. In addition, during the system startup phase, a disk may be identified as online by the system later than other disks, or during a disk firmware upgrade, the disk may go offline briefly.

[0003] Generally speaking, once a disk failure occurs, the system will rebuild the storage unit (Uber) constructed using the storage space on the disk. Storage units can usually be divided into different layers, with storage units in the user data layer used to store user data and storage units in the metadata layer used to store metadata. Compared with the metadata layer, the reconstruction performance of the user data layer is more critical because the user data layer consumes most of the storage space.

[0004] The user data layer is already supported to be rebuilt at the Physical Large Block (PLB) level. However, for each PLB, a scan is required to detect whether the PLB needs to be rebuilt. This process slows down the reconstruction process and may cause data loss during the reconstruction. It also significantly increases the reconstruction overhead and affects system performance. Summary of the invention

[0005] Embodiments of the present disclosure and methods, electronic devices, and computer program products for storage management.

[0006] In a first aspect of an embodiment of the present disclosure, a method for storage management is provided. The method includes, in response to detecting that a disk changes from an unavailable state to an available state, determining at least one candidate storage unit associated with the disk; obtaining historical access information about the at least one candidate storage unit, the historical information including information related to write requests to the at least one candidate storage unit during a period when the disk is in the unavailable state; determining a target storage unit from the at least one candidate storage unit based on the historical access information; and performing reconstruction of the target storage unit.

[0007] In a second aspect of the embodiments of the present disclosure, an electronic device is provided. The device includes a processor; and a memory coupled to the processor, the memory storing instructions to be executed, the instructions causing the electronic device to perform actions when executed by the processor, the actions including, in response to detecting that the disk changes from an unavailable state to an available state, determining at least one candidate storage unit associated with the disk; obtaining historical access information about the at least one candidate storage unit, the historical information including information related to write requests to the at least one candidate storage unit during the period when the disk is in the unavailable state; determining a target storage unit from the at least one candidate storage unit based on the historical access information; and performing reconstruction of the target storage unit.

[0008] In a third aspect of the present disclosure, a computer program product is provided, which is tangibly stored on a non-transitory computer-readable medium and includes machine-executable instructions, which when executed cause a machine to perform the steps of the method of the first aspect above.

[0009] This summary is provided to introduce a selection of concepts in a simplified form, which are further described in the detailed description below. This summary is not intended to identify key features or essential features of the disclosure, nor is it intended to limit the scope of the disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] Figure 1 A schematic diagram showing an exemplary operating environment in which embodiments of the present disclosure may be implemented;

[0011] Figure 2 A schematic diagram showing an example of a storage system according to an embodiment of the present disclosure;

[0012] Figure 3 A schematic diagram showing an example of a storage system according to an embodiment of the present disclosure;

[0013] Figure 4 A schematic diagram showing an example of a storage system according to an embodiment of the present disclosure;

[0014] Figure 5 A flowchart showing a method for storage management according to an embodiment of the present disclosure; and

[0015] Figure 6 A block diagram of an example device that may be used to implement embodiments of the present disclosure is shown.

[0016] In the various drawings, the same or corresponding reference numerals represent the same or corresponding parts. DETAILED DESCRIPTION

[0017] Hereinafter, various exemplary embodiments of the present disclosure will be described in detail with reference to the accompanying drawings. It should be noted that these drawings and descriptions relate to exemplary embodiments only. It should be noted that, according to the subsequent description, it is easy to conceive of alternative embodiments of the structures and methods disclosed herein, and these alternative embodiments can be used without departing from the principles claimed in the present disclosure.

[0018] It should be understood that these exemplary embodiments are provided only to enable those skilled in the art to better understand and further implement the present disclosure, but are not intended to limit the scope of the present disclosure in any way.

[0019] The terms "include", "comprising" and similar terms used herein should be understood as open-ended terms, i.e., "including / includes but not limited to". The term "based on" means "based at least in part on". The term "some embodiments" means "at least some embodiments"; the term "another embodiment" means "at least one additional embodiment". The relevant definitions of other terms will be given in the following description.

[0020] Figure 1 FIG. 1 shows a schematic diagram of an exemplary system according to the present disclosure. Figure 1 As shown, the system 100 includes a mapper 102. The mapper 102 is used to map an address in a user request to a physical space storing data so as to facilitate the user to read or write data.

[0021] The mapper 102 may provide a predetermined size of logical storage space to the upper layer application. In some examples, the size of the logical storage space may be 8EB. The above examples are only used to illustrate the size of the logical storage space that can be provided, and are not intended to limit the present disclosure. Any size of logical storage space may be set based on needs.

[0022] In the mapper 102, any suitable structure can be used to maintain the mapping between the logical address and the physical address. In one example, it uses a B+ tree to maintain the mapping between the logical address and the physical address. The mapping includes the mapping of the virtual logical block to the physical block. The virtual logical block includes one or more nodes. The above examples are only for illustration, not for limitation of the present disclosure. The mapping relationship between the logical address and the physical address in the mapper 102 can be set to any suitable structure based on needs.

[0023] In one example, the address of the physical block is stored in the node. In one example, the minimum granularity of the mapping is a 4KB page. The above examples are only for illustration and not for limitation of the present disclosure. Any suitable information associated with the physical block can be stored and any size of mapping granularity can be set based on the need.

[0024] In one example, if the mapper 102 receives a write request, the mapper 102 first gathers enough 4KB pages into a 2MB physical large block (PLB), and then executes the write request in units of physical large blocks. If the mapper 102 receives a read request, the mapper 102 may execute the read request in units of physical addresses less than or equal to 2MB.

[0025] The storage system 100 also includes a physical disk array 104. In one example, the physical disk array may be an independent redundant physical disk array (RAID). In another example, the physical disk array may be any suitable type of physical disk array. The physical disk array has a predetermined width. The width of the physical disk array refers to the number of physical disks that make up the stripes in the physical disk array. In one example, a RAID5 with a physical disk array width of 4+1 indicates that the number of physical disks that make up the stripes of the RAID5 is 4+1, 4 physical disks for storing data, and one physical disk for storing check data.

[0026] The physical disk array 104 includes a slice pool 110. The slice pool 110 includes one or more physical disks 108. Each physical disk 108 is divided into one or more physical disk slices of a fixed size. Figure 1 The figure shows that a physical disk 108 includes eight physical disk slices. The above example is only for illustrating the present disclosure, but not for limiting the present disclosure. In other embodiments, each physical disk can be configured to include any number of physical disk slices as required.

[0027] The size of the physical disk slice can be set to any value as needed. In one example, the size of the physical disk slice is 4GB. The above example is only used to illustrate the present disclosure, but not to limit the present disclosure. In other embodiments, the physical disk slice can be set to any size as needed.

[0028] Each physical disk in the slice pool 110 is grouped into one or more RAID resilience sets (RAID Resilience Set, RRS) 106-1, 106-2, ..., 106-N (collectively referred to as RAID resilience set 106 in this article), where N is a positive integer greater than 1. Considering the reliability of RAID, it is necessary to limit the number of physical disks contained in an RRS. Therefore, the number N of RAID resilience sets 106 depends on the number of physical disks. Typically, the number of physical disks contained in each RRS is limited to 25. If the number of physical disks exceeds 25, a new RRS needs to be created.

[0029] The slices in the RAID resilience group 106 can be used to form one or more logical storage units. In one example, the slices in a logical storage unit are all from a RAID resilience group. A logical storage unit is equivalent to a traditional RAID. In one example, the mapping relationship between the logical storage unit and the physical block is stored in the mapper 102. The above examples are only used to illustrate the present disclosure, not to limit the present disclosure.

[0030] The physical disk array 104 also includes one or more layers. Figure 1 The physical disk array including the layer 112 is shown for illustration purposes only. The above example is only used to illustrate the present disclosure, but not to limit the present disclosure. Any suitable number of layers can be set based on needs.

[0031] Layer 112 is read and / or called by mapper 102. Layer 112 includes one or more logical storage units. The logical storage unit can be regarded as a RAID stripe group associated with multiple physical disk slices. Alternatively or additionally, the logical storage units in layer 112 have the same physical disk array format. In one example, different layers can have different physical disk array formats. In another example, different layers can have the same physical disk array format.

[0032] In some examples, the logical storage unit in the layer 112 may have a suitable physical disk array type and / or physical disk array width. For example, the logical storage unit adopts a RAID 5 with a physical disk array width of 4+1, a RAID 5 with a physical disk array width of 8+1, or a RAID 5 with a physical disk array width of 16+1. The above examples are only for illustration and are not intended to limit the present disclosure. The logical storage unit in the layer may adopt any suitable physical disk array type and physical disk array width based on needs.

[0033] As described above, once a physical disk 108 in a slice pool 110 fails, the system will rebuild the storage units in layer 112 that are constructed using the storage space on the physical disk 108, i.e., the storage space of the disk slices of the physical disk 108. However, it is possible that the physical disk 108 does not fail permanently, but is only temporarily offline. The physical disk 108 can be turned back online within five minutes, for example. In view of this situation, the system overhead required for traditional reconstruction is large because it needs to rebuild each storage unit associated with the previously failed physical disk. This has a negative impact on system performance. In addition, data loss may also occur.

[0034] Therefore, the embodiments of the present disclosure propose a solution for storage management. This solution allows only necessary storage units to be rebuilt when a physical disk is recovered from a transient failure (offline) state. In this way, system overhead can be significantly reduced and data loss can be avoided.

[0035] The following combination Figures 2 to 4 A solution for storage management according to an embodiment of the present disclosure is described in detail. Figure 2 A schematic diagram showing an example of a storage system according to an embodiment of the present disclosure.

[0036] like Figure 2 As shown, the storage system 200 may include a physical disk array 230, which includes a slice pool 210. The slice pool 210 includes disks 2010-201 21 . Plate 2010-201 21 Each disk in the disk is divided into multiple disk slices of fixed size. For example, disk 2010 can be divided into multiple disk slices 2110-211 N .

[0037] Plate 2010-201 21 One or more disk slices in may be allocated to construct storage units 2210-221 N For example, the storage space of disk slices 2110, 2122, 2134, and 2141 is allocated to storage unit 2210. For another example, the storage space of disk slices 2113, 2123, and 2132 is allocated to storage unit 2210. A list of these storage units that have been constructed is maintained in layer 220.

[0038] like Figure 2 As shown, the storage system 200 may also include a physical disk array 230'. In the storage system, there may be two storage system nodes with the same architecture, for example, the physical disk array 230 may be regarded as one storage system node, and the physical disk array 230' may be regarded as another storage system node equivalent to the physical disk array 230. Figure 2 As can be seen from the figure, the physical disk array 230' has the same architecture as the physical disk array 230, so the architecture of the physical disk array 230' will not be described in detail here.

[0039] As two peer storage system nodes, an access request for a certain storage unit can be received by a mapper (not shown) of the physical disk array 230 and the request can be passed to the corresponding storage unit. Similarly, an access request for a certain storage unit can be received by a mapper (not shown) of the physical disk array 230' and the request can be passed to the corresponding storage unit. For the peer storage units, no matter whether the access request is received from the mapper of the physical disk array 230 or from the mapper of the physical disk array 230', the storage unit can be regarded as having been accessed.

[0040] by Figure 2 Based on the storage system 200 shown in FIG. 1 , an embodiment of the method for storage management according to the present disclosure is described in detail below. The method for storage management can be performed by Figure 2 The storage system 200 or its components shown in FIG. 2 may be implemented by Figure 2 The execution may be performed by other components of the storage system 200 not shown.

[0041] As described above, a disk in slice pool 210 may experience a temporary failure. Once the system detects that the failed disk has changed from an unavailable state to an available state, that is, it has recovered to a normal disk, the storage system determines the storage units associated with the failed disk to further determine whether these storage units need to be rebuilt.

[0042] In some embodiments, in order to determine the storage unit associated with the failed disk, the storage system may determine the disk slice included in the failed disk and further determine the storage unit constructed based on at least a portion of the disk slice. For example, the storage unit associated with the failed disk may be determined by the identification of the disk slice and the identification of the storage unit to which the disk slice is allocated.

[0043] exist Figure 2 In the example, the physical disk array 230 can monitor the status change of the disk. For example, if the physical disk array 230 finds that the disk 2010 is offline, the physical disk array 230 can determine the disk slices on the disk 2010 that have been allocated for building a storage unit. For example, it can be determined that the disk slice 2010 in the disk 2010 is used to build the storage unit 2210, the disk slice 2113 is used to build the storage unit 2211, and the disk slice 2114 is used to build the storage unit 2212.

[0044] The physical disk array 230 marks the corresponding storage locations associated with the disk slices 2110, 2113 and 2114 in the storage units 2210-2212 as faulty, that is, sets the value of their Rebuild Logging Bitmap to "1", which means that the location is inaccessible.

[0045] If the physical disk array 230 detects that the disk 2010 changes from an unavailable state to an available state and storage units 2210-2212 are determined to be storage units associated with the failed disk 2010 (i.e., candidate storage units that may need to be rebuilt), the physical disk array 230 can obtain historical access information about the storage units 2210-2212, which may include information related to write requests to the storage units 2210-2212 during the period when the disk 2010 was in the unavailable state.

[0046] A specific access flag for each storage unit in the storage units 2210 - 2212 may be obtained from the historical access information. The access flag may indicate, for example, whether there is a write request for the storage unit 2210 - 2212 during the period when the disk 2010 is in an unavailable state.

[0047] For example, the access flag may exist in the form of a bit, which is also referred to as a write bit hereinafter. The access flag of a storage unit is initialized to "0" when the storage unit is created. When the performance of the storage unit is degraded (for example, due to a failure of a disk) and a write request is received during the degradation period, the access flag is set to "1". If there is no write request, the write bit is set to "0".

[0048] Based on the historical access information, in particular, based on the access flag for the storage unit, a target storage unit that needs to be rebuilt can be determined from the determined storage units that may need to be rebuilt.

[0049] If the storage system 200 includes only one storage node, for example, the physical disk array 230, it is known by acquiring the access flags for the storage units 2210-2212 from the historical access information that the storage unit 2210 has been accessed during the period when the disk 2010 is in the unavailable state, and the access flag of the storage unit can be expressed as:

[0050] Table 1: Access flags for storage units

[0051] Storage Unit Access flag (write bit) <![CDATA

[2210] ]> 1 <![CDATA

[2211] ]> 0 <![CDATA

[2212] ]> 0

[0052] As shown in Table 1, the write bit of the storage unit 2210 is set to "1", and the write bits of the storage units 2211 and 2212 are set to "0." Therefore, in this embodiment, the storage unit 2210 is determined as the target storage unit that needs to be rebuilt.

[0053] If the storage system includes two equal storage nodes, such as physical disk array 230 and physical disk array 230', it is necessary to consider the access to storage units 2210-2212 on the two storage nodes, because, as shown above, the storage units can be accessed through any storage node.

[0054] Therefore, it is necessary to obtain historical access information of the two storage nodes to determine which storage units have been accessed during the period when the disk is in an unavailable state. For example, the physical disk array 230 may send a request to the physical disk array 230' to synchronize the historical access information of all storage units.

[0055] For example, by acquiring the access flags for storage units 2210-2212 from the historical access information, that is, knowing the write bit, in the physical disk array 230, the storage unit 2210 was accessed during the period when the disk 2010 was in the unavailable state, and in the physical disk array 230', the storage unit 2211 was accessed during the period when the disk 2010 was in the unavailable state, then the access flags of the storage units can be expressed as:

[0056] Table 2: Access flags for storage units

[0057] Storage Unit Access flag (write bit) <![CDATA

[2210] ]> 1 <![CDATA

[2211] ]> 1 <![CDATA

[2212] ]> 0

[0058] As shown in Table 1, the write bits of storage cells 2210 and 2211 are set to "1", and the write bit of storage cell 2212 is set to "0." Therefore, in this embodiment, storage cells 2210 and 2211 are determined as target storage cells that need to be rebuilt.

[0059] After determining the target storage unit that needs to be rebuilt, the reconstruction log bitmap of the storage unit that has not received a write request, that is, the storage unit other than the target storage unit in the candidate storage units previously determined to be associated with the failed disk, will be cleared, and the target storage unit that is determined to need to be rebuilt will be set with a reconstruction bitmap (Rebuildbitmap).

[0060] For example, according to the example shown in Table 2, storage units 2210 and 2211 are determined as target storage units, and the reconstruction log bitmap of storage unit 2212 can be cleared. For the target storage units that have been determined to need reconstruction, such as storage units 2210 and 2211, they are marked as needing reconstruction.

[0061] In addition, for storage units other than the target storage unit among the candidate storage units, such as storage unit 2212, the disablement of write operations thereto during the period when the disk 2010 is in the unavailable state may be released.

[0062] Based on the marked storage units that need to be rebuilt, such as storage units 2210 and 2211, physical disk array 230 and / or physical disk array 230' can send a "repair request" event to a mapper (not shown) to indicate the target storage unit that needs to be rebuilt. After receiving the "repair request" event, the mapper starts the reconstruction of the target storage unit.

[0063] Once reconstruction is complete, the write operation during the disk being in the unavailable state can be disabled to the target storage unit. In addition, after reconstruction is complete, the access flag indicating whether the storage unit is accessed by write during performance degradation is cleared.

[0064] In the case of two peer storage nodes, when determining which storage units associated with a failed disk need to be rebuilt, there is a situation where one storage node suddenly goes offline before obtaining the historical access information of the other storage node. This means that the storage node cannot know which storage units associated with the failed disk have been accessed through the other storage node. Figure 3 This situation is described using the storage system shown in FIG. Figure 3 A schematic diagram showing an example of a storage system according to an embodiment of the present disclosure.

[0065] Figure 3 The storage system 300 is shown with Figure 2 The storage system 200 shown is basically the same in architecture, so it will not be described again here.

[0066] like Figure 3 As shown, for example, this situation can also be called peer lost. At this time, the physical disk array 230 does not know which storage units associated with the failed disk 2010 have been accessed through the physical disk array 230'. In this case, it is assumed that the access flags of all storage units associated with the failed disk 2010, that is, the storage units whose performance has been degraded due to the failure of the disk 2010, should be updated to indicate that they are requested to be written during the period when the disk is in an unavailable state. In other words, their write positions are set to "1".

[0067] For example, if storage units 2210-2212 are still determined to be storage units associated with failed disk 2010, during the period when performance degradation occurs in storage units 2210-2212, even if the physical disk array 230 can only determine that storage unit 2210 was requested to be written while the disk was in an unavailable state (from the storage node including the physical disk array 230), the physical disk array 230 will also regard the access flags of storage units 2210-2212 as being requested to be written while the disk was in an unavailable state (from the storage node including the physical disk array 230').

[0068] Similarly, if the physical disk array 230 goes offline, the physical disk array 230' may also perform the same process.

[0069] Another possible situation is that if a storage node has been restarted, when starting the master node (for example, the storage node of the physical disk array 230), it is necessary to check whether there is a disk that has changed to an online state after the master node is started. If so, it is necessary to update the access flags of all storage units associated with the disk to indicate that they are requested to be written during the period when the disk is in an unavailable state. In other words, their write positions are set to "1". Therefore, the access flag is a non-permanent record, so the physical disk array 230 cannot know whether there is a write request for a storage unit before startup.

[0070] By combining the storage management method according to the present disclosure described in the above embodiments, data loss can be avoided to a great extent. Figure 4 The mechanism of avoiding data loss by the method of the present disclosure is further described in detail. Figure 4 A schematic diagram of an example of a storage system according to an embodiment of the present disclosure is shown. To simplify the description, Figure 4 The storage system shown in FIG. 2 only shows one disk slice pool 210 .

[0071] like Figure 4 As shown, the disk slice pool 210 may include disks 2010-201 21 If disk 2011 goes offline (temporary failure) and disk 2012 fails permanently, and the failures of disk 2011 and disk 2012 affect the performance of storage units 2210-2212 at the same time, under the traditional solution, even if there is no write request to storage units 2210-2212 before disk 2012 fails permanently, after disk 2011 comes back online, the storage system does not know that there is no write request to storage units 2210-2212, so the storage system does not know whether to rebuild the storage unit. In this way, since disk 2012 also fails, the storage unit may cause data loss. Through the method described above, by querying the historical access records to the storage unit, it can be determined through the access flag whether there is a write request to storage units 2210-2212 during the period when disk 2011 is offline (temporary failure). If not, the data of the storage space associated with disk 2011 in the storage unit can be regarded as valid, so the data of the storage space associated with disk 2012 can be recovered through other data on the storage unit, because the failure of disk 2012 is permanent.

[0072] Even if the data in the storage space associated with disk 2012 cannot be restored temporarily or has not been fully restored, if it can be determined whether there is no write request to storage units 2210-2212 during the period when disk 2011 is offline (temporary failure), the data in the storage space associated with disk 2011 in the storage unit can be considered valid, that is, it does not need to be restored. In this way, the performance of the storage units 2210-2212 will be degraded at most, but will not be considered to be completely crashed.

[0073] In this way, a low-cost method is provided to improve reconstruction efficiency and reliability. By introducing the access flag, unnecessary scanning of most storage cells in the user data layer can be avoided when the storage cell does not receive any write request during the degradation period. It can improve the reconstruction efficiency, and in addition, improve the system reliability by avoiding the situation that the storage cell is damaged due to permanent damage of another disk after the failure of one disk. At the same time, maintaining the access flag is low-cost. There is no need to retain the bit or synchronize it with the peer. Therefore, it does not affect the response time of input and output (I / O).

[0074] Figure 5 1 is a flowchart of a method 500 for storage management according to some embodiments of the present disclosure. The method 500 may be implemented in Figure 1 The method 500 may be implemented by, for example, Figure 1 Any component of the operating environment 100 shown in FIG. Figure 1 Other computing devices in the operating environment 100 are used for execution.

[0075] At 510, if it is detected that a disk changes from an unavailable state to an available state, at least one candidate storage unit associated with the disk is determined.

[0076] In one embodiment, a disk slice included in the disk may be determined and a storage unit constructed based on at least a portion of the disk slice may be determined as a candidate storage unit.

[0077] At 520, historical access information about the at least one candidate storage unit is obtained, the historical information including information related to write requests to the at least one candidate storage unit during the period when the disk is in the unavailable state. And at 530, a target storage unit is determined from the at least one candidate storage unit based on the historical access information.

[0078] In one embodiment, an access flag for the at least one candidate storage unit can be determined from the historical access information, the access flag indicating whether there is a write request for the at least one candidate storage unit during the period when the disk is in the unavailable state, and based on the access flag, the target storage unit is determined from the at least one candidate storage unit, and there is a write request for the target storage unit during the period when the disk is in the unavailable state.

[0079] In one embodiment, the at least one candidate storage unit includes a plurality of candidate storage units, and the write operation during the period when the disk is in an unavailable state may be disabled for other candidate storage units among the plurality of candidate storage units except the target candidate unit.

[0080] In one embodiment, an identification of the storage unit targeted by the write request can be obtained from a write request received during the period when the disk is in an unavailable state; and based on determining that the identification corresponds to the at least one candidate storage unit, an access flag for the at least one candidate storage unit is updated to indicate that there is a write request for the at least one candidate storage unit during the period when the disk is in the unavailable state.

[0081] At 540, a rebuild of the target storage unit is performed.

[0082] In one embodiment, in response to the rebuilding being completed, the write operation on the target storage unit during the period when the disk was in the unavailable state may be unblocked.

[0083] In one embodiment, in response to the rebuilding being completed, an access flag for the target storage unit is cleared, the access flag indicating that there is a write request for the target storage unit during the period when the disk is in the unavailable state.

[0084] Figure 6 6 is a schematic block diagram of an example device 600 that can be used to implement an embodiment of the present disclosure. Figure 1Any of the mapper 102, physical disk array 104, slice pool 110 and layer 112 shown can be implemented by device 600. As shown, device 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to computer program instructions stored in a read-only memory (ROM) 602 or loaded from a storage unit 608 into a random access memory (RAM) 603. In RAM 603, various programs and data required for the operation of unit 600 can also be stored. CPU 601, ROM 602 and RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to bus 604.

[0085] Multiple components in the device 600 are connected to the I / O interface 605, including: an input unit 606, such as a keyboard physical disk, a mouse, etc.; an output unit 607, such as various types of displays, speakers, etc.; a storage unit 608, such as a magnetic physical disk, an optical physical disk, etc.; and a communication unit 609, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 609 allows the device 600 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.

[0086] The various processes and processing described above, such as method 500, may be performed by processing unit 601. For example, in some embodiments, method 500 may be implemented as a computer software program, which is tangibly contained in a machine-readable medium, such as storage unit 608. In some embodiments, part or all of the computer program may be loaded and / or installed on device 600 via ROM 602 and / or communication unit 609. When the computer program is loaded into RAM 603 and executed by CPU 601, one or more actions of method 500 described above may be performed.

[0087] The present disclosure may be a method, an apparatus, a system and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for executing various aspects of the present disclosure.

[0088] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage unit, a magnetic storage unit, an optical storage unit, an electromagnetic storage unit, a semiconductor storage unit, or any suitable combination of the above. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer physical disk, a hard physical disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact physical disk read-only memory (CD-ROM), a digital versatile physical disk (DVD), a memory stick, a floppy physical disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the above. The computer-readable storage medium used herein is not to be interpreted as a transient signal itself, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.

[0089] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage unit via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.

[0090] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.

[0091] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.

[0092] These computer-readable program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processing unit of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0093] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.

[0094] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.

[0095] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.

Claims

1. A method for storage management, comprising: In response to detecting that a disk changes from an unavailable state to an available state, determining a plurality of candidate RAID stripes associated with the disk, wherein each of the candidate RAID stripes is constructed using a plurality of disk slices, wherein each of the candidate RAID stripes is constructed at least in part using a corresponding unique disk slice from a plurality of disk slices located on the disk, and wherein determining the plurality of candidate RAID stripes associated with the disk comprises identifying all RAID stripes constructed using any disk slice from the plurality of disk slices located on the disk as the plurality of candidate RAID stripes; requesting, by a first storage node, from a second storage node, historical access information about the candidate RAID stripe, wherein the first storage node and the second storage node are peer storage nodes, wherein the candidate RAID stripe is accessible by both the first storage node and the second storage node, the historical access information comprising information related to write requests to the candidate RAID stripe during a period when the disk was in the unavailable state; Before receiving the historical access information about the candidate RAID stripes from the second storage node, in response to detecting that the second storage node is offline, setting, by the first storage node, access flags corresponding to all the candidate RAID stripes, wherein the access flags corresponding to the candidate RAID stripes indicate whether the corresponding candidate RAID stripes are written during the period when the disk is in the unavailable state, and wherein the set access flags corresponding to all the candidate RAID stripes indicate that all the candidate RAID stripes are written during the period when the disk is in the unavailable state; determining a target RAID stripe from the candidate RAID stripes based on the historical access information, wherein determining the target RAID stripe from the candidate RAID stripes is performed at least in part based on the access flags corresponding to all of the candidate RAID stripes; as well as A reconstruction of the target RAID stripe is performed.

2. The method according to claim 1, further comprising: The write operation during the period when the disk is in the unavailable state is released for other candidate RAID stripes among the plurality of candidate RAID stripes except the target RAID stripe.

3. The method according to claim 1, further comprising: Obtaining, from the write request received during the period when the disk is in an unavailable state, an identifier of the RAID stripe to which the write request is directed; as well as Based on determining that the identifier corresponds to one of the candidate RAID stripes, an access flag corresponding to the one of the candidate RAID stripes is updated to indicate that there is a write request for the one of the candidate RAID stripes while the disk is in the unavailable state.

4. The method according to claim 1, further comprising: In response to the rebuild being completed, the target RAID stripe is unblocked from write operations during the period when the disk was in the unavailable state.

5. The method according to claim 1, further comprising: In response to the rebuild being completed, an access flag for the target RAID stripe is cleared, the access flag indicating that there is a write request for the target RAID stripe during the period when the disk is in the unavailable state.

6. An electronic device comprising: processor; as well as A memory coupled to the processor, the memory storing instructions to be executed, the instructions causing the electronic device to perform actions when executed by the processor, the actions comprising: In response to detecting that a disk changes from an unavailable state to an available state, determining a plurality of candidate RAID stripes associated with the disk, wherein each of the candidate RAID stripes is constructed using a plurality of disk slices, wherein each of the candidate RAID stripes is constructed at least in part using a corresponding unique disk slice from a plurality of disk slices located on the disk, and wherein determining the plurality of candidate RAID stripes associated with the disk comprises identifying all RAID stripes constructed using any disk slice from the plurality of disk slices located on the disk as the plurality of candidate RAID stripes; requesting, by a first storage node, from a second storage node, historical access information about the candidate RAID stripe, wherein the first storage node and the second storage node are peer storage nodes, wherein the candidate RAID stripe is accessible by both the first storage node and the second storage node, the historical access information comprising information related to write requests to the candidate RAID stripe during a period when the disk was in the unavailable state; Before receiving the historical access information about the candidate RAID stripes from the second storage node, in response to detecting that the second storage node is offline, setting, by the first storage node, access flags corresponding to all the candidate RAID stripes, wherein the access flags corresponding to the candidate RAID stripes indicate whether the corresponding candidate RAID stripes are written during the period when the disk is in the unavailable state, and wherein the set access flags corresponding to all the candidate RAID stripes indicate that all the candidate RAID stripes are written during the period when the disk is in the unavailable state; determining a target RAID stripe from the candidate RAID stripes based on the historical access information; and A reconstruction of the target RAID stripe is performed.

7. The device according to claim 6, wherein the actions further comprise: The write operation during the period when the disk is in the unavailable state is released for other candidate RAID stripes among the plurality of candidate RAID stripes except the target RAID stripe.

8. The device according to claim 6, wherein the actions further comprise: Obtaining, from a write request received during the period when the disk is in an unavailable state, an identifier of a RAID stripe to which the write request is directed; as well as Based on determining that the identifier corresponds to one of the candidate RAID stripes, an access flag corresponding to the one of the candidate RAID stripes is updated to indicate that there is a write request for the one of the candidate RAID stripes while the disk is in the unavailable state.

9. The device according to claim 6, wherein the actions further comprise: In response to the rebuild being completed, an access flag for the target RAID stripe is cleared, the access flag indicating that there is a write request for the target RAID stripe during the period when the disk is in the unavailable state.

10. A computer program product tangibly stored on a non-transitory computer readable medium and comprising machine executable instructions which, when executed, cause a machine to perform the steps of the method according to any one of claims 1 to 5.