From mboxrd@z Thu Jan 1 00:00:00 1970 From: Marcelo Tosatti Subject: Re: [PATCH v8 3/4] block: add block timer and throttling algorithm Date: Wed, 14 Sep 2011 07:50:24 -0300 Message-ID: <20110914105024.GA18910@amt.cnet> References: <1315476668-19812-1-git-send-email-wuzhy@linux.vnet.ibm.com> <1315476668-19812-4-git-send-email-wuzhy@linux.vnet.ibm.com> <20110909144403.GB19459@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Zhi Yong Wu , qemu-devel@nongnu.org, kvm@vger.kernel.org, stefanha@linux.vnet.ibm.com, aliguori@us.ibm.com, ryanh@us.ibm.com, kwolf@redhat.com, pair@us.ibm.com To: Zhi Yong Wu Return-path: Received: from mx1.redhat.com ([209.132.183.28]:39350 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756483Ab1INLNP (ORCPT ); Wed, 14 Sep 2011 07:13:15 -0400 Content-Disposition: inline In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Sep 13, 2011 at 11:09:46AM +0800, Zhi Yong Wu wrote: > On Fri, Sep 9, 2011 at 10:44 PM, Marcelo Tosatti wrote: > > On Thu, Sep 08, 2011 at 06:11:07PM +0800, Zhi Yong Wu wrote: > >> Note: > >> =A0 =A0 =A01.) 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 h= andle this senario. > > > > You can increase the length of the slice, if the request is larger = than > > slice_time * bps_limit. > Yeah, but it is a challenge for how to increase it. Do you have some = nice idea? If the queue is empty, and the request being processed does not fit the queue, increase the slice so that the request fits. That is, make BLOCK_IO_SLICE_TIME dynamic and adjust it as described above (if the bps or io limits change, reset it to the default BLOCK_IO_SLICE_TIME). > >> =A0 =A0 =A02.) When "dd" command is issued in guest, if its option= bs is set to a large value such as "bs=3D1024K", the result speed will= slightly bigger than the limits. > > > > Why? > This issue has not existed. I will remove it. > When drive bps=3D1000000, i did some testings on guest VM. > 1.) bs=3D1024K > 18+0 records in > 18+0 records out > 18874368 bytes (19 MB) copied, 26.6268 s, 709 kB/s > 2.) bs=3D2048K > 18+0 records in > 18+0 records out > 37748736 bytes (38 MB) copied, 46.5336 s, 811 kB/s >=20 > > > > There is lots of debugging leftovers in the patch. > sorry, i forgot to remove them. > > > > From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:48302) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R3nP1-0001Gl-LA for qemu-devel@nongnu.org; Wed, 14 Sep 2011 07:13:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R3nOz-0000n5-Iw for qemu-devel@nongnu.org; Wed, 14 Sep 2011 07:13:15 -0400 Received: from mx1.redhat.com ([209.132.183.28]:58770) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R3nOz-0000lh-Bs for qemu-devel@nongnu.org; Wed, 14 Sep 2011 07:13:13 -0400 Date: Wed, 14 Sep 2011 07:50:24 -0300 From: Marcelo Tosatti Message-ID: <20110914105024.GA18910@amt.cnet> References: <1315476668-19812-1-git-send-email-wuzhy@linux.vnet.ibm.com> <1315476668-19812-4-git-send-email-wuzhy@linux.vnet.ibm.com> <20110909144403.GB19459@amt.cnet> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v8 3/4] block: add block timer and throttling algorithm List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Zhi Yong Wu Cc: kwolf@redhat.com, aliguori@us.ibm.com, stefanha@linux.vnet.ibm.com, kvm@vger.kernel.org, Zhi Yong Wu , qemu-devel@nongnu.org, pair@us.ibm.com, ryanh@us.ibm.com On Tue, Sep 13, 2011 at 11:09:46AM +0800, Zhi Yong Wu wrote: > On Fri, Sep 9, 2011 at 10:44 PM, Marcelo Tosatti = wrote: > > On Thu, Sep 08, 2011 at 06:11:07PM +0800, Zhi Yong Wu wrote: > >> Note: > >> =A0 =A0 =A01.) When bps/iops limits are specified to a small value s= uch as 511 bytes/s, this VM will hang up. We are considering how to handl= e this senario. > > > > You can increase the length of the slice, if the request is larger th= an > > slice_time * bps_limit. > Yeah, but it is a challenge for how to increase it. Do you have some ni= ce idea? If the queue is empty, and the request being processed does not fit the queue, increase the slice so that the request fits. That is, make BLOCK_IO_SLICE_TIME dynamic and adjust it as described above (if the bps or io limits change, reset it to the default BLOCK_IO_SLICE_TIME). > >> =A0 =A0 =A02.) When "dd" command is issued in guest, if its option b= s is set to a large value such as "bs=3D1024K", the result speed will sli= ghtly bigger than the limits. > > > > Why? > This issue has not existed. I will remove it. > When drive bps=3D1000000, i did some testings on guest VM. > 1.) bs=3D1024K > 18+0 records in > 18+0 records out > 18874368 bytes (19 MB) copied, 26.6268 s, 709 kB/s > 2.) bs=3D2048K > 18+0 records in > 18+0 records out > 37748736 bytes (38 MB) copied, 46.5336 s, 811 kB/s >=20 > > > > There is lots of debugging leftovers in the patch. > sorry, i forgot to remove them. > > > >