linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Raid 4/5 small writes
@ 2006-04-02 15:37 Gaëtan LEURENT
  2006-04-03  1:37 ` Neil Brown
  0 siblings, 1 reply; 3+ messages in thread
From: Gaëtan LEURENT @ 2006-04-02 15:37 UTC (permalink / raw)
  To: linux-raid

Hi,

I'm considering building a Raid4[#] array for my desktop and I have a
question about small writes with Raid4/Raid5: when a small part of a
block is modified, we have two options:

- read the hole stripe, compute the new checksum and write the data and
  the checksum

- read only the part of the data that will be overwritten, and the
  corresponding part of the checksum.  Since the checksum is a simple
  XOR, we have:
     New Checksum = Old Checksum XOR Old Data XOR New Data
  and we can write the new data and the new checksum without reading
  more data.

Does the Linux kernel implements the second way?


[#] I'm not doing Raid5 because I have two 120Go drives and two 250Go
    drives.  I am thinking of making a Raid0 array out of the two small
    drives, and using that as the parity drive for the Raid4.  I believe
    this should give better performance than Raid5.

Thanks,

-- 
Gaëtan LEURENT
-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-04-16 22:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-02 15:37 Raid 4/5 small writes Gaëtan LEURENT
2006-04-03  1:37 ` Neil Brown
     [not found]   ` <444282BB.6080407@tmr.com>
2006-04-16 22:37     ` Neil Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).