RAID - jude-lindale/Wiki GitHub Wiki

Why we need RAID?

  • hard disks are slow/ slow access time
  • prone to fail

What is RAID?

  • redundant array of independent disk
  • many levels of redundancy

Types

  • RAID 0:
    • files are divided into two halves and each half is stored on different disks from the other
    • increase performance
    • time is reduced
    • two or more disks
    • no redundancy
    • no error checking
    • increased read and write speed
  • RAID 1:
    • duplicates data over two or more disks/mirroring
    • if data is lost there is always a backup
    • no error checking
  • RAID 2:
    • has stripping
    • checking and correcting / parity
    • minimum of 3 disks at the bit level
    • all disks are spinning in unison
    • redundancy by using ECC bits on different disks
    • lots of disks required for ECC
    • do not use
    • uses Hamming code to detect and correct errors
  • RAID 3:
    • still not fast and not much better than RIAD 2
    • only can correct data using XOR (communicative relation)
    • do not use
    • all disks are spinning in unison
    • A XOR B = C
    • B XOR C = A
    • C XOR C = B
    • works with any number of inputs
    • 01101000 01101001 (plain)
    • 01010010 01000101 (key)
    • 00111010 00101100 (result/ parity disk)
    • 01101000 01101001 + 01010010 01000101 = 00111010 00101100
    • 01010010 01000101 + 00111010 00101100 = 01101000 01101001
  • RIAD 4:
    • minimum of 3 disks
    • faster than RAID 3
    • does not need to spin in unison
    • is not used because each time a disk is changed the parity disk will change
    • parity more prone to failure
    • do not use
  • RAID 5:
    • parities are spread over multiple disks
    • if more than one disk fails then data cannot be recovered
    • most common RAID configuration
  • RAID 6:
    • same as RAID 5 but there are two copies of parities over multiple disks
    • not very common
    • if more than two disks fail then they can be recovered