From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37116) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVuqF-0008V4-NU for qemu-devel@nongnu.org; Thu, 03 Apr 2014 23:31:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WVuq6-0000AF-Gt for qemu-devel@nongnu.org; Thu, 03 Apr 2014 23:30:55 -0400 Received: from e7.ny.us.ibm.com ([32.97.182.137]:57202) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WVuq6-00009x-CO for qemu-devel@nongnu.org; Thu, 03 Apr 2014 23:30:46 -0400 Received: from /spool/local by e7.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 3 Apr 2014 23:30:46 -0400 Received: from b01cxnp23034.gho.pok.ibm.com (b01cxnp23034.gho.pok.ibm.com [9.57.198.29]) by d01dlp02.pok.ibm.com (Postfix) with ESMTP id 43FC66E8041 for ; Thu, 3 Apr 2014 23:30:38 -0400 (EDT) Received: from d01av01.pok.ibm.com (d01av01.pok.ibm.com [9.56.224.215]) by b01cxnp23034.gho.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s343Ui6E46858386 for ; Fri, 4 Apr 2014 03:30:44 GMT Received: from d01av01.pok.ibm.com (localhost [127.0.0.1]) by d01av01.pok.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s343UhVN013633 for ; Thu, 3 Apr 2014 23:30:44 -0400 Message-ID: <533E270F.4010906@linux.vnet.ibm.com> Date: Fri, 04 Apr 2014 11:29:19 +0800 From: "Michael R. Hines" MIME-Version: 1.0 References: <1392713429-18201-1-git-send-email-mrhines@linux.vnet.ibm.com> <1392713429-18201-11-git-send-email-mrhines@linux.vnet.ibm.com> <531F84FD.7010608@redhat.com> In-Reply-To: <531F84FD.7010608@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC PATCH v2 10/12] mc: expose tunable parameter for checkpointing frequency List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake , qemu-devel@nongnu.org Cc: GILR@il.ibm.com, SADEKJ@il.ibm.com, pbonzini@redhat.com, quintela@redhat.com, abali@us.ibm.com, EREZH@il.ibm.com, owasserm@redhat.com, onom@us.ibm.com, hinesmr@cn.ibm.com, isaku.yamahata@gmail.com, gokul@us.ibm.com, dbulkow@gmail.com, junqing.wang@cs2c.com.cn, BIRAN@il.ibm.com, lig.fnst@cn.fujitsu.com, "Michael R. Hines" On 03/12/2014 05:49 AM, Eric Blake wrote: > diff --git a/hmp-commands.hx b/hmp-commands.hx > index f3fc514..2066c76 100644 > --- a/hmp-commands.hx > +++ b/hmp-commands.hx > @@ -888,7 +888,7 @@ ETEXI > "\n\t\t\t -b for migration without shared storage with" > " full copy of disk\n\t\t\t -i for migration without " > "shared storage with incremental copy of disk " > - "(base image shared between src and destination)", > + "(base image shared between src and destination)", > Spurious hunk. Oh, I see - you managed to take TAB damage and make it > worse with a space-TAB (I guess this file isn't tab-clean, like the > .json file is). Eww. Ooops. =) >> .mhandler.cmd = hmp_migrate, >> }, >> >> @@ -965,6 +965,20 @@ Set maximum tolerated downtime (in seconds) for migration. >> ETEXI >> >> { >> + .name = "migrate-set-mc-delay", > We're building up a LOT of migrate- tunable commands. Maybe it's time > to think about building a more generic migrate-set-parameter, which > takes both the name of the parameter to set and its value, so that a > single command serves all parameters, instead of needing a proliferation > of commands. Of course, for that to be useful, we also need a way to > introspect which parameters can be tuned; whereas with the current > approach of one command per parameter (well, 2 for set vs. get) the > introspection is based on whether the command exists. > Well, unless there's anymore strong objection, I didn't find it too difficult to add a new command in QEMU, although I did find it quite painful to expose this command in Libvirt - I had to modify something like 5 or 6 (IIRC) different files in libvirt to accomplish the same goal. Could we "merge" the commands into a single command at the libvirt level instead of the QEMU level? Is there any other "pressing" reason to merge them at the QEMU level? >> +++ b/qapi-schema.json >> @@ -2160,6 +2160,19 @@ >> { 'command': 'migrate_set_downtime', 'data': {'value': 'number'} } >> >> ## >> +# @migrate-set-mc-delay >> +# >> +# Set delay (in milliseconds) between micro checkpoints. >> +# >> +# @value: maximum delay in milliseconds >> +# >> +# Returns: nothing on success >> +# >> +# Since: 2.x >> +## >> +{ 'command': 'migrate-set-mc-delay', 'data': {'value': 'int'} } >> + >> +## > I hate write-only interfaces. If I can set the parameter, I _also_ need > a way to query the current value of the parameter. Either an existing > migration statistics output should be modified to include this new > information, or you need to add a counterpart migrate-get-mc-delay command. > Totally forgot about that - will get a 'get' command in there ASAP. - Michael