mirror of https://github.com/xemu-project/xemu.git
qmp-commands: move 'drive-mirror' doc to schema
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
This commit is contained in:
parent
e1f34cb209
commit
12a21b73cb
|
@ -315,60 +315,6 @@ Example:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
drive-mirror
|
|
||||||
------------
|
|
||||||
|
|
||||||
Start mirroring a block device's writes to a new destination. target
|
|
||||||
specifies the target of the new image. If the file exists, or if it is
|
|
||||||
a device, it will be used as the new destination for writes. If it does not
|
|
||||||
exist, a new file will be created. format specifies the format of the
|
|
||||||
mirror image, default is to probe if mode='existing', else the format
|
|
||||||
of the source.
|
|
||||||
|
|
||||||
Arguments:
|
|
||||||
|
|
||||||
- "job-id": Identifier for the newly-created block job. If omitted,
|
|
||||||
the device name will be used. (json-string, optional)
|
|
||||||
- "device": the device name or node-name of a root node whose writes should be
|
|
||||||
mirrored. (json-string)
|
|
||||||
- "target": name of new image file (json-string)
|
|
||||||
- "format": format of new image (json-string, optional)
|
|
||||||
- "node-name": the name of the new block driver state in the node graph
|
|
||||||
(json-string, optional)
|
|
||||||
- "replaces": the block driver node name to replace when finished
|
|
||||||
(json-string, optional)
|
|
||||||
- "mode": how an image file should be created into the target
|
|
||||||
file/device (NewImageMode, optional, default 'absolute-paths')
|
|
||||||
- "speed": maximum speed of the streaming job, in bytes per second
|
|
||||||
(json-int)
|
|
||||||
- "granularity": granularity of the dirty bitmap, in bytes (json-int, optional)
|
|
||||||
- "buf-size": maximum amount of data in flight from source to target, in bytes
|
|
||||||
(json-int, default 10M)
|
|
||||||
- "sync": what parts of the disk image should be copied to the destination;
|
|
||||||
possibilities include "full" for all the disk, "top" for only the sectors
|
|
||||||
allocated in the topmost image, or "none" to only replicate new I/O
|
|
||||||
(MirrorSyncMode).
|
|
||||||
- "on-source-error": the action to take on an error on the source
|
|
||||||
(BlockdevOnError, default 'report')
|
|
||||||
- "on-target-error": the action to take on an error on the target
|
|
||||||
(BlockdevOnError, default 'report')
|
|
||||||
- "unmap": whether the target sectors should be discarded where source has only
|
|
||||||
zeroes. (json-bool, optional, default true)
|
|
||||||
|
|
||||||
The default value of the granularity is the image cluster size clamped
|
|
||||||
between 4096 and 65536, if the image format defines one. If the format
|
|
||||||
does not define a cluster size, the default value of the granularity
|
|
||||||
is 65536.
|
|
||||||
|
|
||||||
|
|
||||||
Example:
|
|
||||||
|
|
||||||
-> { "execute": "drive-mirror", "arguments": { "device": "ide-hd0",
|
|
||||||
"target": "/some/place/my-image",
|
|
||||||
"sync": "full",
|
|
||||||
"format": "qcow2" } }
|
|
||||||
<- { "return": {} }
|
|
||||||
|
|
||||||
blockdev-mirror
|
blockdev-mirror
|
||||||
------------
|
------------
|
||||||
|
|
||||||
|
|
|
@ -1444,7 +1444,12 @@
|
||||||
##
|
##
|
||||||
# @drive-mirror:
|
# @drive-mirror:
|
||||||
#
|
#
|
||||||
# Start mirroring a block device's writes to a new destination.
|
# Start mirroring a block device's writes to a new destination. target
|
||||||
|
# specifies the target of the new image. If the file exists, or if it
|
||||||
|
# is a device, it will be used as the new destination for writes. If
|
||||||
|
# it does not exist, a new file will be created. format specifies the
|
||||||
|
# format of the mirror image, default is to probe if mode='existing',
|
||||||
|
# else the format of the source.
|
||||||
#
|
#
|
||||||
# See DriveMirror for parameter descriptions
|
# See DriveMirror for parameter descriptions
|
||||||
#
|
#
|
||||||
|
@ -1452,6 +1457,16 @@
|
||||||
# If @device is not a valid block device, GenericError
|
# If @device is not a valid block device, GenericError
|
||||||
#
|
#
|
||||||
# Since: 1.3
|
# Since: 1.3
|
||||||
|
#
|
||||||
|
# Example:
|
||||||
|
#
|
||||||
|
# -> { "execute": "drive-mirror",
|
||||||
|
# "arguments": { "device": "ide-hd0",
|
||||||
|
# "target": "/some/place/my-image",
|
||||||
|
# "sync": "full",
|
||||||
|
# "format": "qcow2" } }
|
||||||
|
# <- { "return": {} }
|
||||||
|
#
|
||||||
##
|
##
|
||||||
{ 'command': 'drive-mirror', 'boxed': true,
|
{ 'command': 'drive-mirror', 'boxed': true,
|
||||||
'data': 'DriveMirror' }
|
'data': 'DriveMirror' }
|
||||||
|
|
Loading…
Reference in New Issue