xen: record physmap changes to xenstore
[qemu/ar7.git] / qmp-commands.hx
blobdbb623677c8767c28e5414592f2c26c0d95f7990
1 HXCOMM QMP dispatch table and documentation
2 HXCOMM Text between SQMP and EQMP is copied to the QMP documention file and
3 HXCOMM does not show up in the other formats.
5 SQMP
6 QMP Supported Commands
7 ----------------------
9 This document describes all commands currently supported by QMP.
11 Most of the time their usage is exactly the same as in the user Monitor, this
12 means that any other document which also describe commands (the manpage,
13 QEMU's manual, etc) can and should be consulted.
15 QMP has two types of commands: regular and query commands. Regular commands
16 usually change the Virtual Machine's state someway, while query commands just
17 return information. The sections below are divided accordingly.
19 It's important to observe that all communication examples are formatted in
20 a reader-friendly way, so that they're easier to understand. However, in real
21 protocol usage, they're emitted as a single line.
23 Also, the following notation is used to denote data flow:
25 -> data issued by the Client
26 <- Server data response
28 Please, refer to the QMP specification (QMP/qmp-spec.txt) for detailed
29 information on the Server command and response formats.
31 NOTE: This document is temporary and will be replaced soon.
33 1. Stability Considerations
34 ===========================
36 The current QMP command set (described in this file) may be useful for a
37 number of use cases, however it's limited and several commands have bad
38 defined semantics, specially with regard to command completion.
40 These problems are going to be solved incrementally in the next QEMU releases
41 and we're going to establish a deprecation policy for badly defined commands.
43 If you're planning to adopt QMP, please observe the following:
45 1. The deprecation policy will take effect and be documented soon, please
46 check the documentation of each used command as soon as a new release of
47 QEMU is available
49 2. DO NOT rely on anything which is not explicit documented
51 3. Errors, in special, are not documented. Applications should NOT check
52 for specific errors classes or data (it's strongly recommended to only
53 check for the "error" key)
55 2. Regular Commands
56 ===================
58 Server's responses in the examples below are always a success response, please
59 refer to the QMP specification for more details on error responses.
61 EQMP
64 .name = "quit",
65 .args_type = "",
66 .mhandler.cmd_new = qmp_marshal_input_quit,
69 SQMP
70 quit
71 ----
73 Quit the emulator.
75 Arguments: None.
77 Example:
79 -> { "execute": "quit" }
80 <- { "return": {} }
82 EQMP
85 .name = "eject",
86 .args_type = "force:-f,device:B",
87 .mhandler.cmd_new = qmp_marshal_input_eject,
90 SQMP
91 eject
92 -----
94 Eject a removable medium.
96 Arguments:
98 - force: force ejection (json-bool, optional)
99 - device: device name (json-string)
101 Example:
103 -> { "execute": "eject", "arguments": { "device": "ide1-cd0" } }
104 <- { "return": {} }
106 Note: The "force" argument defaults to false.
108 EQMP
111 .name = "change",
112 .args_type = "device:B,target:F,arg:s?",
113 .mhandler.cmd_new = qmp_marshal_input_change,
116 SQMP
117 change
118 ------
120 Change a removable medium or VNC configuration.
122 Arguments:
124 - "device": device name (json-string)
125 - "target": filename or item (json-string)
126 - "arg": additional argument (json-string, optional)
128 Examples:
130 1. Change a removable medium
132 -> { "execute": "change",
133 "arguments": { "device": "ide1-cd0",
134 "target": "/srv/images/Fedora-12-x86_64-DVD.iso" } }
135 <- { "return": {} }
137 2. Change VNC password
139 -> { "execute": "change",
140 "arguments": { "device": "vnc", "target": "password",
141 "arg": "foobar1" } }
142 <- { "return": {} }
144 EQMP
147 .name = "screendump",
148 .args_type = "filename:F",
149 .params = "filename",
150 .help = "save screen into PPM image 'filename'",
151 .user_print = monitor_user_noop,
152 .mhandler.cmd_new = do_screen_dump,
155 SQMP
156 screendump
157 ----------
159 Save screen into PPM image.
161 Arguments:
163 - "filename": file path (json-string)
165 Example:
167 -> { "execute": "screendump", "arguments": { "filename": "/tmp/image" } }
168 <- { "return": {} }
170 EQMP
173 .name = "stop",
174 .args_type = "",
175 .mhandler.cmd_new = qmp_marshal_input_stop,
178 SQMP
179 stop
180 ----
182 Stop the emulator.
184 Arguments: None.
186 Example:
188 -> { "execute": "stop" }
189 <- { "return": {} }
191 EQMP
194 .name = "cont",
195 .args_type = "",
196 .mhandler.cmd_new = qmp_marshal_input_cont,
199 SQMP
200 cont
201 ----
203 Resume emulation.
205 Arguments: None.
207 Example:
209 -> { "execute": "cont" }
210 <- { "return": {} }
212 EQMP
215 .name = "system_wakeup",
216 .args_type = "",
217 .mhandler.cmd_new = qmp_marshal_input_system_wakeup,
220 SQMP
221 system_wakeup
222 -------------
224 Wakeup guest from suspend.
226 Arguments: None.
228 Example:
230 -> { "execute": "system_wakeup" }
231 <- { "return": {} }
233 EQMP
236 .name = "system_reset",
237 .args_type = "",
238 .mhandler.cmd_new = qmp_marshal_input_system_reset,
241 SQMP
242 system_reset
243 ------------
245 Reset the system.
247 Arguments: None.
249 Example:
251 -> { "execute": "system_reset" }
252 <- { "return": {} }
254 EQMP
257 .name = "system_powerdown",
258 .args_type = "",
259 .mhandler.cmd_new = qmp_marshal_input_system_powerdown,
262 SQMP
263 system_powerdown
264 ----------------
266 Send system power down event.
268 Arguments: None.
270 Example:
272 -> { "execute": "system_powerdown" }
273 <- { "return": {} }
275 EQMP
278 .name = "device_add",
279 .args_type = "device:O",
280 .params = "driver[,prop=value][,...]",
281 .help = "add device, like -device on the command line",
282 .user_print = monitor_user_noop,
283 .mhandler.cmd_new = do_device_add,
286 SQMP
287 device_add
288 ----------
290 Add a device.
292 Arguments:
294 - "driver": the name of the new device's driver (json-string)
295 - "bus": the device's parent bus (device tree path, json-string, optional)
296 - "id": the device's ID, must be unique (json-string)
297 - device properties
299 Example:
301 -> { "execute": "device_add", "arguments": { "driver": "e1000", "id": "net1" } }
302 <- { "return": {} }
304 Notes:
306 (1) For detailed information about this command, please refer to the
307 'docs/qdev-device-use.txt' file.
309 (2) It's possible to list device properties by running QEMU with the
310 "-device DEVICE,\?" command-line argument, where DEVICE is the device's name
312 EQMP
315 .name = "device_del",
316 .args_type = "id:s",
317 .params = "device",
318 .help = "remove device",
319 .user_print = monitor_user_noop,
320 .mhandler.cmd_new = do_device_del,
323 SQMP
324 device_del
325 ----------
327 Remove a device.
329 Arguments:
331 - "id": the device's ID (json-string)
333 Example:
335 -> { "execute": "device_del", "arguments": { "id": "net1" } }
336 <- { "return": {} }
338 EQMP
341 .name = "cpu",
342 .args_type = "index:i",
343 .mhandler.cmd_new = qmp_marshal_input_cpu,
346 SQMP
350 Set the default CPU.
352 Arguments:
354 - "index": the CPU's index (json-int)
356 Example:
358 -> { "execute": "cpu", "arguments": { "index": 0 } }
359 <- { "return": {} }
361 Note: CPUs' indexes are obtained with the 'query-cpus' command.
363 EQMP
366 .name = "memsave",
367 .args_type = "val:l,size:i,filename:s,cpu:i?",
368 .mhandler.cmd_new = qmp_marshal_input_memsave,
371 SQMP
372 memsave
373 -------
375 Save to disk virtual memory dump starting at 'val' of size 'size'.
377 Arguments:
379 - "val": the starting address (json-int)
380 - "size": the memory size, in bytes (json-int)
381 - "filename": file path (json-string)
382 - "cpu": virtual CPU index (json-int, optional)
384 Example:
386 -> { "execute": "memsave",
387 "arguments": { "val": 10,
388 "size": 100,
389 "filename": "/tmp/virtual-mem-dump" } }
390 <- { "return": {} }
392 EQMP
395 .name = "pmemsave",
396 .args_type = "val:l,size:i,filename:s",
397 .mhandler.cmd_new = qmp_marshal_input_pmemsave,
400 SQMP
401 pmemsave
402 --------
404 Save to disk physical memory dump starting at 'val' of size 'size'.
406 Arguments:
408 - "val": the starting address (json-int)
409 - "size": the memory size, in bytes (json-int)
410 - "filename": file path (json-string)
412 Example:
414 -> { "execute": "pmemsave",
415 "arguments": { "val": 10,
416 "size": 100,
417 "filename": "/tmp/physical-mem-dump" } }
418 <- { "return": {} }
420 EQMP
423 .name = "inject-nmi",
424 .args_type = "",
425 .mhandler.cmd_new = qmp_marshal_input_inject_nmi,
428 SQMP
429 inject-nmi
430 ----------
432 Inject an NMI on guest's CPUs.
434 Arguments: None.
436 Example:
438 -> { "execute": "inject-nmi" }
439 <- { "return": {} }
441 Note: inject-nmi is only supported for x86 guest currently, it will
442 returns "Unsupported" error for non-x86 guest.
444 EQMP
447 .name = "xen-save-devices-state",
448 .args_type = "filename:F",
449 .mhandler.cmd_new = qmp_marshal_input_xen_save_devices_state,
452 SQMP
453 xen-save-devices-state
454 -------
456 Save the state of all devices to file. The RAM and the block devices
457 of the VM are not saved by this command.
459 Arguments:
461 - "filename": the file to save the state of the devices to as binary
462 data. See xen-save-devices-state.txt for a description of the binary
463 format.
465 Example:
467 -> { "execute": "xen-save-devices-state",
468 "arguments": { "filename": "/tmp/save" } }
469 <- { "return": {} }
471 EQMP
474 .name = "migrate",
475 .args_type = "detach:-d,blk:-b,inc:-i,uri:s",
476 .params = "[-d] [-b] [-i] uri",
477 .help = "migrate to URI (using -d to not wait for completion)"
478 "\n\t\t\t -b for migration without shared storage with"
479 " full copy of disk\n\t\t\t -i for migration without "
480 "shared storage with incremental copy of disk "
481 "(base image shared between src and destination)",
482 .user_print = monitor_user_noop,
483 .mhandler.cmd_new = do_migrate,
486 SQMP
487 migrate
488 -------
490 Migrate to URI.
492 Arguments:
494 - "blk": block migration, full disk copy (json-bool, optional)
495 - "inc": incremental disk copy (json-bool, optional)
496 - "uri": Destination URI (json-string)
498 Example:
500 -> { "execute": "migrate", "arguments": { "uri": "tcp:0:4446" } }
501 <- { "return": {} }
503 Notes:
505 (1) The 'query-migrate' command should be used to check migration's progress
506 and final result (this information is provided by the 'status' member)
507 (2) All boolean arguments default to false
508 (3) The user Monitor's "detach" argument is invalid in QMP and should not
509 be used
511 EQMP
514 .name = "migrate_cancel",
515 .args_type = "",
516 .mhandler.cmd_new = qmp_marshal_input_migrate_cancel,
519 SQMP
520 migrate_cancel
521 --------------
523 Cancel the current migration.
525 Arguments: None.
527 Example:
529 -> { "execute": "migrate_cancel" }
530 <- { "return": {} }
532 EQMP
535 .name = "migrate_set_speed",
536 .args_type = "value:o",
537 .mhandler.cmd_new = qmp_marshal_input_migrate_set_speed,
540 SQMP
541 migrate_set_speed
542 -----------------
544 Set maximum speed for migrations.
546 Arguments:
548 - "value": maximum speed, in bytes per second (json-int)
550 Example:
552 -> { "execute": "migrate_set_speed", "arguments": { "value": 1024 } }
553 <- { "return": {} }
555 EQMP
558 .name = "migrate_set_downtime",
559 .args_type = "value:T",
560 .mhandler.cmd_new = qmp_marshal_input_migrate_set_downtime,
563 SQMP
564 migrate_set_downtime
565 --------------------
567 Set maximum tolerated downtime (in seconds) for migrations.
569 Arguments:
571 - "value": maximum downtime (json-number)
573 Example:
575 -> { "execute": "migrate_set_downtime", "arguments": { "value": 0.1 } }
576 <- { "return": {} }
578 EQMP
581 .name = "client_migrate_info",
582 .args_type = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?",
583 .params = "protocol hostname port tls-port cert-subject",
584 .help = "send migration info to spice/vnc client",
585 .user_print = monitor_user_noop,
586 .mhandler.cmd_async = client_migrate_info,
587 .flags = MONITOR_CMD_ASYNC,
590 SQMP
591 client_migrate_info
592 ------------------
594 Set the spice/vnc connection info for the migration target. The spice/vnc
595 server will ask the spice/vnc client to automatically reconnect using the
596 new parameters (if specified) once the vm migration finished successfully.
598 Arguments:
600 - "protocol": protocol: "spice" or "vnc" (json-string)
601 - "hostname": migration target hostname (json-string)
602 - "port": spice/vnc tcp port for plaintext channels (json-int, optional)
603 - "tls-port": spice tcp port for tls-secured channels (json-int, optional)
604 - "cert-subject": server certificate subject (json-string, optional)
606 Example:
608 -> { "execute": "client_migrate_info",
609 "arguments": { "protocol": "spice",
610 "hostname": "virt42.lab.kraxel.org",
611 "port": 1234 } }
612 <- { "return": {} }
614 EQMP
617 .name = "netdev_add",
618 .args_type = "netdev:O",
619 .params = "[user|tap|socket],id=str[,prop=value][,...]",
620 .help = "add host network device",
621 .user_print = monitor_user_noop,
622 .mhandler.cmd_new = do_netdev_add,
625 SQMP
626 netdev_add
627 ----------
629 Add host network device.
631 Arguments:
633 - "type": the device type, "tap", "user", ... (json-string)
634 - "id": the device's ID, must be unique (json-string)
635 - device options
637 Example:
639 -> { "execute": "netdev_add", "arguments": { "type": "user", "id": "netdev1" } }
640 <- { "return": {} }
642 Note: The supported device options are the same ones supported by the '-net'
643 command-line argument, which are listed in the '-help' output or QEMU's
644 manual
646 EQMP
649 .name = "netdev_del",
650 .args_type = "id:s",
651 .params = "id",
652 .help = "remove host network device",
653 .user_print = monitor_user_noop,
654 .mhandler.cmd_new = do_netdev_del,
657 SQMP
658 netdev_del
659 ----------
661 Remove host network device.
663 Arguments:
665 - "id": the device's ID, must be unique (json-string)
667 Example:
669 -> { "execute": "netdev_del", "arguments": { "id": "netdev1" } }
670 <- { "return": {} }
673 EQMP
676 .name = "block_resize",
677 .args_type = "device:B,size:o",
678 .mhandler.cmd_new = qmp_marshal_input_block_resize,
681 SQMP
682 block_resize
683 ------------
685 Resize a block image while a guest is running.
687 Arguments:
689 - "device": the device's ID, must be unique (json-string)
690 - "size": new size
692 Example:
694 -> { "execute": "block_resize", "arguments": { "device": "scratch", "size": 1073741824 } }
695 <- { "return": {} }
697 EQMP
700 .name = "block_stream",
701 .args_type = "device:B,base:s?",
702 .mhandler.cmd_new = qmp_marshal_input_block_stream,
706 .name = "block_job_set_speed",
707 .args_type = "device:B,value:o",
708 .mhandler.cmd_new = qmp_marshal_input_block_job_set_speed,
712 .name = "block_job_cancel",
713 .args_type = "device:B",
714 .mhandler.cmd_new = qmp_marshal_input_block_job_cancel,
718 .name = "blockdev-snapshot-sync",
719 .args_type = "device:B,snapshot-file:s,format:s?",
720 .mhandler.cmd_new = qmp_marshal_input_blockdev_snapshot_sync,
723 SQMP
724 blockdev-snapshot-sync
725 ----------------------
727 Synchronous snapshot of a block device. snapshot-file specifies the
728 target of the new image. If the file exists, or if it is a device, the
729 snapshot will be created in the existing file/device. If does not
730 exist, a new file will be created. format specifies the format of the
731 snapshot image, default is qcow2.
733 Arguments:
735 - "device": device name to snapshot (json-string)
736 - "snapshot-file": name of new image file (json-string)
737 - "format": format of new image (json-string, optional)
739 Example:
741 -> { "execute": "blockdev-snapshot-sync", "arguments": { "device": "ide-hd0",
742 "snapshot-file":
743 "/some/place/my-image",
744 "format": "qcow2" } }
745 <- { "return": {} }
747 EQMP
750 .name = "balloon",
751 .args_type = "value:M",
752 .mhandler.cmd_new = qmp_marshal_input_balloon,
755 SQMP
756 balloon
757 -------
759 Request VM to change its memory allocation (in bytes).
761 Arguments:
763 - "value": New memory allocation (json-int)
765 Example:
767 -> { "execute": "balloon", "arguments": { "value": 536870912 } }
768 <- { "return": {} }
770 EQMP
773 .name = "set_link",
774 .args_type = "name:s,up:b",
775 .mhandler.cmd_new = qmp_marshal_input_set_link,
778 SQMP
779 set_link
780 --------
782 Change the link status of a network adapter.
784 Arguments:
786 - "name": network device name (json-string)
787 - "up": status is up (json-bool)
789 Example:
791 -> { "execute": "set_link", "arguments": { "name": "e1000.0", "up": false } }
792 <- { "return": {} }
794 EQMP
797 .name = "getfd",
798 .args_type = "fdname:s",
799 .params = "getfd name",
800 .help = "receive a file descriptor via SCM rights and assign it a name",
801 .user_print = monitor_user_noop,
802 .mhandler.cmd_new = do_getfd,
805 SQMP
806 getfd
807 -----
809 Receive a file descriptor via SCM rights and assign it a name.
811 Arguments:
813 - "fdname": file descriptor name (json-string)
815 Example:
817 -> { "execute": "getfd", "arguments": { "fdname": "fd1" } }
818 <- { "return": {} }
820 EQMP
823 .name = "closefd",
824 .args_type = "fdname:s",
825 .params = "closefd name",
826 .help = "close a file descriptor previously passed via SCM rights",
827 .user_print = monitor_user_noop,
828 .mhandler.cmd_new = do_closefd,
831 SQMP
832 closefd
833 -------
835 Close a file descriptor previously passed via SCM rights.
837 Arguments:
839 - "fdname": file descriptor name (json-string)
841 Example:
843 -> { "execute": "closefd", "arguments": { "fdname": "fd1" } }
844 <- { "return": {} }
846 EQMP
849 .name = "block_passwd",
850 .args_type = "device:B,password:s",
851 .mhandler.cmd_new = qmp_marshal_input_block_passwd,
854 SQMP
855 block_passwd
856 ------------
858 Set the password of encrypted block devices.
860 Arguments:
862 - "device": device name (json-string)
863 - "password": password (json-string)
865 Example:
867 -> { "execute": "block_passwd", "arguments": { "device": "ide0-hd0",
868 "password": "12345" } }
869 <- { "return": {} }
871 EQMP
874 .name = "block_set_io_throttle",
875 .args_type = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l",
876 .mhandler.cmd_new = qmp_marshal_input_block_set_io_throttle,
879 SQMP
880 block_set_io_throttle
881 ------------
883 Change I/O throttle limits for a block drive.
885 Arguments:
887 - "device": device name (json-string)
888 - "bps": total throughput limit in bytes per second(json-int)
889 - "bps_rd": read throughput limit in bytes per second(json-int)
890 - "bps_wr": read throughput limit in bytes per second(json-int)
891 - "iops": total I/O operations per second(json-int)
892 - "iops_rd": read I/O operations per second(json-int)
893 - "iops_wr": write I/O operations per second(json-int)
895 Example:
897 -> { "execute": "block_set_io_throttle", "arguments": { "device": "virtio0",
898 "bps": "1000000",
899 "bps_rd": "0",
900 "bps_wr": "0",
901 "iops": "0",
902 "iops_rd": "0",
903 "iops_wr": "0" } }
904 <- { "return": {} }
906 EQMP
909 .name = "set_password",
910 .args_type = "protocol:s,password:s,connected:s?",
911 .mhandler.cmd_new = qmp_marshal_input_set_password,
914 SQMP
915 set_password
916 ------------
918 Set the password for vnc/spice protocols.
920 Arguments:
922 - "protocol": protocol name (json-string)
923 - "password": password (json-string)
924 - "connected": [ keep | disconnect | fail ] (josn-string, optional)
926 Example:
928 -> { "execute": "set_password", "arguments": { "protocol": "vnc",
929 "password": "secret" } }
930 <- { "return": {} }
932 EQMP
935 .name = "expire_password",
936 .args_type = "protocol:s,time:s",
937 .mhandler.cmd_new = qmp_marshal_input_expire_password,
940 SQMP
941 expire_password
942 ---------------
944 Set the password expire time for vnc/spice protocols.
946 Arguments:
948 - "protocol": protocol name (json-string)
949 - "time": [ now | never | +secs | secs ] (json-string)
951 Example:
953 -> { "execute": "expire_password", "arguments": { "protocol": "vnc",
954 "time": "+60" } }
955 <- { "return": {} }
957 EQMP
960 .name = "add_client",
961 .args_type = "protocol:s,fdname:s,skipauth:b?,tls:b?",
962 .params = "protocol fdname skipauth tls",
963 .help = "add a graphics client",
964 .user_print = monitor_user_noop,
965 .mhandler.cmd_new = add_graphics_client,
968 SQMP
969 add_client
970 ----------
972 Add a graphics client
974 Arguments:
976 - "protocol": protocol name (json-string)
977 - "fdname": file descriptor name (json-string)
978 - "skipauth": whether to skip authentication (json-bool, optional)
979 - "tls": whether to perform TLS (json-bool, optional)
981 Example:
983 -> { "execute": "add_client", "arguments": { "protocol": "vnc",
984 "fdname": "myclient" } }
985 <- { "return": {} }
987 EQMP
989 .name = "qmp_capabilities",
990 .args_type = "",
991 .params = "",
992 .help = "enable QMP capabilities",
993 .user_print = monitor_user_noop,
994 .mhandler.cmd_new = do_qmp_capabilities,
997 SQMP
998 qmp_capabilities
999 ----------------
1001 Enable QMP capabilities.
1003 Arguments: None.
1005 Example:
1007 -> { "execute": "qmp_capabilities" }
1008 <- { "return": {} }
1010 Note: This command must be issued before issuing any other command.
1012 EQMP
1015 .name = "human-monitor-command",
1016 .args_type = "command-line:s,cpu-index:i?",
1017 .mhandler.cmd_new = qmp_marshal_input_human_monitor_command,
1020 SQMP
1021 human-monitor-command
1022 ---------------------
1024 Execute a Human Monitor command.
1026 Arguments:
1028 - command-line: the command name and its arguments, just like the
1029 Human Monitor's shell (json-string)
1030 - cpu-index: select the CPU number to be used by commands which access CPU
1031 data, like 'info registers'. The Monitor selects CPU 0 if this
1032 argument is not provided (json-int, optional)
1034 Example:
1036 -> { "execute": "human-monitor-command", "arguments": { "command-line": "info kvm" } }
1037 <- { "return": "kvm support: enabled\r\n" }
1039 Notes:
1041 (1) The Human Monitor is NOT an stable interface, this means that command
1042 names, arguments and responses can change or be removed at ANY time.
1043 Applications that rely on long term stability guarantees should NOT
1044 use this command
1046 (2) Limitations:
1048 o This command is stateless, this means that commands that depend
1049 on state information (such as getfd) might not work
1051 o Commands that prompt the user for data (eg. 'cont' when the block
1052 device is encrypted) don't currently work
1054 3. Query Commands
1055 =================
1057 HXCOMM Each query command below is inside a SQMP/EQMP section, do NOT change
1058 HXCOMM this! We will possibly move query commands definitions inside those
1059 HXCOMM sections, just like regular commands.
1061 EQMP
1063 SQMP
1064 query-version
1065 -------------
1067 Show QEMU version.
1069 Return a json-object with the following information:
1071 - "qemu": A json-object containing three integer values:
1072 - "major": QEMU's major version (json-int)
1073 - "minor": QEMU's minor version (json-int)
1074 - "micro": QEMU's micro version (json-int)
1075 - "package": package's version (json-string)
1077 Example:
1079 -> { "execute": "query-version" }
1080 <- {
1081 "return":{
1082 "qemu":{
1083 "major":0,
1084 "minor":11,
1085 "micro":5
1087 "package":""
1091 EQMP
1094 .name = "query-version",
1095 .args_type = "",
1096 .mhandler.cmd_new = qmp_marshal_input_query_version,
1099 SQMP
1100 query-commands
1101 --------------
1103 List QMP available commands.
1105 Each command is represented by a json-object, the returned value is a json-array
1106 of all commands.
1108 Each json-object contain:
1110 - "name": command's name (json-string)
1112 Example:
1114 -> { "execute": "query-commands" }
1115 <- {
1116 "return":[
1118 "name":"query-balloon"
1121 "name":"system_powerdown"
1126 Note: This example has been shortened as the real response is too long.
1128 EQMP
1131 .name = "query-commands",
1132 .args_type = "",
1133 .mhandler.cmd_new = qmp_marshal_input_query_commands,
1136 SQMP
1137 query-chardev
1138 -------------
1140 Each device is represented by a json-object. The returned value is a json-array
1141 of all devices.
1143 Each json-object contain the following:
1145 - "label": device's label (json-string)
1146 - "filename": device's file (json-string)
1148 Example:
1150 -> { "execute": "query-chardev" }
1151 <- {
1152 "return":[
1154 "label":"monitor",
1155 "filename":"stdio"
1158 "label":"serial0",
1159 "filename":"vc"
1164 EQMP
1167 .name = "query-chardev",
1168 .args_type = "",
1169 .mhandler.cmd_new = qmp_marshal_input_query_chardev,
1172 SQMP
1173 query-block
1174 -----------
1176 Show the block devices.
1178 Each block device information is stored in a json-object and the returned value
1179 is a json-array of all devices.
1181 Each json-object contain the following:
1183 - "device": device name (json-string)
1184 - "type": device type (json-string)
1185 - deprecated, retained for backward compatibility
1186 - Possible values: "unknown"
1187 - "removable": true if the device is removable, false otherwise (json-bool)
1188 - "locked": true if the device is locked, false otherwise (json-bool)
1189 - "tray-open": only present if removable, true if the device has a tray,
1190 and it is open (json-bool)
1191 - "inserted": only present if the device is inserted, it is a json-object
1192 containing the following:
1193 - "file": device file name (json-string)
1194 - "ro": true if read-only, false otherwise (json-bool)
1195 - "drv": driver format name (json-string)
1196 - Possible values: "blkdebug", "bochs", "cloop", "cow", "dmg",
1197 "file", "file", "ftp", "ftps", "host_cdrom",
1198 "host_device", "host_floppy", "http", "https",
1199 "nbd", "parallels", "qcow", "qcow2", "raw",
1200 "tftp", "vdi", "vmdk", "vpc", "vvfat"
1201 - "backing_file": backing file name (json-string, optional)
1202 - "encrypted": true if encrypted, false otherwise (json-bool)
1203 - "bps": limit total bytes per second (json-int)
1204 - "bps_rd": limit read bytes per second (json-int)
1205 - "bps_wr": limit write bytes per second (json-int)
1206 - "iops": limit total I/O operations per second (json-int)
1207 - "iops_rd": limit read operations per second (json-int)
1208 - "iops_wr": limit write operations per second (json-int)
1210 - "io-status": I/O operation status, only present if the device supports it
1211 and the VM is configured to stop on errors. It's always reset
1212 to "ok" when the "cont" command is issued (json_string, optional)
1213 - Possible values: "ok", "failed", "nospace"
1215 Example:
1217 -> { "execute": "query-block" }
1218 <- {
1219 "return":[
1221 "io-status": "ok",
1222 "device":"ide0-hd0",
1223 "locked":false,
1224 "removable":false,
1225 "inserted":{
1226 "ro":false,
1227 "drv":"qcow2",
1228 "encrypted":false,
1229 "file":"disks/test.img",
1230 "bps":1000000,
1231 "bps_rd":0,
1232 "bps_wr":0,
1233 "iops":1000000,
1234 "iops_rd":0,
1235 "iops_wr":0,
1237 "type":"unknown"
1240 "io-status": "ok",
1241 "device":"ide1-cd0",
1242 "locked":false,
1243 "removable":true,
1244 "type":"unknown"
1247 "device":"floppy0",
1248 "locked":false,
1249 "removable":true,
1250 "type":"unknown"
1253 "device":"sd0",
1254 "locked":false,
1255 "removable":true,
1256 "type":"unknown"
1261 EQMP
1264 .name = "query-block",
1265 .args_type = "",
1266 .mhandler.cmd_new = qmp_marshal_input_query_block,
1269 SQMP
1270 query-blockstats
1271 ----------------
1273 Show block device statistics.
1275 Each device statistic information is stored in a json-object and the returned
1276 value is a json-array of all devices.
1278 Each json-object contain the following:
1280 - "device": device name (json-string)
1281 - "stats": A json-object with the statistics information, it contains:
1282 - "rd_bytes": bytes read (json-int)
1283 - "wr_bytes": bytes written (json-int)
1284 - "rd_operations": read operations (json-int)
1285 - "wr_operations": write operations (json-int)
1286 - "flush_operations": cache flush operations (json-int)
1287 - "wr_total_time_ns": total time spend on writes in nano-seconds (json-int)
1288 - "rd_total_time_ns": total time spend on reads in nano-seconds (json-int)
1289 - "flush_total_time_ns": total time spend on cache flushes in nano-seconds (json-int)
1290 - "wr_highest_offset": Highest offset of a sector written since the
1291 BlockDriverState has been opened (json-int)
1292 - "parent": Contains recursively the statistics of the underlying
1293 protocol (e.g. the host file for a qcow2 image). If there is
1294 no underlying protocol, this field is omitted
1295 (json-object, optional)
1297 Example:
1299 -> { "execute": "query-blockstats" }
1300 <- {
1301 "return":[
1303 "device":"ide0-hd0",
1304 "parent":{
1305 "stats":{
1306 "wr_highest_offset":3686448128,
1307 "wr_bytes":9786368,
1308 "wr_operations":751,
1309 "rd_bytes":122567168,
1310 "rd_operations":36772
1311 "wr_total_times_ns":313253456
1312 "rd_total_times_ns":3465673657
1313 "flush_total_times_ns":49653
1314 "flush_operations":61,
1317 "stats":{
1318 "wr_highest_offset":2821110784,
1319 "wr_bytes":9786368,
1320 "wr_operations":692,
1321 "rd_bytes":122739200,
1322 "rd_operations":36604
1323 "flush_operations":51,
1324 "wr_total_times_ns":313253456
1325 "rd_total_times_ns":3465673657
1326 "flush_total_times_ns":49653
1330 "device":"ide1-cd0",
1331 "stats":{
1332 "wr_highest_offset":0,
1333 "wr_bytes":0,
1334 "wr_operations":0,
1335 "rd_bytes":0,
1336 "rd_operations":0
1337 "flush_operations":0,
1338 "wr_total_times_ns":0
1339 "rd_total_times_ns":0
1340 "flush_total_times_ns":0
1344 "device":"floppy0",
1345 "stats":{
1346 "wr_highest_offset":0,
1347 "wr_bytes":0,
1348 "wr_operations":0,
1349 "rd_bytes":0,
1350 "rd_operations":0
1351 "flush_operations":0,
1352 "wr_total_times_ns":0
1353 "rd_total_times_ns":0
1354 "flush_total_times_ns":0
1358 "device":"sd0",
1359 "stats":{
1360 "wr_highest_offset":0,
1361 "wr_bytes":0,
1362 "wr_operations":0,
1363 "rd_bytes":0,
1364 "rd_operations":0
1365 "flush_operations":0,
1366 "wr_total_times_ns":0
1367 "rd_total_times_ns":0
1368 "flush_total_times_ns":0
1374 EQMP
1377 .name = "query-blockstats",
1378 .args_type = "",
1379 .mhandler.cmd_new = qmp_marshal_input_query_blockstats,
1382 SQMP
1383 query-cpus
1384 ----------
1386 Show CPU information.
1388 Return a json-array. Each CPU is represented by a json-object, which contains:
1390 - "CPU": CPU index (json-int)
1391 - "current": true if this is the current CPU, false otherwise (json-bool)
1392 - "halted": true if the cpu is halted, false otherwise (json-bool)
1393 - Current program counter. The key's name depends on the architecture:
1394 "pc": i386/x86_64 (json-int)
1395 "nip": PPC (json-int)
1396 "pc" and "npc": sparc (json-int)
1397 "PC": mips (json-int)
1398 - "thread_id": ID of the underlying host thread (json-int)
1400 Example:
1402 -> { "execute": "query-cpus" }
1403 <- {
1404 "return":[
1406 "CPU":0,
1407 "current":true,
1408 "halted":false,
1409 "pc":3227107138
1410 "thread_id":3134
1413 "CPU":1,
1414 "current":false,
1415 "halted":true,
1416 "pc":7108165
1417 "thread_id":3135
1422 EQMP
1425 .name = "query-cpus",
1426 .args_type = "",
1427 .mhandler.cmd_new = qmp_marshal_input_query_cpus,
1430 SQMP
1431 query-pci
1432 ---------
1434 PCI buses and devices information.
1436 The returned value is a json-array of all buses. Each bus is represented by
1437 a json-object, which has a key with a json-array of all PCI devices attached
1438 to it. Each device is represented by a json-object.
1440 The bus json-object contains the following:
1442 - "bus": bus number (json-int)
1443 - "devices": a json-array of json-objects, each json-object represents a
1444 PCI device
1446 The PCI device json-object contains the following:
1448 - "bus": identical to the parent's bus number (json-int)
1449 - "slot": slot number (json-int)
1450 - "function": function number (json-int)
1451 - "class_info": a json-object containing:
1452 - "desc": device class description (json-string, optional)
1453 - "class": device class number (json-int)
1454 - "id": a json-object containing:
1455 - "device": device ID (json-int)
1456 - "vendor": vendor ID (json-int)
1457 - "irq": device's IRQ if assigned (json-int, optional)
1458 - "qdev_id": qdev id string (json-string)
1459 - "pci_bridge": It's a json-object, only present if this device is a
1460 PCI bridge, contains:
1461 - "bus": bus number (json-int)
1462 - "secondary": secondary bus number (json-int)
1463 - "subordinate": subordinate bus number (json-int)
1464 - "io_range": I/O memory range information, a json-object with the
1465 following members:
1466 - "base": base address, in bytes (json-int)
1467 - "limit": limit address, in bytes (json-int)
1468 - "memory_range": memory range information, a json-object with the
1469 following members:
1470 - "base": base address, in bytes (json-int)
1471 - "limit": limit address, in bytes (json-int)
1472 - "prefetchable_range": Prefetchable memory range information, a
1473 json-object with the following members:
1474 - "base": base address, in bytes (json-int)
1475 - "limit": limit address, in bytes (json-int)
1476 - "devices": a json-array of PCI devices if there's any attached, each
1477 each element is represented by a json-object, which contains
1478 the same members of the 'PCI device json-object' described
1479 above (optional)
1480 - "regions": a json-array of json-objects, each json-object represents a
1481 memory region of this device
1483 The memory range json-object contains the following:
1485 - "base": base memory address (json-int)
1486 - "limit": limit value (json-int)
1488 The region json-object can be an I/O region or a memory region, an I/O region
1489 json-object contains the following:
1491 - "type": "io" (json-string, fixed)
1492 - "bar": BAR number (json-int)
1493 - "address": memory address (json-int)
1494 - "size": memory size (json-int)
1496 A memory region json-object contains the following:
1498 - "type": "memory" (json-string, fixed)
1499 - "bar": BAR number (json-int)
1500 - "address": memory address (json-int)
1501 - "size": memory size (json-int)
1502 - "mem_type_64": true or false (json-bool)
1503 - "prefetch": true or false (json-bool)
1505 Example:
1507 -> { "execute": "query-pci" }
1508 <- {
1509 "return":[
1511 "bus":0,
1512 "devices":[
1514 "bus":0,
1515 "qdev_id":"",
1516 "slot":0,
1517 "class_info":{
1518 "class":1536,
1519 "desc":"Host bridge"
1521 "id":{
1522 "device":32902,
1523 "vendor":4663
1525 "function":0,
1526 "regions":[
1531 "bus":0,
1532 "qdev_id":"",
1533 "slot":1,
1534 "class_info":{
1535 "class":1537,
1536 "desc":"ISA bridge"
1538 "id":{
1539 "device":32902,
1540 "vendor":28672
1542 "function":0,
1543 "regions":[
1548 "bus":0,
1549 "qdev_id":"",
1550 "slot":1,
1551 "class_info":{
1552 "class":257,
1553 "desc":"IDE controller"
1555 "id":{
1556 "device":32902,
1557 "vendor":28688
1559 "function":1,
1560 "regions":[
1562 "bar":4,
1563 "size":16,
1564 "address":49152,
1565 "type":"io"
1570 "bus":0,
1571 "qdev_id":"",
1572 "slot":2,
1573 "class_info":{
1574 "class":768,
1575 "desc":"VGA controller"
1577 "id":{
1578 "device":4115,
1579 "vendor":184
1581 "function":0,
1582 "regions":[
1584 "prefetch":true,
1585 "mem_type_64":false,
1586 "bar":0,
1587 "size":33554432,
1588 "address":4026531840,
1589 "type":"memory"
1592 "prefetch":false,
1593 "mem_type_64":false,
1594 "bar":1,
1595 "size":4096,
1596 "address":4060086272,
1597 "type":"memory"
1600 "prefetch":false,
1601 "mem_type_64":false,
1602 "bar":6,
1603 "size":65536,
1604 "address":-1,
1605 "type":"memory"
1610 "bus":0,
1611 "qdev_id":"",
1612 "irq":11,
1613 "slot":4,
1614 "class_info":{
1615 "class":1280,
1616 "desc":"RAM controller"
1618 "id":{
1619 "device":6900,
1620 "vendor":4098
1622 "function":0,
1623 "regions":[
1625 "bar":0,
1626 "size":32,
1627 "address":49280,
1628 "type":"io"
1637 Note: This example has been shortened as the real response is too long.
1639 EQMP
1642 .name = "query-pci",
1643 .args_type = "",
1644 .mhandler.cmd_new = qmp_marshal_input_query_pci,
1647 SQMP
1648 query-kvm
1649 ---------
1651 Show KVM information.
1653 Return a json-object with the following information:
1655 - "enabled": true if KVM support is enabled, false otherwise (json-bool)
1656 - "present": true if QEMU has KVM support, false otherwise (json-bool)
1658 Example:
1660 -> { "execute": "query-kvm" }
1661 <- { "return": { "enabled": true, "present": true } }
1663 EQMP
1666 .name = "query-kvm",
1667 .args_type = "",
1668 .mhandler.cmd_new = qmp_marshal_input_query_kvm,
1671 SQMP
1672 query-status
1673 ------------
1675 Return a json-object with the following information:
1677 - "running": true if the VM is running, or false if it is paused (json-bool)
1678 - "singlestep": true if the VM is in single step mode,
1679 false otherwise (json-bool)
1680 - "status": one of the following values (json-string)
1681 "debug" - QEMU is running on a debugger
1682 "inmigrate" - guest is paused waiting for an incoming migration
1683 "internal-error" - An internal error that prevents further guest
1684 execution has occurred
1685 "io-error" - the last IOP has failed and the device is configured
1686 to pause on I/O errors
1687 "paused" - guest has been paused via the 'stop' command
1688 "postmigrate" - guest is paused following a successful 'migrate'
1689 "prelaunch" - QEMU was started with -S and guest has not started
1690 "finish-migrate" - guest is paused to finish the migration process
1691 "restore-vm" - guest is paused to restore VM state
1692 "running" - guest is actively running
1693 "save-vm" - guest is paused to save the VM state
1694 "shutdown" - guest is shut down (and -no-shutdown is in use)
1695 "watchdog" - the watchdog action is configured to pause and
1696 has been triggered
1698 Example:
1700 -> { "execute": "query-status" }
1701 <- { "return": { "running": true, "singlestep": false, "status": "running" } }
1703 EQMP
1706 .name = "query-status",
1707 .args_type = "",
1708 .mhandler.cmd_new = qmp_marshal_input_query_status,
1711 SQMP
1712 query-mice
1713 ----------
1715 Show VM mice information.
1717 Each mouse is represented by a json-object, the returned value is a json-array
1718 of all mice.
1720 The mouse json-object contains the following:
1722 - "name": mouse's name (json-string)
1723 - "index": mouse's index (json-int)
1724 - "current": true if this mouse is receiving events, false otherwise (json-bool)
1725 - "absolute": true if the mouse generates absolute input events (json-bool)
1727 Example:
1729 -> { "execute": "query-mice" }
1730 <- {
1731 "return":[
1733 "name":"QEMU Microsoft Mouse",
1734 "index":0,
1735 "current":false,
1736 "absolute":false
1739 "name":"QEMU PS/2 Mouse",
1740 "index":1,
1741 "current":true,
1742 "absolute":true
1747 EQMP
1750 .name = "query-mice",
1751 .args_type = "",
1752 .mhandler.cmd_new = qmp_marshal_input_query_mice,
1755 SQMP
1756 query-vnc
1757 ---------
1759 Show VNC server information.
1761 Return a json-object with server information. Connected clients are returned
1762 as a json-array of json-objects.
1764 The main json-object contains the following:
1766 - "enabled": true or false (json-bool)
1767 - "host": server's IP address (json-string)
1768 - "family": address family (json-string)
1769 - Possible values: "ipv4", "ipv6", "unix", "unknown"
1770 - "service": server's port number (json-string)
1771 - "auth": authentication method (json-string)
1772 - Possible values: "invalid", "none", "ra2", "ra2ne", "sasl", "tight",
1773 "tls", "ultra", "unknown", "vencrypt", "vencrypt",
1774 "vencrypt+plain", "vencrypt+tls+none",
1775 "vencrypt+tls+plain", "vencrypt+tls+sasl",
1776 "vencrypt+tls+vnc", "vencrypt+x509+none",
1777 "vencrypt+x509+plain", "vencrypt+x509+sasl",
1778 "vencrypt+x509+vnc", "vnc"
1779 - "clients": a json-array of all connected clients
1781 Clients are described by a json-object, each one contain the following:
1783 - "host": client's IP address (json-string)
1784 - "family": address family (json-string)
1785 - Possible values: "ipv4", "ipv6", "unix", "unknown"
1786 - "service": client's port number (json-string)
1787 - "x509_dname": TLS dname (json-string, optional)
1788 - "sasl_username": SASL username (json-string, optional)
1790 Example:
1792 -> { "execute": "query-vnc" }
1793 <- {
1794 "return":{
1795 "enabled":true,
1796 "host":"0.0.0.0",
1797 "service":"50402",
1798 "auth":"vnc",
1799 "family":"ipv4",
1800 "clients":[
1802 "host":"127.0.0.1",
1803 "service":"50401",
1804 "family":"ipv4"
1810 EQMP
1813 .name = "query-vnc",
1814 .args_type = "",
1815 .mhandler.cmd_new = qmp_marshal_input_query_vnc,
1818 SQMP
1819 query-spice
1820 -----------
1822 Show SPICE server information.
1824 Return a json-object with server information. Connected clients are returned
1825 as a json-array of json-objects.
1827 The main json-object contains the following:
1829 - "enabled": true or false (json-bool)
1830 - "host": server's IP address (json-string)
1831 - "port": server's port number (json-int, optional)
1832 - "tls-port": server's port number (json-int, optional)
1833 - "auth": authentication method (json-string)
1834 - Possible values: "none", "spice"
1835 - "channels": a json-array of all active channels clients
1837 Channels are described by a json-object, each one contain the following:
1839 - "host": client's IP address (json-string)
1840 - "family": address family (json-string)
1841 - Possible values: "ipv4", "ipv6", "unix", "unknown"
1842 - "port": client's port number (json-string)
1843 - "connection-id": spice connection id. All channels with the same id
1844 belong to the same spice session (json-int)
1845 - "channel-type": channel type. "1" is the main control channel, filter for
1846 this one if you want track spice sessions only (json-int)
1847 - "channel-id": channel id. Usually "0", might be different needed when
1848 multiple channels of the same type exist, such as multiple
1849 display channels in a multihead setup (json-int)
1850 - "tls": whevener the channel is encrypted (json-bool)
1852 Example:
1854 -> { "execute": "query-spice" }
1855 <- {
1856 "return": {
1857 "enabled": true,
1858 "auth": "spice",
1859 "port": 5920,
1860 "tls-port": 5921,
1861 "host": "0.0.0.0",
1862 "channels": [
1864 "port": "54924",
1865 "family": "ipv4",
1866 "channel-type": 1,
1867 "connection-id": 1804289383,
1868 "host": "127.0.0.1",
1869 "channel-id": 0,
1870 "tls": true
1873 "port": "36710",
1874 "family": "ipv4",
1875 "channel-type": 4,
1876 "connection-id": 1804289383,
1877 "host": "127.0.0.1",
1878 "channel-id": 0,
1879 "tls": false
1881 [ ... more channels follow ... ]
1886 EQMP
1888 #if defined(CONFIG_SPICE)
1890 .name = "query-spice",
1891 .args_type = "",
1892 .mhandler.cmd_new = qmp_marshal_input_query_spice,
1894 #endif
1896 SQMP
1897 query-name
1898 ----------
1900 Show VM name.
1902 Return a json-object with the following information:
1904 - "name": VM's name (json-string, optional)
1906 Example:
1908 -> { "execute": "query-name" }
1909 <- { "return": { "name": "qemu-name" } }
1911 EQMP
1914 .name = "query-name",
1915 .args_type = "",
1916 .mhandler.cmd_new = qmp_marshal_input_query_name,
1919 SQMP
1920 query-uuid
1921 ----------
1923 Show VM UUID.
1925 Return a json-object with the following information:
1927 - "UUID": Universally Unique Identifier (json-string)
1929 Example:
1931 -> { "execute": "query-uuid" }
1932 <- { "return": { "UUID": "550e8400-e29b-41d4-a716-446655440000" } }
1934 EQMP
1937 .name = "query-uuid",
1938 .args_type = "",
1939 .mhandler.cmd_new = qmp_marshal_input_query_uuid,
1942 SQMP
1943 query-migrate
1944 -------------
1946 Migration status.
1948 Return a json-object. If migration is active there will be another json-object
1949 with RAM migration status and if block migration is active another one with
1950 block migration status.
1952 The main json-object contains the following:
1954 - "status": migration status (json-string)
1955 - Possible values: "active", "completed", "failed", "cancelled"
1956 - "ram": only present if "status" is "active", it is a json-object with the
1957 following RAM information (in bytes):
1958 - "transferred": amount transferred (json-int)
1959 - "remaining": amount remaining (json-int)
1960 - "total": total (json-int)
1961 - "disk": only present if "status" is "active" and it is a block migration,
1962 it is a json-object with the following disk information (in bytes):
1963 - "transferred": amount transferred (json-int)
1964 - "remaining": amount remaining (json-int)
1965 - "total": total (json-int)
1967 Examples:
1969 1. Before the first migration
1971 -> { "execute": "query-migrate" }
1972 <- { "return": {} }
1974 2. Migration is done and has succeeded
1976 -> { "execute": "query-migrate" }
1977 <- { "return": { "status": "completed" } }
1979 3. Migration is done and has failed
1981 -> { "execute": "query-migrate" }
1982 <- { "return": { "status": "failed" } }
1984 4. Migration is being performed and is not a block migration:
1986 -> { "execute": "query-migrate" }
1987 <- {
1988 "return":{
1989 "status":"active",
1990 "ram":{
1991 "transferred":123,
1992 "remaining":123,
1993 "total":246
1998 5. Migration is being performed and is a block migration:
2000 -> { "execute": "query-migrate" }
2001 <- {
2002 "return":{
2003 "status":"active",
2004 "ram":{
2005 "total":1057024,
2006 "remaining":1053304,
2007 "transferred":3720
2009 "disk":{
2010 "total":20971520,
2011 "remaining":20880384,
2012 "transferred":91136
2017 EQMP
2020 .name = "query-migrate",
2021 .args_type = "",
2022 .mhandler.cmd_new = qmp_marshal_input_query_migrate,
2025 SQMP
2026 query-balloon
2027 -------------
2029 Show balloon information.
2031 Make an asynchronous request for balloon info. When the request completes a
2032 json-object will be returned containing the following data:
2034 - "actual": current balloon value in bytes (json-int)
2035 - "mem_swapped_in": Amount of memory swapped in bytes (json-int, optional)
2036 - "mem_swapped_out": Amount of memory swapped out in bytes (json-int, optional)
2037 - "major_page_faults": Number of major faults (json-int, optional)
2038 - "minor_page_faults": Number of minor faults (json-int, optional)
2039 - "free_mem": Total amount of free and unused memory in
2040 bytes (json-int, optional)
2041 - "total_mem": Total amount of available memory in bytes (json-int, optional)
2043 Example:
2045 -> { "execute": "query-balloon" }
2046 <- {
2047 "return":{
2048 "actual":1073741824,
2049 "mem_swapped_in":0,
2050 "mem_swapped_out":0,
2051 "major_page_faults":142,
2052 "minor_page_faults":239245,
2053 "free_mem":1014185984,
2054 "total_mem":1044668416
2058 EQMP
2061 .name = "query-balloon",
2062 .args_type = "",
2063 .mhandler.cmd_new = qmp_marshal_input_query_balloon,
2067 .name = "query-block-jobs",
2068 .args_type = "",
2069 .mhandler.cmd_new = qmp_marshal_input_query_block_jobs,
2073 .name = "qom-list",
2074 .args_type = "path:s",
2075 .mhandler.cmd_new = qmp_marshal_input_qom_list,
2079 .name = "qom-set",
2080 .args_type = "path:s,property:s,opts:O",
2081 .mhandler.cmd_new = qmp_qom_set,
2085 .name = "qom-get",
2086 .args_type = "path:s,property:s",
2087 .mhandler.cmd_new = qmp_qom_get,
2091 .name = "change-vnc-password",
2092 .args_type = "password:s",
2093 .mhandler.cmd_new = qmp_marshal_input_change_vnc_password,
2096 .name = "qom-list-types",
2097 .args_type = "implements:s?,abstract:b?",
2098 .mhandler.cmd_new = qmp_marshal_input_qom_list_types,