prad wrote:

why in diagram 20-3 of the handbook do they show 2 parity blocks though
for disk3 and disk4? why would you ever have more than 1 for any single

The diagram shows a RAID5 made out of a number of disk stripes spread
across 4 physical drives.  It's the /stripes/ that are the basic building
block, not the disks in that implementation.  What RAID5 does is take
N-1 data blocks and adds a Nth parity block as a stripe across the N
drives. ie. reading across the diagram the first stripe consists of the
top row of 3 data blocks on the first three disks plus the 1 parity block
on the top row on the 4th disk. The next stripe (the 2nd row down) arranges it as data data parity data, and so forth for the succeeding stripes.

The parity blocks are staggered across the drives to even out the traffic levels on each spindle. As the diagram shows, it's not always possible to have an exactly equal balance of parity and data blocks per drive. The
diagram is simplistic though -- in a real system the stripe size would be
something like N*128k -- which means that there would be millions of stripes
on typical GB sized disks, so the differences between drives are entirely neglible.

You have to have at least three disks to make a RAID5, and while theoretically you can have as many disks as you want, there's a practical
limit somewhere around 12-13 drives [Remember, you have to calculate the
XOR of all the data blocks in the stripe on any IO operation, and with so many drives, that rapidly becomes onerous.] The sweet spot seems to be
around 7 drives.

There is a variant not supported by vinum called RAID6 -- this is simply
RAID5 with the parity block doubled up as a backup.  It's relatively new
and available under FreeBSD only by using hardware cards (Areca, 3ware etc.)
All this does is allow the file system to survive loss of any *two* disks -- something that is more likely to occur than you might think, particularly
as the number of disks per RAID goes up.



Dr Matthew J Seaman MA, D.Phil.                   7 Priory Courtyard
                                                 Flat 3
PGP:     Ramsgate
                                                 Kent, CT11 9PW

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to