4.2.39 · D3 · HinglishOperating Systems

Worked examplesRAID — levels 0, 1, 5, 6, 10 — trade-offs

3,601 words16 min read↑ Read in English

4.2.39 · D3 · Coding › Operating Systems › RAID — levels 0, 1, 5, 6, 10 — trade-offs

Hum poore page mein sirf teen tools use karte hain, sab parent note mein banaye hue:

  • XOR likha jaata hai — "carry ke bina add karo", jahan (dekho XOR and Boolean Algebra).
  • Capacity formulas, , , , .
  • Write-penalty count — small writes = 4 I/Os (RAID 5) ya 6 I/Os (RAID 6).

Kuch naya assume nahi kiya gaya. Neeche har symbol parent note mein kamaya gaya hai.


Scenario matrix

Har RAID problem inhi case classes mein se ek hoti hai. Is page ka goal har cell ko fill karna hai.

# Case class Isme tricky kya hai Worked example
A Capacity — normal array level formula mein plug karo Ex 1
B Fault tolerance — normal kitni failures survive hoti hain Ex 1, Ex 4
C Degenerate input (chota ) , : formulas limits hit karti hain Ex 2
D Zero / impossible input RAID 6 with 2 disks = "no data disks" Ex 3
E XOR recovery — data disk dies ek data block rebuild karo Ex 5
F XOR recovery — parity disk dies parity khud lost ho jaati hai Ex 5
G Small-write I/O count read-modify-write penalty Ex 6
H Limiting behaviour (bada ) efficiency jab Ex 7
I Second-failure-during-rebuild kyun RAID 5 bade arrays par mar jaata hai Ex 8
J Real-world word problem requirements se level chuno Ex 9
K Exam twist (RAID 0+1 vs 10) operations ka order fate badal deta hai Ex 10

Neeche ke examples is order mein hain taaki saath milke woh A se K tak cover karen.


Worked examples











Recall Quick self-test

RAID 6 with 2 disks — usable capacity? ::: 0 disks (invalid config; dono parity hain). RAID 5 efficiency jab n→∞? ::: 100% approach karta hai, kyunki (n−1)/n → 1. RAID 10, 3 pairs — random 2-disk failures ka kitna fraction survive hota hai? ::: 12/15 = 80%. Small RAID 6 write mein kitne I/Os lagte hain? ::: 6 (data, P, aur Q ka read+write). P_new for P_old=0100, D_old=0011, D_new=1111? ::: 1000. RAID 10 (3 pairs) mein guaranteed vs lucky failures survived? ::: Guaranteed 1 (worst case), up to 3 (ek per pair, best case). RAID 0+1 wahin kyun marti hai jahan RAID 10 survive karta hai (same disks)? ::: Stripe-then-mirror ke andar ek stripe mein redundancy nahi hoti; ek loss poori stripe tod deta hai.

Back to the RAID overview · related: Disk Scheduling, File Systems, Reliability and MTBF.