linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stan Hoeppner <stan@hardwarefreak.com>
To: Jeff Allison <jeff.allison@allygray.2y.net>, linux-raid@vger.kernel.org
Subject: Re: raid resync speed
Date: Thu, 20 Mar 2014 09:35:52 -0500	[thread overview]
Message-ID: <532AFCC8.6080902@hardwarefreak.com> (raw)
In-Reply-To: <CAPrpM6wLpRhMqqsXQ8Baqz4axxj6cvoB2Z1HAOiNm7gPv1FT=w@mail.gmail.com>

On 3/19/2014 8:12 PM, Jeff Allison wrote:
...
> In this box I have a 3x2TB disk raid 5 array, which I am in the
> process of extending to a 4x2TB raid 5 array.
> 
> I've added the new disk --> mdadm --add /dev/md0 /dev/sdb
> 
> And grown the array --> mdadm --grow /dev/md0 --raid-devices=4
> 
> Now the problem the resync speed is v slow, it refuses to rise above
> 5MB, in general it sits at 4M.
...
> Model: ATA ST2000DM001-1E61 (scsi)
> Disk /dev/sdb: 2000GB
> Sector size (logical/physical): 512B/4096B
> Partition Table: msdos

Seagate Advanced Format 512e disk drive

> Number Start End Size Type File system Flags
> 1 1049kB 2000GB 2000GB primary ntfs raid

Offset is 262 physical sectors, strange value, but won't incur RMW
internally.  So no performance hit here.

...
> I've followed the article here -->
> http://www.cyberciti.biz/tips/linux-raid-increase-resync-rebuild-speed.html
> to attempt to speed it up but no joy.
> 
> Any Ideas what I've done wrong?

Yes.  The article gives 16384 and 32768 as examples for
stripe_cache_size.  Such high values tend to reduce throughput instead
of increasing it.  Never use a value above 2048 with rust, and 1024 is
usually optimal for 7.2K drives.  Only go 4096 or higher with SSDs.  In
addition, high values eat huge amounts of memory.  The formula is:

stripe_cache_size * 4096 bytes * drive_count = RAM usage

(32768*4096) * 4 = 512MB of RAM consumed by the stripe cache
(16384*4096) * 4 = 256MB of RAM consumed by the stripe cache

 (2048*4096) * 4 =  32MB of RAM consumed by the stripe cache
 (1024*4096) * 4 =  16MB of RAM consumed by the stripe cache


Cheers,

-- 
Stan

  reply	other threads:[~2014-03-20 14:35 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-20  1:12 raid resync speed Jeff Allison
2014-03-20 14:35 ` Stan Hoeppner [this message]
2014-03-20 15:35   ` Bernd Schubert
2014-03-20 15:36     ` Bernd Schubert
2014-03-20 16:19       ` Eivind Sarto
2014-03-20 16:22         ` Bernd Schubert
2014-03-20 18:44     ` Stan Hoeppner
2014-03-27 16:08       ` Bernd Schubert
2014-03-28  8:03         ` Stan Hoeppner
2014-03-20 17:46 ` Bernd Schubert
2014-03-21  0:44   ` Jeff Allison

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=532AFCC8.6080902@hardwarefreak.com \
    --to=stan@hardwarefreak.com \
    --cc=jeff.allison@allygray.2y.net \
    --cc=linux-raid@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).