linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Two RAID1 mirrors are faster than three
@ 2003-05-12  2:10 Chuck Ebbert
  2003-05-12  4:35 ` Clemens Schwaighofer
  0 siblings, 1 reply; 16+ messages in thread
From: Chuck Ebbert @ 2003-05-12  2:10 UTC (permalink / raw)
  To: linux-raid; +Cc: linux-kernel


  All these tests were run on 2.4.21-rc2-ac1...

  We start out with a three disk raid1 array in failure mode:
        md21 : active raid1 hdi9[1] hdg9[2]
              3145856 blocks [3/2] [_UU]
        
  There are three 500 MiB contiguous files in the volume root:
        -rw-r--r--    1 root     root     524288000 May 11 13:53 file1
        -rw-r--r--    1 root     root     524288000 May 11 13:54 file2
        -rw-r--r--    1 root     root     524288000 May 11 13:55 file3

  First test is a single sequential stream:
        # umount /mnt/md21; mount /mnt/md21
        # time dd if=/mnt/md21/file1 of=/dev/null bs=64k &
        real    0m18.230s   <==== 27.5 MiB/s 
        user    0m0.020s
        sys     0m3.760s

  Now two streams:
        # umount /mnt/md21; mount /mnt/md21
        # time dd if=/mnt/md21/file1 of=/dev/null bs=64k &
        # time dd if=/mnt/md21/file2 of=/dev/null bs=64k &
        real    0m18.065s   <==== 27.6 MiB/s
        user    0m0.040s
        sys     0m4.280s
        real    0m23.197s   <==== 21.6 MiB/s
        user    0m0.020s
        sys     0m4.250s

  Add the third disk back into the array:
        # raidhotadd /dev/md21 /dev/hde9
        [rebuilt 3000MiB in 313s == (3000+3000)/313 == 19MiB/s throughput]
        
  Now rerun the two streams test:
        # umount /mnt/md21; mount /mnt/md21
        # time dd if=/mnt/md21/file1 of=/dev/null bs=64k &
        # time dd if=/mnt/md21/file2 of=/dev/null bs=64k &
        real    0m50.336s   <==== 9.94 MiB/s (!)
        user    0m0.030s
        sys     0m4.350s
        real    0m50.431s   <==== 9.91 MiB/s (!)
        user    0m0.030s
        sys     0m4.200s

  So 50% more hardware (disks, channels) gives a 60% performance drop
  when using raid1 with sequential reads... and raid1.c:read_balance()
  is the culprit.


Uniform Multi-Platform E-IDE driver Revision: 7.00beta3-.2.4
  
HPT370: IDE controller at PCI slot 00:0d.0  
HPT370: chipset revision 3

PDC20262: IDE controller at PCI slot 00:10.0
PDC20262: chipset revision 1

hde: MAXTOR 4K060H3, ATA DISK drive
hdg: MAXTOR 4K060H3, ATA DISK drive
hdi: MAXTOR 4K060H3, ATA DISK drive

 hde: hde1 hde2 hde3 hde4 < hde5 hde6 hde7 hde8 hde9 hde10 >
 hdg: hdg1 hdg2 hdg3 hdg4 < hdg5 hdg6 hdg7 hdg8 hdg9 hdg10 >
 hdi: hdi1 hdi2 hdi3 hdi4 < hdi5 hdi6 hdi7 hdi8 hdi9 hdi10 >
 

^ permalink raw reply	[flat|nested] 16+ messages in thread
* Re: Two RAID1 mirrors are faster than three
@ 2003-05-12 16:32 Chuck Ebbert
  0 siblings, 0 replies; 16+ messages in thread
From: Chuck Ebbert @ 2003-05-12 16:32 UTC (permalink / raw)
  To: Clemens Schwaighofer, Linux Kernel Mailing List

Clemens Schwaighofer wrote:

> Why three drives in a Raid1? Raid one is just mirror, or is the third
> drive like a "hot" replace drive if one of the others fail?

  The goal is to get better (read) performance, as well as extra
redundancy.  The system is supposed to balance reads among the
available drives but in this case it breaks when there are more
than two disks.

  I have a "changes way too much code" patch that fixes this; guess
I should at least post it and see what happens...



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

end of thread, other threads:[~2003-05-19  8:06 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-05-12  2:10 Two RAID1 mirrors are faster than three Chuck Ebbert
2003-05-12  4:35 ` Clemens Schwaighofer
2003-05-12  5:10   ` Anders Karlsson
2003-05-12  5:41     ` Paul P Komkoff Jr
2003-05-12  7:23       ` Anders Karlsson
2003-05-12  8:40     ` Clemens Schwaighofer
2003-05-12  9:30       ` [OT] " Anders Karlsson
2003-05-12 11:20         ` Paul P Komkoff Jr
2003-05-12 14:29           ` Valdis.Kletnieks
2003-05-13  2:24         ` Clemens Schwaighofer
2003-05-13  7:41           ` Anders Karlsson
2003-05-12 14:56       ` Lars Marowsky-Bree
2003-05-15  7:21     ` Riley Williams
2003-05-15 10:51       ` Anders Karlsson
2003-05-19  8:19         ` Jakob Oestergaard
2003-05-12 16:32 Chuck Ebbert

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).