[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Software vs Hardware RAID 10?



Gabor Gombas <gombasg@sztaki.hu> writes:

> On Tue, Aug 28, 2007 at 12:21:03PM +0200, Goswin von Brederlow wrote:
>
>> Raid 1:
>>   There is a "bug" in recent linux kernels with raid1 regarding read
>>   scheduling. Before when multiple read requests where made to a raid1
>>   device the kernel would distribute them across both disks giving you
>>   double the read speed to a single request. But something is broken
>>   and that no longer happens. Read and write from7to raid1 is now both
>>   the same (slow) speed.
>
> If you mean the md driver (there is also RAID1 based on dm), then it

I did indeed mean the md driver, not dm-mirror.

> never did really distribute the reads. Continuous read requests are
> always served from the same disk. For parallel requests, the md driver
> maintains the sector count of the last disk access position and issues
> the request to the disk where the head is closer. Of course this simple
> heuristics works only if the disks has just a single RAID1 partition; if
> there are more RAID partitions per device then this optimization is
> worthless.

And that is the part that no longer works.

You can test this with for example:

dd if=/dev/md0 of=/dev/zero bs=1M count=1024 &
dd if=/dev/md0 of=/dev/zero bs=1M count=1024 skip=1024

That reads the first and second GiB of the raid in parallel. With
older kernels this would cause the two continious reads to be
performed in parallel on both disks giving me about 100MiB/s
combined. Now I get 16MiB/s. A single dd gets about 50MiB/s.

>> Raid 5:
>>   At home something is broken there too. I get less performance from
>>   my raid5 than form any one disk in the raid5. With older kernel and
>>   different controlers I remember getting far more speed. I'm not sure
>>   if it is the controler or if this is releated to the raid1 "bug".
>>   Hopefully this is specific to my setup or temporary.
>
> If you have numbers I suggest sending them to the linux-raid mailing
> list, just to make sure that the problem is known to the developers.

I have to find some time to reboot the system with an old kernel and
compare. I changed both kernel and controler and disks at the same
time so it could be one of multiple culprits.

> Gabor

MfG
        Goswin



Reply to: