qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 0/8] block: generic image streaming


From: Luiz Capitulino
Subject: Re: [Qemu-devel] [PATCH 0/8] block: generic image streaming
Date: Thu, 27 Oct 2011 16:58:07 -0200

On Thu, 27 Oct 2011 16:22:47 +0100
Stefan Hajnoczi <address@hidden> wrote:

> This series adds the 'block_stream' command which copies the contents of a
> backing file into the image file while the VM is running.  The series builds 
> on
> copy-on-read and zero detection features which I sent out recently and I
> suggest grabbing my git tree to try it out without merging these dependencies
> yourself:
> 
> http://repo.or.cz/w/qemu/stefanha.git/shortlog/refs/heads/image-streaming-api
> 
> The image streaming HMP/QMP commands are documented in the patch and also
> described here:
> 
> http://wiki.qemu.org/Features/LiveBlockMigration/ImageStreamingAPI

I haven't reviewed the series yet, but new QMP commands should be using
the QAPI now that the basic infrastructure is in place.

I'll write some documentation on how to do it shortly, but you already can
find examples in the tree (eg. qmp_stop()/hmp_stop() and
qmp_query_chardev()/hmp_info_chardev()).

> The basic idea is to execute 'block_stream virtio0' while the guest is 
> running.
> Progress can be monitored using 'info block-jobs'.  When the streaming
> operation completes it raises a QMP event.
> 
> This series includes a Python test script called test-stream.py.  When run in 
> a
> QEMU source tree it performs basic image streaming QMP tests.
> 
> TODO:
>  * support 'base' argument for stream partial backing file chains
>  * rate-limiting support, currently a NotSupported error is raised
> 
> My plan is to add rate-limiting shortly but the 'base' argument will require
> more work later.  I'm sending these patches out to share the general direction
> and let folks know what to expect as I continue to test this code.
> 
> Stefan Hajnoczi (8):
>   coroutine: add co_sleep_ns() coroutine sleep function
>   block: add BlockJob interface for long-running operations
>   block: add image streaming block job
>   qmp: add block_stream command
>   qmp: add block_job_set_speed command
>   qmp: add block_job_cancel command
>   qmp: add query-block-jobs
>   test: add image streaming test cases
> 
>  Makefile.objs          |    3 +-
>  block/stream.c         |  135 ++++++++++++++++++++++++++++++++
>  block_int.h            |   98 +++++++++++++++++++++++
>  blockdev.c             |  183 +++++++++++++++++++++++++++++++++++++++++++
>  blockdev.h             |    8 ++
>  hmp-commands.hx        |   45 +++++++++++
>  monitor.c              |   19 +++++
>  monitor.h              |    1 +
>  qemu-coroutine-sleep.c |   38 +++++++++
>  qemu-coroutine.h       |    6 ++
>  qerror.c               |    4 +
>  qerror.h               |    3 +
>  qmp-commands.hx        |  173 +++++++++++++++++++++++++++++++++++++++++
>  test-stream.py         |  200 
> ++++++++++++++++++++++++++++++++++++++++++++++++
>  trace-events           |   10 +++
>  15 files changed, 925 insertions(+), 1 deletions(-)
>  create mode 100644 block/stream.c
>  create mode 100644 qemu-coroutine-sleep.c
>  create mode 100644 test-stream.py
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]