For When You Can't Have The Real Thing
[ start | index | login ]
start > Raid Types

Raid Types

Created by dave. Last edited by dave, 8 years and 250 days ago. Viewed 2,345 times. #1
[edit] [rdf]
labels
attachments

Raid Types

  • RAID0: AKA "stripe". Consecutive blocks are written to alternate drives. Theory being that you can read and write with more than one head at a time, reducing the amount of time you have to wait for data.
  • RAID1: AKA "mirror". A set of two or more disks which have the same blocks on them. This means you can survive the loss of one of the disks and keep running. Read times are improved since reads can be staggered the same way they can on stripes. Writes are slower because you have to issue n writes (one for each disk in the mirror); even though the writes happen quasi-simultaneously, you still have to issue the two write commands serially.
  • RAID4: A set of n disks where data is laid out on n-1 disks and the remaining disk is a parity disk for each "stripe"; eg:
    data | data | data | parity
    data | data | data | parity
    ...etc. This gives you the ability to read as per a stripe, while the parity block gives you the ability to recreate any single drive which has failed, granting some measure of failure recovery. Writes can be very slow, since for each write you have to read the entire stripe across all blocks, then write out your changed block and the changed parity block.
  • RAID5: Same as RAID-4 except the data and parity blocks all share the same disks; eg:
    data | data | data | parity
    data | data | parity | data
    data | parity | data | data
    ...etc.
  • RAID6: RAID-4 with a second parity disk. The parity of each block is calculated using a different set of blocks, sometimes referred to as "diagonal" parity. This is to provide a second level of error correction, should one of the surviving disks of an array fail during a rebuild operation. (So far I've only seen this on NetApp.) Write operations again can be very slow since you have to read two sets of parity sectors in order to calculate the changed parities.
  • RAID10: A set of mirrored drives which are then striped.
  • RAID01: A set of striped drives, which are then mirrored.
  • RAID50: A set of discrete RAID5 sets, which are then striped.

A Note On Parity RAIDs

At a tech lunch (see Disk Arrays) I was talking RAID with a NetApp guy. He noted that nobody as far as he knew actually calculated parity on read operations. That is, if you read one block of a drive, the system doesn't read all the blocks in the stripe to ensure the disks have not failed. This is for a few reasons:

  • reading like this would be very slow, every read would require several disk reads and a parity calculation; doing it without means you get either the benefit of randomized concurrent reads or striped consecutive block reads, depending on what you are doing
  • the drives have complicated electronics in them to detect failure anyways; if a disk can tell you if it has failed or not, why re-invent the wheel?
NetApp recommends RAID6 because their experience has shown that as disks and arrays get larger and larger, the chances of a second disk being bad in an array increases to intolerable levels.
no comments | post comment
This is a collection of techical information, much of it learned the hard way. Consider it a lab book or a /info directory. I doubt much of it will be of use to anyone else.

Useful:


snipsnap.org | Copyright 2000-2002 Matthias L. Jugel and Stephan J. Schmidt