1

When I do "cat /proc/mdstat", there seems no such information as to tell which disks are in mirror.

% cat /proc/mdstat
md126 : active raid10 sda1[0] sdd1[3] sdc1[2] sdb1[1]
... near-copies

Thanks for the hint.

Does "near-copies" implies sda1 and sdd1 are mirror, and so are sdc and sdb?

Add:

It looks like the same question has been raised before (https://serverfault.com/questions/200725/mirrored-and-stripped-hd-drives-in-raid10) and seems no clear answer.

First, the number [#] beside each device seems to be related to the order in which they appear in "mdadm --create", don't know why '/proc/mdstat' has to order them strangely. If so, then by "near-copies", it might be concluded that 'sda1' and 'sdb1' are in mirror, and so are 'sdc1' and 'sdd1', correct?

Add:

And it was (partially) confirmed by the test here (http://www.linuxquestions.org/questions/linux-server-73/software-raid10-does-the-disk-order-in-mdadm-matter-671016/).

1 Answer 1

0

/proc/mdstat lists them in the order they were activated/detected, which may change between boots. The [number] is the logical order they appear in the array, and comes from the order given to mdadm --create. In your case, using the near layout, sdb1 contains the copy of data on sda1, and sdd1 contains the copy of data from sdc1.

Note that using the offset layout will give better performance since all 4 drives contain a stripe of all data, just like raid0, then the next stripe is all a copy of the first stripe, but rotated by one drive, so that each copy is on a different drive than the original. Because the main copy of each stripe spans all 4 disks, reads can read from all 4 at the same time, giving higher throughput.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .