All of lore.kernel.org
 help / color / mirror / Atom feed
From: Joe Thornber <thornber@redhat.com>
To: Mikulas Patocka <mpatocka@redhat.com>
Cc: device-mapper development <dm-devel@redhat.com>,
	"Alasdair G. Kergon" <agk@redhat.com>
Subject: Re: [PATCH 1/2] dm-kcopyd: introduce per-module throttle structure
Date: Fri, 10 Jun 2011 09:44:25 +0100	[thread overview]
Message-ID: <20110610084424.GA3672@ubuntu> (raw)
In-Reply-To: <Pine.LNX.4.64.1106091136510.7642@hs20-bc2-1.build.redhat.com>

On Thu, Jun 09, 2011 at 12:08:08PM -0400, Mikulas Patocka wrote:
> 
> 
> On Thu, 9 Jun 2011, Joe Thornber wrote:
> > What we're trying to do is avoid kcopyd issuing so much io that it
> > interferes with userland io.
> 
> But you don't know if there is some userland IO or not to the same disk.

None the less, this was the motivation Alasdair gave for wanting this
throttling.

> > i) If there is lots of memory available can your throttling patch
> > still manage to issue too much io in the time that kcopyd is active?
> 
> It issues as much IO as it can in the active period.

Exactly, it can issue too much.

> > ii) If there is little memory available few ios will be issued.  But
> > your throttling will still occur, slowing things down even more.
> 
> Yes. Memory pressure and throttiling are independent things.

True, but if kcopyd has only managed to submit 50k of io in it's last
timeslice why on earth would you decide to put it to sleep rather than
try and issue some more?  I don't believe your time based throttling
behaves the same under different memory pressure situations.  So the
sys admin could set up your throttle parameters under one set of
conditions.  Then these conditions could change and result in either
too much or too little throttling.

> 
> > I think it makes much more sense to throttle based on amount of io
> > issued by kcopyd.  Either tracking throughput,
> 
> You don't know what is the throughput of the device. So throttling to 
> something like "50% throughput" can't be done.

I agree we don't know what the throughput on the devices is.  What I
meant was to throttle the volume of io that kcopyd generates against
an absolute value.  eg.  "The mirror kcopyd client cannot submit more
than 100M of io per second."  So you don't have to measure and
calculate any theoretical maximum throughput and calculate percentages
off that.

> > or even just putting a
> > limit on the amount of io that can be in flight at any one time.
> 
> Which is much less reliable throttling than time slots.
> the resync spee is:
> 8 sub jobs --- 76MB/s
> 2 sub jobs --- 74MB/s
> 1 sub job --- 65MB/s

I really don't understand these figures.  Why doesn't it scale
linearly with the number of sub jobs?  Are the sub jobs all the same
size in these cases?  Is this with your throttling?  Are the sub jobs
so large that memory pressure is imposing a max limit of in flight io?

- Joe

  parent reply	other threads:[~2011-06-10  8:44 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-31 22:03 [PATCH 1/2] dm-kcopyd: introduce per-module throttle structure Mikulas Patocka
2011-06-01  6:18 ` Ankit Jain
2011-06-01  7:13   ` Ankit Jain
2011-06-02 19:16   ` Mikulas Patocka
2011-06-01  9:51 ` Joe Thornber
2011-06-02 19:55   ` Mikulas Patocka
2011-06-03 11:01     ` Joe Thornber
2011-06-03 15:54       ` Mike Snitzer
2011-06-07 17:50       ` Mikulas Patocka
2011-06-09  9:47         ` Joe Thornber
2011-06-09 16:08           ` Mikulas Patocka
2011-06-09 16:27             ` Alasdair G Kergon
2011-06-10  8:44             ` Joe Thornber [this message]
2011-06-10  9:28               ` Lars Ellenberg
2011-06-10 10:14                 ` Joe Thornber
2011-06-10 13:41                   ` Mikulas Patocka
2011-06-10 13:48                     ` Joe Thornber
2011-06-10 16:13                       ` Lars Ellenberg
2011-06-10 13:51                     ` Mike Snitzer
2011-06-11 20:27               ` Mikulas Patocka
2011-06-13  9:17                 ` Joe Thornber
2011-06-13 21:06                   ` Mikulas Patocka
2011-06-14  8:34                     ` Joe Thornber

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=20110610084424.GA3672@ubuntu \
    --to=thornber@redhat.com \
    --cc=agk@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=mpatocka@redhat.com \
    /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.