Skip to content

buffer and delay backup COW write operation

Liang Li qemu-devel 1 version In review

Get series with b4
b4 am 20190428100052.GA63525@localhost

Versions newest first

  1. v1 Latest2 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2backup: buffer COW request and delay the write operationblock/backup.c+104 -130 replies
2/2qapi: add interface for setting backup cow buffer sizeblock/backup.c block/replication.c blockdev.c +2 more+15 -20 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [Qemu-devel] [PATCH 0/2] buffer and delay backup COW write operation

If the backup target is a slow device like ceph rbd, the backup process will affect guest BLK write IO performance seriously, it's cause by the drawback of COW mechanism, if guest overwrite the backup BLK area, the IO can only be processed after the data has been written to backup target.
The impact can be relieved by buffering data read from backup source and writing to backup target later, so the guest BLK write IO can be processed in time.
Data area with no overwrite will be process like before without buffering, in most case, we don't need a very large buffer.

An fio test was done when the backup was going on, the test resut show a obvious performance improvement by buffering.

Test result(1GB buffer):
========================
fio setting:
[random-writers]
ioengine=libaio
iodepth=8
rw=randwrite
bs=32k
direct=1
size=1G
numjobs=1

result:

                      IOPS        AVG latency
       no backup:     19389         410 us
          backup:      1402        5702 us

backup w/ buffer: 8684 918 us
==============================================

Cc John Snow <[email protected]>
Cc Kevin Wolf <[email protected]>
Cc Max Reitz <[email protected]>
Cc Wen Congyang <[email protected]>
Cc Xie Changlong <[email protected]>
Cc Markus Armbruster <[email protected]>
Cc Eric Blake <[email protected]>
Cc Fam Zheng <[email protected]>

Liang Li (2):
backup: buffer COW request and delay the write operation
qapi: add interface for setting backup cow buffer size

 block/backup.c            | 118 +++++++++++++++++++++++++++++++++++++++++-----
 block/replication.c       |   2 +-
 blockdev.c                |   5 ++
 include/block/block_int.h |   2 +
 qapi/block-core.json      |   5 ++
 5 files changed, 118 insertions(+), 14 deletions(-)
Signature · 1 line
2.14.1