]> git.proxmox.com Git - mirror_qemu.git/blob - qapi/migration.json
migration: Add postcopy-preempt capability
[mirror_qemu.git] / qapi / migration.json
1 # -*- Mode: Python -*-
2 # vim: filetype=python
3 #
4
5 ##
6 # = Migration
7 ##
8
9 { 'include': 'common.json' }
10 { 'include': 'sockets.json' }
11
12 ##
13 # @MigrationStats:
14 #
15 # Detailed migration status.
16 #
17 # @transferred: amount of bytes already transferred to the target VM
18 #
19 # @remaining: amount of bytes remaining to be transferred to the target VM
20 #
21 # @total: total amount of bytes involved in the migration process
22 #
23 # @duplicate: number of duplicate (zero) pages (since 1.2)
24 #
25 # @skipped: number of skipped zero pages (since 1.5)
26 #
27 # @normal: number of normal pages (since 1.2)
28 #
29 # @normal-bytes: number of normal bytes sent (since 1.2)
30 #
31 # @dirty-pages-rate: number of pages dirtied by second by the
32 # guest (since 1.3)
33 #
34 # @mbps: throughput in megabits/sec. (since 1.6)
35 #
36 # @dirty-sync-count: number of times that dirty ram was synchronized (since 2.1)
37 #
38 # @postcopy-requests: The number of page requests received from the destination
39 # (since 2.7)
40 #
41 # @page-size: The number of bytes per page for the various page-based
42 # statistics (since 2.10)
43 #
44 # @multifd-bytes: The number of bytes sent through multifd (since 3.0)
45 #
46 # @pages-per-second: the number of memory pages transferred per second
47 # (Since 4.0)
48 #
49 # @precopy-bytes: The number of bytes sent in the pre-copy phase
50 # (since 7.0).
51 #
52 # @downtime-bytes: The number of bytes sent while the guest is paused
53 # (since 7.0).
54 #
55 # @postcopy-bytes: The number of bytes sent during the post-copy phase
56 # (since 7.0).
57 #
58 # Since: 0.14
59 ##
60 { 'struct': 'MigrationStats',
61 'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' ,
62 'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
63 'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
64 'mbps' : 'number', 'dirty-sync-count' : 'int',
65 'postcopy-requests' : 'int', 'page-size' : 'int',
66 'multifd-bytes' : 'uint64', 'pages-per-second' : 'uint64',
67 'precopy-bytes' : 'uint64', 'downtime-bytes' : 'uint64',
68 'postcopy-bytes' : 'uint64' } }
69
70 ##
71 # @XBZRLECacheStats:
72 #
73 # Detailed XBZRLE migration cache statistics
74 #
75 # @cache-size: XBZRLE cache size
76 #
77 # @bytes: amount of bytes already transferred to the target VM
78 #
79 # @pages: amount of pages transferred to the target VM
80 #
81 # @cache-miss: number of cache miss
82 #
83 # @cache-miss-rate: rate of cache miss (since 2.1)
84 #
85 # @encoding-rate: rate of encoded bytes (since 5.1)
86 #
87 # @overflow: number of overflows
88 #
89 # Since: 1.2
90 ##
91 { 'struct': 'XBZRLECacheStats',
92 'data': {'cache-size': 'size', 'bytes': 'int', 'pages': 'int',
93 'cache-miss': 'int', 'cache-miss-rate': 'number',
94 'encoding-rate': 'number', 'overflow': 'int' } }
95
96 ##
97 # @CompressionStats:
98 #
99 # Detailed migration compression statistics
100 #
101 # @pages: amount of pages compressed and transferred to the target VM
102 #
103 # @busy: count of times that no free thread was available to compress data
104 #
105 # @busy-rate: rate of thread busy
106 #
107 # @compressed-size: amount of bytes after compression
108 #
109 # @compression-rate: rate of compressed size
110 #
111 # Since: 3.1
112 ##
113 { 'struct': 'CompressionStats',
114 'data': {'pages': 'int', 'busy': 'int', 'busy-rate': 'number',
115 'compressed-size': 'int', 'compression-rate': 'number' } }
116
117 ##
118 # @MigrationStatus:
119 #
120 # An enumeration of migration status.
121 #
122 # @none: no migration has ever happened.
123 #
124 # @setup: migration process has been initiated.
125 #
126 # @cancelling: in the process of cancelling migration.
127 #
128 # @cancelled: cancelling migration is finished.
129 #
130 # @active: in the process of doing migration.
131 #
132 # @postcopy-active: like active, but now in postcopy mode. (since 2.5)
133 #
134 # @postcopy-paused: during postcopy but paused. (since 3.0)
135 #
136 # @postcopy-recover: trying to recover from a paused postcopy. (since 3.0)
137 #
138 # @completed: migration is finished.
139 #
140 # @failed: some error occurred during migration process.
141 #
142 # @colo: VM is in the process of fault tolerance, VM can not get into this
143 # state unless colo capability is enabled for migration. (since 2.8)
144 #
145 # @pre-switchover: Paused before device serialisation. (since 2.11)
146 #
147 # @device: During device serialisation when pause-before-switchover is enabled
148 # (since 2.11)
149 #
150 # @wait-unplug: wait for device unplug request by guest OS to be completed.
151 # (since 4.2)
152 #
153 # Since: 2.3
154 ##
155 { 'enum': 'MigrationStatus',
156 'data': [ 'none', 'setup', 'cancelling', 'cancelled',
157 'active', 'postcopy-active', 'postcopy-paused',
158 'postcopy-recover', 'completed', 'failed', 'colo',
159 'pre-switchover', 'device', 'wait-unplug' ] }
160 ##
161 # @VfioStats:
162 #
163 # Detailed VFIO devices migration statistics
164 #
165 # @transferred: amount of bytes transferred to the target VM by VFIO devices
166 #
167 # Since: 5.2
168 ##
169 { 'struct': 'VfioStats',
170 'data': {'transferred': 'int' } }
171
172 ##
173 # @MigrationInfo:
174 #
175 # Information about current migration process.
176 #
177 # @status: @MigrationStatus describing the current migration status.
178 # If this field is not returned, no migration process
179 # has been initiated
180 #
181 # @ram: @MigrationStats containing detailed migration
182 # status, only returned if status is 'active' or
183 # 'completed'(since 1.2)
184 #
185 # @disk: @MigrationStats containing detailed disk migration
186 # status, only returned if status is 'active' and it is a block
187 # migration
188 #
189 # @xbzrle-cache: @XBZRLECacheStats containing detailed XBZRLE
190 # migration statistics, only returned if XBZRLE feature is on and
191 # status is 'active' or 'completed' (since 1.2)
192 #
193 # @total-time: total amount of milliseconds since migration started.
194 # If migration has ended, it returns the total migration
195 # time. (since 1.2)
196 #
197 # @downtime: only present when migration finishes correctly
198 # total downtime in milliseconds for the guest.
199 # (since 1.3)
200 #
201 # @expected-downtime: only present while migration is active
202 # expected downtime in milliseconds for the guest in last walk
203 # of the dirty bitmap. (since 1.3)
204 #
205 # @setup-time: amount of setup time in milliseconds *before* the
206 # iterations begin but *after* the QMP command is issued. This is designed
207 # to provide an accounting of any activities (such as RDMA pinning) which
208 # may be expensive, but do not actually occur during the iterative
209 # migration rounds themselves. (since 1.6)
210 #
211 # @cpu-throttle-percentage: percentage of time guest cpus are being
212 # throttled during auto-converge. This is only present when auto-converge
213 # has started throttling guest cpus. (Since 2.7)
214 #
215 # @error-desc: the human readable error description string, when
216 # @status is 'failed'. Clients should not attempt to parse the
217 # error strings. (Since 2.7)
218 #
219 # @postcopy-blocktime: total time when all vCPU were blocked during postcopy
220 # live migration. This is only present when the postcopy-blocktime
221 # migration capability is enabled. (Since 3.0)
222 #
223 # @postcopy-vcpu-blocktime: list of the postcopy blocktime per vCPU. This is
224 # only present when the postcopy-blocktime migration capability
225 # is enabled. (Since 3.0)
226 #
227 # @compression: migration compression statistics, only returned if compression
228 # feature is on and status is 'active' or 'completed' (Since 3.1)
229 #
230 # @socket-address: Only used for tcp, to know what the real port is (Since 4.0)
231 #
232 # @vfio: @VfioStats containing detailed VFIO devices migration statistics,
233 # only returned if VFIO device is present, migration is supported by all
234 # VFIO devices and status is 'active' or 'completed' (since 5.2)
235 #
236 # @blocked-reasons: A list of reasons an outgoing migration is blocked.
237 # Present and non-empty when migration is blocked.
238 # (since 6.0)
239 #
240 # Since: 0.14
241 ##
242 { 'struct': 'MigrationInfo',
243 'data': {'*status': 'MigrationStatus', '*ram': 'MigrationStats',
244 '*disk': 'MigrationStats',
245 '*vfio': 'VfioStats',
246 '*xbzrle-cache': 'XBZRLECacheStats',
247 '*total-time': 'int',
248 '*expected-downtime': 'int',
249 '*downtime': 'int',
250 '*setup-time': 'int',
251 '*cpu-throttle-percentage': 'int',
252 '*error-desc': 'str',
253 '*blocked-reasons': ['str'],
254 '*postcopy-blocktime' : 'uint32',
255 '*postcopy-vcpu-blocktime': ['uint32'],
256 '*compression': 'CompressionStats',
257 '*socket-address': ['SocketAddress'] } }
258
259 ##
260 # @query-migrate:
261 #
262 # Returns information about current migration process. If migration
263 # is active there will be another json-object with RAM migration
264 # status and if block migration is active another one with block
265 # migration status.
266 #
267 # Returns: @MigrationInfo
268 #
269 # Since: 0.14
270 #
271 # Example:
272 #
273 # 1. Before the first migration
274 #
275 # -> { "execute": "query-migrate" }
276 # <- { "return": {} }
277 #
278 # 2. Migration is done and has succeeded
279 #
280 # -> { "execute": "query-migrate" }
281 # <- { "return": {
282 # "status": "completed",
283 # "total-time":12345,
284 # "setup-time":12345,
285 # "downtime":12345,
286 # "ram":{
287 # "transferred":123,
288 # "remaining":123,
289 # "total":246,
290 # "duplicate":123,
291 # "normal":123,
292 # "normal-bytes":123456,
293 # "dirty-sync-count":15
294 # }
295 # }
296 # }
297 #
298 # 3. Migration is done and has failed
299 #
300 # -> { "execute": "query-migrate" }
301 # <- { "return": { "status": "failed" } }
302 #
303 # 4. Migration is being performed and is not a block migration:
304 #
305 # -> { "execute": "query-migrate" }
306 # <- {
307 # "return":{
308 # "status":"active",
309 # "total-time":12345,
310 # "setup-time":12345,
311 # "expected-downtime":12345,
312 # "ram":{
313 # "transferred":123,
314 # "remaining":123,
315 # "total":246,
316 # "duplicate":123,
317 # "normal":123,
318 # "normal-bytes":123456,
319 # "dirty-sync-count":15
320 # }
321 # }
322 # }
323 #
324 # 5. Migration is being performed and is a block migration:
325 #
326 # -> { "execute": "query-migrate" }
327 # <- {
328 # "return":{
329 # "status":"active",
330 # "total-time":12345,
331 # "setup-time":12345,
332 # "expected-downtime":12345,
333 # "ram":{
334 # "total":1057024,
335 # "remaining":1053304,
336 # "transferred":3720,
337 # "duplicate":123,
338 # "normal":123,
339 # "normal-bytes":123456,
340 # "dirty-sync-count":15
341 # },
342 # "disk":{
343 # "total":20971520,
344 # "remaining":20880384,
345 # "transferred":91136
346 # }
347 # }
348 # }
349 #
350 # 6. Migration is being performed and XBZRLE is active:
351 #
352 # -> { "execute": "query-migrate" }
353 # <- {
354 # "return":{
355 # "status":"active",
356 # "total-time":12345,
357 # "setup-time":12345,
358 # "expected-downtime":12345,
359 # "ram":{
360 # "total":1057024,
361 # "remaining":1053304,
362 # "transferred":3720,
363 # "duplicate":10,
364 # "normal":3333,
365 # "normal-bytes":3412992,
366 # "dirty-sync-count":15
367 # },
368 # "xbzrle-cache":{
369 # "cache-size":67108864,
370 # "bytes":20971520,
371 # "pages":2444343,
372 # "cache-miss":2244,
373 # "cache-miss-rate":0.123,
374 # "encoding-rate":80.1,
375 # "overflow":34434
376 # }
377 # }
378 # }
379 #
380 ##
381 { 'command': 'query-migrate', 'returns': 'MigrationInfo' }
382
383 ##
384 # @MigrationCapability:
385 #
386 # Migration capabilities enumeration
387 #
388 # @xbzrle: Migration supports xbzrle (Xor Based Zero Run Length Encoding).
389 # This feature allows us to minimize migration traffic for certain work
390 # loads, by sending compressed difference of the pages
391 #
392 # @rdma-pin-all: Controls whether or not the entire VM memory footprint is
393 # mlock()'d on demand or all at once. Refer to docs/rdma.txt for usage.
394 # Disabled by default. (since 2.0)
395 #
396 # @zero-blocks: During storage migration encode blocks of zeroes efficiently. This
397 # essentially saves 1MB of zeroes per block on the wire. Enabling requires
398 # source and target VM to support this feature. To enable it is sufficient
399 # to enable the capability on the source VM. The feature is disabled by
400 # default. (since 1.6)
401 #
402 # @compress: Use multiple compression threads to accelerate live migration.
403 # This feature can help to reduce the migration traffic, by sending
404 # compressed pages. Please note that if compress and xbzrle are both
405 # on, compress only takes effect in the ram bulk stage, after that,
406 # it will be disabled and only xbzrle takes effect, this can help to
407 # minimize migration traffic. The feature is disabled by default.
408 # (since 2.4 )
409 #
410 # @events: generate events for each migration state change
411 # (since 2.4 )
412 #
413 # @auto-converge: If enabled, QEMU will automatically throttle down the guest
414 # to speed up convergence of RAM migration. (since 1.6)
415 #
416 # @postcopy-ram: Start executing on the migration target before all of RAM has
417 # been migrated, pulling the remaining pages along as needed. The
418 # capacity must have the same setting on both source and target
419 # or migration will not even start. NOTE: If the migration fails during
420 # postcopy the VM will fail. (since 2.6)
421 #
422 # @x-colo: If enabled, migration will never end, and the state of the VM on the
423 # primary side will be migrated continuously to the VM on secondary
424 # side, this process is called COarse-Grain LOck Stepping (COLO) for
425 # Non-stop Service. (since 2.8)
426 #
427 # @release-ram: if enabled, qemu will free the migrated ram pages on the source
428 # during postcopy-ram migration. (since 2.9)
429 #
430 # @block: If enabled, QEMU will also migrate the contents of all block
431 # devices. Default is disabled. A possible alternative uses
432 # mirror jobs to a builtin NBD server on the destination, which
433 # offers more flexibility.
434 # (Since 2.10)
435 #
436 # @return-path: If enabled, migration will use the return path even
437 # for precopy. (since 2.10)
438 #
439 # @pause-before-switchover: Pause outgoing migration before serialising device
440 # state and before disabling block IO (since 2.11)
441 #
442 # @multifd: Use more than one fd for migration (since 4.0)
443 #
444 # @dirty-bitmaps: If enabled, QEMU will migrate named dirty bitmaps.
445 # (since 2.12)
446 #
447 # @postcopy-blocktime: Calculate downtime for postcopy live migration
448 # (since 3.0)
449 #
450 # @late-block-activate: If enabled, the destination will not activate block
451 # devices (and thus take locks) immediately at the end of migration.
452 # (since 3.0)
453 #
454 # @x-ignore-shared: If enabled, QEMU will not migrate shared memory (since 4.0)
455 #
456 # @validate-uuid: Send the UUID of the source to allow the destination
457 # to ensure it is the same. (since 4.2)
458 #
459 # @background-snapshot: If enabled, the migration stream will be a snapshot
460 # of the VM exactly at the point when the migration
461 # procedure starts. The VM RAM is saved with running VM.
462 # (since 6.0)
463 #
464 # @zero-copy-send: Controls behavior on sending memory pages on migration.
465 # When true, enables a zero-copy mechanism for sending
466 # memory pages, if host supports it.
467 # Requires that QEMU be permitted to use locked memory
468 # for guest RAM pages.
469 # (since 7.1)
470 # @postcopy-preempt: If enabled, the migration process will allow postcopy
471 # requests to preempt precopy stream, so postcopy requests
472 # will be handled faster. This is a performance feature and
473 # should not affect the correctness of postcopy migration.
474 # (since 7.1)
475 #
476 # Features:
477 # @unstable: Members @x-colo and @x-ignore-shared are experimental.
478 #
479 # Since: 1.2
480 ##
481 { 'enum': 'MigrationCapability',
482 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks',
483 'compress', 'events', 'postcopy-ram',
484 { 'name': 'x-colo', 'features': [ 'unstable' ] },
485 'release-ram',
486 'block', 'return-path', 'pause-before-switchover', 'multifd',
487 'dirty-bitmaps', 'postcopy-blocktime', 'late-block-activate',
488 { 'name': 'x-ignore-shared', 'features': [ 'unstable' ] },
489 'validate-uuid', 'background-snapshot',
490 'zero-copy-send', 'postcopy-preempt'] }
491
492 ##
493 # @MigrationCapabilityStatus:
494 #
495 # Migration capability information
496 #
497 # @capability: capability enum
498 #
499 # @state: capability state bool
500 #
501 # Since: 1.2
502 ##
503 { 'struct': 'MigrationCapabilityStatus',
504 'data': { 'capability' : 'MigrationCapability', 'state' : 'bool' } }
505
506 ##
507 # @migrate-set-capabilities:
508 #
509 # Enable/Disable the following migration capabilities (like xbzrle)
510 #
511 # @capabilities: json array of capability modifications to make
512 #
513 # Since: 1.2
514 #
515 # Example:
516 #
517 # -> { "execute": "migrate-set-capabilities" , "arguments":
518 # { "capabilities": [ { "capability": "xbzrle", "state": true } ] } }
519 #
520 ##
521 { 'command': 'migrate-set-capabilities',
522 'data': { 'capabilities': ['MigrationCapabilityStatus'] } }
523
524 ##
525 # @query-migrate-capabilities:
526 #
527 # Returns information about the current migration capabilities status
528 #
529 # Returns: @MigrationCapabilitiesStatus
530 #
531 # Since: 1.2
532 #
533 # Example:
534 #
535 # -> { "execute": "query-migrate-capabilities" }
536 # <- { "return": [
537 # {"state": false, "capability": "xbzrle"},
538 # {"state": false, "capability": "rdma-pin-all"},
539 # {"state": false, "capability": "auto-converge"},
540 # {"state": false, "capability": "zero-blocks"},
541 # {"state": false, "capability": "compress"},
542 # {"state": true, "capability": "events"},
543 # {"state": false, "capability": "postcopy-ram"},
544 # {"state": false, "capability": "x-colo"}
545 # ]}
546 #
547 ##
548 { 'command': 'query-migrate-capabilities', 'returns': ['MigrationCapabilityStatus']}
549
550 ##
551 # @MultiFDCompression:
552 #
553 # An enumeration of multifd compression methods.
554 #
555 # @none: no compression.
556 # @zlib: use zlib compression method.
557 # @zstd: use zstd compression method.
558 #
559 # Since: 5.0
560 ##
561 { 'enum': 'MultiFDCompression',
562 'data': [ 'none', 'zlib',
563 { 'name': 'zstd', 'if': 'CONFIG_ZSTD' } ] }
564
565 ##
566 # @BitmapMigrationBitmapAliasTransform:
567 #
568 # @persistent: If present, the bitmap will be made persistent
569 # or transient depending on this parameter.
570 #
571 # Since: 6.0
572 ##
573 { 'struct': 'BitmapMigrationBitmapAliasTransform',
574 'data': {
575 '*persistent': 'bool'
576 } }
577
578 ##
579 # @BitmapMigrationBitmapAlias:
580 #
581 # @name: The name of the bitmap.
582 #
583 # @alias: An alias name for migration (for example the bitmap name on
584 # the opposite site).
585 #
586 # @transform: Allows the modification of the migrated bitmap.
587 # (since 6.0)
588 #
589 # Since: 5.2
590 ##
591 { 'struct': 'BitmapMigrationBitmapAlias',
592 'data': {
593 'name': 'str',
594 'alias': 'str',
595 '*transform': 'BitmapMigrationBitmapAliasTransform'
596 } }
597
598 ##
599 # @BitmapMigrationNodeAlias:
600 #
601 # Maps a block node name and the bitmaps it has to aliases for dirty
602 # bitmap migration.
603 #
604 # @node-name: A block node name.
605 #
606 # @alias: An alias block node name for migration (for example the
607 # node name on the opposite site).
608 #
609 # @bitmaps: Mappings for the bitmaps on this node.
610 #
611 # Since: 5.2
612 ##
613 { 'struct': 'BitmapMigrationNodeAlias',
614 'data': {
615 'node-name': 'str',
616 'alias': 'str',
617 'bitmaps': [ 'BitmapMigrationBitmapAlias' ]
618 } }
619
620 ##
621 # @MigrationParameter:
622 #
623 # Migration parameters enumeration
624 #
625 # @announce-initial: Initial delay (in milliseconds) before sending the first
626 # announce (Since 4.0)
627 #
628 # @announce-max: Maximum delay (in milliseconds) between packets in the
629 # announcement (Since 4.0)
630 #
631 # @announce-rounds: Number of self-announce packets sent after migration
632 # (Since 4.0)
633 #
634 # @announce-step: Increase in delay (in milliseconds) between subsequent
635 # packets in the announcement (Since 4.0)
636 #
637 # @compress-level: Set the compression level to be used in live migration,
638 # the compression level is an integer between 0 and 9, where 0 means
639 # no compression, 1 means the best compression speed, and 9 means best
640 # compression ratio which will consume more CPU.
641 #
642 # @compress-threads: Set compression thread count to be used in live migration,
643 # the compression thread count is an integer between 1 and 255.
644 #
645 # @compress-wait-thread: Controls behavior when all compression threads are
646 # currently busy. If true (default), wait for a free
647 # compression thread to become available; otherwise,
648 # send the page uncompressed. (Since 3.1)
649 #
650 # @decompress-threads: Set decompression thread count to be used in live
651 # migration, the decompression thread count is an integer between 1
652 # and 255. Usually, decompression is at least 4 times as fast as
653 # compression, so set the decompress-threads to the number about 1/4
654 # of compress-threads is adequate.
655 #
656 # @throttle-trigger-threshold: The ratio of bytes_dirty_period and bytes_xfer_period
657 # to trigger throttling. It is expressed as percentage.
658 # The default value is 50. (Since 5.0)
659 #
660 # @cpu-throttle-initial: Initial percentage of time guest cpus are throttled
661 # when migration auto-converge is activated. The
662 # default value is 20. (Since 2.7)
663 #
664 # @cpu-throttle-increment: throttle percentage increase each time
665 # auto-converge detects that migration is not making
666 # progress. The default value is 10. (Since 2.7)
667 #
668 # @cpu-throttle-tailslow: Make CPU throttling slower at tail stage
669 # At the tail stage of throttling, the Guest is very
670 # sensitive to CPU percentage while the @cpu-throttle
671 # -increment is excessive usually at tail stage.
672 # If this parameter is true, we will compute the ideal
673 # CPU percentage used by the Guest, which may exactly make
674 # the dirty rate match the dirty rate threshold. Then we
675 # will choose a smaller throttle increment between the
676 # one specified by @cpu-throttle-increment and the one
677 # generated by ideal CPU percentage.
678 # Therefore, it is compatible to traditional throttling,
679 # meanwhile the throttle increment won't be excessive
680 # at tail stage.
681 # The default value is false. (Since 5.1)
682 #
683 # @tls-creds: ID of the 'tls-creds' object that provides credentials for
684 # establishing a TLS connection over the migration data channel.
685 # On the outgoing side of the migration, the credentials must
686 # be for a 'client' endpoint, while for the incoming side the
687 # credentials must be for a 'server' endpoint. Setting this
688 # will enable TLS for all migrations. The default is unset,
689 # resulting in unsecured migration at the QEMU level. (Since 2.7)
690 #
691 # @tls-hostname: hostname of the target host for the migration. This is
692 # required when using x509 based TLS credentials and the
693 # migration URI does not already include a hostname. For
694 # example if using fd: or exec: based migration, the
695 # hostname must be provided so that the server's x509
696 # certificate identity can be validated. (Since 2.7)
697 #
698 # @tls-authz: ID of the 'authz' object subclass that provides access control
699 # checking of the TLS x509 certificate distinguished name.
700 # This object is only resolved at time of use, so can be deleted
701 # and recreated on the fly while the migration server is active.
702 # If missing, it will default to denying access (Since 4.0)
703 #
704 # @max-bandwidth: to set maximum speed for migration. maximum speed in
705 # bytes per second. (Since 2.8)
706 #
707 # @downtime-limit: set maximum tolerated downtime for migration. maximum
708 # downtime in milliseconds (Since 2.8)
709 #
710 # @x-checkpoint-delay: The delay time (in ms) between two COLO checkpoints in
711 # periodic mode. (Since 2.8)
712 #
713 # @block-incremental: Affects how much storage is migrated when the
714 # block migration capability is enabled. When false, the entire
715 # storage backing chain is migrated into a flattened image at
716 # the destination; when true, only the active qcow2 layer is
717 # migrated and the destination must already have access to the
718 # same backing chain as was used on the source. (since 2.10)
719 #
720 # @multifd-channels: Number of channels used to migrate data in
721 # parallel. This is the same number that the
722 # number of sockets used for migration. The
723 # default value is 2 (since 4.0)
724 #
725 # @xbzrle-cache-size: cache size to be used by XBZRLE migration. It
726 # needs to be a multiple of the target page size
727 # and a power of 2
728 # (Since 2.11)
729 #
730 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
731 # Defaults to 0 (unlimited). In bytes per second.
732 # (Since 3.0)
733 #
734 # @max-cpu-throttle: maximum cpu throttle percentage.
735 # Defaults to 99. (Since 3.1)
736 #
737 # @multifd-compression: Which compression method to use.
738 # Defaults to none. (Since 5.0)
739 #
740 # @multifd-zlib-level: Set the compression level to be used in live
741 # migration, the compression level is an integer between 0
742 # and 9, where 0 means no compression, 1 means the best
743 # compression speed, and 9 means best compression ratio which
744 # will consume more CPU.
745 # Defaults to 1. (Since 5.0)
746 #
747 # @multifd-zstd-level: Set the compression level to be used in live
748 # migration, the compression level is an integer between 0
749 # and 20, where 0 means no compression, 1 means the best
750 # compression speed, and 20 means best compression ratio which
751 # will consume more CPU.
752 # Defaults to 1. (Since 5.0)
753 #
754 #
755 # @block-bitmap-mapping: Maps block nodes and bitmaps on them to
756 # aliases for the purpose of dirty bitmap migration. Such
757 # aliases may for example be the corresponding names on the
758 # opposite site.
759 # The mapping must be one-to-one, but not necessarily
760 # complete: On the source, unmapped bitmaps and all bitmaps
761 # on unmapped nodes will be ignored. On the destination,
762 # encountering an unmapped alias in the incoming migration
763 # stream will result in a report, and all further bitmap
764 # migration data will then be discarded.
765 # Note that the destination does not know about bitmaps it
766 # does not receive, so there is no limitation or requirement
767 # regarding the number of bitmaps received, or how they are
768 # named, or on which nodes they are placed.
769 # By default (when this parameter has never been set), bitmap
770 # names are mapped to themselves. Nodes are mapped to their
771 # block device name if there is one, and to their node name
772 # otherwise. (Since 5.2)
773 #
774 # Features:
775 # @unstable: Member @x-checkpoint-delay is experimental.
776 #
777 # Since: 2.4
778 ##
779 { 'enum': 'MigrationParameter',
780 'data': ['announce-initial', 'announce-max',
781 'announce-rounds', 'announce-step',
782 'compress-level', 'compress-threads', 'decompress-threads',
783 'compress-wait-thread', 'throttle-trigger-threshold',
784 'cpu-throttle-initial', 'cpu-throttle-increment',
785 'cpu-throttle-tailslow',
786 'tls-creds', 'tls-hostname', 'tls-authz', 'max-bandwidth',
787 'downtime-limit',
788 { 'name': 'x-checkpoint-delay', 'features': [ 'unstable' ] },
789 'block-incremental',
790 'multifd-channels',
791 'xbzrle-cache-size', 'max-postcopy-bandwidth',
792 'max-cpu-throttle', 'multifd-compression',
793 'multifd-zlib-level' ,'multifd-zstd-level',
794 'block-bitmap-mapping' ] }
795
796 ##
797 # @MigrateSetParameters:
798 #
799 # @announce-initial: Initial delay (in milliseconds) before sending the first
800 # announce (Since 4.0)
801 #
802 # @announce-max: Maximum delay (in milliseconds) between packets in the
803 # announcement (Since 4.0)
804 #
805 # @announce-rounds: Number of self-announce packets sent after migration
806 # (Since 4.0)
807 #
808 # @announce-step: Increase in delay (in milliseconds) between subsequent
809 # packets in the announcement (Since 4.0)
810 #
811 # @compress-level: compression level
812 #
813 # @compress-threads: compression thread count
814 #
815 # @compress-wait-thread: Controls behavior when all compression threads are
816 # currently busy. If true (default), wait for a free
817 # compression thread to become available; otherwise,
818 # send the page uncompressed. (Since 3.1)
819 #
820 # @decompress-threads: decompression thread count
821 #
822 # @throttle-trigger-threshold: The ratio of bytes_dirty_period and bytes_xfer_period
823 # to trigger throttling. It is expressed as percentage.
824 # The default value is 50. (Since 5.0)
825 #
826 # @cpu-throttle-initial: Initial percentage of time guest cpus are
827 # throttled when migration auto-converge is activated.
828 # The default value is 20. (Since 2.7)
829 #
830 # @cpu-throttle-increment: throttle percentage increase each time
831 # auto-converge detects that migration is not making
832 # progress. The default value is 10. (Since 2.7)
833 #
834 # @cpu-throttle-tailslow: Make CPU throttling slower at tail stage
835 # At the tail stage of throttling, the Guest is very
836 # sensitive to CPU percentage while the @cpu-throttle
837 # -increment is excessive usually at tail stage.
838 # If this parameter is true, we will compute the ideal
839 # CPU percentage used by the Guest, which may exactly make
840 # the dirty rate match the dirty rate threshold. Then we
841 # will choose a smaller throttle increment between the
842 # one specified by @cpu-throttle-increment and the one
843 # generated by ideal CPU percentage.
844 # Therefore, it is compatible to traditional throttling,
845 # meanwhile the throttle increment won't be excessive
846 # at tail stage.
847 # The default value is false. (Since 5.1)
848 #
849 # @tls-creds: ID of the 'tls-creds' object that provides credentials
850 # for establishing a TLS connection over the migration data
851 # channel. On the outgoing side of the migration, the credentials
852 # must be for a 'client' endpoint, while for the incoming side the
853 # credentials must be for a 'server' endpoint. Setting this
854 # to a non-empty string enables TLS for all migrations.
855 # An empty string means that QEMU will use plain text mode for
856 # migration, rather than TLS (Since 2.9)
857 # Previously (since 2.7), this was reported by omitting
858 # tls-creds instead.
859 #
860 # @tls-hostname: hostname of the target host for the migration. This
861 # is required when using x509 based TLS credentials and the
862 # migration URI does not already include a hostname. For
863 # example if using fd: or exec: based migration, the
864 # hostname must be provided so that the server's x509
865 # certificate identity can be validated. (Since 2.7)
866 # An empty string means that QEMU will use the hostname
867 # associated with the migration URI, if any. (Since 2.9)
868 # Previously (since 2.7), this was reported by omitting
869 # tls-hostname instead.
870 #
871 # @max-bandwidth: to set maximum speed for migration. maximum speed in
872 # bytes per second. (Since 2.8)
873 #
874 # @downtime-limit: set maximum tolerated downtime for migration. maximum
875 # downtime in milliseconds (Since 2.8)
876 #
877 # @x-checkpoint-delay: the delay time between two COLO checkpoints. (Since 2.8)
878 #
879 # @block-incremental: Affects how much storage is migrated when the
880 # block migration capability is enabled. When false, the entire
881 # storage backing chain is migrated into a flattened image at
882 # the destination; when true, only the active qcow2 layer is
883 # migrated and the destination must already have access to the
884 # same backing chain as was used on the source. (since 2.10)
885 #
886 # @multifd-channels: Number of channels used to migrate data in
887 # parallel. This is the same number that the
888 # number of sockets used for migration. The
889 # default value is 2 (since 4.0)
890 #
891 # @xbzrle-cache-size: cache size to be used by XBZRLE migration. It
892 # needs to be a multiple of the target page size
893 # and a power of 2
894 # (Since 2.11)
895 #
896 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
897 # Defaults to 0 (unlimited). In bytes per second.
898 # (Since 3.0)
899 #
900 # @max-cpu-throttle: maximum cpu throttle percentage.
901 # The default value is 99. (Since 3.1)
902 #
903 # @multifd-compression: Which compression method to use.
904 # Defaults to none. (Since 5.0)
905 #
906 # @multifd-zlib-level: Set the compression level to be used in live
907 # migration, the compression level is an integer between 0
908 # and 9, where 0 means no compression, 1 means the best
909 # compression speed, and 9 means best compression ratio which
910 # will consume more CPU.
911 # Defaults to 1. (Since 5.0)
912 #
913 # @multifd-zstd-level: Set the compression level to be used in live
914 # migration, the compression level is an integer between 0
915 # and 20, where 0 means no compression, 1 means the best
916 # compression speed, and 20 means best compression ratio which
917 # will consume more CPU.
918 # Defaults to 1. (Since 5.0)
919 #
920 # @block-bitmap-mapping: Maps block nodes and bitmaps on them to
921 # aliases for the purpose of dirty bitmap migration. Such
922 # aliases may for example be the corresponding names on the
923 # opposite site.
924 # The mapping must be one-to-one, but not necessarily
925 # complete: On the source, unmapped bitmaps and all bitmaps
926 # on unmapped nodes will be ignored. On the destination,
927 # encountering an unmapped alias in the incoming migration
928 # stream will result in a report, and all further bitmap
929 # migration data will then be discarded.
930 # Note that the destination does not know about bitmaps it
931 # does not receive, so there is no limitation or requirement
932 # regarding the number of bitmaps received, or how they are
933 # named, or on which nodes they are placed.
934 # By default (when this parameter has never been set), bitmap
935 # names are mapped to themselves. Nodes are mapped to their
936 # block device name if there is one, and to their node name
937 # otherwise. (Since 5.2)
938 #
939 # Features:
940 # @unstable: Member @x-checkpoint-delay is experimental.
941 #
942 # Since: 2.4
943 ##
944 # TODO either fuse back into MigrationParameters, or make
945 # MigrationParameters members mandatory
946 { 'struct': 'MigrateSetParameters',
947 'data': { '*announce-initial': 'size',
948 '*announce-max': 'size',
949 '*announce-rounds': 'size',
950 '*announce-step': 'size',
951 '*compress-level': 'uint8',
952 '*compress-threads': 'uint8',
953 '*compress-wait-thread': 'bool',
954 '*decompress-threads': 'uint8',
955 '*throttle-trigger-threshold': 'uint8',
956 '*cpu-throttle-initial': 'uint8',
957 '*cpu-throttle-increment': 'uint8',
958 '*cpu-throttle-tailslow': 'bool',
959 '*tls-creds': 'StrOrNull',
960 '*tls-hostname': 'StrOrNull',
961 '*tls-authz': 'StrOrNull',
962 '*max-bandwidth': 'size',
963 '*downtime-limit': 'uint64',
964 '*x-checkpoint-delay': { 'type': 'uint32',
965 'features': [ 'unstable' ] },
966 '*block-incremental': 'bool',
967 '*multifd-channels': 'uint8',
968 '*xbzrle-cache-size': 'size',
969 '*max-postcopy-bandwidth': 'size',
970 '*max-cpu-throttle': 'uint8',
971 '*multifd-compression': 'MultiFDCompression',
972 '*multifd-zlib-level': 'uint8',
973 '*multifd-zstd-level': 'uint8',
974 '*block-bitmap-mapping': [ 'BitmapMigrationNodeAlias' ] } }
975
976 ##
977 # @migrate-set-parameters:
978 #
979 # Set various migration parameters.
980 #
981 # Since: 2.4
982 #
983 # Example:
984 #
985 # -> { "execute": "migrate-set-parameters" ,
986 # "arguments": { "compress-level": 1 } }
987 #
988 ##
989 { 'command': 'migrate-set-parameters', 'boxed': true,
990 'data': 'MigrateSetParameters' }
991
992 ##
993 # @MigrationParameters:
994 #
995 # The optional members aren't actually optional.
996 #
997 # @announce-initial: Initial delay (in milliseconds) before sending the
998 # first announce (Since 4.0)
999 #
1000 # @announce-max: Maximum delay (in milliseconds) between packets in the
1001 # announcement (Since 4.0)
1002 #
1003 # @announce-rounds: Number of self-announce packets sent after migration
1004 # (Since 4.0)
1005 #
1006 # @announce-step: Increase in delay (in milliseconds) between subsequent
1007 # packets in the announcement (Since 4.0)
1008 #
1009 # @compress-level: compression level
1010 #
1011 # @compress-threads: compression thread count
1012 #
1013 # @compress-wait-thread: Controls behavior when all compression threads are
1014 # currently busy. If true (default), wait for a free
1015 # compression thread to become available; otherwise,
1016 # send the page uncompressed. (Since 3.1)
1017 #
1018 # @decompress-threads: decompression thread count
1019 #
1020 # @throttle-trigger-threshold: The ratio of bytes_dirty_period and bytes_xfer_period
1021 # to trigger throttling. It is expressed as percentage.
1022 # The default value is 50. (Since 5.0)
1023 #
1024 # @cpu-throttle-initial: Initial percentage of time guest cpus are
1025 # throttled when migration auto-converge is activated.
1026 # (Since 2.7)
1027 #
1028 # @cpu-throttle-increment: throttle percentage increase each time
1029 # auto-converge detects that migration is not making
1030 # progress. (Since 2.7)
1031 #
1032 # @cpu-throttle-tailslow: Make CPU throttling slower at tail stage
1033 # At the tail stage of throttling, the Guest is very
1034 # sensitive to CPU percentage while the @cpu-throttle
1035 # -increment is excessive usually at tail stage.
1036 # If this parameter is true, we will compute the ideal
1037 # CPU percentage used by the Guest, which may exactly make
1038 # the dirty rate match the dirty rate threshold. Then we
1039 # will choose a smaller throttle increment between the
1040 # one specified by @cpu-throttle-increment and the one
1041 # generated by ideal CPU percentage.
1042 # Therefore, it is compatible to traditional throttling,
1043 # meanwhile the throttle increment won't be excessive
1044 # at tail stage.
1045 # The default value is false. (Since 5.1)
1046 #
1047 # @tls-creds: ID of the 'tls-creds' object that provides credentials
1048 # for establishing a TLS connection over the migration data
1049 # channel. On the outgoing side of the migration, the credentials
1050 # must be for a 'client' endpoint, while for the incoming side the
1051 # credentials must be for a 'server' endpoint.
1052 # An empty string means that QEMU will use plain text mode for
1053 # migration, rather than TLS (Since 2.7)
1054 # Note: 2.8 reports this by omitting tls-creds instead.
1055 #
1056 # @tls-hostname: hostname of the target host for the migration. This
1057 # is required when using x509 based TLS credentials and the
1058 # migration URI does not already include a hostname. For
1059 # example if using fd: or exec: based migration, the
1060 # hostname must be provided so that the server's x509
1061 # certificate identity can be validated. (Since 2.7)
1062 # An empty string means that QEMU will use the hostname
1063 # associated with the migration URI, if any. (Since 2.9)
1064 # Note: 2.8 reports this by omitting tls-hostname instead.
1065 #
1066 # @tls-authz: ID of the 'authz' object subclass that provides access control
1067 # checking of the TLS x509 certificate distinguished name. (Since
1068 # 4.0)
1069 #
1070 # @max-bandwidth: to set maximum speed for migration. maximum speed in
1071 # bytes per second. (Since 2.8)
1072 #
1073 # @downtime-limit: set maximum tolerated downtime for migration. maximum
1074 # downtime in milliseconds (Since 2.8)
1075 #
1076 # @x-checkpoint-delay: the delay time between two COLO checkpoints. (Since 2.8)
1077 #
1078 # @block-incremental: Affects how much storage is migrated when the
1079 # block migration capability is enabled. When false, the entire
1080 # storage backing chain is migrated into a flattened image at
1081 # the destination; when true, only the active qcow2 layer is
1082 # migrated and the destination must already have access to the
1083 # same backing chain as was used on the source. (since 2.10)
1084 #
1085 # @multifd-channels: Number of channels used to migrate data in
1086 # parallel. This is the same number that the
1087 # number of sockets used for migration.
1088 # The default value is 2 (since 4.0)
1089 #
1090 # @xbzrle-cache-size: cache size to be used by XBZRLE migration. It
1091 # needs to be a multiple of the target page size
1092 # and a power of 2
1093 # (Since 2.11)
1094 #
1095 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
1096 # Defaults to 0 (unlimited). In bytes per second.
1097 # (Since 3.0)
1098 #
1099 # @max-cpu-throttle: maximum cpu throttle percentage.
1100 # Defaults to 99.
1101 # (Since 3.1)
1102 #
1103 # @multifd-compression: Which compression method to use.
1104 # Defaults to none. (Since 5.0)
1105 #
1106 # @multifd-zlib-level: Set the compression level to be used in live
1107 # migration, the compression level is an integer between 0
1108 # and 9, where 0 means no compression, 1 means the best
1109 # compression speed, and 9 means best compression ratio which
1110 # will consume more CPU.
1111 # Defaults to 1. (Since 5.0)
1112 #
1113 # @multifd-zstd-level: Set the compression level to be used in live
1114 # migration, the compression level is an integer between 0
1115 # and 20, where 0 means no compression, 1 means the best
1116 # compression speed, and 20 means best compression ratio which
1117 # will consume more CPU.
1118 # Defaults to 1. (Since 5.0)
1119 #
1120 # @block-bitmap-mapping: Maps block nodes and bitmaps on them to
1121 # aliases for the purpose of dirty bitmap migration. Such
1122 # aliases may for example be the corresponding names on the
1123 # opposite site.
1124 # The mapping must be one-to-one, but not necessarily
1125 # complete: On the source, unmapped bitmaps and all bitmaps
1126 # on unmapped nodes will be ignored. On the destination,
1127 # encountering an unmapped alias in the incoming migration
1128 # stream will result in a report, and all further bitmap
1129 # migration data will then be discarded.
1130 # Note that the destination does not know about bitmaps it
1131 # does not receive, so there is no limitation or requirement
1132 # regarding the number of bitmaps received, or how they are
1133 # named, or on which nodes they are placed.
1134 # By default (when this parameter has never been set), bitmap
1135 # names are mapped to themselves. Nodes are mapped to their
1136 # block device name if there is one, and to their node name
1137 # otherwise. (Since 5.2)
1138 #
1139 # Features:
1140 # @unstable: Member @x-checkpoint-delay is experimental.
1141 #
1142 # Since: 2.4
1143 ##
1144 { 'struct': 'MigrationParameters',
1145 'data': { '*announce-initial': 'size',
1146 '*announce-max': 'size',
1147 '*announce-rounds': 'size',
1148 '*announce-step': 'size',
1149 '*compress-level': 'uint8',
1150 '*compress-threads': 'uint8',
1151 '*compress-wait-thread': 'bool',
1152 '*decompress-threads': 'uint8',
1153 '*throttle-trigger-threshold': 'uint8',
1154 '*cpu-throttle-initial': 'uint8',
1155 '*cpu-throttle-increment': 'uint8',
1156 '*cpu-throttle-tailslow': 'bool',
1157 '*tls-creds': 'str',
1158 '*tls-hostname': 'str',
1159 '*tls-authz': 'str',
1160 '*max-bandwidth': 'size',
1161 '*downtime-limit': 'uint64',
1162 '*x-checkpoint-delay': { 'type': 'uint32',
1163 'features': [ 'unstable' ] },
1164 '*block-incremental': 'bool',
1165 '*multifd-channels': 'uint8',
1166 '*xbzrle-cache-size': 'size',
1167 '*max-postcopy-bandwidth': 'size',
1168 '*max-cpu-throttle': 'uint8',
1169 '*multifd-compression': 'MultiFDCompression',
1170 '*multifd-zlib-level': 'uint8',
1171 '*multifd-zstd-level': 'uint8',
1172 '*block-bitmap-mapping': [ 'BitmapMigrationNodeAlias' ] } }
1173
1174 ##
1175 # @query-migrate-parameters:
1176 #
1177 # Returns information about the current migration parameters
1178 #
1179 # Returns: @MigrationParameters
1180 #
1181 # Since: 2.4
1182 #
1183 # Example:
1184 #
1185 # -> { "execute": "query-migrate-parameters" }
1186 # <- { "return": {
1187 # "decompress-threads": 2,
1188 # "cpu-throttle-increment": 10,
1189 # "compress-threads": 8,
1190 # "compress-level": 1,
1191 # "cpu-throttle-initial": 20,
1192 # "max-bandwidth": 33554432,
1193 # "downtime-limit": 300
1194 # }
1195 # }
1196 #
1197 ##
1198 { 'command': 'query-migrate-parameters',
1199 'returns': 'MigrationParameters' }
1200
1201 ##
1202 # @client_migrate_info:
1203 #
1204 # Set migration information for remote display. This makes the server
1205 # ask the client to automatically reconnect using the new parameters
1206 # once migration finished successfully. Only implemented for SPICE.
1207 #
1208 # @protocol: must be "spice"
1209 # @hostname: migration target hostname
1210 # @port: spice tcp port for plaintext channels
1211 # @tls-port: spice tcp port for tls-secured channels
1212 # @cert-subject: server certificate subject
1213 #
1214 # Since: 0.14
1215 #
1216 # Example:
1217 #
1218 # -> { "execute": "client_migrate_info",
1219 # "arguments": { "protocol": "spice",
1220 # "hostname": "virt42.lab.kraxel.org",
1221 # "port": 1234 } }
1222 # <- { "return": {} }
1223 #
1224 ##
1225 { 'command': 'client_migrate_info',
1226 'data': { 'protocol': 'str', 'hostname': 'str', '*port': 'int',
1227 '*tls-port': 'int', '*cert-subject': 'str' } }
1228
1229 ##
1230 # @migrate-start-postcopy:
1231 #
1232 # Followup to a migration command to switch the migration to postcopy mode.
1233 # The postcopy-ram capability must be set on both source and destination
1234 # before the original migration command.
1235 #
1236 # Since: 2.5
1237 #
1238 # Example:
1239 #
1240 # -> { "execute": "migrate-start-postcopy" }
1241 # <- { "return": {} }
1242 #
1243 ##
1244 { 'command': 'migrate-start-postcopy' }
1245
1246 ##
1247 # @MIGRATION:
1248 #
1249 # Emitted when a migration event happens
1250 #
1251 # @status: @MigrationStatus describing the current migration status.
1252 #
1253 # Since: 2.4
1254 #
1255 # Example:
1256 #
1257 # <- {"timestamp": {"seconds": 1432121972, "microseconds": 744001},
1258 # "event": "MIGRATION",
1259 # "data": {"status": "completed"} }
1260 #
1261 ##
1262 { 'event': 'MIGRATION',
1263 'data': {'status': 'MigrationStatus'}}
1264
1265 ##
1266 # @MIGRATION_PASS:
1267 #
1268 # Emitted from the source side of a migration at the start of each pass
1269 # (when it syncs the dirty bitmap)
1270 #
1271 # @pass: An incrementing count (starting at 1 on the first pass)
1272 #
1273 # Since: 2.6
1274 #
1275 # Example:
1276 #
1277 # { "timestamp": {"seconds": 1449669631, "microseconds": 239225},
1278 # "event": "MIGRATION_PASS", "data": {"pass": 2} }
1279 #
1280 ##
1281 { 'event': 'MIGRATION_PASS',
1282 'data': { 'pass': 'int' } }
1283
1284 ##
1285 # @COLOMessage:
1286 #
1287 # The message transmission between Primary side and Secondary side.
1288 #
1289 # @checkpoint-ready: Secondary VM (SVM) is ready for checkpointing
1290 #
1291 # @checkpoint-request: Primary VM (PVM) tells SVM to prepare for checkpointing
1292 #
1293 # @checkpoint-reply: SVM gets PVM's checkpoint request
1294 #
1295 # @vmstate-send: VM's state will be sent by PVM.
1296 #
1297 # @vmstate-size: The total size of VMstate.
1298 #
1299 # @vmstate-received: VM's state has been received by SVM.
1300 #
1301 # @vmstate-loaded: VM's state has been loaded by SVM.
1302 #
1303 # Since: 2.8
1304 ##
1305 { 'enum': 'COLOMessage',
1306 'data': [ 'checkpoint-ready', 'checkpoint-request', 'checkpoint-reply',
1307 'vmstate-send', 'vmstate-size', 'vmstate-received',
1308 'vmstate-loaded' ] }
1309
1310 ##
1311 # @COLOMode:
1312 #
1313 # The COLO current mode.
1314 #
1315 # @none: COLO is disabled.
1316 #
1317 # @primary: COLO node in primary side.
1318 #
1319 # @secondary: COLO node in slave side.
1320 #
1321 # Since: 2.8
1322 ##
1323 { 'enum': 'COLOMode',
1324 'data': [ 'none', 'primary', 'secondary'] }
1325
1326 ##
1327 # @FailoverStatus:
1328 #
1329 # An enumeration of COLO failover status
1330 #
1331 # @none: no failover has ever happened
1332 #
1333 # @require: got failover requirement but not handled
1334 #
1335 # @active: in the process of doing failover
1336 #
1337 # @completed: finish the process of failover
1338 #
1339 # @relaunch: restart the failover process, from 'none' -> 'completed' (Since 2.9)
1340 #
1341 # Since: 2.8
1342 ##
1343 { 'enum': 'FailoverStatus',
1344 'data': [ 'none', 'require', 'active', 'completed', 'relaunch' ] }
1345
1346 ##
1347 # @COLO_EXIT:
1348 #
1349 # Emitted when VM finishes COLO mode due to some errors happening or
1350 # at the request of users.
1351 #
1352 # @mode: report COLO mode when COLO exited.
1353 #
1354 # @reason: describes the reason for the COLO exit.
1355 #
1356 # Since: 3.1
1357 #
1358 # Example:
1359 #
1360 # <- { "timestamp": {"seconds": 2032141960, "microseconds": 417172},
1361 # "event": "COLO_EXIT", "data": {"mode": "primary", "reason": "request" } }
1362 #
1363 ##
1364 { 'event': 'COLO_EXIT',
1365 'data': {'mode': 'COLOMode', 'reason': 'COLOExitReason' } }
1366
1367 ##
1368 # @COLOExitReason:
1369 #
1370 # The reason for a COLO exit.
1371 #
1372 # @none: failover has never happened. This state does not occur
1373 # in the COLO_EXIT event, and is only visible in the result of
1374 # query-colo-status.
1375 #
1376 # @request: COLO exit is due to an external request.
1377 #
1378 # @error: COLO exit is due to an internal error.
1379 #
1380 # @processing: COLO is currently handling a failover (since 4.0).
1381 #
1382 # Since: 3.1
1383 ##
1384 { 'enum': 'COLOExitReason',
1385 'data': [ 'none', 'request', 'error' , 'processing' ] }
1386
1387 ##
1388 # @x-colo-lost-heartbeat:
1389 #
1390 # Tell qemu that heartbeat is lost, request it to do takeover procedures.
1391 # If this command is sent to the PVM, the Primary side will exit COLO mode.
1392 # If sent to the Secondary, the Secondary side will run failover work,
1393 # then takes over server operation to become the service VM.
1394 #
1395 # Features:
1396 # @unstable: This command is experimental.
1397 #
1398 # Since: 2.8
1399 #
1400 # Example:
1401 #
1402 # -> { "execute": "x-colo-lost-heartbeat" }
1403 # <- { "return": {} }
1404 #
1405 ##
1406 { 'command': 'x-colo-lost-heartbeat',
1407 'features': [ 'unstable' ] }
1408
1409 ##
1410 # @migrate_cancel:
1411 #
1412 # Cancel the current executing migration process.
1413 #
1414 # Returns: nothing on success
1415 #
1416 # Notes: This command succeeds even if there is no migration process running.
1417 #
1418 # Since: 0.14
1419 #
1420 # Example:
1421 #
1422 # -> { "execute": "migrate_cancel" }
1423 # <- { "return": {} }
1424 #
1425 ##
1426 { 'command': 'migrate_cancel' }
1427
1428 ##
1429 # @migrate-continue:
1430 #
1431 # Continue migration when it's in a paused state.
1432 #
1433 # @state: The state the migration is currently expected to be in
1434 #
1435 # Returns: nothing on success
1436 #
1437 # Since: 2.11
1438 #
1439 # Example:
1440 #
1441 # -> { "execute": "migrate-continue" , "arguments":
1442 # { "state": "pre-switchover" } }
1443 # <- { "return": {} }
1444 ##
1445 { 'command': 'migrate-continue', 'data': {'state': 'MigrationStatus'} }
1446
1447 ##
1448 # @migrate:
1449 #
1450 # Migrates the current running guest to another Virtual Machine.
1451 #
1452 # @uri: the Uniform Resource Identifier of the destination VM
1453 #
1454 # @blk: do block migration (full disk copy)
1455 #
1456 # @inc: incremental disk copy migration
1457 #
1458 # @detach: this argument exists only for compatibility reasons and
1459 # is ignored by QEMU
1460 #
1461 # @resume: resume one paused migration, default "off". (since 3.0)
1462 #
1463 # Returns: nothing on success
1464 #
1465 # Since: 0.14
1466 #
1467 # Notes:
1468 #
1469 # 1. The 'query-migrate' command should be used to check migration's progress
1470 # and final result (this information is provided by the 'status' member)
1471 #
1472 # 2. All boolean arguments default to false
1473 #
1474 # 3. The user Monitor's "detach" argument is invalid in QMP and should not
1475 # be used
1476 #
1477 # Example:
1478 #
1479 # -> { "execute": "migrate", "arguments": { "uri": "tcp:0:4446" } }
1480 # <- { "return": {} }
1481 #
1482 ##
1483 { 'command': 'migrate',
1484 'data': {'uri': 'str', '*blk': 'bool', '*inc': 'bool',
1485 '*detach': 'bool', '*resume': 'bool' } }
1486
1487 ##
1488 # @migrate-incoming:
1489 #
1490 # Start an incoming migration, the qemu must have been started
1491 # with -incoming defer
1492 #
1493 # @uri: The Uniform Resource Identifier identifying the source or
1494 # address to listen on
1495 #
1496 # Returns: nothing on success
1497 #
1498 # Since: 2.3
1499 #
1500 # Notes:
1501 #
1502 # 1. It's a bad idea to use a string for the uri, but it needs to stay
1503 # compatible with -incoming and the format of the uri is already exposed
1504 # above libvirt.
1505 #
1506 # 2. QEMU must be started with -incoming defer to allow migrate-incoming to
1507 # be used.
1508 #
1509 # 3. The uri format is the same as for -incoming
1510 #
1511 # Example:
1512 #
1513 # -> { "execute": "migrate-incoming",
1514 # "arguments": { "uri": "tcp::4446" } }
1515 # <- { "return": {} }
1516 #
1517 ##
1518 { 'command': 'migrate-incoming', 'data': {'uri': 'str' } }
1519
1520 ##
1521 # @xen-save-devices-state:
1522 #
1523 # Save the state of all devices to file. The RAM and the block devices
1524 # of the VM are not saved by this command.
1525 #
1526 # @filename: the file to save the state of the devices to as binary
1527 # data. See xen-save-devices-state.txt for a description of the binary
1528 # format.
1529 #
1530 # @live: Optional argument to ask QEMU to treat this command as part of a live
1531 # migration. Default to true. (since 2.11)
1532 #
1533 # Returns: Nothing on success
1534 #
1535 # Since: 1.1
1536 #
1537 # Example:
1538 #
1539 # -> { "execute": "xen-save-devices-state",
1540 # "arguments": { "filename": "/tmp/save" } }
1541 # <- { "return": {} }
1542 #
1543 ##
1544 { 'command': 'xen-save-devices-state',
1545 'data': {'filename': 'str', '*live':'bool' } }
1546
1547 ##
1548 # @xen-set-global-dirty-log:
1549 #
1550 # Enable or disable the global dirty log mode.
1551 #
1552 # @enable: true to enable, false to disable.
1553 #
1554 # Returns: nothing
1555 #
1556 # Since: 1.3
1557 #
1558 # Example:
1559 #
1560 # -> { "execute": "xen-set-global-dirty-log",
1561 # "arguments": { "enable": true } }
1562 # <- { "return": {} }
1563 #
1564 ##
1565 { 'command': 'xen-set-global-dirty-log', 'data': { 'enable': 'bool' } }
1566
1567 ##
1568 # @xen-load-devices-state:
1569 #
1570 # Load the state of all devices from file. The RAM and the block devices
1571 # of the VM are not loaded by this command.
1572 #
1573 # @filename: the file to load the state of the devices from as binary
1574 # data. See xen-save-devices-state.txt for a description of the binary
1575 # format.
1576 #
1577 # Since: 2.7
1578 #
1579 # Example:
1580 #
1581 # -> { "execute": "xen-load-devices-state",
1582 # "arguments": { "filename": "/tmp/resume" } }
1583 # <- { "return": {} }
1584 #
1585 ##
1586 { 'command': 'xen-load-devices-state', 'data': {'filename': 'str'} }
1587
1588 ##
1589 # @xen-set-replication:
1590 #
1591 # Enable or disable replication.
1592 #
1593 # @enable: true to enable, false to disable.
1594 #
1595 # @primary: true for primary or false for secondary.
1596 #
1597 # @failover: true to do failover, false to stop. but cannot be
1598 # specified if 'enable' is true. default value is false.
1599 #
1600 # Returns: nothing.
1601 #
1602 # Example:
1603 #
1604 # -> { "execute": "xen-set-replication",
1605 # "arguments": {"enable": true, "primary": false} }
1606 # <- { "return": {} }
1607 #
1608 # Since: 2.9
1609 ##
1610 { 'command': 'xen-set-replication',
1611 'data': { 'enable': 'bool', 'primary': 'bool', '*failover' : 'bool' },
1612 'if': 'CONFIG_REPLICATION' }
1613
1614 ##
1615 # @ReplicationStatus:
1616 #
1617 # The result format for 'query-xen-replication-status'.
1618 #
1619 # @error: true if an error happened, false if replication is normal.
1620 #
1621 # @desc: the human readable error description string, when
1622 # @error is 'true'.
1623 #
1624 # Since: 2.9
1625 ##
1626 { 'struct': 'ReplicationStatus',
1627 'data': { 'error': 'bool', '*desc': 'str' },
1628 'if': 'CONFIG_REPLICATION' }
1629
1630 ##
1631 # @query-xen-replication-status:
1632 #
1633 # Query replication status while the vm is running.
1634 #
1635 # Returns: A @ReplicationStatus object showing the status.
1636 #
1637 # Example:
1638 #
1639 # -> { "execute": "query-xen-replication-status" }
1640 # <- { "return": { "error": false } }
1641 #
1642 # Since: 2.9
1643 ##
1644 { 'command': 'query-xen-replication-status',
1645 'returns': 'ReplicationStatus',
1646 'if': 'CONFIG_REPLICATION' }
1647
1648 ##
1649 # @xen-colo-do-checkpoint:
1650 #
1651 # Xen uses this command to notify replication to trigger a checkpoint.
1652 #
1653 # Returns: nothing.
1654 #
1655 # Example:
1656 #
1657 # -> { "execute": "xen-colo-do-checkpoint" }
1658 # <- { "return": {} }
1659 #
1660 # Since: 2.9
1661 ##
1662 { 'command': 'xen-colo-do-checkpoint',
1663 'if': 'CONFIG_REPLICATION' }
1664
1665 ##
1666 # @COLOStatus:
1667 #
1668 # The result format for 'query-colo-status'.
1669 #
1670 # @mode: COLO running mode. If COLO is running, this field will return
1671 # 'primary' or 'secondary'.
1672 #
1673 # @last-mode: COLO last running mode. If COLO is running, this field
1674 # will return same like mode field, after failover we can
1675 # use this field to get last colo mode. (since 4.0)
1676 #
1677 # @reason: describes the reason for the COLO exit.
1678 #
1679 # Since: 3.1
1680 ##
1681 { 'struct': 'COLOStatus',
1682 'data': { 'mode': 'COLOMode', 'last-mode': 'COLOMode',
1683 'reason': 'COLOExitReason' } }
1684
1685 ##
1686 # @query-colo-status:
1687 #
1688 # Query COLO status while the vm is running.
1689 #
1690 # Returns: A @COLOStatus object showing the status.
1691 #
1692 # Example:
1693 #
1694 # -> { "execute": "query-colo-status" }
1695 # <- { "return": { "mode": "primary", "last-mode": "none", "reason": "request" } }
1696 #
1697 # Since: 3.1
1698 ##
1699 { 'command': 'query-colo-status',
1700 'returns': 'COLOStatus' }
1701
1702 ##
1703 # @migrate-recover:
1704 #
1705 # Provide a recovery migration stream URI.
1706 #
1707 # @uri: the URI to be used for the recovery of migration stream.
1708 #
1709 # Returns: nothing.
1710 #
1711 # Example:
1712 #
1713 # -> { "execute": "migrate-recover",
1714 # "arguments": { "uri": "tcp:192.168.1.200:12345" } }
1715 # <- { "return": {} }
1716 #
1717 # Since: 3.0
1718 ##
1719 { 'command': 'migrate-recover',
1720 'data': { 'uri': 'str' },
1721 'allow-oob': true }
1722
1723 ##
1724 # @migrate-pause:
1725 #
1726 # Pause a migration. Currently it only supports postcopy.
1727 #
1728 # Returns: nothing.
1729 #
1730 # Example:
1731 #
1732 # -> { "execute": "migrate-pause" }
1733 # <- { "return": {} }
1734 #
1735 # Since: 3.0
1736 ##
1737 { 'command': 'migrate-pause', 'allow-oob': true }
1738
1739 ##
1740 # @UNPLUG_PRIMARY:
1741 #
1742 # Emitted from source side of a migration when migration state is
1743 # WAIT_UNPLUG. Device was unplugged by guest operating system.
1744 # Device resources in QEMU are kept on standby to be able to re-plug it in case
1745 # of migration failure.
1746 #
1747 # @device-id: QEMU device id of the unplugged device
1748 #
1749 # Since: 4.2
1750 #
1751 # Example:
1752 #
1753 # <- { "event": "UNPLUG_PRIMARY",
1754 # "data": { "device-id": "hostdev0" },
1755 # "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
1756 #
1757 ##
1758 { 'event': 'UNPLUG_PRIMARY',
1759 'data': { 'device-id': 'str' } }
1760
1761 ##
1762 # @DirtyRateVcpu:
1763 #
1764 # Dirty rate of vcpu.
1765 #
1766 # @id: vcpu index.
1767 #
1768 # @dirty-rate: dirty rate.
1769 #
1770 # Since: 6.2
1771 ##
1772 { 'struct': 'DirtyRateVcpu',
1773 'data': { 'id': 'int', 'dirty-rate': 'int64' } }
1774
1775 ##
1776 # @DirtyRateStatus:
1777 #
1778 # An enumeration of dirtyrate status.
1779 #
1780 # @unstarted: the dirtyrate thread has not been started.
1781 #
1782 # @measuring: the dirtyrate thread is measuring.
1783 #
1784 # @measured: the dirtyrate thread has measured and results are available.
1785 #
1786 # Since: 5.2
1787 ##
1788 { 'enum': 'DirtyRateStatus',
1789 'data': [ 'unstarted', 'measuring', 'measured'] }
1790
1791 ##
1792 # @DirtyRateMeasureMode:
1793 #
1794 # An enumeration of mode of measuring dirtyrate.
1795 #
1796 # @page-sampling: calculate dirtyrate by sampling pages.
1797 #
1798 # @dirty-ring: calculate dirtyrate by dirty ring.
1799 #
1800 # @dirty-bitmap: calculate dirtyrate by dirty bitmap.
1801 #
1802 # Since: 6.2
1803 ##
1804 { 'enum': 'DirtyRateMeasureMode',
1805 'data': ['page-sampling', 'dirty-ring', 'dirty-bitmap'] }
1806
1807 ##
1808 # @DirtyRateInfo:
1809 #
1810 # Information about current dirty page rate of vm.
1811 #
1812 # @dirty-rate: an estimate of the dirty page rate of the VM in units of
1813 # MB/s, present only when estimating the rate has completed.
1814 #
1815 # @status: status containing dirtyrate query status includes
1816 # 'unstarted' or 'measuring' or 'measured'
1817 #
1818 # @start-time: start time in units of second for calculation
1819 #
1820 # @calc-time: time in units of second for sample dirty pages
1821 #
1822 # @sample-pages: page count per GB for sample dirty pages
1823 # the default value is 512 (since 6.1)
1824 #
1825 # @mode: mode containing method of calculate dirtyrate includes
1826 # 'page-sampling' and 'dirty-ring' (Since 6.2)
1827 #
1828 # @vcpu-dirty-rate: dirtyrate for each vcpu if dirty-ring
1829 # mode specified (Since 6.2)
1830 #
1831 # Since: 5.2
1832 ##
1833 { 'struct': 'DirtyRateInfo',
1834 'data': {'*dirty-rate': 'int64',
1835 'status': 'DirtyRateStatus',
1836 'start-time': 'int64',
1837 'calc-time': 'int64',
1838 'sample-pages': 'uint64',
1839 'mode': 'DirtyRateMeasureMode',
1840 '*vcpu-dirty-rate': [ 'DirtyRateVcpu' ] } }
1841
1842 ##
1843 # @calc-dirty-rate:
1844 #
1845 # start calculating dirty page rate for vm
1846 #
1847 # @calc-time: time in units of second for sample dirty pages
1848 #
1849 # @sample-pages: page count per GB for sample dirty pages
1850 # the default value is 512 (since 6.1)
1851 #
1852 # @mode: mechanism of calculating dirtyrate includes
1853 # 'page-sampling' and 'dirty-ring' (Since 6.1)
1854 #
1855 # Since: 5.2
1856 #
1857 # Example:
1858 #
1859 # {"execute": "calc-dirty-rate", "arguments": {"calc-time": 1,
1860 # 'sample-pages': 512} }
1861 #
1862 ##
1863 { 'command': 'calc-dirty-rate', 'data': {'calc-time': 'int64',
1864 '*sample-pages': 'int',
1865 '*mode': 'DirtyRateMeasureMode'} }
1866
1867 ##
1868 # @query-dirty-rate:
1869 #
1870 # query dirty page rate in units of MB/s for vm
1871 #
1872 # Since: 5.2
1873 ##
1874 { 'command': 'query-dirty-rate', 'returns': 'DirtyRateInfo' }
1875
1876 ##
1877 # @DirtyLimitInfo:
1878 #
1879 # Dirty page rate limit information of a virtual CPU.
1880 #
1881 # @cpu-index: index of a virtual CPU.
1882 #
1883 # @limit-rate: upper limit of dirty page rate (MB/s) for a virtual
1884 # CPU, 0 means unlimited.
1885 #
1886 # @current-rate: current dirty page rate (MB/s) for a virtual CPU.
1887 #
1888 # Since: 7.1
1889 #
1890 ##
1891 { 'struct': 'DirtyLimitInfo',
1892 'data': { 'cpu-index': 'int',
1893 'limit-rate': 'uint64',
1894 'current-rate': 'uint64' } }
1895
1896 ##
1897 # @set-vcpu-dirty-limit:
1898 #
1899 # Set the upper limit of dirty page rate for virtual CPUs.
1900 #
1901 # Requires KVM with accelerator property "dirty-ring-size" set.
1902 # A virtual CPU's dirty page rate is a measure of its memory load.
1903 # To observe dirty page rates, use @calc-dirty-rate.
1904 #
1905 # @cpu-index: index of a virtual CPU, default is all.
1906 #
1907 # @dirty-rate: upper limit of dirty page rate (MB/s) for virtual CPUs.
1908 #
1909 # Since: 7.1
1910 #
1911 # Example:
1912 # {"execute": "set-vcpu-dirty-limit"}
1913 # "arguments": { "dirty-rate": 200,
1914 # "cpu-index": 1 } }
1915 #
1916 ##
1917 { 'command': 'set-vcpu-dirty-limit',
1918 'data': { '*cpu-index': 'int',
1919 'dirty-rate': 'uint64' } }
1920
1921 ##
1922 # @cancel-vcpu-dirty-limit:
1923 #
1924 # Cancel the upper limit of dirty page rate for virtual CPUs.
1925 #
1926 # Cancel the dirty page limit for the vCPU which has been set with
1927 # set-vcpu-dirty-limit command. Note that this command requires
1928 # support from dirty ring, same as the "set-vcpu-dirty-limit".
1929 #
1930 # @cpu-index: index of a virtual CPU, default is all.
1931 #
1932 # Since: 7.1
1933 #
1934 # Example:
1935 # {"execute": "cancel-vcpu-dirty-limit"}
1936 # "arguments": { "cpu-index": 1 } }
1937 #
1938 ##
1939 { 'command': 'cancel-vcpu-dirty-limit',
1940 'data': { '*cpu-index': 'int'} }
1941
1942 ##
1943 # @query-vcpu-dirty-limit:
1944 #
1945 # Returns information about virtual CPU dirty page rate limits, if any.
1946 #
1947 # Since: 7.1
1948 #
1949 # Example:
1950 # {"execute": "query-vcpu-dirty-limit"}
1951 #
1952 ##
1953 { 'command': 'query-vcpu-dirty-limit',
1954 'returns': [ 'DirtyLimitInfo' ] }
1955
1956 ##
1957 # @snapshot-save:
1958 #
1959 # Save a VM snapshot
1960 #
1961 # @job-id: identifier for the newly created job
1962 # @tag: name of the snapshot to create
1963 # @vmstate: block device node name to save vmstate to
1964 # @devices: list of block device node names to save a snapshot to
1965 #
1966 # Applications should not assume that the snapshot save is complete
1967 # when this command returns. The job commands / events must be used
1968 # to determine completion and to fetch details of any errors that arise.
1969 #
1970 # Note that execution of the guest CPUs may be stopped during the
1971 # time it takes to save the snapshot. A future version of QEMU
1972 # may ensure CPUs are executing continuously.
1973 #
1974 # It is strongly recommended that @devices contain all writable
1975 # block device nodes if a consistent snapshot is required.
1976 #
1977 # If @tag already exists, an error will be reported
1978 #
1979 # Returns: nothing
1980 #
1981 # Example:
1982 #
1983 # -> { "execute": "snapshot-save",
1984 # "arguments": {
1985 # "job-id": "snapsave0",
1986 # "tag": "my-snap",
1987 # "vmstate": "disk0",
1988 # "devices": ["disk0", "disk1"]
1989 # }
1990 # }
1991 # <- { "return": { } }
1992 # <- {"event": "JOB_STATUS_CHANGE",
1993 # "data": {"status": "created", "id": "snapsave0"}}
1994 # <- {"event": "JOB_STATUS_CHANGE",
1995 # "data": {"status": "running", "id": "snapsave0"}}
1996 # <- {"event": "STOP"}
1997 # <- {"event": "RESUME"}
1998 # <- {"event": "JOB_STATUS_CHANGE",
1999 # "data": {"status": "waiting", "id": "snapsave0"}}
2000 # <- {"event": "JOB_STATUS_CHANGE",
2001 # "data": {"status": "pending", "id": "snapsave0"}}
2002 # <- {"event": "JOB_STATUS_CHANGE",
2003 # "data": {"status": "concluded", "id": "snapsave0"}}
2004 # -> {"execute": "query-jobs"}
2005 # <- {"return": [{"current-progress": 1,
2006 # "status": "concluded",
2007 # "total-progress": 1,
2008 # "type": "snapshot-save",
2009 # "id": "snapsave0"}]}
2010 #
2011 # Since: 6.0
2012 ##
2013 { 'command': 'snapshot-save',
2014 'data': { 'job-id': 'str',
2015 'tag': 'str',
2016 'vmstate': 'str',
2017 'devices': ['str'] } }
2018
2019 ##
2020 # @snapshot-load:
2021 #
2022 # Load a VM snapshot
2023 #
2024 # @job-id: identifier for the newly created job
2025 # @tag: name of the snapshot to load.
2026 # @vmstate: block device node name to load vmstate from
2027 # @devices: list of block device node names to load a snapshot from
2028 #
2029 # Applications should not assume that the snapshot load is complete
2030 # when this command returns. The job commands / events must be used
2031 # to determine completion and to fetch details of any errors that arise.
2032 #
2033 # Note that execution of the guest CPUs will be stopped during the
2034 # time it takes to load the snapshot.
2035 #
2036 # It is strongly recommended that @devices contain all writable
2037 # block device nodes that can have changed since the original
2038 # @snapshot-save command execution.
2039 #
2040 # Returns: nothing
2041 #
2042 # Example:
2043 #
2044 # -> { "execute": "snapshot-load",
2045 # "arguments": {
2046 # "job-id": "snapload0",
2047 # "tag": "my-snap",
2048 # "vmstate": "disk0",
2049 # "devices": ["disk0", "disk1"]
2050 # }
2051 # }
2052 # <- { "return": { } }
2053 # <- {"event": "JOB_STATUS_CHANGE",
2054 # "data": {"status": "created", "id": "snapload0"}}
2055 # <- {"event": "JOB_STATUS_CHANGE",
2056 # "data": {"status": "running", "id": "snapload0"}}
2057 # <- {"event": "STOP"}
2058 # <- {"event": "RESUME"}
2059 # <- {"event": "JOB_STATUS_CHANGE",
2060 # "data": {"status": "waiting", "id": "snapload0"}}
2061 # <- {"event": "JOB_STATUS_CHANGE",
2062 # "data": {"status": "pending", "id": "snapload0"}}
2063 # <- {"event": "JOB_STATUS_CHANGE",
2064 # "data": {"status": "concluded", "id": "snapload0"}}
2065 # -> {"execute": "query-jobs"}
2066 # <- {"return": [{"current-progress": 1,
2067 # "status": "concluded",
2068 # "total-progress": 1,
2069 # "type": "snapshot-load",
2070 # "id": "snapload0"}]}
2071 #
2072 # Since: 6.0
2073 ##
2074 { 'command': 'snapshot-load',
2075 'data': { 'job-id': 'str',
2076 'tag': 'str',
2077 'vmstate': 'str',
2078 'devices': ['str'] } }
2079
2080 ##
2081 # @snapshot-delete:
2082 #
2083 # Delete a VM snapshot
2084 #
2085 # @job-id: identifier for the newly created job
2086 # @tag: name of the snapshot to delete.
2087 # @devices: list of block device node names to delete a snapshot from
2088 #
2089 # Applications should not assume that the snapshot delete is complete
2090 # when this command returns. The job commands / events must be used
2091 # to determine completion and to fetch details of any errors that arise.
2092 #
2093 # Returns: nothing
2094 #
2095 # Example:
2096 #
2097 # -> { "execute": "snapshot-delete",
2098 # "arguments": {
2099 # "job-id": "snapdelete0",
2100 # "tag": "my-snap",
2101 # "devices": ["disk0", "disk1"]
2102 # }
2103 # }
2104 # <- { "return": { } }
2105 # <- {"event": "JOB_STATUS_CHANGE",
2106 # "data": {"status": "created", "id": "snapdelete0"}}
2107 # <- {"event": "JOB_STATUS_CHANGE",
2108 # "data": {"status": "running", "id": "snapdelete0"}}
2109 # <- {"event": "JOB_STATUS_CHANGE",
2110 # "data": {"status": "waiting", "id": "snapdelete0"}}
2111 # <- {"event": "JOB_STATUS_CHANGE",
2112 # "data": {"status": "pending", "id": "snapdelete0"}}
2113 # <- {"event": "JOB_STATUS_CHANGE",
2114 # "data": {"status": "concluded", "id": "snapdelete0"}}
2115 # -> {"execute": "query-jobs"}
2116 # <- {"return": [{"current-progress": 1,
2117 # "status": "concluded",
2118 # "total-progress": 1,
2119 # "type": "snapshot-delete",
2120 # "id": "snapdelete0"}]}
2121 #
2122 # Since: 6.0
2123 ##
2124 { 'command': 'snapshot-delete',
2125 'data': { 'job-id': 'str',
2126 'tag': 'str',
2127 'devices': ['str'] } }