<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
On 29/09/11 12:01, Martin wrote:
<blockquote
cite="mid:CAMG+XERC8o-S9CU5dsYWJgN_ikOqAYUwTkEvDh6N0V_Vn9gfMA@mail.gmail.com"
type="cite">
<pre wrap="">Sergiusz,
On 29 September 2011 11:10, Sergiusz Pawlowicz <a class="moz-txt-link-rfc2396E" href="mailto:sergiusz@pawlowicz.name"><sergiusz@pawlowicz.name></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">and another post, sorry :)
stripe size is pretty well explained at
<a class="moz-txt-link-freetext" href="http://tldp.org/HOWTO/Software-RAID-0.4x-HOWTO-8.html">http://tldp.org/HOWTO/Software-RAID-0.4x-HOWTO-8.html</a> - par. 8
</pre>
</blockquote>
<pre wrap="">
Thanks for that one... Long forgotten! Unfortunately, it is rather
dated in using ext2 examples!...
A good explanatory part is:
###
<snip>
times)...
So... Is the read-modify-write the highest performance penalty now?
</pre>
</blockquote>
<br>
That will depend on how you configure your disk, RAID and FS.<br>
The default extN FS blocksize is 4096. <br>
If your disk is has 4k blocks and your RAID/FS are set up:<br>
<br>
Start of disk|<---512 bit boot sector--><--- RAID or
filesystem blocks---> <br>
<br>
With 512 bit disk blocks this didn't matter too much but with 4k
blocks <br>
the misalignment leaves you doing 2 disk block operations for every
filesystem block<br>
operation.<br>
<br>
If on the other hand you align things nicely:<br>
Start of disk|<---512 bit boot sector--><--- 3584 bit
gap---><--- RAID or filesystem blocks---> <br>
<br>
you lose a tiny amount of space but are back to doing 1 disk block
operation per filesystem block operation.<br>
<br>
If you want performance then it is important to align file system
blocks to RAID block to disk blocks.<br>
<br>
<span class="st"><em>Theodore Tso wrote a useful article on
alignments for SSD</em></span> [1] but it appears to be hidden<br>
behind a linuxfoundation need to authorization these days. You may
find a copy elsewhere<br>
in the intertubes.<br>
<br>
There may be some mileage in making the RAID stripe size an integer
multiple of the disk<br>
read-ahead buffer or mapping it to the disk cache configuration but
I've not tested this myself.<br>
<br>
[1]<a class="moz-txt-link-freetext" href="http://www.linuxfoundation.org/news-media/blogs/browse/2009/02/aligning-filesystems-ssd%E2%80%99s-erase-block-size">http://www.linuxfoundation.org/news-media/blogs/browse/2009/02/aligning-filesystems-ssd%E2%80%99s-erase-block-size</a><br>
<br>
Have fun,<br>
Duncan<br>
</body>
</html>