Patent ID: 8843782

Claim:
A method for reconstructing a redundant array of inexpensive disks, comprising: when a first physical disk is faulty, finding disk units of other physical disks, where the disk units are located on a same logic disk stripe as a disk unit of the first physical disk, in each logic module of a pre-generated layout template, performing exclusive-OR on data read from the disk units of the other physical disks, and writing the data into a hot spare disk unit of a second physical disk; and in the layout template, replacing a first disk unit identifier of the first physical disk with a second disk unit identifier of the second physical disk; wherein the layout template comprises m logic modules, each logic module comprises two logic disk stripes, the redundant array of the inexpensive disks comprises N physical disks; when N is an even number, a value of m is N−1, and each logic disk stripe comprises (m+1)/2 disk unit identifiers; or when N is an odd number, a value of m is N, and each logic disk stripe comprises (m−1)/2 disk unit identifiers, the disk units corresponding to the disk unit identifiers in each logic disk stripe belong to different physical disks, and the disk unit identifiers comprised in each logic disk stripe in the same logic module are different from each other; the second disk unit identifier and the first disk unit identifier are located in a same column of the logic module, and disk unit identifiers of the first physical disk and the second physical disk belong to different logic disk stripes.