mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrea Righi <righiandr@users.sourceforge.net>
To: Naveen Gupta <ngupta@google.com>
Cc: Paul Menage <menage@google.com>,
	Dhaval Giani <dhaval@linux.vnet.ibm.com>,
	Balbir Singh <balbir@linux.vnet.ibm.com>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] cgroup: limit block I/O bandwidth
Date: Sat, 19 Jan 2008 12:17:01 +0100 (MET)	[thread overview]
Message-ID: <4791DC2C.9090405@users.sourceforge.net> (raw)
In-Reply-To: <2846be6b0801181439o55dcff09ted2b8f817e7ba682@mail.gmail.com>

Naveen Gupta wrote:
>> Paul Menage wrote:
>>> On Jan 18,  2008 7:36 AM, Dhaval Giani <dhaval@linux.vnet.ibm.com>  wrote:
>>>> On Fri, Jan 18, 2008 at 12:41:03PM +0100, Andrea Righi  wrote:
>>>>> Allow to limit the  block I/O bandwidth for  specific process containers
>>>>> (cgroups) imposing additional delays  on I/O requests for those processes
>>>>> that exceed the  limits defined in the control group filesystem.
>>>>>
>>>>>  Example:
>>>>>   # mkdir /dev/cgroup
>>>>>   # mount -t cgroup -oio-throttle io-throttle /dev/cgroup
>>>> Just a minor nit, can't we name it as io,  keeping in mind that other
>>>> controllers are known as cpu and  memory?
>>> Or maybe "blockio"?
>> Agree, blockio seems better. Not all I/O is performed on  block devices
>> and in this case we're  considering block devices only.
> 
> Here we want to rate limit in block layer, I would think I/O scheduler
> is the place where we are in much better position to do this kind of
> limiting.
> 
> Also we are changing the behavior of application by adding sleeps to
> it during request submission. Moreover, we will prevent requests from
> being merged since we won't allow them to be submitted in this case.
> 
> Since bulk of submission for writes is done in background kernel
> threads and we throttle based on limits on current, we will end up
> throttling these threads and not the actual processes submitting i/o.

Yep, that's true! This works for read operations only... at the very
least, if I've understood well, we could throttle I/O reads in the
submit_bio() path and write operations in __set_page_dirty(). But this
would change the applications behavior, so probably the best approcah
could be to just get I/O statistics from TASK_IO_ACCOUNTING stuff and
implement task delays at the I/O scheduler layer...

Thanks,
-Andrea

  reply	other threads:[~2008-01-19 11:17 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-18 22:39 Naveen Gupta
2008-01-19 11:17 ` Andrea Righi [this message]
2008-01-20 13:45   ` Andrea Righi
2008-01-20 14:32     ` Jens Axboe
2008-01-20 14:58       ` Balbir Singh
2008-01-20 15:41       ` Andrea Righi
2008-01-20 16:06         ` Jens Axboe
2008-01-20 23:59           ` Andrea Righi
2008-01-22 19:02             ` Naveen Gupta
2008-01-22 23:11               ` Andrea Righi
2008-01-23  1:17                 ` Naveen Gupta
2008-01-23 15:23                   ` Andrea Righi
2008-01-23 15:38                     ` Balbir Singh
2008-01-23 20:55                       ` Andrea Righi
2008-01-24  9:05                         ` Pavel Emelyanov
2008-01-24 13:48                           ` Andrea Righi
2008-01-24 13:50                             ` Balbir Singh
  -- strict thread matches above, loose matches on Subject: below --
2008-01-18 11:41 Andrea Righi
2008-01-18 12:36 ` Dhaval Giani
2008-01-18 12:41   ` Paul Menage
2008-01-18 13:02     ` Andrea Righi
2008-01-18 15:50 ` Andrea Righi

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=4791DC2C.9090405@users.sourceforge.net \
    --to=righiandr@users.sourceforge.net \
    --cc=balbir@linux.vnet.ibm.com \
    --cc=dhaval@linux.vnet.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=menage@google.com \
    --cc=ngupta@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome