QMP Supported Commands
----------------------
This document describes all commands currently supported by QMP.
Most of the time their usage is exactly the same as in the user Monitor, this
means that any other document which also describe commands (the manpage,
QEMU's manual, etc) can and should be consulted.
QMP has two types of commands: regular and query commands. Regular commands
usually change the Virtual Machine's state someway, while query commands just
return information. The sections below are divided accordingly.
It's important to observe that all communication examples are formatted in
a reader-friendly way, so that they're easier to understand. However, in real
protocol usage, they're emitted as a single line.
Also, the following notation is used to denote data flow:
-> data issued by the Client
<- Server data response
Please, refer to the QMP specification (QMP/qmp-spec.txt) for detailed
information on the Server command and response formats.
NOTE: This document is temporary and will be replaced soon.
1. Stability Considerations
===========================
The current QMP command set (described in this file) may be useful for a
number of use cases, however it's limited and several commands have bad
defined semantics, specially with regard to command completion.
These problems are going to be solved incrementally in the next QEMU releases
and we're going to establish a deprecation policy for badly defined commands.
If you're planning to adopt QMP, please observe the following:
1. The deprecation policy will take effect and be documented soon, please
check the documentation of each used command as soon as a new release of
QEMU is available
2. DO NOT rely on anything which is not explicit documented
3. Errors, in special, are not documented. Applications should NOT check
for specific errors classes or data (it's strongly recommended to only
check for the "error" key)
2. Regular Commands
===================
Server's responses in the examples below are always a success response, please
refer to the QMP specification for more details on error responses.
quit
----
Quit the emulator.
Arguments: None.
Example:
-> { "execute": "quit" }
<- { "return": {} }
eject
-----
Eject a removable medium.
Arguments:
- force: force ejection (json-bool, optional)
- device: device name (json-string)
Example:
-> { "execute": "eject", "arguments": { "device": "ide1-cd0" } }
<- { "return": {} }
Note: The "force" argument defaults to false.
change
------
Change a removable medium or VNC configuration.
Arguments:
- "device": device name (json-string)
- "target": filename or item (json-string)
- "arg": additional argument (json-string, optional)
Examples:
1. Change a removable medium
-> { "execute": "change",
"arguments": { "device": "ide1-cd0",
"target": "/srv/images/Fedora-12-x86_64-DVD.iso" } }
<- { "return": {} }
2. Change VNC password
-> { "execute": "change",
"arguments": { "device": "vnc", "target": "password",
"arg": "foobar1" } }
<- { "return": {} }
screendump
----------
Save screen into PPM image.
Arguments:
- "filename": file path (json-string)
Example:
-> { "execute": "screendump", "arguments": { "filename": "/tmp/image" } }
<- { "return": {} }
stop
----
Stop the emulator.
Arguments: None.
Example:
-> { "execute": "stop" }
<- { "return": {} }
cont
----
Resume emulation.
Arguments: None.
Example:
-> { "execute": "cont" }
<- { "return": {} }
system_wakeup
-------------
Wakeup guest from suspend.
Arguments: None.
Example:
-> { "execute": "system_wakeup" }
<- { "return": {} }
system_reset
------------
Reset the system.
Arguments: None.
Example:
-> { "execute": "system_reset" }
<- { "return": {} }
system_powerdown
----------------
Send system power down event.
Arguments: None.
Example:
-> { "execute": "system_powerdown" }
<- { "return": {} }
device_add
----------
Add a device.
Arguments:
- "driver": the name of the new device's driver (json-string)
- "bus": the device's parent bus (device tree path, json-string, optional)
- "id": the device's ID, must be unique (json-string)
- device properties
Example:
-> { "execute": "device_add", "arguments": { "driver": "e1000", "id": "net1" } }
<- { "return": {} }
Notes:
(1) For detailed information about this command, please refer to the
'docs/qdev-device-use.txt' file.
(2) It's possible to list device properties by running QEMU with the
"-device DEVICE,\?" command-line argument, where DEVICE is the device's name
device_del
----------
Remove a device.
Arguments:
- "id": the device's ID (json-string)
Example:
-> { "execute": "device_del", "arguments": { "id": "net1" } }
<- { "return": {} }
send-key
----------
Send keys to VM.
Arguments:
keys array:
- "key": key sequence (a json-array of key enum values)
- hold-time: time to delay key up events, milliseconds. Defaults to 100
(json-int, optional)
Example:
-> { "execute": "send-key",
"arguments": { 'keys': [ 'ctrl', 'alt', 'delete' ] } }
<- { "return": {} }
cpu
---
Set the default CPU.
Arguments:
- "index": the CPU's index (json-int)
Example:
-> { "execute": "cpu", "arguments": { "index": 0 } }
<- { "return": {} }
Note: CPUs' indexes are obtained with the 'query-cpus' command.
memsave
-------
Save to disk virtual memory dump starting at 'val' of size 'size'.
Arguments:
- "val": the starting address (json-int)
- "size": the memory size, in bytes (json-int)
- "filename": file path (json-string)
- "cpu": virtual CPU index (json-int, optional)
Example:
-> { "execute": "memsave",
"arguments": { "val": 10,
"size": 100,
"filename": "/tmp/virtual-mem-dump" } }
<- { "return": {} }
pmemsave
--------
Save to disk physical memory dump starting at 'val' of size 'size'.
Arguments:
- "val": the starting address (json-int)
- "size": the memory size, in bytes (json-int)
- "filename": file path (json-string)
Example:
-> { "execute": "pmemsave",
"arguments": { "val": 10,
"size": 100,
"filename": "/tmp/physical-mem-dump" } }
<- { "return": {} }
inject-nmi
----------
Inject an NMI on guest's CPUs.
Arguments: None.
Example:
-> { "execute": "inject-nmi" }
<- { "return": {} }
Note: inject-nmi fails when the guest doesn't support injecting.
Currently, only x86 guests do.
xen-save-devices-state
-------
Save the state of all devices to file. The RAM and the block devices
of the VM are not saved by this command.
Arguments:
- "filename": the file to save the state of the devices to as binary
data. See xen-save-devices-state.txt for a description of the binary
format.
Example:
-> { "execute": "xen-save-devices-state",
"arguments": { "filename": "/tmp/save" } }
<- { "return": {} }
xen-set-global-dirty-log
-------
Enable or disable the global dirty log mode.
Arguments:
- "enable": Enable it or disable it.
Example:
-> { "execute": "xen-set-global-dirty-log",
"arguments": { "enable": true } }
<- { "return": {} }
migrate
-------
Migrate to URI.
Arguments:
- "blk": block migration, full disk copy (json-bool, optional)
- "inc": incremental disk copy (json-bool, optional)
- "uri": Destination URI (json-string)
Example:
-> { "execute": "migrate", "arguments": { "uri": "tcp:0:4446" } }
<- { "return": {} }
Notes:
(1) The 'query-migrate' command should be used to check migration's progress
and final result (this information is provided by the 'status' member)
(2) All boolean arguments default to false
(3) The user Monitor's "detach" argument is invalid in QMP and should not
be used
migrate_cancel
--------------
Cancel the current migration.
Arguments: None.
Example:
-> { "execute": "migrate_cancel" }
<- { "return": {} }
m
没有合适的资源?快使用搜索试试~ 我知道了~
QEMU 1.3 win x86 x64
共95个文件
bin:15个
dll:9个
rom:7个
2星 需积分: 31 16 下载量 44 浏览量
2012-12-23
01:45:55
上传
评论 1
收藏 8.94MB 7Z 举报
温馨提示
QEMU是一套由Fabrice Bellard所编写的模拟处理器的自由软件。它与Bochs,PearPC近似,但其具有某些后两者所不具备的特性,如高速度及跨平台的特性
资源推荐
资源详情
资源评论
收起资源包目录
Qemu.7z (95个子文件)
intl.dll 149KB
libssp-0.dll 36KB
zlib1.dll 98KB
qemu-system-x86_64w.exe 21.07MB
SDL.dll 297KB
libglib-2.0-0.dll 1.19MB
libpng14-14.dll 225KB
Bios
multiboot.bin 1024B
s390-zipl.rom 3KB
vgabios-cirrus.bin 35KB
vgabios-qxl.bin 40KB
pxe-rtl8139.rom 60KB
pxe-e1000.rom 66KB
pxe-pcnet.rom 60KB
spapr-rtas.bin 20B
vgabios-vmware.bin 40KB
openbios-ppc 713KB
linuxboot.bin 1024B
openbios-sparc32 373KB
vgabios0.bin 40KB
openbios-sparc64 1.52MB
qemu.ico 766B
pxe-eepro100.rom 60KB
bootsplash.bmp 1.37MB
slof.bin 858KB
pxe-ne2k_pci.rom 60KB
ppc_rom.bin 512KB
petalogix-s3adsp1800.dtb 8KB
sgabios.bin 4KB
kvmvapic.bin 9KB
petalogix-ml605.dtb 10KB
keymaps
ar 2KB
tr 3KB
common 2KB
fr-ca 934B
en-gb 3KB
nl 1KB
th 3KB
de 2KB
da 3KB
fo 906B
sv 1008B
is 3KB
de-ch 2KB
fr 3KB
en-us 609B
pl 3KB
fr-be 3KB
es 2KB
fi 3KB
it 2KB
no 3KB
sl 2KB
modifiers 293B
bepo 11KB
et 1KB
nl-be 43B
pt-br 1KB
hr 3KB
ja 2KB
fr-ch 2KB
ru 2KB
mk 2KB
pt 2KB
lv 3KB
hu 2KB
lt 1KB
kqemu
inskqemu.exe 364KB
kqemu.inf 2KB
kqemu.sys 141KB
qemu-icon.bmp 630B
target-x86_64.conf 0B
bios.bin 128KB
pxe-virtio.rom 59KB
vgabios-stdvga.bin 40KB
palcode-clipper 181KB
bamboo.dtb 3KB
vgabios.bin 41KB
Doc
qemu-doc.html 290KB
qemu-tech.html 28KB
qmp-commands.txt 51KB
qemu-system-i386w.exe 20.07MB
libgcc_s_dw2-1.dll 117KB
lang
Spanish.lng 2KB
English.lng 2KB
German.lng 2KB
Italian.lng 2KB
Chinese.lng 1KB
French.lng 2KB
bios.bin 128KB
libgthread-2.0-0.dll 43KB
qemu-img.exe 2.52MB
qemu-io.exe 2.55MB
qemu.txt 3KB
fmod.dll 159KB
共 95 条
- 1
资源评论
- yumufenglin2013-10-08win7下不好用
- txm1003082014-06-07不能用。谢谢分享
- bisking2013-02-13好像不能用啊
wangyouqi
- 粉丝: 3
- 资源: 5
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功