]> Git Repo - qemu.git/blob - qapi/migration.json
qapi/migration.json: fix the description for "query-migrate" output
[qemu.git] / qapi / migration.json
1 # -*- Mode: Python -*-
2 #
3
4 ##
5 # = Migration
6 ##
7
8 { 'include': 'common.json' }
9
10 ##
11 # @MigrationStats:
12 #
13 # Detailed migration status.
14 #
15 # @transferred: amount of bytes already transferred to the target VM
16 #
17 # @remaining: amount of bytes remaining to be transferred to the target VM
18 #
19 # @total: total amount of bytes involved in the migration process
20 #
21 # @duplicate: number of duplicate (zero) pages (since 1.2)
22 #
23 # @skipped: number of skipped zero pages (since 1.5)
24 #
25 # @normal: number of normal pages (since 1.2)
26 #
27 # @normal-bytes: number of normal bytes sent (since 1.2)
28 #
29 # @dirty-pages-rate: number of pages dirtied by second by the
30 #        guest (since 1.3)
31 #
32 # @mbps: throughput in megabits/sec. (since 1.6)
33 #
34 # @dirty-sync-count: number of times that dirty ram was synchronized (since 2.1)
35 #
36 # @postcopy-requests: The number of page requests received from the destination
37 #        (since 2.7)
38 #
39 # @page-size: The number of bytes per page for the various page-based
40 #        statistics (since 2.10)
41 #
42 # @multifd-bytes: The number of bytes sent through multifd (since 3.0)
43 #
44 # Since: 0.14.0
45 ##
46 { 'struct': 'MigrationStats',
47   'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' ,
48            'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
49            'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
50            'mbps' : 'number', 'dirty-sync-count' : 'int',
51            'postcopy-requests' : 'int', 'page-size' : 'int',
52            'multifd-bytes' : 'uint64' } }
53
54 ##
55 # @XBZRLECacheStats:
56 #
57 # Detailed XBZRLE migration cache statistics
58 #
59 # @cache-size: XBZRLE cache size
60 #
61 # @bytes: amount of bytes already transferred to the target VM
62 #
63 # @pages: amount of pages transferred to the target VM
64 #
65 # @cache-miss: number of cache miss
66 #
67 # @cache-miss-rate: rate of cache miss (since 2.1)
68 #
69 # @overflow: number of overflows
70 #
71 # Since: 1.2
72 ##
73 { 'struct': 'XBZRLECacheStats',
74   'data': {'cache-size': 'int', 'bytes': 'int', 'pages': 'int',
75            'cache-miss': 'int', 'cache-miss-rate': 'number',
76            'overflow': 'int' } }
77
78 ##
79 # @MigrationStatus:
80 #
81 # An enumeration of migration status.
82 #
83 # @none: no migration has ever happened.
84 #
85 # @setup: migration process has been initiated.
86 #
87 # @cancelling: in the process of cancelling migration.
88 #
89 # @cancelled: cancelling migration is finished.
90 #
91 # @active: in the process of doing migration.
92 #
93 # @postcopy-active: like active, but now in postcopy mode. (since 2.5)
94 #
95 # @postcopy-paused: during postcopy but paused. (since 3.0)
96 #
97 # @postcopy-recover: trying to recover from a paused postcopy. (since 3.0)
98 #
99 # @completed: migration is finished.
100 #
101 # @failed: some error occurred during migration process.
102 #
103 # @colo: VM is in the process of fault tolerance, VM can not get into this
104 #        state unless colo capability is enabled for migration. (since 2.8)
105 #
106 # @pre-switchover: Paused before device serialisation. (since 2.11)
107 #
108 # @device: During device serialisation when pause-before-switchover is enabled
109 #        (since 2.11)
110 #
111 # Since: 2.3
112 #
113 ##
114 { 'enum': 'MigrationStatus',
115   'data': [ 'none', 'setup', 'cancelling', 'cancelled',
116             'active', 'postcopy-active', 'postcopy-paused',
117             'postcopy-recover', 'completed', 'failed', 'colo',
118             'pre-switchover', 'device' ] }
119
120 ##
121 # @MigrationInfo:
122 #
123 # Information about current migration process.
124 #
125 # @status: @MigrationStatus describing the current migration status.
126 #          If this field is not returned, no migration process
127 #          has been initiated
128 #
129 # @ram: @MigrationStats containing detailed migration
130 #       status, only returned if status is 'active' or
131 #       'completed'(since 1.2)
132 #
133 # @disk: @MigrationStats containing detailed disk migration
134 #        status, only returned if status is 'active' and it is a block
135 #        migration
136 #
137 # @xbzrle-cache: @XBZRLECacheStats containing detailed XBZRLE
138 #                migration statistics, only returned if XBZRLE feature is on and
139 #                status is 'active' or 'completed' (since 1.2)
140 #
141 # @total-time: total amount of milliseconds since migration started.
142 #        If migration has ended, it returns the total migration
143 #        time. (since 1.2)
144 #
145 # @downtime: only present when migration finishes correctly
146 #        total downtime in milliseconds for the guest.
147 #        (since 1.3)
148 #
149 # @expected-downtime: only present while migration is active
150 #        expected downtime in milliseconds for the guest in last walk
151 #        of the dirty bitmap. (since 1.3)
152 #
153 # @setup-time: amount of setup time in milliseconds _before_ the
154 #        iterations begin but _after_ the QMP command is issued. This is designed
155 #        to provide an accounting of any activities (such as RDMA pinning) which
156 #        may be expensive, but do not actually occur during the iterative
157 #        migration rounds themselves. (since 1.6)
158 #
159 # @cpu-throttle-percentage: percentage of time guest cpus are being
160 #        throttled during auto-converge. This is only present when auto-converge
161 #        has started throttling guest cpus. (Since 2.7)
162 #
163 # @error-desc: the human readable error description string, when
164 #              @status is 'failed'. Clients should not attempt to parse the
165 #              error strings. (Since 2.7)
166 #
167 # @postcopy-blocktime: total time when all vCPU were blocked during postcopy
168 #           live migration. This is only present when the postcopy-blocktime
169 #           migration capability is enabled. (Since 3.0)
170 #
171 # @postcopy-vcpu-blocktime: list of the postcopy blocktime per vCPU.  This is
172 #           only present when the postcopy-blocktime migration capability
173 #           is enabled. (Since 3.0)
174 #
175 #
176 # Since: 0.14.0
177 ##
178 { 'struct': 'MigrationInfo',
179   'data': {'*status': 'MigrationStatus', '*ram': 'MigrationStats',
180            '*disk': 'MigrationStats',
181            '*xbzrle-cache': 'XBZRLECacheStats',
182            '*total-time': 'int',
183            '*expected-downtime': 'int',
184            '*downtime': 'int',
185            '*setup-time': 'int',
186            '*cpu-throttle-percentage': 'int',
187            '*error-desc': 'str',
188            '*postcopy-blocktime' : 'uint32',
189            '*postcopy-vcpu-blocktime': ['uint32']} }
190
191 ##
192 # @query-migrate:
193 #
194 # Returns information about current migration process. If migration
195 # is active there will be another json-object with RAM migration
196 # status and if block migration is active another one with block
197 # migration status.
198 #
199 # Returns: @MigrationInfo
200 #
201 # Since: 0.14.0
202 #
203 # Example:
204 #
205 # 1. Before the first migration
206 #
207 # -> { "execute": "query-migrate" }
208 # <- { "return": {} }
209 #
210 # 2. Migration is done and has succeeded
211 #
212 # -> { "execute": "query-migrate" }
213 # <- { "return": {
214 #         "status": "completed",
215 #         "total-time":12345,
216 #         "setup-time":12345,
217 #         "downtime":12345,
218 #         "ram":{
219 #           "transferred":123,
220 #           "remaining":123,
221 #           "total":246,
222 #           "duplicate":123,
223 #           "normal":123,
224 #           "normal-bytes":123456,
225 #           "dirty-sync-count":15
226 #         }
227 #      }
228 #    }
229 #
230 # 3. Migration is done and has failed
231 #
232 # -> { "execute": "query-migrate" }
233 # <- { "return": { "status": "failed" } }
234 #
235 # 4. Migration is being performed and is not a block migration:
236 #
237 # -> { "execute": "query-migrate" }
238 # <- {
239 #       "return":{
240 #          "status":"active",
241 #          "total-time":12345,
242 #          "setup-time":12345,
243 #          "expected-downtime":12345,
244 #          "ram":{
245 #             "transferred":123,
246 #             "remaining":123,
247 #             "total":246,
248 #             "duplicate":123,
249 #             "normal":123,
250 #             "normal-bytes":123456,
251 #             "dirty-sync-count":15
252 #          }
253 #       }
254 #    }
255 #
256 # 5. Migration is being performed and is a block migration:
257 #
258 # -> { "execute": "query-migrate" }
259 # <- {
260 #       "return":{
261 #          "status":"active",
262 #          "total-time":12345,
263 #          "setup-time":12345,
264 #          "expected-downtime":12345,
265 #          "ram":{
266 #             "total":1057024,
267 #             "remaining":1053304,
268 #             "transferred":3720,
269 #             "duplicate":123,
270 #             "normal":123,
271 #             "normal-bytes":123456,
272 #             "dirty-sync-count":15
273 #          },
274 #          "disk":{
275 #             "total":20971520,
276 #             "remaining":20880384,
277 #             "transferred":91136
278 #          }
279 #       }
280 #    }
281 #
282 # 6. Migration is being performed and XBZRLE is active:
283 #
284 # -> { "execute": "query-migrate" }
285 # <- {
286 #       "return":{
287 #          "status":"active",
288 #          "total-time":12345,
289 #          "setup-time":12345,
290 #          "expected-downtime":12345,
291 #          "ram":{
292 #             "total":1057024,
293 #             "remaining":1053304,
294 #             "transferred":3720,
295 #             "duplicate":10,
296 #             "normal":3333,
297 #             "normal-bytes":3412992,
298 #             "dirty-sync-count":15
299 #          },
300 #          "xbzrle-cache":{
301 #             "cache-size":67108864,
302 #             "bytes":20971520,
303 #             "pages":2444343,
304 #             "cache-miss":2244,
305 #             "cache-miss-rate":0.123,
306 #             "overflow":34434
307 #          }
308 #       }
309 #    }
310 #
311 ##
312 { 'command': 'query-migrate', 'returns': 'MigrationInfo' }
313
314 ##
315 # @MigrationCapability:
316 #
317 # Migration capabilities enumeration
318 #
319 # @xbzrle: Migration supports xbzrle (Xor Based Zero Run Length Encoding).
320 #          This feature allows us to minimize migration traffic for certain work
321 #          loads, by sending compressed difference of the pages
322 #
323 # @rdma-pin-all: Controls whether or not the entire VM memory footprint is
324 #          mlock()'d on demand or all at once. Refer to docs/rdma.txt for usage.
325 #          Disabled by default. (since 2.0)
326 #
327 # @zero-blocks: During storage migration encode blocks of zeroes efficiently. This
328 #          essentially saves 1MB of zeroes per block on the wire. Enabling requires
329 #          source and target VM to support this feature. To enable it is sufficient
330 #          to enable the capability on the source VM. The feature is disabled by
331 #          default. (since 1.6)
332 #
333 # @compress: Use multiple compression threads to accelerate live migration.
334 #          This feature can help to reduce the migration traffic, by sending
335 #          compressed pages. Please note that if compress and xbzrle are both
336 #          on, compress only takes effect in the ram bulk stage, after that,
337 #          it will be disabled and only xbzrle takes effect, this can help to
338 #          minimize migration traffic. The feature is disabled by default.
339 #          (since 2.4 )
340 #
341 # @events: generate events for each migration state change
342 #          (since 2.4 )
343 #
344 # @auto-converge: If enabled, QEMU will automatically throttle down the guest
345 #          to speed up convergence of RAM migration. (since 1.6)
346 #
347 # @postcopy-ram: Start executing on the migration target before all of RAM has
348 #          been migrated, pulling the remaining pages along as needed. The
349 #          capacity must have the same setting on both source and target
350 #          or migration will not even start. NOTE: If the migration fails during
351 #          postcopy the VM will fail.  (since 2.6)
352 #
353 # @x-colo: If enabled, migration will never end, and the state of the VM on the
354 #        primary side will be migrated continuously to the VM on secondary
355 #        side, this process is called COarse-Grain LOck Stepping (COLO) for
356 #        Non-stop Service. (since 2.8)
357 #
358 # @release-ram: if enabled, qemu will free the migrated ram pages on the source
359 #        during postcopy-ram migration. (since 2.9)
360 #
361 # @block: If enabled, QEMU will also migrate the contents of all block
362 #          devices.  Default is disabled.  A possible alternative uses
363 #          mirror jobs to a builtin NBD server on the destination, which
364 #          offers more flexibility.
365 #          (Since 2.10)
366 #
367 # @return-path: If enabled, migration will use the return path even
368 #               for precopy. (since 2.10)
369 #
370 # @pause-before-switchover: Pause outgoing migration before serialising device
371 #          state and before disabling block IO (since 2.11)
372 #
373 # @x-multifd: Use more than one fd for migration (since 2.11)
374 #
375 # @dirty-bitmaps: If enabled, QEMU will migrate named dirty bitmaps.
376 #                 (since 2.12)
377 #
378 # @postcopy-blocktime: Calculate downtime for postcopy live migration
379 #                     (since 3.0)
380 #
381 # @late-block-activate: If enabled, the destination will not activate block
382 #           devices (and thus take locks) immediately at the end of migration.
383 #           (since 3.0)
384 #
385 # Since: 1.2
386 ##
387 { 'enum': 'MigrationCapability',
388   'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks',
389            'compress', 'events', 'postcopy-ram', 'x-colo', 'release-ram',
390            'block', 'return-path', 'pause-before-switchover', 'x-multifd',
391            'dirty-bitmaps', 'postcopy-blocktime', 'late-block-activate' ] }
392
393 ##
394 # @MigrationCapabilityStatus:
395 #
396 # Migration capability information
397 #
398 # @capability: capability enum
399 #
400 # @state: capability state bool
401 #
402 # Since: 1.2
403 ##
404 { 'struct': 'MigrationCapabilityStatus',
405   'data': { 'capability' : 'MigrationCapability', 'state' : 'bool' } }
406
407 ##
408 # @migrate-set-capabilities:
409 #
410 # Enable/Disable the following migration capabilities (like xbzrle)
411 #
412 # @capabilities: json array of capability modifications to make
413 #
414 # Since: 1.2
415 #
416 # Example:
417 #
418 # -> { "execute": "migrate-set-capabilities" , "arguments":
419 #      { "capabilities": [ { "capability": "xbzrle", "state": true } ] } }
420 #
421 ##
422 { 'command': 'migrate-set-capabilities',
423   'data': { 'capabilities': ['MigrationCapabilityStatus'] } }
424
425 ##
426 # @query-migrate-capabilities:
427 #
428 # Returns information about the current migration capabilities status
429 #
430 # Returns: @MigrationCapabilitiesStatus
431 #
432 # Since: 1.2
433 #
434 # Example:
435 #
436 # -> { "execute": "query-migrate-capabilities" }
437 # <- { "return": [
438 #       {"state": false, "capability": "xbzrle"},
439 #       {"state": false, "capability": "rdma-pin-all"},
440 #       {"state": false, "capability": "auto-converge"},
441 #       {"state": false, "capability": "zero-blocks"},
442 #       {"state": false, "capability": "compress"},
443 #       {"state": true, "capability": "events"},
444 #       {"state": false, "capability": "postcopy-ram"},
445 #       {"state": false, "capability": "x-colo"}
446 #    ]}
447 #
448 ##
449 { 'command': 'query-migrate-capabilities', 'returns':   ['MigrationCapabilityStatus']}
450
451 ##
452 # @MigrationParameter:
453 #
454 # Migration parameters enumeration
455 #
456 # @compress-level: Set the compression level to be used in live migration,
457 #          the compression level is an integer between 0 and 9, where 0 means
458 #          no compression, 1 means the best compression speed, and 9 means best
459 #          compression ratio which will consume more CPU.
460 #
461 # @compress-threads: Set compression thread count to be used in live migration,
462 #          the compression thread count is an integer between 1 and 255.
463 #
464 # @decompress-threads: Set decompression thread count to be used in live
465 #          migration, the decompression thread count is an integer between 1
466 #          and 255. Usually, decompression is at least 4 times as fast as
467 #          compression, so set the decompress-threads to the number about 1/4
468 #          of compress-threads is adequate.
469 #
470 # @cpu-throttle-initial: Initial percentage of time guest cpus are throttled
471 #                        when migration auto-converge is activated. The
472 #                        default value is 20. (Since 2.7)
473 #
474 # @cpu-throttle-increment: throttle percentage increase each time
475 #                          auto-converge detects that migration is not making
476 #                          progress. The default value is 10. (Since 2.7)
477 #
478 # @tls-creds: ID of the 'tls-creds' object that provides credentials for
479 #             establishing a TLS connection over the migration data channel.
480 #             On the outgoing side of the migration, the credentials must
481 #             be for a 'client' endpoint, while for the incoming side the
482 #             credentials must be for a 'server' endpoint. Setting this
483 #             will enable TLS for all migrations. The default is unset,
484 #             resulting in unsecured migration at the QEMU level. (Since 2.7)
485 #
486 # @tls-hostname: hostname of the target host for the migration. This is
487 #                required when using x509 based TLS credentials and the
488 #                migration URI does not already include a hostname. For
489 #                example if using fd: or exec: based migration, the
490 #                hostname must be provided so that the server's x509
491 #                certificate identity can be validated. (Since 2.7)
492 #
493 # @max-bandwidth: to set maximum speed for migration. maximum speed in
494 #                 bytes per second. (Since 2.8)
495 #
496 # @downtime-limit: set maximum tolerated downtime for migration. maximum
497 #                  downtime in milliseconds (Since 2.8)
498 #
499 # @x-checkpoint-delay: The delay time (in ms) between two COLO checkpoints in
500 #          periodic mode. (Since 2.8)
501 #
502 # @block-incremental: Affects how much storage is migrated when the
503 #       block migration capability is enabled.  When false, the entire
504 #       storage backing chain is migrated into a flattened image at
505 #       the destination; when true, only the active qcow2 layer is
506 #       migrated and the destination must already have access to the
507 #       same backing chain as was used on the source.  (since 2.10)
508 #
509 # @x-multifd-channels: Number of channels used to migrate data in
510 #                     parallel. This is the same number that the
511 #                     number of sockets used for migration.  The
512 #                     default value is 2 (since 2.11)
513 #
514 # @x-multifd-page-count: Number of pages sent together to a thread.
515 #                        The default value is 16 (since 2.11)
516 #
517 # @xbzrle-cache-size: cache size to be used by XBZRLE migration.  It
518 #                     needs to be a multiple of the target page size
519 #                     and a power of 2
520 #                     (Since 2.11)
521 #
522 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
523 #                     Defaults to 0 (unlimited).  In bytes per second.
524 #                     (Since 3.0)
525 # Since: 2.4
526 ##
527 { 'enum': 'MigrationParameter',
528   'data': ['compress-level', 'compress-threads', 'decompress-threads',
529            'cpu-throttle-initial', 'cpu-throttle-increment',
530            'tls-creds', 'tls-hostname', 'max-bandwidth',
531            'downtime-limit', 'x-checkpoint-delay', 'block-incremental',
532            'x-multifd-channels', 'x-multifd-page-count',
533            'xbzrle-cache-size', 'max-postcopy-bandwidth' ] }
534
535 ##
536 # @MigrateSetParameters:
537 #
538 # @compress-level: compression level
539 #
540 # @compress-threads: compression thread count
541 #
542 # @decompress-threads: decompression thread count
543 #
544 # @cpu-throttle-initial: Initial percentage of time guest cpus are
545 #                        throttled when migration auto-converge is activated.
546 #                        The default value is 20. (Since 2.7)
547 #
548 # @cpu-throttle-increment: throttle percentage increase each time
549 #                          auto-converge detects that migration is not making
550 #                          progress. The default value is 10. (Since 2.7)
551 #
552 # @tls-creds: ID of the 'tls-creds' object that provides credentials
553 #             for establishing a TLS connection over the migration data
554 #             channel. On the outgoing side of the migration, the credentials
555 #             must be for a 'client' endpoint, while for the incoming side the
556 #             credentials must be for a 'server' endpoint. Setting this
557 #             to a non-empty string enables TLS for all migrations.
558 #             An empty string means that QEMU will use plain text mode for
559 #             migration, rather than TLS (Since 2.9)
560 #             Previously (since 2.7), this was reported by omitting
561 #             tls-creds instead.
562 #
563 # @tls-hostname: hostname of the target host for the migration. This
564 #                is required when using x509 based TLS credentials and the
565 #                migration URI does not already include a hostname. For
566 #                example if using fd: or exec: based migration, the
567 #                hostname must be provided so that the server's x509
568 #                certificate identity can be validated. (Since 2.7)
569 #                An empty string means that QEMU will use the hostname
570 #                associated with the migration URI, if any. (Since 2.9)
571 #                Previously (since 2.7), this was reported by omitting
572 #                tls-hostname instead.
573 #
574 # @max-bandwidth: to set maximum speed for migration. maximum speed in
575 #                 bytes per second. (Since 2.8)
576 #
577 # @downtime-limit: set maximum tolerated downtime for migration. maximum
578 #                  downtime in milliseconds (Since 2.8)
579 #
580 # @x-checkpoint-delay: the delay time between two COLO checkpoints. (Since 2.8)
581 #
582 # @block-incremental: Affects how much storage is migrated when the
583 #       block migration capability is enabled.  When false, the entire
584 #       storage backing chain is migrated into a flattened image at
585 #       the destination; when true, only the active qcow2 layer is
586 #       migrated and the destination must already have access to the
587 #       same backing chain as was used on the source.  (since 2.10)
588 #
589 # @x-multifd-channels: Number of channels used to migrate data in
590 #                     parallel. This is the same number that the
591 #                     number of sockets used for migration.  The
592 #                     default value is 2 (since 2.11)
593 #
594 # @x-multifd-page-count: Number of pages sent together to a thread.
595 #                        The default value is 16 (since 2.11)
596 #
597 # @xbzrle-cache-size: cache size to be used by XBZRLE migration.  It
598 #                     needs to be a multiple of the target page size
599 #                     and a power of 2
600 #                     (Since 2.11)
601 #
602 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
603 #                     Defaults to 0 (unlimited).  In bytes per second.
604 #                     (Since 3.0)
605 # Since: 2.4
606 ##
607 # TODO either fuse back into MigrationParameters, or make
608 # MigrationParameters members mandatory
609 { 'struct': 'MigrateSetParameters',
610   'data': { '*compress-level': 'int',
611             '*compress-threads': 'int',
612             '*decompress-threads': 'int',
613             '*cpu-throttle-initial': 'int',
614             '*cpu-throttle-increment': 'int',
615             '*tls-creds': 'StrOrNull',
616             '*tls-hostname': 'StrOrNull',
617             '*max-bandwidth': 'int',
618             '*downtime-limit': 'int',
619             '*x-checkpoint-delay': 'int',
620             '*block-incremental': 'bool',
621             '*x-multifd-channels': 'int',
622             '*x-multifd-page-count': 'int',
623             '*xbzrle-cache-size': 'size',
624             '*max-postcopy-bandwidth': 'size' } }
625
626 ##
627 # @migrate-set-parameters:
628 #
629 # Set various migration parameters.
630 #
631 # Since: 2.4
632 #
633 # Example:
634 #
635 # -> { "execute": "migrate-set-parameters" ,
636 #      "arguments": { "compress-level": 1 } }
637 #
638 ##
639 { 'command': 'migrate-set-parameters', 'boxed': true,
640   'data': 'MigrateSetParameters' }
641
642 ##
643 # @MigrationParameters:
644 #
645 # The optional members aren't actually optional.
646 #
647 # @compress-level: compression level
648 #
649 # @compress-threads: compression thread count
650 #
651 # @decompress-threads: decompression thread count
652 #
653 # @cpu-throttle-initial: Initial percentage of time guest cpus are
654 #                        throttled when migration auto-converge is activated.
655 #                        (Since 2.7)
656 #
657 # @cpu-throttle-increment: throttle percentage increase each time
658 #                          auto-converge detects that migration is not making
659 #                          progress. (Since 2.7)
660 #
661 # @tls-creds: ID of the 'tls-creds' object that provides credentials
662 #             for establishing a TLS connection over the migration data
663 #             channel. On the outgoing side of the migration, the credentials
664 #             must be for a 'client' endpoint, while for the incoming side the
665 #             credentials must be for a 'server' endpoint.
666 #             An empty string means that QEMU will use plain text mode for
667 #             migration, rather than TLS (Since 2.7)
668 #             Note: 2.8 reports this by omitting tls-creds instead.
669 #
670 # @tls-hostname: hostname of the target host for the migration. This
671 #                is required when using x509 based TLS credentials and the
672 #                migration URI does not already include a hostname. For
673 #                example if using fd: or exec: based migration, the
674 #                hostname must be provided so that the server's x509
675 #                certificate identity can be validated. (Since 2.7)
676 #                An empty string means that QEMU will use the hostname
677 #                associated with the migration URI, if any. (Since 2.9)
678 #                Note: 2.8 reports this by omitting tls-hostname instead.
679 #
680 # @max-bandwidth: to set maximum speed for migration. maximum speed in
681 #                 bytes per second. (Since 2.8)
682 #
683 # @downtime-limit: set maximum tolerated downtime for migration. maximum
684 #                  downtime in milliseconds (Since 2.8)
685 #
686 # @x-checkpoint-delay: the delay time between two COLO checkpoints. (Since 2.8)
687 #
688 # @block-incremental: Affects how much storage is migrated when the
689 #       block migration capability is enabled.  When false, the entire
690 #       storage backing chain is migrated into a flattened image at
691 #       the destination; when true, only the active qcow2 layer is
692 #       migrated and the destination must already have access to the
693 #       same backing chain as was used on the source.  (since 2.10)
694 #
695 # @x-multifd-channels: Number of channels used to migrate data in
696 #                     parallel. This is the same number that the
697 #                     number of sockets used for migration.
698 #                     The default value is 2 (since 2.11)
699 #
700 # @x-multifd-page-count: Number of pages sent together to a thread.
701 #                        The default value is 16 (since 2.11)
702 #
703 # @xbzrle-cache-size: cache size to be used by XBZRLE migration.  It
704 #                     needs to be a multiple of the target page size
705 #                     and a power of 2
706 #                     (Since 2.11)
707 #
708 # @max-postcopy-bandwidth: Background transfer bandwidth during postcopy.
709 #                     Defaults to 0 (unlimited).  In bytes per second.
710 #                     (Since 3.0)
711 # Since: 2.4
712 ##
713 { 'struct': 'MigrationParameters',
714   'data': { '*compress-level': 'uint8',
715             '*compress-threads': 'uint8',
716             '*decompress-threads': 'uint8',
717             '*cpu-throttle-initial': 'uint8',
718             '*cpu-throttle-increment': 'uint8',
719             '*tls-creds': 'str',
720             '*tls-hostname': 'str',
721             '*max-bandwidth': 'size',
722             '*downtime-limit': 'uint64',
723             '*x-checkpoint-delay': 'uint32',
724             '*block-incremental': 'bool' ,
725             '*x-multifd-channels': 'uint8',
726             '*x-multifd-page-count': 'uint32',
727             '*xbzrle-cache-size': 'size',
728             '*max-postcopy-bandwidth': 'size'  } }
729
730 ##
731 # @query-migrate-parameters:
732 #
733 # Returns information about the current migration parameters
734 #
735 # Returns: @MigrationParameters
736 #
737 # Since: 2.4
738 #
739 # Example:
740 #
741 # -> { "execute": "query-migrate-parameters" }
742 # <- { "return": {
743 #          "decompress-threads": 2,
744 #          "cpu-throttle-increment": 10,
745 #          "compress-threads": 8,
746 #          "compress-level": 1,
747 #          "cpu-throttle-initial": 20,
748 #          "max-bandwidth": 33554432,
749 #          "downtime-limit": 300
750 #       }
751 #    }
752 #
753 ##
754 { 'command': 'query-migrate-parameters',
755   'returns': 'MigrationParameters' }
756
757 ##
758 # @client_migrate_info:
759 #
760 # Set migration information for remote display.  This makes the server
761 # ask the client to automatically reconnect using the new parameters
762 # once migration finished successfully.  Only implemented for SPICE.
763 #
764 # @protocol:     must be "spice"
765 # @hostname:     migration target hostname
766 # @port:         spice tcp port for plaintext channels
767 # @tls-port:     spice tcp port for tls-secured channels
768 # @cert-subject: server certificate subject
769 #
770 # Since: 0.14.0
771 #
772 # Example:
773 #
774 # -> { "execute": "client_migrate_info",
775 #      "arguments": { "protocol": "spice",
776 #                     "hostname": "virt42.lab.kraxel.org",
777 #                     "port": 1234 } }
778 # <- { "return": {} }
779 #
780 ##
781 { 'command': 'client_migrate_info',
782   'data': { 'protocol': 'str', 'hostname': 'str', '*port': 'int',
783             '*tls-port': 'int', '*cert-subject': 'str' } }
784
785 ##
786 # @migrate-start-postcopy:
787 #
788 # Followup to a migration command to switch the migration to postcopy mode.
789 # The postcopy-ram capability must be set on both source and destination
790 # before the original migration command.
791 #
792 # Since: 2.5
793 #
794 # Example:
795 #
796 # -> { "execute": "migrate-start-postcopy" }
797 # <- { "return": {} }
798 #
799 ##
800 { 'command': 'migrate-start-postcopy' }
801
802 ##
803 # @MIGRATION:
804 #
805 # Emitted when a migration event happens
806 #
807 # @status: @MigrationStatus describing the current migration status.
808 #
809 # Since: 2.4
810 #
811 # Example:
812 #
813 # <- {"timestamp": {"seconds": 1432121972, "microseconds": 744001},
814 #     "event": "MIGRATION",
815 #     "data": {"status": "completed"} }
816 #
817 ##
818 { 'event': 'MIGRATION',
819   'data': {'status': 'MigrationStatus'}}
820
821 ##
822 # @MIGRATION_PASS:
823 #
824 # Emitted from the source side of a migration at the start of each pass
825 # (when it syncs the dirty bitmap)
826 #
827 # @pass: An incrementing count (starting at 1 on the first pass)
828 #
829 # Since: 2.6
830 #
831 # Example:
832 #
833 # { "timestamp": {"seconds": 1449669631, "microseconds": 239225},
834 #   "event": "MIGRATION_PASS", "data": {"pass": 2} }
835 #
836 ##
837 { 'event': 'MIGRATION_PASS',
838   'data': { 'pass': 'int' } }
839
840 ##
841 # @COLOMessage:
842 #
843 # The message transmission between Primary side and Secondary side.
844 #
845 # @checkpoint-ready: Secondary VM (SVM) is ready for checkpointing
846 #
847 # @checkpoint-request: Primary VM (PVM) tells SVM to prepare for checkpointing
848 #
849 # @checkpoint-reply: SVM gets PVM's checkpoint request
850 #
851 # @vmstate-send: VM's state will be sent by PVM.
852 #
853 # @vmstate-size: The total size of VMstate.
854 #
855 # @vmstate-received: VM's state has been received by SVM.
856 #
857 # @vmstate-loaded: VM's state has been loaded by SVM.
858 #
859 # Since: 2.8
860 ##
861 { 'enum': 'COLOMessage',
862   'data': [ 'checkpoint-ready', 'checkpoint-request', 'checkpoint-reply',
863             'vmstate-send', 'vmstate-size', 'vmstate-received',
864             'vmstate-loaded' ] }
865
866 ##
867 # @COLOMode:
868 #
869 # The colo mode
870 #
871 # @unknown: unknown mode
872 #
873 # @primary: master side
874 #
875 # @secondary: slave side
876 #
877 # Since: 2.8
878 ##
879 { 'enum': 'COLOMode',
880   'data': [ 'unknown', 'primary', 'secondary'] }
881
882 ##
883 # @FailoverStatus:
884 #
885 # An enumeration of COLO failover status
886 #
887 # @none: no failover has ever happened
888 #
889 # @require: got failover requirement but not handled
890 #
891 # @active: in the process of doing failover
892 #
893 # @completed: finish the process of failover
894 #
895 # @relaunch: restart the failover process, from 'none' -> 'completed' (Since 2.9)
896 #
897 # Since: 2.8
898 ##
899 { 'enum': 'FailoverStatus',
900   'data': [ 'none', 'require', 'active', 'completed', 'relaunch' ] }
901
902 ##
903 # @x-colo-lost-heartbeat:
904 #
905 # Tell qemu that heartbeat is lost, request it to do takeover procedures.
906 # If this command is sent to the PVM, the Primary side will exit COLO mode.
907 # If sent to the Secondary, the Secondary side will run failover work,
908 # then takes over server operation to become the service VM.
909 #
910 # Since: 2.8
911 #
912 # Example:
913 #
914 # -> { "execute": "x-colo-lost-heartbeat" }
915 # <- { "return": {} }
916 #
917 ##
918 { 'command': 'x-colo-lost-heartbeat' }
919
920 ##
921 # @migrate_cancel:
922 #
923 # Cancel the current executing migration process.
924 #
925 # Returns: nothing on success
926 #
927 # Notes: This command succeeds even if there is no migration process running.
928 #
929 # Since: 0.14.0
930 #
931 # Example:
932 #
933 # -> { "execute": "migrate_cancel" }
934 # <- { "return": {} }
935 #
936 ##
937 { 'command': 'migrate_cancel' }
938
939 ##
940 # @migrate-continue:
941 #
942 # Continue migration when it's in a paused state.
943 #
944 # @state: The state the migration is currently expected to be in
945 #
946 # Returns: nothing on success
947 # Since: 2.11
948 # Example:
949 #
950 # -> { "execute": "migrate-continue" , "arguments":
951 #      { "state": "pre-switchover" } }
952 # <- { "return": {} }
953 ##
954 { 'command': 'migrate-continue', 'data': {'state': 'MigrationStatus'} }
955
956 ##
957 # @migrate_set_downtime:
958 #
959 # Set maximum tolerated downtime for migration.
960 #
961 # @value: maximum downtime in seconds
962 #
963 # Returns: nothing on success
964 #
965 # Notes: This command is deprecated in favor of 'migrate-set-parameters'
966 #
967 # Since: 0.14.0
968 #
969 # Example:
970 #
971 # -> { "execute": "migrate_set_downtime", "arguments": { "value": 0.1 } }
972 # <- { "return": {} }
973 #
974 ##
975 { 'command': 'migrate_set_downtime', 'data': {'value': 'number'} }
976
977 ##
978 # @migrate_set_speed:
979 #
980 # Set maximum speed for migration.
981 #
982 # @value: maximum speed in bytes per second.
983 #
984 # Returns: nothing on success
985 #
986 # Notes: This command is deprecated in favor of 'migrate-set-parameters'
987 #
988 # Since: 0.14.0
989 #
990 # Example:
991 #
992 # -> { "execute": "migrate_set_speed", "arguments": { "value": 1024 } }
993 # <- { "return": {} }
994 #
995 ##
996 { 'command': 'migrate_set_speed', 'data': {'value': 'int'} }
997
998 ##
999 # @migrate-set-cache-size:
1000 #
1001 # Set cache size to be used by XBZRLE migration
1002 #
1003 # @value: cache size in bytes
1004 #
1005 # The size will be rounded down to the nearest power of 2.
1006 # The cache size can be modified before and during ongoing migration
1007 #
1008 # Returns: nothing on success
1009 #
1010 # Notes: This command is deprecated in favor of 'migrate-set-parameters'
1011 #
1012 # Since: 1.2
1013 #
1014 # Example:
1015 #
1016 # -> { "execute": "migrate-set-cache-size",
1017 #      "arguments": { "value": 536870912 } }
1018 # <- { "return": {} }
1019 #
1020 ##
1021 { 'command': 'migrate-set-cache-size', 'data': {'value': 'int'} }
1022
1023 ##
1024 # @query-migrate-cache-size:
1025 #
1026 # Query migration XBZRLE cache size
1027 #
1028 # Returns: XBZRLE cache size in bytes
1029 #
1030 # Notes: This command is deprecated in favor of 'query-migrate-parameters'
1031 #
1032 # Since: 1.2
1033 #
1034 # Example:
1035 #
1036 # -> { "execute": "query-migrate-cache-size" }
1037 # <- { "return": 67108864 }
1038 #
1039 ##
1040 { 'command': 'query-migrate-cache-size', 'returns': 'int' }
1041
1042 ##
1043 # @migrate:
1044 #
1045 # Migrates the current running guest to another Virtual Machine.
1046 #
1047 # @uri: the Uniform Resource Identifier of the destination VM
1048 #
1049 # @blk: do block migration (full disk copy)
1050 #
1051 # @inc: incremental disk copy migration
1052 #
1053 # @detach: this argument exists only for compatibility reasons and
1054 #          is ignored by QEMU
1055 #
1056 # @resume: resume one paused migration, default "off". (since 3.0)
1057 #
1058 # Returns: nothing on success
1059 #
1060 # Since: 0.14.0
1061 #
1062 # Notes:
1063 #
1064 # 1. The 'query-migrate' command should be used to check migration's progress
1065 #    and final result (this information is provided by the 'status' member)
1066 #
1067 # 2. All boolean arguments default to false
1068 #
1069 # 3. The user Monitor's "detach" argument is invalid in QMP and should not
1070 #    be used
1071 #
1072 # Example:
1073 #
1074 # -> { "execute": "migrate", "arguments": { "uri": "tcp:0:4446" } }
1075 # <- { "return": {} }
1076 #
1077 ##
1078 { 'command': 'migrate',
1079   'data': {'uri': 'str', '*blk': 'bool', '*inc': 'bool',
1080            '*detach': 'bool', '*resume': 'bool' } }
1081
1082 ##
1083 # @migrate-incoming:
1084 #
1085 # Start an incoming migration, the qemu must have been started
1086 # with -incoming defer
1087 #
1088 # @uri: The Uniform Resource Identifier identifying the source or
1089 #       address to listen on
1090 #
1091 # Returns: nothing on success
1092 #
1093 # Since: 2.3
1094 #
1095 # Notes:
1096 #
1097 # 1. It's a bad idea to use a string for the uri, but it needs to stay
1098 #    compatible with -incoming and the format of the uri is already exposed
1099 #    above libvirt.
1100 #
1101 # 2. QEMU must be started with -incoming defer to allow migrate-incoming to
1102 #    be used.
1103 #
1104 # 3. The uri format is the same as for -incoming
1105 #
1106 # Example:
1107 #
1108 # -> { "execute": "migrate-incoming",
1109 #      "arguments": { "uri": "tcp::4446" } }
1110 # <- { "return": {} }
1111 #
1112 ##
1113 { 'command': 'migrate-incoming', 'data': {'uri': 'str' } }
1114
1115 ##
1116 # @xen-save-devices-state:
1117 #
1118 # Save the state of all devices to file. The RAM and the block devices
1119 # of the VM are not saved by this command.
1120 #
1121 # @filename: the file to save the state of the devices to as binary
1122 # data. See xen-save-devices-state.txt for a description of the binary
1123 # format.
1124 #
1125 # @live: Optional argument to ask QEMU to treat this command as part of a live
1126 # migration. Default to true. (since 2.11)
1127 #
1128 # Returns: Nothing on success
1129 #
1130 # Since: 1.1
1131 #
1132 # Example:
1133 #
1134 # -> { "execute": "xen-save-devices-state",
1135 #      "arguments": { "filename": "/tmp/save" } }
1136 # <- { "return": {} }
1137 #
1138 ##
1139 { 'command': 'xen-save-devices-state',
1140   'data': {'filename': 'str', '*live':'bool' } }
1141
1142 ##
1143 # @xen-set-replication:
1144 #
1145 # Enable or disable replication.
1146 #
1147 # @enable: true to enable, false to disable.
1148 #
1149 # @primary: true for primary or false for secondary.
1150 #
1151 # @failover: true to do failover, false to stop. but cannot be
1152 #            specified if 'enable' is true. default value is false.
1153 #
1154 # Returns: nothing.
1155 #
1156 # Example:
1157 #
1158 # -> { "execute": "xen-set-replication",
1159 #      "arguments": {"enable": true, "primary": false} }
1160 # <- { "return": {} }
1161 #
1162 # Since: 2.9
1163 ##
1164 { 'command': 'xen-set-replication',
1165   'data': { 'enable': 'bool', 'primary': 'bool', '*failover' : 'bool' } }
1166
1167 ##
1168 # @ReplicationStatus:
1169 #
1170 # The result format for 'query-xen-replication-status'.
1171 #
1172 # @error: true if an error happened, false if replication is normal.
1173 #
1174 # @desc: the human readable error description string, when
1175 #        @error is 'true'.
1176 #
1177 # Since: 2.9
1178 ##
1179 { 'struct': 'ReplicationStatus',
1180   'data': { 'error': 'bool', '*desc': 'str' } }
1181
1182 ##
1183 # @query-xen-replication-status:
1184 #
1185 # Query replication status while the vm is running.
1186 #
1187 # Returns: A @ReplicationResult object showing the status.
1188 #
1189 # Example:
1190 #
1191 # -> { "execute": "query-xen-replication-status" }
1192 # <- { "return": { "error": false } }
1193 #
1194 # Since: 2.9
1195 ##
1196 { 'command': 'query-xen-replication-status',
1197   'returns': 'ReplicationStatus' }
1198
1199 ##
1200 # @xen-colo-do-checkpoint:
1201 #
1202 # Xen uses this command to notify replication to trigger a checkpoint.
1203 #
1204 # Returns: nothing.
1205 #
1206 # Example:
1207 #
1208 # -> { "execute": "xen-colo-do-checkpoint" }
1209 # <- { "return": {} }
1210 #
1211 # Since: 2.9
1212 ##
1213 { 'command': 'xen-colo-do-checkpoint' }
1214
1215 ##
1216 # @migrate-recover:
1217 #
1218 # Provide a recovery migration stream URI.
1219 #
1220 # @uri: the URI to be used for the recovery of migration stream.
1221 #
1222 # Returns: nothing.
1223 #
1224 # Example:
1225 #
1226 # -> { "execute": "migrate-recover",
1227 #      "arguments": { "uri": "tcp:192.168.1.200:12345" } }
1228 # <- { "return": {} }
1229 #
1230 # Since: 3.0
1231 ##
1232 { 'command': 'migrate-recover', 'data': { 'uri': 'str' },
1233   'allow-oob': true }
1234
1235 ##
1236 # @migrate-pause:
1237 #
1238 # Pause a migration.  Currently it only supports postcopy.
1239 #
1240 # Returns: nothing.
1241 #
1242 # Example:
1243 #
1244 # -> { "execute": "migrate-pause" }
1245 # <- { "return": {} }
1246 #
1247 # Since: 3.0
1248 ##
1249 { 'command': 'migrate-pause', 'allow-oob': true }
This page took 0.092626 seconds and 4 git commands to generate.