Thread (36 messages) 36 messages, 14 authors, 2011-05-07

Re: mdadm raid1 read performance

From: Liam Kurmos <hidden>
Date: 2011-05-05 00:40:57

Cheers Roberto,

I've got the gist of the far layout from looking at wikipedia. There
is some clever stuff going on that i had never considered.
i'm going for f2 for my system drive.

Liam


On Thu, May 5, 2011 at 1:25 AM, Roberto Spadim [off-list ref] wrote:
raid10,f2 is a stripe configuration and mirror too, think about it like this:

disk 1,2,3,4
/dev/md0 = raid1 (1,2)
/dev/md1 = raid1 (3,4)

/dev/md2 = raid0 (stripe) (md0,md1)  <--- it´s near raid10




2011/5/4 Liam Kurmos [off-list ref]:
quoted
incidentally what does the f2 layout do that it performs so much
better than the default?

Liam


On Thu, May 5, 2011 at 1:14 AM, Liam Kurmos [off-list ref] wrote:
quoted
Thanks guys!


quoted
quoted
raid10: 220MB/s
Assuming the default 'n2' layout, I would expect 2*140 or 280, so this is a
little slow.  Try "--layout=f2" and see what you get (should be more like
RAID0).

mdadm -C /dev/md0 --level=raid10 --layout=f2 --raid-devices=4
/dev/sda1 /dev/sdc1 /dev/sdd1 /dev/sde1

dd if=/dev/md0 of=/dev/null bs=1M count=1000
1000+0 records in
1000+0 records out
1048576000 bytes (1.0 GB) copied, 2.23352 s, 469 MB/s

:D

awesome!!
quoted
quoted
raid5: ~165MB/s
I would expect 3*140 or 420, so this is very slow.  I wonder if read-ahead is
set badly.
quoted
Can you:
  blockdev --getra /dev/md0
multiply the number it gives you by 8 and give it back with
  blockdev --setra NUMBER /dev/md0
genius.

im not really sure what this did but it totally fixed the problem.

look ahead was 768, set it 6144 and immediately got 400MB/s
quoted
quoted
raid1: ~140MB/s  (single disk speed)
as expected.
quoted
for 4 disks raid0 seems like suicide, but for my system drive the
speed advantage is so great im tempted to try it anyway and try and
use rsync to keep constant back up.
If you have somewhere to rsync to, then you have more disks so RAID10 might
be an answer... but I suspect you cannot move disks around that freely :-)
no need now! f2 layout is awesome.

many thanks,

Liam


quoted
NeilBrown


quoted
cheers for you responses,

Liam
--
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


--
Roberto Spadim
Spadim Technology / SPAEmpresarial
--
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
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help