Sunteți pe pagina 1din 30

Basics of RAID

Raghavan R
raghavan.krish@wipro.com
CSSP

Copyright 2006. Wipro Confidential


Agenda

 What is RAID?
 Need for RAID
 Advantages of RAID
 Comparing different RAID levels
 RAID levels
 Basic / Single
 Multiple / Nested
 Hardware vs Software RAID
 Miscellaneous RAID concepts
 Drawbacks of RAID

Copyright 2006. Wipro Confidential


What is RAID?

 RAID - Redundant Array of Inexpensive/Independent Disks


 Conceptualized by a paper presented in 1987 at University
of California, Berkeley
 Fundamentally, RAID is the use of multiple hard disk drives
in an array that behaves in most respects like a single
large, fast one.
 Improve availability of data
 An attempt to bridge the widening gap between
Performance of Processor vs. Performance of disks
 To support faster data access required by video and multi-
media applications - warranted new storage architecture

Copyright 2006. Wipro Confidential


Advantages of RAID

 Fault Tolerance: ability to withstand failures


 Improved Availability: access to data
 Increased, Integrated Capacity
 Improved Performance

Copyright 2006. Wipro Confidential


Agenda

 What is RAID?
 Need for RAID
 Advantages of RAID
 Comparing different RAID levels
 RAID levels
 Basic / Single
 Multiple / Nested
 Hardware vs Software RAID
 Miscellaneous RAID concepts
 Drawbacks of RAID

Copyright 2006. Wipro Confidential


Comparing different RAID levels

 Number of hard disks required


 Array capacity: Disk space available to applications
 Storage efficiency
 Read/write performance: sequential & random
 Fault tolerance
 Availability
 Degradation and Rebuilding
 Applications/Recommended uses

Copyright 2006. Wipro Confidential


RAID 0

 Provides data striping : data is broken down into blocks and each
block is written to a separate disk drive
 Requires a minimum of 2 drives to implement.
 Improves performance
 Provides no redundancy: just an Array of Inexpensive Disks
 Stripe width & configurable stripe size
 Applications: Audio/video streaming, graphic design

Copyright 2006. Wipro Confidential


RAID 0 Example
 Array containing four disks
 Stripe size 16 KB
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB
8 KB of blue file & 8 KB
of green file form 2nd
stripe
4 KB of red
file & 12 KB
of blue file
form 1st
stripe

Copyright 2006. Wipro Confidential


RAID 1

 Disk mirroring.
 Provides fault tolerance
 Low Storage efficiency: 50%
 Applications that require fault tolerance with low cost: small
database systems for accounting & financial data
 Duplexing: two controllers

Copyright 2006. Wipro Confidential


RAID 1 Example
 Array containing two disks
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


RAID 2

 Black sheep amongst the single RAID levels


 Bit-level striping with Hamming code ECC.
 Array contains data disks and redundancy disks. Redundant
bits are calculated using Hamming code ECC.
 Expensive; complex controller; substandard performance
 Typical setup: 10 data disks & 4 redundancy disks

Copyright 2006. Wipro Confidential


Parity

 Data protection technique used to overcome the high overhead


associated with mirroring
 Take N pieces of data and compute an extra piece
 If any of the N + 1 pieces of data is lost, the lost data can be
recovered by using the remaining N pieces of data regardless of
which piece was lost
 Calculation is based on Exclusive OR (XOR)

Byte 1 10100101 Byte 1 10100101


Byte 2 11110000 Byte 2 11110000

Parity Info 01010101 Parity Info 01010101

Byte 2 11110000
Parity Info 01010101

Byte 1 10100101

Copyright 2006. Wipro Confidential


RAID 3

 Byte-level striping with dedicated parity


 The data block is striped and written on the data disks. Stripe parity is
generated on Writes, recorded on the parity disk and checked on Reads.
 Typical stripe size < 1024 bytes
 Provides good performance and some level of fault tolerance.
 Dedicated parity disk serves as a performance bottleneck
 Applications that require good performance with fault tolerance

Copyright 2006. Wipro Confidential


RAID 3 Example

 Array containing four disks


 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


RAID 4

 Block-level striping with dedicated parity.


 Similar to both RAID 3 & RAID 5
 Differs from RAID 3 in the size of the stripes written to disks
 Jack of all trades and master of none: not as popular as RAID 3
or 5: databases, multimedia publishing

Copyright 2006. Wipro Confidential


RAID 4 Example

 Array containing four disks


 Stripe size 16 KB
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


RAID 5

 Block-level striping with distributed parity


 Requires a minimum of 3 drives to implement
 Most popular among the single RAID levels: good performance,
good fault tolerance, high capacity and storage efficiency

Copyright 2006. Wipro Confidential


RAID 5 Example

 Array containing four disks


 Stripe size 16 KB
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


RAID 6

 Block-level striping with dual distributed parity.


 Two independent distributed parity schemes
 Solely to improve fault tolerance: can handle the failure of
any two drives in the array

Copyright 2006. Wipro Confidential


RAID 6 Example

 Array containing four disks


 Stripe size 16 KB
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


Agenda

 What is RAID?
 Need for RAID
 Advantages of RAID
 Comparing different RAID levels
 RAID levels
 Basic / Single
 Multiple / Nested
 Hardware vs Software RAID
 Miscellaneous RAID concepts
 Drawbacks of RAID

Copyright 2006. Wipro Confidential


Multiple (Nested) RAID Levels

 Most commonly used to improve performance


 Combine single RAID levels that complement each other with
different strengths and weaknesses
 Most commonly combined level is RAID 0: to provide fault
tolerance while exploiting the performance advantages of RAID 0
 Creating a multi RAID array:
 Divide the array into a number of disks called sets or sub-
arrays
 Within each set a single RAID level is applied
 Second RAID level is applied to the array(s) to create a
higher-level array
 Naming convention - RAID X+Y (RAID XY): Apply Level X to each
sub-array and apply Level Y to the whole array

Copyright 2006. Wipro Confidential


RAID 01

 Mirror of stripes
 Ten disk array:
 Two sets of 5 disks each.
 Each set implements RAID 0 (striping)
 Mirroring takes place across the sets
 If one drive in a set fails, the entire set is not available
 Requires a minimum of 4 drives to implement

Copyright 2006. Wipro Confidential


RAID 01 Example

 Array containing eight disks


 Stripe size 16 KB
 Red file 4 KB, Blue 20 KB, Green 100 KB, Pink 500 KB

Copyright 2006. Wipro Confidential


RAID 10

 Stripe of mirrors
 Ten disk array:
 Five sets of 2 disks each.
 Each set implements RAID 1 (mirroring)
 Striping takes place across the sets
 More robust than RAID 01. Very High Reliability combined with
High Performance

Copyright 2006. Wipro Confidential


Hardware vs Software RAID

 Hardware RAID
 Most prevalent implementation
 Main types of hardware RAID:
 Bus-based: Similar to a SCSI Host Adapter or IDE controller
 External RAID controller: Use dedicated hardware (processors, cache,
battery backup) to control the array
 More expensive but delivers superior performance
 Nested RAID levels are implemented in hardware
 Software RAID
 Software solution that uses cycles of the system processor
 Cheaper but System performance takes a hit
 Generally supports only the single RAID levels
 No support for hot spares or drive swaps
 Eg.: md (Multiple Devices) driver in Linux

Copyright 2006. Wipro Confidential


Other RAID concepts

 Degraded mode: Failed drive affects performance & fault tolerance


 Rebuild: Automatic & manual
 Rebuild: Process of regenerating the data on a failed drive
 Automatic rebuild: helpful when failures occur at remote sites or at
unearthly hours
 Manual rebuild is preferred when system performance should not be
affected during working hours.
 Drive swapping: Used to replace failed drive(s) without taking the array
offline.
 Hot spares
 Used to improve fault tolerance & performance.
 Additional spare drives are available in standby mode
 Caching: Generally used to improve the performance of write operations.

Copyright 2006. Wipro Confidential


Drawbacks of RAID

 Does not make your system invulnerable.


 Single RAID levels cannot recover from multiple disk failures
 Failure of support hardware: controller, power supply
 Does not protect against natural calamities

Backups remain critical even


when RAID is used!

Copyright 2006. Wipro Confidential


References

 RAID tutorial
http://www.ecs.umass.edu/ece/koren/architecture/Raid/raidhome.html
 Comparison of RAID levels with diagrams
http://www.acnc.com/04_01_00.html
 Illustrations of RAID
http://www.lascon.co.uk/d008005.htm
 Types of RAID implementations
http://en.wikipedia.org/wiki/Redundant_array_of_independent_disks#RAID_im
plementations

Copyright 2006. Wipro Confidential


Thank you

Copyright 2006. Wipro Confidential

S-ar putea să vă placă și