Capacity and fault tolerance with MD RAID10 with N2 F2 layout

The following is starting from Intro to Nested Raid

Linux md allows you to combine “near” and “Far” RAID configurations. For example, in am=2 and f=2 configuration with four drives (the minimum allowed) the data layout looks the following (omitted). Notice that there are four copies of each data chunk! Also notice that we can lose two drives without losing access to the data. However, in contrast to the normal RAID-10 we can lose any two drives and still retain access to all of the data. This is much better than RAID-10 where we can lose any single drive, but only specific combinations of two drives. The capacity of this particular four-drive “near” and “far” RAID configuration is the following. | Capacity = (n/2) * capacity of single disk | So we don ‘t gain any extra capacity relative to RAID-10 but we do gain the ability to lose any drives (a strong plus in my book).

I don’t know if there is an error, I really I can’t find any other mention of the huge (in my opinion) benefits of the MD-RAID10 n2 f2 layout -Ability to release any two (in 4 disks) array drives from the array instead of standard RAID10, in this case you can only lose some of the disk pairs. This is true for any MD RAID10 n2 f2 layout Is it true? In addition, what is the capacity of the 4-disk md raid 10 n2 f2 layout? This article is wrong, and some comments are inconsistent.

Thank you!

They are correct, this arrangement will allow any two failures to survive.

The’N = 2’setting ensures that the first two copy blocks are located on the equivalent sectors of different disks.

The “F = 2” setting ensures that the last two copies of the block Do not share disks with N = 2 replicated blocks, as long as the size of the array reaches or exceeds NF drives.

As for the capacity math, the article is incorrect (see below). Let’s look at a few Example:

A 4-drive 2×2 array

>There are a total of 4 drives in the array
>There are two’nearby’ copies
>There are 2 The’far’ copy
>’stripe width’ is therefore 4 blocks.

So each block is copied four times. The capacity is the size of a single drive.

One 5 drives 2×2 array

>There are a total of 5 drives in the array
>There are two’near’ replicas
>There are 2’far’ replicas
>’ The stripe width’ is therefore 4 blocks.

Like a 4-drive array, each block is copied four times. However, the additional drive provides another full drive block that can be expanded. The capacity is two The size of each drive.

To put it another way:

Given:

> N = number of drives
> R = copy of each strip Number of blocks
> S = the size of the drive

Capacity = S *(N – (R-1))

4 drive array:
N = 4
R = 4
Capacity = S(4 – (4-1))= S *(4-3)= S * 1

5 drive array:
N = 5
R = 4
Capacity = S *(5 – (4-1))= S *(5-3)= S * 2

If N≥R, then “any two fail “The condition only exists. In fact, in the case of R = 4, any three may fail. Similarly, only when N≥R

I must point out the mathematical error of the article itself. Quote: < /p>

The capacity of this specific four-wheel drive “near” and “far” RAID configuration is as follows.

Capacity = (n/2) * capacity of single disk

This is incorrect. The 2 in the formula should be the number of copied blocks. 4 in the 2×2 setting. This is clearly shown in the figure, where the “A1” block is shown four times. The author is correct for the 3 drive example because these formulas show division by 3.

[The example applies to three disks Double copy RAID]

Capacity = 2/3 * capacity of single disk

md’s man-page further supports this:

Finally, it is possible to have an array with both’near’ and’far’
copies. If an array is configured with 2 near copies and 2 far copies,
then there will be a total of 4 copies of each block, each on a different
drive. This is an artifact of the implementation and is unlikely
to be of real value.

So the 2-by-2 RAID setup will have four copies. Therefore, the four-drive implementation of the 2×2 RAID will have the capacity of a single drive.

The author’s argument is that near/ The far RAID setting will provide additional protection beyond the normal R10. The protection does not come from the near/far setting, and the protection comes from the data repeated more than 2 times.

The RAID configuration that replicates data R times can tolerate R-1 Disk failure. As long as additional failed devices are in the replication set that has failed, more failures can be tolerated. This is why the mirrored pair of RAID0 devices (R = 2) can tolerate a single drive failure. If R is equal to the number of drives (N ), all drives except one will fail and remain in service.

The following is from Intro to Nested Raid

< p>

Linux md allows you to combine “near” and “far” RAID configurations. For example, in am=2 and f=2 configu ration with four drives (the minimum allowed) the data layout looks the following (omitted). Notice that there are four copies of each data chunk! Also notice that we can lose two drives without losing access to the data. However, in contrast to the normal RAID-10 we can lose any two drives and still retain access to all of the data. This is much better than RAID-10 where we can lose any single drive, but only specific combinations of two drives. The capacity of this particular four-drive “near” and “far” RAID configuration is the following. | Capacity = (n/2) * capacity of single disk | So we don’t gain any extra capacity relative to RAID-10 but we do gain the ability to lose any drives (a strong plus in my book).

I don’t know if there is an error, I really can’t find any other mentions of the huge MD-RAID10 n2 f2 layout ( In my opinion) benefit-being able to loosen any two (in 4 disks) array drives from the array, instead of standard RAID10, in this case you can only lose some of the disk pairs. This is for Is this true for any MD RAID10 n2 f2 layout? In addition, what is the capacity of the 4-disk md raid 10 n2 f2 layout? This article is wrong, and some comments are inconsistent.

Thank you!

They are correct, such an arrangement will allow any two failures to survive.

‘N = 2’ The setting ensures that the first two replicated blocks are located on the equivalent sectors of different disks.

The “F=2” setting ensures that the last two replicated blocks do not share the disk with N = 2 replicated blocks, As long as the size of the array reaches or exceeds NF drives.

As for the capacity math, the article is incorrect (see below). Let’s look at a few examples:

A 4-drive 2×2 array

>There are a total of 4 drives in the array
>There are two’near’ replicas
>There are 2’far’ replicas
>’strip width ‘So 4 blocks.

So each block is copied four times. The capacity is the size of a single drive.

A 5-drive 2×2 array

>There are a total of 5 drives in the array
>There are two’nearby’ replicas
>There are 2’far’ replicas
>The’stripe width’ is therefore 4 blocks.

Like a 4-drive array, each block is copied four times. However, the additional drive provides another full drive block that can be expanded. The capacity is the size of two drives.

To put it another way:

Given:

> N = number of drives
> R = number of replicated blocks per strip
> S = size of drive< /p>

Capacity = S *(N – (R-1))

4 drive array:
N = 4
R = 4
Capacity = S(4 – (4-1))= S *(4-3)= S * 1

5 drive array:
N = 5
R = 4
Capacity = S *( 5 – (4-1))= S *(5-3)= S * 2

If N≥R, the “any two failures” condition only exists. In fact, when R = 4 In the case of, any three may fail. Similarly, only when N≥R

I must point out the mathematical error of the article itself. Quote:

This particular four-wheel drive The capacities of “near” and “far” RAID configurations are as follows.

Capacity = (n/2) * capacity of single disk

This is incorrect The 2 in the formula should be the number of copied blocks. It is 4 in the 2×2 setting. This is clearly shown in the figure, where the “A1” block is shown four times. The author is correct for the 3 drive example, because These formulas show division by 3.

[The example applies to double copies on three disks RAID]

Capacity = 2/3 * capacity of single disk

md’s man-page further supports this:

Finally, it is possible to have an array with both’near’ and’far’
copies. If an array is configured with 2 near copies and 2 far copies,
then there will be a total of 4 copies of each block, each on a different
drive. This is an artifact of the implementation and is unlikely
to be of real value.

So the 2-by-2 RAID setup will have four copies. Therefore, the four-drive implementation of the 2×2 RAID will have the capacity of a single drive.

The author’s argument is that near/far RAID The setting will provide extra protection beyond the normal R10. The protection does not come from the near/far setting, and the protection comes from the data repeated more than 2 times.

The RAID configuration that replicates the data R times can tolerate R-1 disk failure As long as the additional failed devices are in the replication set that has failed, more failures can be tolerated. This is why the mirrored pair of RAID0 devices (R = 2) can tolerate a single drive failure. If R is equal to the number of drives (N), All drives except one drive will fail and remain in service.

Leave a Comment

Your email address will not be published.