All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tim Moore <linux-raid@nsr500.net>
To: linux-raid@vger.kernel.org
Subject: Re: syncing RAID1 with more than 10MB/sec
Date: Wed, 30 Mar 2005 22:25:21 -0800	[thread overview]
Message-ID: <424B97D1.1000506@nsr500.net> (raw)
In-Reply-To: <200503300940.j2U9enm06046@www.watkins-home.com>

Generally the min/max values make no difference as long as max is > 45000. 
  System use during resync is the biggest factor other than raw CPU.

Check actual resync times:

 > cat /var/log/messages.8 | synctime
array, blocks, sec, blocks/s, start, finish
md10,    2104448,    63, 33403.9, Mar 16 23:33:37, Mar 16 23:34:40
md11,    2096384,    64, 32756.0, Mar 16 23:35:30, Mar 16 23:36:34
md13,    2096384,   127, 16507.0, Mar 16 23:36:34, Mar 16 23:37:37
md12,    2096384,   191, 10975.8, Mar 16 23:37:37, Mar 16 23:38:41
md12,    2104448,    61, 34499.1, Mar 16 23:50:38, Mar 16 23:51:39
  md5,    2096384,    63, 33275.9, Mar 16 23:51:50, Mar 16 23:52:53
md12,    2104448,    61, 34499.1, Mar 17 00:00:39, Mar 17 00:01:40
  md6,    2104384,   122, 17249.0, Mar 17 00:01:40, Mar 17 00:02:41
  md5,    2104384,   183, 11499.4, Mar 17 00:02:41, Mar 17 00:03:42
  md7,    6289344,   366, 17184.0, Mar 17 00:03:42, Mar 17 00:06:45
  md9,   52170944,  1873, 27854.2, Mar 17 00:06:45, Mar 17 00:31:52
  md8,   52187008,  3489, 14957.6, Mar 17 00:31:52, Mar 17 00:58:48

 > cat ~/bin/synctime | cksum
1035800810 528
 > cat ~/bin/synctime
#!/bin/awk -f
#GNU Awk 3.1.1
#Copyright (C) 1989, 1991-2002 Free Software Foundation.
#md resync time csv

BEGIN{
         printf "array, blocks, sec, blocks/s, start, finish\n"
         }

/md: syncing RAID array/{
         sdate = $1 " " $2 " " $3
         "date -d \"" sdate "\" +%s" | getline start
         dev = $10
         }
/md: using.*window,/{
         size = $14
         }
/md:.*sync done\./{
         fdate = $1 " " $2 " " $3
         "date -d \"" fdate "\" +%s" | getline finish
         delta = finish-start
         printf "%4s, %10s, %5s, %6.1f, %s, %s\n",
                 dev,size,delta,size/delta,sdate,fdate
         }
#end

Guy wrote:
>>-----Original Message-----
>>From: linux-raid-owner@vger.kernel.org [mailto:linux-raid-
>>owner@vger.kernel.org] On Behalf Of Nils-Henner Krueger
>>Sent: Wednesday, March 30, 2005 4:13 AM
>>To: linux-raid@vger.kernel.org
>>Subject: syncing RAID1 with more than 10MB/sec
>>
>>Syncing a raid1 takes long time for large disks because of
>>the 10MB/sec limit:
>>
>>Mar 30 10:58:31 imap1 kernel: raid1: raid set md2 not clean;
>>reconstructing mirrors
>>Mar 30 10:58:31 imap1 kernel: raid1: raid set md2 active with 2 out of 2
>>mirrors
>>Mar 30 10:58:31 imap1 kernel: md: syncing RAID array md2
>>Mar 30 10:58:31 imap1 kernel: md: minimum _guaranteed_ reconstruction
>>speed: 100 KB/sec/disc.
>>Mar 30 10:58:31 imap1 kernel: md: using maximum available idle IO
>>bandwith (but not more than 10000 KB/sec) for reconstruction.
>>
>>Is it possible to raise this value (without recompiling)?
>>I know about possible performance tradeoffs with other
>>processes, I'm just generally interested.
>>
>>Thanks.
>>
>>nils-henner
> 
> 
> Yes.  For details:
> man md
> 
> The default of 10,000 has been increased to 100,000 in newer kernels.
> I don't know which kernels.
> 
> If you want to override the defaults you could add these 3 lines to
> /etc/sysctl.conf:
> # RAID rebuild min/max speed K/Sec per device
> dev.raid.speed_limit_min = 1000
> dev.raid.speed_limit_max = 100000
> 
> Adjust above as required.  The above will take effect after a reboot.
> 
> To see current values type these 2 lines:
> cat /proc/sys/dev/raid/speed_limit_min
> cat /proc/sys/dev/raid/speed_limit_max
> 
> To temporarily change the defaults use these 2 commands:
> echo 1000 > /proc/sys/dev/raid/speed_limit_min
> echo 100000 > /proc/sys/dev/raid/speed_limit_max
> 
> Adjust above as required.  The above will take effect now.
> 
> Guy
> 
> -
> 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
> 

-- 
  | for direct mail add "private_" in front of user name

      reply	other threads:[~2005-03-31  6:25 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-03-30  9:12 syncing RAID1 with more than 10MB/sec Nils-Henner Krueger
2005-03-30  9:15 ` Catalin(ux aka Dino) BOIE
2005-03-30  9:40 ` Guy
2005-03-31  6:25   ` Tim Moore [this message]

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=424B97D1.1000506@nsr500.net \
    --to=linux-raid@nsr500.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.