Thursday 18 September 2014

XOR

Today, i get a question about RAID 4 from my friend. Interesting point is how to recover data from 1 death disk? 
From here => http://en.wikipedia.org/wiki/Standard_RAID_levels#RAID_4
I figure out the way it works.

example, we had: 
A x B x C x D = E
problem: A was lost, how to recover A?
solve:
i had: 
A x A = 0
# x 0 = #
# x 1 = !#
so:

A x B x C x D x B x C x D = E x B x C x D
<=> A = E x B x C x D

we got A.