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