qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 0/8] block: generic image streaming
@ 2011-10-27 15:22 Stefan Hajnoczi
  2011-10-27 15:22 ` [Qemu-devel] [PATCH 1/8] coroutine: add co_sleep_ns() coroutine sleep function Stefan Hajnoczi
                   ` (9 more replies)
  0 siblings, 10 replies; 17+ messages in thread
From: Stefan Hajnoczi @ 2011-10-27 15:22 UTC (permalink / raw)
  To: qemu-devel; +Cc: Kevin Wolf, Anthony Liguori, Marcelo Tosatti, Stefan Hajnoczi

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

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

-- 
1.7.7

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2011-11-04  9:16 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-27 15:22 [Qemu-devel] [PATCH 0/8] block: generic image streaming Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 1/8] coroutine: add co_sleep_ns() coroutine sleep function Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 2/8] block: add BlockJob interface for long-running operations Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 3/8] block: add image streaming block job Stefan Hajnoczi
2011-11-01 18:06   ` Marcelo Tosatti
2011-11-02 15:43     ` Stefan Hajnoczi
2011-11-02 16:43       ` Kevin Wolf
2011-11-03 16:34       ` Marcelo Tosatti
2011-11-04  8:03         ` Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 4/8] qmp: add block_stream command Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 5/8] qmp: add block_job_set_speed command Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 6/8] qmp: add block_job_cancel command Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 7/8] qmp: add query-block-jobs Stefan Hajnoczi
2011-10-27 15:22 ` [Qemu-devel] [PATCH 8/8] test: add image streaming test cases Stefan Hajnoczi
2011-10-27 18:58 ` [Qemu-devel] [PATCH 0/8] block: generic image streaming Luiz Capitulino
2011-11-01 16:46 ` Marcelo Tosatti
2011-11-02 11:06   ` Stefan Hajnoczi

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).