CS 537-2 Spring 2004

Instructor: Anoop Gupta

RAID - Redundant Arrays of Inexpensive Disks

Disk drives have continued to get smaller and cheaper, so it is now economically feasible to attach a large number of disks to a computer system. Initially developed to combat cost and provide reliability and performance in disk systems, RAIDs were contrasted to single large expensive disks (SLEDs). As disks have gotten cheaper and capacity has grown, reliability and performance have become the main issues and the 'I' in RAID now stands for Independent rather than Inexpensive!

RAID's only real hurdle was that the probability of failure of a disk in a pool of disks is much higher than the probability that any single disk will fail.  Instead of using probability, this is usually expressed as Mean Time To Failure (MTTF).  If the MTTF of any particular disk in a group of 100 disks is 100,000 hours, the MTTF  of some disk in the group is 100,000 / 100 = 1000 hours.  Most of the work done with RAID systems was to combat this issue.  As a side effect, enhancements in throughput is realized, since a subset of the data is coming from each disk resulting in a parallel disk load scheme.  A decrease in latency may also be noticed since requests may be load balanced across mirrors.  The performance increase is dependent on the style of the RAID.

The theory:  As proposed in the paper, there were 5 RAID levels:

RAID 1: Disk Mirroring or Disk Shadowing
Redundancy provides higher level of protection, but has a 100% overhead for data disks as every block is written out to two locations. Writes can be done in parallel, so there is no performance penalty.  Reads need only come from one disk, so, on average, twice as many requests can be performed in a unit of time.  Failure of one disk allows the system to keep functioning using only its mirror. Maximum tolerance is failure of half of the disks. The mirrored disks have a common controller. Thus failure of controller, though quite unlikely, will lead to access failure. To overcome this, a variant Disk Duplexing is used where every disk has its own controller.

RAID 2: Memory Style Error Correction
Think Hamming Codes.  Bits are interleaved across the disks and extra disks store check information.  The check information consists of the information needed to detect a failure in one of the disks as well as parity information.  In the case of a single failure, the parity can be used to reconstruct the lost information.  The level of parallelism with this organization is equal to the number of RAID-2 groups on the system since all disks in a group must be accessed to fetch any data.  For the same reason this setup is inappropriate for accessing small blocks of data.  Traditionally RAID 2 has been used for reliable storage on systems used for scientific simulations and other tasks requiring large blocks of data.

RAID 3: Bit-level Striping with Parity
Disk controllers are capable of detecting disk failures.  Because of this, the extra information stored for Hamming style encoding is superfluous.  This makes a  single parity bit enough to reconstruct the data lost in the event of a single disk failure.  The advantage of RAID 3 over RAID 2 is the requirement of a single disk as contrasted to several disks to store the Hamming encoding regardless of the number of data disks.

RAID 4: Block-level Striping with Parity
Block interleaving stores one disk block per a RAID block and computes parity across all blocks at the same sector location on the disks.  Bit interleaving was initially used because of the ease of calculating Hamming codes, which were well understood and in common use by the time RAID systems were developed.  However, once only a single parity bit is being stored, there is no compelling reason to choose bit interleaving over block interleaving.  To the contrary, once  entire blocks are being stored on single disks, only that disk and the parity disk must be accessed for any block access on the RAID system.  This style is much more appropriate for transactional type systems.

RAID 5: Block-Interleaved Distributed Parity
The issue with storing the parity on a single disk is that the parity disk becomes the bottleneck of the system, since all updating access must do both a read and a write of the parity.  RAID 5 attempts to alleviate this by spreading the parity out amongst all the disks.  One possible scheme:  if there are n disks, the sector number modulo n plus the disk number (zero based) will be a parity block on each disk.

In practice 3 is a better version of 2 and 5 is a better version of 4, so 2 and 4 are not often used.  What people often install now:


ganoop@cs.wisc.edu
Tue Apr 20 10:45:23
CST 2004

Copyright ©2004 by Anoop Gupta. All rights reserved.