Lets take a really simple case.
You have four volumes and a recovery volume, each with 1 bit of information in it:
======================================================== Volumes: = Volume 1 = Volume 2 = Volume 3 = Volume 4 = Recovery = =----------=----------=----------=----------=----------= Bits: = 1 = 0 = 1 = 1 = 1 = ========================================================
The recovery volume would contain the result of each of these bits XORd together:
1 XOR 0 XOR 1 XOR 1 = 1
So, our recovery volume contains the single bit 1
.
Now, lets say volume 1 fails.
If we XOR the remaining volumes 2, 3 and 4 with the recovery bit in place of the failed volume we get:
1 XOR 0 XOR 1 XOR 1 = 1 ^
So, this tells us that volume 1 contained 1
, since it is the result of the equation.
Let us pretend volume 2 died instead, so we replace it's value in the equation with the recovery bit:
1 XOR 1 XOR 1 XOR 1 = 0 ^
So we know that volume 2 contained 0
, since it is the result of the equation.
If volume 3 or 4 failed, they would both produce 1
in this equation.
So, if any of the volumes failed, the recovery volume can be used to reconstruct the data based on the remaining volumes. This is probably the simplest form of error correction you can have. If two volumes failed, you can't recover anything.