From: "Daniel P. Berrange" <berrange@redhat.com>
To: Anthony Liguori <anthony@codemonkey.ws>
Cc: Amit Shah <amit.shah@redhat.com>,
Paolo Bonzini <pbonzini@redhat.com>,
Juan Quintela <quintela@redhat.com>,
qemu list <qemu-devel@nongnu.org>,
agl@us.ibm.com
Subject: Re: [Qemu-devel] [PATCH V2] balloon: Don't try fetching info if machine is stopped
Date: Mon, 23 Aug 2010 10:24:01 +0100 [thread overview]
Message-ID: <20100823092401.GB28382@redhat.com> (raw)
In-Reply-To: <4C719C7E.6030606@codemonkey.ws>
On Sun, Aug 22, 2010 at 04:54:06PM -0500, Anthony Liguori wrote:
> On 08/19/2010 07:48 PM, Amit Shah wrote:
> >If the machine is stopped and 'info balloon' is invoked, the monitor
> >process just hangs waiting for info from the guest. Return the most
> >recent balloon data in that case.
> >
> >See https://bugzilla.redhat.com/show_bug.cgi?id=623903
> >
> >Reported-by:<lihuang@redhat.com>
> >Signed-off-by: Amit Shah<amit.shah@redhat.com>
> >
>
> !vm_running is just a special case of an unresponsive guest. Even if
> the guest was running, if it was oops'd and the administrator didn't
> know, you would have the same issue.
>
> I'd suggest using a timeout based on rt_clock. If the stats request
> times out, print an appropriate message to the user.
By all means add a timeout to cope with a unresponsive guest,
but in this case where we can be sure the guest can't respond
there's no point waiting on a timeout.
On a tangent, a future todo item I mentioned to some people at
the summit, is that I'd like to see the interaction with the
balloon driver change/enhanced. It is currently hard/impossible
to use this in an efficient manner. We should never have overloaded
the existing balloon command with guest memstats refresh + data,
because it has made 'query balloon' a significantly slower command
than it was, in particular you can no longer rely on it being a
'fast' response, or even responding at all. This is bad when all
you care about is the balloon actual level, and not the guest
memstats. I'd like to see something along the lines of:
- 'query balloon' to return the balloon + memstats values that
are *currently* known to QEMU. Probably need a new name
to avoid changing semantics of the existing command
- 'balloon changed' event to indicate when the balloon actual
level has changed (so we never need to poll on 'query balloon')
- 'update memstats' to request an guest kernel mem stats update
- 'memstats updated' event (or update memstats async reply) to
indicate when the guest kernel has refreshed the mem stats.
Primarily I'd like to avoid having to invoke anything at all
to get the main balloon driver actual memory level. Being able
to fetch the memstats without also triggering an update is
fairly useful too though.
Daniel
--
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://deltacloud.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
next prev parent reply other threads:[~2010-08-23 9:24 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-20 0:48 [Qemu-devel] [PATCH V2] balloon: Don't try fetching info if machine is stopped Amit Shah
2010-08-20 10:13 ` [Qemu-devel] " Paolo Bonzini
2010-08-20 12:01 ` [Qemu-devel] " Amit Shah
2010-08-22 21:54 ` Anthony Liguori
2010-08-23 9:24 ` Daniel P. Berrange [this message]
2010-08-26 5:25 ` Amit Shah
2010-08-26 6:05 ` Amit Shah
2010-08-26 8:05 ` Paolo Bonzini
2010-08-26 8:14 ` Daniel P. Berrange
2010-08-26 13:22 ` Anthony Liguori
2010-08-26 8:17 ` Amit Shah
2010-08-26 8:19 ` Paolo Bonzini
2010-08-26 8:28 ` Daniel P. Berrange
2010-08-26 12:57 ` Luiz Capitulino
2010-08-26 13:30 ` Paolo Bonzini
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=20100823092401.GB28382@redhat.com \
--to=berrange@redhat.com \
--cc=agl@us.ibm.com \
--cc=amit.shah@redhat.com \
--cc=anthony@codemonkey.ws \
--cc=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.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;
as well as URLs for NNTP newsgroup(s).