From: "Daniel P. Berrangé" <berrange@redhat.com>
To: John Snow <jsnow@redhat.com>,
Maksim Davydov <davydov-max@yandex-team.ru>,
qemu-devel@nongnu.org, vsementsov@yandex-team.ru,
eduardo@habkost.net, marcel.apfelbaum@gmail.com,
philmd@linaro.org, wangyanan55@huawei.com, crosa@redhat.com,
bleal@redhat.com, eblake@redhat.com, armbru@redhat.com,
pbonzini@redhat.com, alxndr@bu.edu, bsd@redhat.com,
stefanha@redhat.com, thuth@redhat.com, darren.kenny@oracle.com,
Qiuhao.Li@outlook.com, lvivier@redhat.com
Subject: Re: [PATCH v3 2/4] python/qmp: increase read buffer size
Date: Wed, 9 Nov 2022 10:59:59 +0000 [thread overview]
Message-ID: <Y2uIL3XkmuiXXSGT@redhat.com> (raw)
In-Reply-To: <Y2t1QlBAhqhG9Oaq@redhat.com>
On Wed, Nov 09, 2022 at 09:39:14AM +0000, Daniel P. Berrangé wrote:
> On Tue, Nov 08, 2022 at 03:38:21PM -0500, John Snow wrote:
> > On Thu, Nov 3, 2022 at 6:29 AM Maksim Davydov
> > <davydov-max@yandex-team.ru> wrote:
> > >
> > > After modification of "query-machines" command the buffer size should be
> > > more than 452kB to contain output with compat-props.
> > >
> > > Signed-off-by: Maksim Davydov <davydov-max@yandex-team.ru>
> > > Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
> > > ---
> > > python/qemu/qmp/qmp_client.py | 4 ++--
> > > 1 file changed, 2 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/python/qemu/qmp/qmp_client.py b/python/qemu/qmp/qmp_client.py
> > > index 5dcda04a75..659fe4d98c 100644
> > > --- a/python/qemu/qmp/qmp_client.py
> > > +++ b/python/qemu/qmp/qmp_client.py
> > > @@ -197,8 +197,8 @@ async def run(self, address='/tmp/qemu.socket'):
> > > #: Logger object used for debugging messages.
> > > logger = logging.getLogger(__name__)
> > >
> > > - # Read buffer limit; large enough to accept query-qmp-schema
> > > - _limit = (256 * 1024)
> > > + # Read buffer limit; large enough to accept query-machines
> > > + _limit = (512 * 1024)
> >
> > wow :)
>
> Meanwhile over in python/qemu/qmp/protocol.py the read buffer limit is
> set to just 64 kb.
>
> If the current output of a particular command is known to 450 kb, then
> setting this limit to 512 kb is waaaaaaay to conservative, and we'll
> inevitably have to change it again when someone finds the next command
> that overflows.
>
> Recall this thread
>
> https://lists.gnu.org/archive/html/qemu-devel/2022-09/msg01060.html
>
> In fact, let me be the someone who demonstrates a real case where 512kb
> is not enough....
Another example...
Create a guest with 255 vCPUs (current RHEL downstream vCPU limit),
and run
{"execute":"query-stats","arguments":{"target": "vcpu"}}
it'll get back a 0.38 MB QMP reply. RHEL raised the limit to 710
vCPUs, giving a little over 1 MB QMP reply. There is a strong desire
to go even higher. With 4096 vCPUs it'd get an ~6 MB QMP reply.
With regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
next prev parent reply other threads:[~2022-11-09 11:00 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-03 10:27 [PATCH v3 0/4] compare machine type compat_props Maksim Davydov
2022-11-03 10:27 ` [PATCH v3 1/4] qom: add default value Maksim Davydov
2022-11-03 10:27 ` [PATCH v3 2/4] python/qmp: increase read buffer size Maksim Davydov
2022-11-08 20:38 ` John Snow
2022-11-09 9:39 ` Daniel P. Berrangé
2022-11-09 10:59 ` Daniel P. Berrangé [this message]
2022-11-09 17:53 ` John Snow
2022-11-03 10:27 ` [PATCH v3 3/4] qmp: add dump machine type compatible properties Maksim Davydov
2022-11-03 10:27 ` [PATCH v3 4/4] scripts: add script to compare " Maksim Davydov
2022-11-08 15:37 ` Vladimir Sementsov-Ogievskiy
2022-11-08 17:48 ` Maksim Davydov
2022-11-08 21:16 ` John Snow
2022-11-17 20:34 ` Maksim Davydov
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=Y2uIL3XkmuiXXSGT@redhat.com \
--to=berrange@redhat.com \
--cc=Qiuhao.Li@outlook.com \
--cc=alxndr@bu.edu \
--cc=armbru@redhat.com \
--cc=bleal@redhat.com \
--cc=bsd@redhat.com \
--cc=crosa@redhat.com \
--cc=darren.kenny@oracle.com \
--cc=davydov-max@yandex-team.ru \
--cc=eblake@redhat.com \
--cc=eduardo@habkost.net \
--cc=jsnow@redhat.com \
--cc=lvivier@redhat.com \
--cc=marcel.apfelbaum@gmail.com \
--cc=pbonzini@redhat.com \
--cc=philmd@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=stefanha@redhat.com \
--cc=thuth@redhat.com \
--cc=vsementsov@yandex-team.ru \
--cc=wangyanan55@huawei.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 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.