Thread (11 messages) 11 messages, 4 authors, 2017-10-20

Re: Wiki, raid 10, and my new system :-)

From: Phil Turmel <hidden>
Date: 2017-10-17 19:04:09

On 10/17/2017 02:32 PM, Anthony Youngman wrote:
On 17/10/17 01:33, NeilBrown wrote:
quoted
This patch has some good stuff, but

   Chunk Size, as per the Linux RAID wiki, is the smallest unit of data
   that can be written to the devices

I wonder where the Linux RAID wiki say that.  It is wrong.
The smallest unit of data that can be written to the devices is the
block size, which is hardware dependant and typically 512bytes or 4K.
This is not the same as the chunk size.
https://raid.wiki.kernel.org/index.php/RAID_setup#Chunk_sizes

I understand what it's saying - this is the smallest size passed down to
the disk, not the smallest size that the disk can write ... :-)

This page has made it into the archaeology section so I don't plan to
update it. And in context, it's reasonably clear what it means.
No, it is *wrong*.  Writes in multiples of 4k and entirely within a
chunk are passes as-is to the devices.  For mirrors, all affected
devices get a copy of the request.  For parity raid, the 4k stripes
corresponding to those 4k blocks will be pulled into the stripe cache
for recalculation.  Not whole chunk-size stripes.  The stripe cache is
multiples of 4k, not multiples of the chunk size!

Writes smaller than 4k, or not aligned to 4k, will generate a
read-modify-write cycle of the 4k block involved.  Not the whole chunk.

It is more accurate to say that a chunk may be the *largest* a request
can be before it is split between devices.

Phil
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help