All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [Qemu-devel] [PATCH v6 0/4] The intro of QEMU block I/O throttling
       [not found] <1314786708-3998-1-git-send-email-wuzhy@linux.vnet.ibm.com>
@ 2011-09-01  3:00 ` Zhi Yong Wu
  0 siblings, 0 replies; 2+ messages in thread
From: Zhi Yong Wu @ 2011-09-01  3:00 UTC (permalink / raw)
  To: qemu-devel; +Cc: pair

On Wed, Aug 31, 2011 at 06:31:44PM +0800, Zhi Yong Wu wrote:
>Return-Path: <root@f15.linux.ibm.com>
>Received: from imap.linux.ibm.com ([unix socket])  by imap.linux.ibm.com
> (Cyrus v2.3.16-Fedora-RPM-2.3.16-6.el6_1.2) with LMTPA;  Wed, 31 Aug 2011
> 07:10:59 -0400
>X-Sieve: CMU Sieve 2.3
>Received: from localhost (localhost [127.0.0.1]) by imap.linux.ibm.com
> (Postfix) with ESMTP id 458A11600040 for <wuzhy@imap.linux.ibm.com>; Wed,
> 31 Aug 2011 07:10:59 -0400 (EDT)
>X-Virus-Scanned: amavisd-new at linux.ibm.com
>X-Spam-Flag: NO
>X-Spam-Score: -1.578
>X-Spam-Level:
>X-Spam-Status: No, score=-1.578 tagged_above=-9999 required=5
> tests=[ALL_TRUSTED=-1, AWL=-0.037, RP_MATCHES_RCVD=-0.541]
> autolearn=disabled
>Received: from imap.linux.ibm.com ([127.0.0.1]) by localhost
> (maier.raleigh.ibm.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id
> IY4ziHLPdPGE for <wuzhy@imap.linux.ibm.com>; Wed, 31 Aug 2011 07:10:43
> -0400 (EDT)
>Received: from smtp.linux.ibm.com (smtp.linux.ibm.com [9.26.4.197]) by
> imap.linux.ibm.com (Postfix) with ESMTP id 7C6F11600046 for
> <wuzhy@imap.linux.ibm.com>; Wed, 31 Aug 2011 06:32:56 -0400 (EDT)
>Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com
> [9.17.195.107]) by smtp.linux.ibm.com (Postfix) with ESMTP id 2C79EC7A04
> for <wuzhy@linux.ibm.com>; Wed, 31 Aug 2011 06:32:56 -0400 (EDT)
>Received: from d03av01.boulder.ibm.com (d03av01.boulder.ibm.com
> [9.17.195.167]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0)
> with ESMTP id p7VAWtDc065946 for <wuzhy@linux.ibm.com>; Wed, 31 Aug 2011
> 04:32:55 -0600
>Received: from d03av01.boulder.ibm.com (loopback [127.0.0.1]) by
> d03av01.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id
> p7VAWtL0020748 for <wuzhy@linux.ibm.com>; Wed, 31 Aug 2011 04:32:55 -0600
>Received: from VMSDVM6.POK.IBM.COM (vmsdvm6.pok.ibm.com [9.57.5.25]) by
> d03av01.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id
> p7VAWskr020721 for <@vm-av.bld.relay.ibm.com:wuzhy@linux.ibm.com>; Wed, 31
> Aug 2011 04:32:54 -0600
>Received: by VMSDVM6.POK.IBM.COM (IBM VM SMTP Level 540) via spool with SMTP
> id 4823 ; Wed, 31 Aug 2011 06:32:38 EDT
>Received: by vmsdvm6.vnet.ibm.com (xagent2 6.3.1) via xagsmtp4 with spool id
> 0929 for wuzhy@linux.vnet.ibm.com; Wed, 31 Aug 2011 06:32:38 -0400 (EDT)
>Received: from d03relay03.boulder.ibm.com [9.17.195.228] by
> VMSDVM6.POK.IBM.COM (IBM VM SMTP Level 540) via TCP with ESMTP ; Wed, 31
> Aug 2011 06:32:36 EDT
>Received: from d03av04.boulder.ibm.com (d03av04.boulder.ibm.com
> [9.17.195.170])	by d03relay03.boulder.ibm.com (8.13.8/8.13.8/NCO
> v10.0) with ESMTP id p7VAWpoc158318;	Wed, 31 Aug 2011 04:32:52 -0600
>Received: from d03av04.boulder.ibm.com (loopback [127.0.0.1])	by
> d03av04.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id
> p7V4Wp7A005389;	Tue, 30 Aug 2011 22:32:51 -0600
>Received: from f15.cn.ibm.com ([9.115.118.18])	by d03av04.boulder.ibm.com
> (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id p7V4WmrS002404
> (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO);	Tue,
> 30 Aug 2011 22:32:50 -0600
>Received: from f15 (localhost [127.0.0.1])	by f15.cn.ibm.com
> (8.14.4/8.14.4) with ESMTP id p7VAVvbC004033;	Wed, 31 Aug 2011 18:31:58
> +0800
>Received: (from root@localhost)	by f15 (8.14.4/8.14.4/Submit) id
> p7VAVphk004032;	Wed, 31 Aug 2011 18:31:52 +0800
>From: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
>To: qemu-devel@nongnu.org
>Cc: kvm@vger.kernel.org, stefanha@linux.vnet.ibm.com, mtosatti@redhat.com,
> aliguori@us.ibm.com, ryanh@us.ibm.com, zwu.kernel@gmail.com,
> kwolf@redhat.com, pair@us.ibm.com, Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
>Subject: [PATCH v6 0/4] The intro of QEMU block I/O throttling
>Date: Wed, 31 Aug 2011 18:31:44 +0800
>Message-Id: <1314786708-3998-1-git-send-email-wuzhy@linux.vnet.ibm.com>
>X-Mailer: git-send-email 1.7.6
>X-Xagent-From: wuzhy@linux.vnet.ibm.com
>X-Xagent-To: wuzhy@linux.vnet.ibm.com
>X-Xagent-Gateway: vmsdvm6.vnet.ibm.com (XAGENTU5 at VMSDVM6)
>
>The main goal of the patch is to effectively cap the disk I/O speed or counts of one single VM.It is only one draft, so it unavoidably has some drawbacks, if you catch them, please let me know.
>
>The patch will mainly introduce one block I/O throttling algorithm, one timer and one block queue for each I/O limits enabled drive.
>
>When a block request is coming in, the throttling algorithm will check if its I/O rate or counts exceed the limits; if yes, then it will enqueue to the block queue; The timer will handle the I/O requests in it.
>
>Some available features follow as below:
>(1) global bps limit.
>   -drive bps=xxx            in bytes/s
>(2) only read bps limit
>   -drive bps_rd=xxx         in bytes/s
>(3) only write bps limit
>   -drive bps_wr=xxx         in bytes/s
>(4) global iops limit
>   -drive iops=xxx           in ios/s
>(5) only read iops limit
>   -drive iops_rd=xxx        in ios/s
>(6) only write iops limit
>   -drive iops_wr=xxx        in ios/s
>(7) the combination of some limits.
>   -drive bps=xxx,iops=xxx
>
>Known Limitations:
>(1) #1 can not coexist with #2, #3
>(2) #4 can not coexist with #5, #6
>(3) When bps/iops limits are specified to a small value such as 511 bytes/s, this VM will hang up. We are considering how to handle this senario.
>
>Changes since code V5:
>  Mainly fix the aio callback issue for block queue.
Sorry, thanks Ram Pai, some code changes based on his comments.
>
>Zhi Yong Wu (4):
>  block: add the command line support
>  block: add the block queue support
>  block: add block timer and block throttling algorithm
>  qmp/hmp: add block_set_io_throttle
>
> v5: add qmp/hmp support. 
>     Adjust the codes based on stefan's comments
>     qmp/hmp: add block_set_io_throttle
>
> v4: fix memory leaking based on ryan's feedback.
>
> v3: Added the code for extending slice time, and modified the method to compute wait time for the timer.
>
> v2: The codes V2 for QEMU disk I/O limits.
>     Modified the codes mainly based on stefan's comments.
>
> v1: Submit the codes for QEMU disk I/O limits.
>     Only a code draft.
>
> Makefile.objs     |    2 +-
> block.c           |  324 +++++++++++++++++++++++++++++++++++++++++++++++++++--
> block.h           |    6 +-
> block/blk-queue.c |  226 +++++++++++++++++++++++++++++++++++++
> block/blk-queue.h |   63 ++++++++++
> block_int.h       |   30 +++++
> blockdev.c        |   98 ++++++++++++++++
> blockdev.h        |    2 +
> hmp-commands.hx   |   15 +++
> qemu-config.c     |   24 ++++
> qemu-options.hx   |    1 +
> qerror.c          |    4 +
> qerror.h          |    3 +
> qmp-commands.hx   |   52 +++++++++-
> 14 files changed, 837 insertions(+), 13 deletions(-)
> create mode 100644 block/blk-queue.c
> create mode 100644 block/blk-queue.h
>
>-- 
>1.7.6
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Qemu-devel] [PATCH v6 0/4] The intro of QEMU block I/O throttling
@ 2011-09-01 11:44 Zhi Yong Wu
  0 siblings, 0 replies; 2+ messages in thread
From: Zhi Yong Wu @ 2011-09-01 11:44 UTC (permalink / raw)
  To: qemu-devel
  Cc: kwolf, aliguori, stefanha, kvm, mtosatti, Zhi Yong Wu, pair,
	zwu.kernel, ryanh

The main goal of the patch is to effectively cap the disk I/O speed or counts of one single VM.It is only one draft, so it unavoidably has some drawbacks, if you catch them, please let me know.

The patch will mainly introduce one block I/O throttling algorithm, one timer and one block queue for each I/O limits enabled drive.

When a block request is coming in, the throttling algorithm will check if its I/O rate or counts exceed the limits; if yes, then it will enqueue to the block queue; The timer will handle the I/O requests in it.

Some available features follow as below:
(1) global bps limit.
   -drive bps=xxx            in bytes/s
(2) only read bps limit
   -drive bps_rd=xxx         in bytes/s
(3) only write bps limit
   -drive bps_wr=xxx         in bytes/s
(4) global iops limit
   -drive iops=xxx           in ios/s
(5) only read iops limit
   -drive iops_rd=xxx        in ios/s
(6) only write iops limit
   -drive iops_wr=xxx        in ios/s
(7) the combination of some limits.
   -drive bps=xxx,iops=xxx

Known Limitations:
(1) #1 can not coexist with #2, #3
(2) #4 can not coexist with #5, #6
(3) When bps/iops limits are specified to a small value such as 511 bytes/s, this VM will hang up. We are considering how to handle this senario.

Changes since code V5:
  Mainly fix the aio callback issue for block queue.
  Adjust codes based on Ram Pai's comments.

Zhi Yong Wu (4):
  block: add the command line support
  block: add the block queue support
  block: add block timer and block throttling algorithm
  qmp/hmp: add block_set_io_throttle

 v5: add qmp/hmp support. 
     Adjust the codes based on stefan's comments
     qmp/hmp: add block_set_io_throttle
 
 v4: fix memory leaking based on ryan's feedback.
 
 v3: Added the code for extending slice time, and modified the method to compute wait time for the timer.
 
 v2: The codes V2 for QEMU disk I/O limits.
     Modified the codes mainly based on stefan's comments.
 
 v1: Submit the codes for QEMU disk I/O limits.
     Only a code draft.

 Makefile.objs     |    2 +-
 block.c           |  324 +++++++++++++++++++++++++++++++++++++++++++++++++++--
 block.h           |    6 +-
 block/blk-queue.c |  226 +++++++++++++++++++++++++++++++++++++
 block/blk-queue.h |   63 ++++++++++
 block_int.h       |   30 +++++
 blockdev.c        |   98 ++++++++++++++++
 blockdev.h        |    2 +
 hmp-commands.hx   |   15 +++
 qemu-config.c     |   24 ++++
 qemu-options.hx   |    1 +
 qerror.c          |    4 +
 qerror.h          |    3 +
 qmp-commands.hx   |   52 +++++++++-
 14 files changed, 837 insertions(+), 13 deletions(-)
 create mode 100644 block/blk-queue.c
 create mode 100644 block/blk-queue.h

-- 
1.7.6

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-09-01 11:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <1314786708-3998-1-git-send-email-wuzhy@linux.vnet.ibm.com>
2011-09-01  3:00 ` [Qemu-devel] [PATCH v6 0/4] The intro of QEMU block I/O throttling Zhi Yong Wu
2011-09-01 11:44 Zhi Yong Wu

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.