RAID - UofR.net

Download Report

Transcript RAID - UofR.net

RAID
Redundant
Array of
Inexpensive
Disks
Presented by Greg Briggs
RAID example: Striping
1 2 3 4 5 6
●
Disk 1
2 4 6
Disk 2
RAID
Write every other block to different disk
–
●
1 3 5
Disk block size varies, could be 1 kB
Performance
–
–
–
–
Throughput: up to N times better
Latency: same
Reliability: dropped to 1/N
Redundancy: none
Redundancy
1 2 3 4 5 6
●
●
●
●
●
1 2 3 4 5 6
Disk 1
1 2 3 4 5 6
Disk 2
RAID
Reliability increase instead of decrease
MTTF: Mean Time to Failure
MTTR: Mean Time to Repair
If MTTF >> MTTR, only need to survive a
small number of failures at most
MTTR improved via “hot spares”
RAID levels
RAID level
Min #
faults
Example
data disks
Example
check
disks
Corporations producing
products
-
Linear / spanned
0
8
0
Linux, Windows
0
Striped
0
8
0
widely used
1
Mirrored
1
8
8
EMC, Compaq, IBM,
Linux, Windows
2
Memory-style ECC
1
8
4
none
3
Bit-interleaved parity
1
8
1
Storage Concepts
4
Block-interleaved parity
1
8
1
Network Appliance, Linux
5
Block-interleaved
distributed parity
1
8
1
widely used
6
P+Q redundancy
2
8
2
Linux (beta)
1+0 or
10
Striped mirrors
1
8
8
Linux
0+1
Mirrored stripes
1
8
8
JetStor
RAID 1: Mirroring
1 2 3 4 5 6
●
●
●
●
1 2 3 4 5 6
Disk 1
1 2 3 4 5 6
Disk 2
RAID
Optionally, let disk heads be out of sync to
improve read seek time and allow parallel
small reads, at the cost of write seek time
Expensive (2N disks)
RAID 1+0: create RAID 1 pairs, and then
stripe across them
RAID 0+1: create two RAID 0 sets, and
maintain them as mirrors
RAID 3: Bit-Interleaved Parity
1 2 3 4 5 6
RAID
1&2 3&4 5&6
Disk 1
1&2 3&4 5&6
Disk 2
Disk 3
Parity Parity Parity
1&2 3&4 5&6
●
●
●
●
●
Protection group: group of N+1 disks
redundantly holding particular data
Inexpensive
Writes go to all disks in protection group
The extra disk holds parity bits, the “sum”
(xor) of the other disks
RAID 1 mirroring is like RAID 3 with N=1
RAID 4 and 5: Block-interleaved
parity
●
●
Same # disks as RAID 3: N+1
RAID 4: parity disk is still a write bottleneck
1 3 5 Disk 1
1 2 3 4 5 6
●
RAID
2 4 6 Disk 2
Parity Parity Parity
1&2 3&4 5&6 Disk 3
RAID 5: distributed parity  removes
bottleneck
1 3
1 2 3 4 5 6
RAID
2
Parity
1&2
Parity
3&4
Parity
5&6
Disk 1
5 Disk 2
4 6 Disk 3
RAID 4 and 5: Block-interleaved
parity
●
●
Read shortcut- can
do small
independent reads
Write shortcut- just
check old block and
old parity
RAID 6: P+Q redundancy
●
Like RAID 5, except uses N+2 disks per
protection group, and can survive two disk
failures
1 3
1 2 3 4 5 6 7 8
RAID
2
Parity Parity
3&4 5&8
Parity Parity
1&2 4&6
Parity
1&3
Parity Parity
5&6 2&7
Disk 1
7
Disk 2
5 8
Disk 3
4 6
Parity
7&8
Disk 4
“Software” RAID
●
RAID normally implemented by special diskcontroller cards
–
–
●
Transparent to OS
Hardware designed to operate with failed disks
Windows and Linux implement RAID in
software as well
–
–
–
–
CPU load
System may freeze with failed disks
Often, better management of RAID array
Support per-partition RAID schemes
RAID Summary
●
●
●
Higher throughput, higher transaction rate
Fault tolerance
Thus, RAID dominates today’s large storage
systems