From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:39225) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RyU6C-0003RB-JY for qemu-devel@nongnu.org; Fri, 17 Feb 2012 15:08:09 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RyU6A-00081Z-Sc for qemu-devel@nongnu.org; Fri, 17 Feb 2012 15:08:08 -0500 Received: from e34.co.us.ibm.com ([32.97.110.152]:53293) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RyU6A-00081H-K5 for qemu-devel@nongnu.org; Fri, 17 Feb 2012 15:08:06 -0500 Received: from /spool/local by e34.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 17 Feb 2012 13:08:04 -0700 Received: from d03relay03.boulder.ibm.com (d03relay03.boulder.ibm.com [9.17.195.228]) by d03dlp03.boulder.ibm.com (Postfix) with ESMTP id C4FB319D8052 for ; Fri, 17 Feb 2012 13:07:56 -0700 (MST) 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 q1HK7sG0091048 for ; Fri, 17 Feb 2012 13:07:54 -0700 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 q1HK7nES018981 for ; Fri, 17 Feb 2012 13:07:50 -0700 Message-ID: <4F3EB393.8090605@us.ibm.com> Date: Fri, 17 Feb 2012 14:07:47 -0600 From: Anthony Liguori MIME-Version: 1.0 References: <1328733040-16697-1-git-send-email-lcapitulino@redhat.com> <1328733040-16697-7-git-send-email-lcapitulino@redhat.com> <4F3E868D.8020107@us.ibm.com> <20120217170910.GC20920@illuin> In-Reply-To: <20120217170910.GC20920@illuin> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 6/6] qmp: add balloon-get-memory-stats & event List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Roth Cc: qemu-devel@nongnu.org, Luiz Capitulino , eblake@redhat.com, armbru@redhat.com, agl@us.ibm.com On 02/17/2012 11:09 AM, Michael Roth wrote: > On Fri, Feb 17, 2012 at 10:55:41AM -0600, Anthony Liguori wrote: >> On 02/08/2012 02:30 PM, Luiz Capitulino wrote: >>> This commit adds a QMP API for the guest provided memory statistics >>> (long disabled by commit 07b0403dfc2b2ac179ae5b48105096cc2d03375a). >>> >>> The approach taken by the original commit >>> (625a5befc2e3200b396594f002218d235e375da5) was to extend the >>> query-balloon command. It introduced a severe bug though: query-balloon >>> would hang if the guest didn't respond. >>> >>> The approach taken by this commit is asynchronous and thus avoids >>> any QMP hangs. >>> >>> First, a client has to issue the balloon-get-memory-stats command. >>> That command gets the process started by only sending a request to >>> the guest, it doesn't block. When the memory stats are made available >>> by the guest, they are returned to the client as an QMP event. >>> >>> Signed-off-by: Luiz Capitulino >> >> Do we need this to be stable in 1.1? >> >> We can do this pretty nicely through QOM. We can have a polling >> property in the virtio-balloon driver, that when set, will enable >> the virtio-balloon device to poll the guest for statistics. >> >> We can also have properties for each of the memory statistics and a >> timestamp for when the last update was. >> >> I think this is a friendlier approach for clients, and a cleaner >> approach from a QEMU perspective. >> >> There's nothing generic about this functionality. It's extremely >> specific to virtio-balloon. We just lacked ways to expose device >> specific function pre-QOM. > > I'm not so sure, I think proxying guest agent commands through QMP > would hit very similar snags, for instance. We would proxy guest agent commands as asynchronous QMP commands, no? Regards, Anthony Liguori > >> >> Regards, >> >> Anthony Liguori >> >> > >