Page 184 - DCAP403_Operating System
P. 184
Unit 9: I/O & Secondary Storage Structure
RAID-3 also has configuration limitations. The number of data drives in a RAID-3 confi guration Notes
must be a power of two. The most common configurations have four or eight data drives.
Some disk controllers claim to implement RAID-3, but have a segment size. The concept of
segment size is not compatible with RAID-3. If an implementation claims to be RAID-3, and has
a segment size, then it is probably RAID-4.
RAID-4: RAID Level 4 is defined as blockwise striping with parity. The parity is always written
to the same disk drive. This can create a great deal of contention for the parity drive during write
operations.
For reads, and large writes, RAID-4 performance will be similar to a RAID-0 array containing an
equal number of data disks.
For small writes, the performance will decrease considerably. To understand the cause for this, a
one-block write will be used as an example.
1. A write request for one block is issued by a program.
2. The RAID software determines which disks contain the data, and parity, and which block
they are in.
3. The disk controller reads the data block from disk.
4. The disk controller reads the corresponding parity block from disk.
5. The data block just read is XORed with the parity block just read.
6. The data block to be written is XORed with the parity block.
7. The data block and the updated parity block are both written to disk.
It can be seen from the above example that a one block write will result in two blocks being read
from disk and two blocks being written to disk. If the data blocks to be read happen to be in a
buffer in the RAID controller, the amount of data read from disk could drop to one, or even zero
blocks, thus improving the write performance.
The individual segments in a 4+1 RAID-4 array are organized as follows:
Table 9.3: RAID-4 Segments
Drive 0 Drive 1 Drive 2 Drive 3 Drive 4
0 1 2 3 Parity
4 5 6 7 Parity
8 9 10 11 Parity
12 13 14 15 Parity
16 17 18 19 Parity
20 21 22 23 Parity
RAID-5: RAID Level 5 is defined as blockwise striping with parity. It differs from RAID-4, in that
the parity data is not always written to the same disk drive.
RAID-5 has all the performance issues and benefits that RAID-4 has, except as follows:
Since there is no dedicated parity drive, there is no single point where contention will be created.
This will speed up multiple small writes.
Multiple small reads are slightly faster. This is because data resides on all drives in the array. It is
possible to get all drives involved in the read operation.
LOVELY PROFESSIONAL UNIVERSITY 177