blob: ed67e997fd67ab54065e8fd572b866396a45fbdc [file] [log] [blame]
Blue Swirl23130862009-06-06 08:22:04 +00001HXCOMM Use DEFHEADING() to define headings in both help text and texi
2HXCOMM Text between STEXI and ETEXI are copied to texi version and
3HXCOMM discarded from C version
4HXCOMM DEF(command, args, callback, arg_string, help) is used to construct
5HXCOMM monitor commands
6HXCOMM HXCOMM can be used for comments, discarded from both texi and C
7
8STEXI
9@table @option
10ETEXI
11
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030012 {
13 .name = "help|?",
14 .args_type = "name:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030015 .params = "[cmd]",
16 .help = "show the help",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -030017 .mhandler.cmd = do_help_cmd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030018 },
19
Blue Swirl23130862009-06-06 08:22:04 +000020STEXI
21@item help or ? [@var{cmd}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +010022@findex help
Blue Swirl23130862009-06-06 08:22:04 +000023Show the help for all commands or just for command @var{cmd}.
24ETEXI
25
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030026 {
27 .name = "commit",
28 .args_type = "device:B",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030029 .params = "device|all",
30 .help = "commit changes to the disk images (if -snapshot is used) or backing files",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -030031 .mhandler.cmd = do_commit,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030032 },
33
Blue Swirl23130862009-06-06 08:22:04 +000034STEXI
35@item commit
Stefan Weil70fcbbe2010-02-05 23:52:04 +010036@findex commit
Blue Swirl23130862009-06-06 08:22:04 +000037Commit changes to the disk images (if -snapshot is used) or backing files.
38ETEXI
39
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030040 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030041 .name = "q|quit",
42 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030043 .params = "",
44 .help = "quit the emulator",
Luiz Capitulinob223f352009-10-07 13:41:56 -030045 .user_print = monitor_user_noop,
Luiz Capitulino7a7f3252011-09-15 14:20:28 -030046 .mhandler.cmd = hmp_quit,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030047 },
48
Blue Swirl23130862009-06-06 08:22:04 +000049STEXI
50@item q or quit
Stefan Weil70fcbbe2010-02-05 23:52:04 +010051@findex quit
Blue Swirl23130862009-06-06 08:22:04 +000052Quit the emulator.
53ETEXI
54
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030055 {
Christoph Hellwig6d4a2b32011-01-24 13:32:33 +010056 .name = "block_resize",
57 .args_type = "device:B,size:o",
58 .params = "device size",
59 .help = "resize a block image",
Luiz Capitulino5e7caac2011-11-25 14:57:10 -020060 .mhandler.cmd = hmp_block_resize,
Christoph Hellwig6d4a2b32011-01-24 13:32:33 +010061 },
62
63STEXI
64@item block_resize
65@findex block_resize
66Resize a block image while a guest is running. Usually requires guest
67action to see the updated size. Resize to a lower size is supported,
68but should be used with extreme caution. Note that this command only
69resizes image files, it can not resize block devices like LVM volumes.
70ETEXI
71
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +000072 {
73 .name = "block_stream",
Stefan Hajnoczic83c66c2012-04-25 16:51:03 +010074 .args_type = "device:B,speed:o?,base:s?",
75 .params = "device [speed [base]]",
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +000076 .help = "copy data from a backing file into a block device",
77 .mhandler.cmd = hmp_block_stream,
78 },
79
80STEXI
81@item block_stream
82@findex block_stream
83Copy data from a backing file into a block device.
84ETEXI
Christoph Hellwig6d4a2b32011-01-24 13:32:33 +010085
86 {
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +000087 .name = "block_job_set_speed",
Stefan Hajnoczi882ec7c2012-04-25 16:51:02 +010088 .args_type = "device:B,speed:o",
89 .params = "device speed",
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +000090 .help = "set maximum speed for a background block operation",
91 .mhandler.cmd = hmp_block_job_set_speed,
92 },
93
94STEXI
Paolo Bonzini4451b792012-04-13 12:03:46 +020095@item block_job_set_speed
96@findex block_job_set_speed
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +000097Set maximum speed for a background block operation.
98ETEXI
99
100 {
Stefan Hajnoczi370521a2012-01-18 14:40:48 +0000101 .name = "block_job_cancel",
102 .args_type = "device:B",
103 .params = "device",
Paolo Bonzini05290d82012-07-24 13:03:39 +0200104 .help = "stop an active background block operation",
Stefan Hajnoczi370521a2012-01-18 14:40:48 +0000105 .mhandler.cmd = hmp_block_job_cancel,
106 },
107
108STEXI
109@item block_job_cancel
110@findex block_job_cancel
111Stop an active block streaming operation.
112ETEXI
113
114 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300115 .name = "eject",
Luiz Capitulino78d714e2009-12-14 18:53:21 -0200116 .args_type = "force:-f,device:B",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300117 .params = "[-f] device",
118 .help = "eject a removable medium (use -f to force it)",
Luiz Capitulinoc245b6a2011-12-07 16:02:36 -0200119 .mhandler.cmd = hmp_eject,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300120 },
121
Blue Swirl23130862009-06-06 08:22:04 +0000122STEXI
123@item eject [-f] @var{device}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100124@findex eject
Blue Swirl23130862009-06-06 08:22:04 +0000125Eject a removable medium (use -f to force it).
126ETEXI
127
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300128 {
Ryan Harper9063f812010-11-12 11:07:13 -0600129 .name = "drive_del",
130 .args_type = "id:s",
131 .params = "device",
132 .help = "remove host block device",
133 .user_print = monitor_user_noop,
134 .mhandler.cmd_new = do_drive_del,
135 },
136
137STEXI
138@item drive_del @var{device}
139@findex drive_del
140Remove host block device. The result is that guest generated IO is no longer
141submitted against the host device underlying the disk. Once a drive has
142been deleted, the QEMU Block layer returns -EIO which results in IO
143errors in the guest for applications that are reading/writing to the device.
144ETEXI
145
146 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300147 .name = "change",
148 .args_type = "device:B,target:F,arg:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300149 .params = "device filename [format]",
150 .help = "change a removable medium, optional format",
Luiz Capitulino333a96e2011-12-08 11:13:50 -0200151 .mhandler.cmd = hmp_change,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300152 },
153
Blue Swirl23130862009-06-06 08:22:04 +0000154STEXI
155@item change @var{device} @var{setting}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100156@findex change
Blue Swirl23130862009-06-06 08:22:04 +0000157
158Change the configuration of a device.
159
160@table @option
161@item change @var{diskdevice} @var{filename} [@var{format}]
162Change the medium for a removable disk device to point to @var{filename}. eg
163
164@example
165(qemu) change ide1-cd0 /path/to/some.iso
166@end example
167
168@var{format} is optional.
169
170@item change vnc @var{display},@var{options}
171Change the configuration of the VNC server. The valid syntax for @var{display}
172and @var{options} are described at @ref{sec_invocation}. eg
173
174@example
175(qemu) change vnc localhost:1
176@end example
177
178@item change vnc password [@var{password}]
179
180Change the password associated with the VNC server. If the new password is not
181supplied, the monitor will prompt for it to be entered. VNC passwords are only
182significant up to 8 letters. eg
183
184@example
185(qemu) change vnc password
186Password: ********
187@end example
188
189@end table
190ETEXI
191
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300192 {
193 .name = "screendump",
194 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300195 .params = "filename",
196 .help = "save screen into PPM image 'filename'",
Luiz Capitulinoad39cf62012-05-24 13:48:23 -0300197 .mhandler.cmd = hmp_screen_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300198 },
199
Blue Swirl23130862009-06-06 08:22:04 +0000200STEXI
201@item screendump @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100202@findex screendump
Blue Swirl23130862009-06-06 08:22:04 +0000203Save screen into PPM image @var{filename}.
204ETEXI
205
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300206 {
207 .name = "logfile",
208 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300209 .params = "filename",
210 .help = "output logs to 'filename'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300211 .mhandler.cmd = do_logfile,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300212 },
213
Blue Swirl23130862009-06-06 08:22:04 +0000214STEXI
215@item logfile @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100216@findex logfile
Blue Swirl23130862009-06-06 08:22:04 +0000217Output logs to @var{filename}.
218ETEXI
219
Prerna Saxena22890ab2010-06-24 17:04:53 +0530220 {
221 .name = "trace-event",
222 .args_type = "name:s,option:b",
223 .params = "name on|off",
224 .help = "changes status of a specific trace event",
Lluísfc764102011-08-31 20:31:18 +0200225 .mhandler.cmd = do_trace_event_set_state,
Prerna Saxena22890ab2010-06-24 17:04:53 +0530226 },
227
228STEXI
229@item trace-event
230@findex trace-event
231changes status of a trace event
232ETEXI
Stefan Hajnoczic5ceb522010-07-13 09:26:33 +0100233
Michael Rothc45a8162011-10-02 08:44:37 -0500234#if defined(CONFIG_TRACE_SIMPLE)
Stefan Hajnoczic5ceb522010-07-13 09:26:33 +0100235 {
236 .name = "trace-file",
237 .args_type = "op:s?,arg:F?",
238 .params = "on|off|flush|set [arg]",
239 .help = "open, close, or flush trace file, or set a new file name",
240 .mhandler.cmd = do_trace_file,
241 },
242
243STEXI
244@item trace-file on|off|flush
245@findex trace-file
246Open, close, or flush the trace file. If no argument is given, the status of the trace file is displayed.
247ETEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +0530248#endif
249
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300250 {
251 .name = "log",
252 .args_type = "items:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300253 .params = "item1[,...]",
254 .help = "activate logging of the specified items to '/tmp/qemu.log'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300255 .mhandler.cmd = do_log,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300256 },
257
Blue Swirl23130862009-06-06 08:22:04 +0000258STEXI
259@item log @var{item1}[,...]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100260@findex log
Blue Swirl23130862009-06-06 08:22:04 +0000261Activate logging of the specified items to @file{/tmp/qemu.log}.
262ETEXI
263
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300264 {
265 .name = "savevm",
266 .args_type = "name:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300267 .params = "[tag|id]",
268 .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300269 .mhandler.cmd = do_savevm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300270 },
271
Blue Swirl23130862009-06-06 08:22:04 +0000272STEXI
273@item savevm [@var{tag}|@var{id}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100274@findex savevm
Blue Swirl23130862009-06-06 08:22:04 +0000275Create a snapshot of the whole virtual machine. If @var{tag} is
276provided, it is used as human readable identifier. If there is already
277a snapshot with the same tag or ID, it is replaced. More info at
278@ref{vm_snapshots}.
279ETEXI
280
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300281 {
282 .name = "loadvm",
283 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300284 .params = "tag|id",
285 .help = "restore a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300286 .mhandler.cmd = do_loadvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300287 },
288
Blue Swirl23130862009-06-06 08:22:04 +0000289STEXI
290@item loadvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100291@findex loadvm
Blue Swirl23130862009-06-06 08:22:04 +0000292Set the whole virtual machine to the snapshot identified by the tag
293@var{tag} or the unique snapshot ID @var{id}.
294ETEXI
295
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300296 {
297 .name = "delvm",
298 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300299 .params = "tag|id",
300 .help = "delete a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300301 .mhandler.cmd = do_delvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300302 },
303
Blue Swirl23130862009-06-06 08:22:04 +0000304STEXI
305@item delvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100306@findex delvm
Blue Swirl23130862009-06-06 08:22:04 +0000307Delete the snapshot identified by @var{tag} or @var{id}.
308ETEXI
309
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300310 {
311 .name = "singlestep",
312 .args_type = "option:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300313 .params = "[on|off]",
314 .help = "run emulation in singlestep mode or switch to normal mode",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300315 .mhandler.cmd = do_singlestep,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300316 },
317
Blue Swirl23130862009-06-06 08:22:04 +0000318STEXI
319@item singlestep [off]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100320@findex singlestep
Blue Swirl23130862009-06-06 08:22:04 +0000321Run the emulation in single step mode.
322If called with option off, the emulation returns to normal mode.
323ETEXI
324
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300325 {
326 .name = "stop",
327 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300328 .params = "",
329 .help = "stop emulation",
Luiz Capitulino5f158f22011-09-15 14:34:39 -0300330 .mhandler.cmd = hmp_stop,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300331 },
332
Blue Swirl23130862009-06-06 08:22:04 +0000333STEXI
334@item stop
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100335@findex stop
Blue Swirl23130862009-06-06 08:22:04 +0000336Stop emulation.
337ETEXI
338
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300339 {
340 .name = "c|cont",
341 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300342 .params = "",
343 .help = "resume emulation",
Luiz Capitulinoe42e8182011-11-22 17:58:31 -0200344 .mhandler.cmd = hmp_cont,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300345 },
346
Blue Swirl23130862009-06-06 08:22:04 +0000347STEXI
348@item c or cont
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100349@findex cont
Blue Swirl23130862009-06-06 08:22:04 +0000350Resume emulation.
351ETEXI
352
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300353 {
Gerd Hoffmann9b9df252012-02-23 13:45:21 +0100354 .name = "system_wakeup",
355 .args_type = "",
356 .params = "",
357 .help = "wakeup guest from suspend",
358 .mhandler.cmd = hmp_system_wakeup,
359 },
360
361STEXI
362@item system_wakeup
363@findex system_wakeup
364Wakeup guest from suspend.
365ETEXI
366
367 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300368 .name = "gdbserver",
369 .args_type = "device:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300370 .params = "[device]",
371 .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300372 .mhandler.cmd = do_gdbserver,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300373 },
374
Blue Swirl23130862009-06-06 08:22:04 +0000375STEXI
376@item gdbserver [@var{port}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100377@findex gdbserver
Blue Swirl23130862009-06-06 08:22:04 +0000378Start gdbserver session (default @var{port}=1234)
379ETEXI
380
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300381 {
382 .name = "x",
383 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300384 .params = "/fmt addr",
385 .help = "virtual memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300386 .mhandler.cmd = do_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300387 },
388
Blue Swirl23130862009-06-06 08:22:04 +0000389STEXI
390@item x/fmt @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100391@findex x
Blue Swirl23130862009-06-06 08:22:04 +0000392Virtual memory dump starting at @var{addr}.
393ETEXI
394
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300395 {
396 .name = "xp",
397 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300398 .params = "/fmt addr",
399 .help = "physical memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300400 .mhandler.cmd = do_physical_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300401 },
402
Blue Swirl23130862009-06-06 08:22:04 +0000403STEXI
404@item xp /@var{fmt} @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100405@findex xp
Blue Swirl23130862009-06-06 08:22:04 +0000406Physical memory dump starting at @var{addr}.
407
408@var{fmt} is a format which tells the command how to format the
409data. Its syntax is: @option{/@{count@}@{format@}@{size@}}
410
411@table @var
412@item count
413is the number of items to be dumped.
414
415@item format
416can be x (hex), d (signed decimal), u (unsigned decimal), o (octal),
417c (char) or i (asm instruction).
418
419@item size
420can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86,
421@code{h} or @code{w} can be specified with the @code{i} format to
422respectively select 16 or 32 bit code instruction size.
423
424@end table
425
426Examples:
427@itemize
428@item
429Dump 10 instructions at the current instruction pointer:
430@example
431(qemu) x/10i $eip
4320x90107063: ret
4330x90107064: sti
4340x90107065: lea 0x0(%esi,1),%esi
4350x90107069: lea 0x0(%edi,1),%edi
4360x90107070: ret
4370x90107071: jmp 0x90107080
4380x90107073: nop
4390x90107074: nop
4400x90107075: nop
4410x90107076: nop
442@end example
443
444@item
445Dump 80 16 bit values at the start of the video memory.
446@smallexample
447(qemu) xp/80hx 0xb8000
4480x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42
4490x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41
4500x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72
4510x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73
4520x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20
4530x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720
4540x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4550x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4560x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4570x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
458@end smallexample
459@end itemize
460ETEXI
461
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300462 {
463 .name = "p|print",
464 .args_type = "fmt:/,val:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300465 .params = "/fmt expr",
466 .help = "print expression value (use $reg for CPU register access)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300467 .mhandler.cmd = do_print,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300468 },
469
Blue Swirl23130862009-06-06 08:22:04 +0000470STEXI
471@item p or print/@var{fmt} @var{expr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100472@findex print
Blue Swirl23130862009-06-06 08:22:04 +0000473
474Print expression value. Only the @var{format} part of @var{fmt} is
475used.
476ETEXI
477
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300478 {
479 .name = "i",
480 .args_type = "fmt:/,addr:i,index:i.",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300481 .params = "/fmt addr",
482 .help = "I/O port read",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300483 .mhandler.cmd = do_ioport_read,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300484 },
485
Blue Swirl23130862009-06-06 08:22:04 +0000486STEXI
487Read I/O port.
488ETEXI
489
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300490 {
491 .name = "o",
492 .args_type = "fmt:/,addr:i,val:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300493 .params = "/fmt addr value",
494 .help = "I/O port write",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300495 .mhandler.cmd = do_ioport_write,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300496 },
497
Jan Kiszkaf1147842009-07-14 10:20:11 +0200498STEXI
499Write to I/O port.
500ETEXI
Blue Swirl23130862009-06-06 08:22:04 +0000501
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300502 {
503 .name = "sendkey",
Amos Kong2ef20c12012-08-31 10:56:22 +0800504 .args_type = "keys:s,hold-time:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300505 .params = "keys [hold_ms]",
506 .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)",
Amos Konge4c8f002012-08-31 10:56:26 +0800507 .mhandler.cmd = hmp_send_key,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300508 },
509
Blue Swirl23130862009-06-06 08:22:04 +0000510STEXI
511@item sendkey @var{keys}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100512@findex sendkey
Blue Swirl23130862009-06-06 08:22:04 +0000513
Amos Kong886cc702012-08-31 10:56:20 +0800514Send @var{keys} to the guest. @var{keys} could be the name of the
515key or the raw value in hexadecimal format. Use @code{-} to press
516several keys simultaneously. Example:
Blue Swirl23130862009-06-06 08:22:04 +0000517@example
518sendkey ctrl-alt-f1
519@end example
520
521This command is useful to send keys that your graphical user interface
522intercepts at low level, such as @code{ctrl-alt-f1} in X Window.
523ETEXI
524
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300525 {
526 .name = "system_reset",
527 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300528 .params = "",
529 .help = "reset the system",
Luiz Capitulino38d22652011-09-15 14:41:46 -0300530 .mhandler.cmd = hmp_system_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300531 },
532
Blue Swirl23130862009-06-06 08:22:04 +0000533STEXI
534@item system_reset
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100535@findex system_reset
Blue Swirl23130862009-06-06 08:22:04 +0000536
537Reset the system.
538ETEXI
539
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300540 {
541 .name = "system_powerdown",
542 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300543 .params = "",
544 .help = "send system power down event",
Luiz Capitulino5bc465e2011-09-28 11:06:15 -0300545 .mhandler.cmd = hmp_system_powerdown,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300546 },
547
Blue Swirl23130862009-06-06 08:22:04 +0000548STEXI
549@item system_powerdown
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100550@findex system_powerdown
Blue Swirl23130862009-06-06 08:22:04 +0000551
552Power down the system (if supported).
553ETEXI
554
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300555 {
556 .name = "sum",
557 .args_type = "start:i,size:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300558 .params = "addr size",
559 .help = "compute the checksum of a memory region",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300560 .mhandler.cmd = do_sum,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300561 },
562
Blue Swirl23130862009-06-06 08:22:04 +0000563STEXI
564@item sum @var{addr} @var{size}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100565@findex sum
Blue Swirl23130862009-06-06 08:22:04 +0000566
567Compute the checksum of a memory region.
568ETEXI
569
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300570 {
571 .name = "usb_add",
572 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300573 .params = "device",
574 .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300575 .mhandler.cmd = do_usb_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300576 },
577
Blue Swirl23130862009-06-06 08:22:04 +0000578STEXI
579@item usb_add @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100580@findex usb_add
Blue Swirl23130862009-06-06 08:22:04 +0000581
582Add the USB device @var{devname}. For details of available devices see
583@ref{usb_devices}
584ETEXI
585
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300586 {
587 .name = "usb_del",
588 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300589 .params = "device",
590 .help = "remove USB device 'bus.addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300591 .mhandler.cmd = do_usb_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300592 },
593
Blue Swirl23130862009-06-06 08:22:04 +0000594STEXI
595@item usb_del @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100596@findex usb_del
Blue Swirl23130862009-06-06 08:22:04 +0000597
598Remove the USB device @var{devname} from the QEMU virtual USB
599hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor
600command @code{info usb} to see the devices you can remove.
601ETEXI
602
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300603 {
604 .name = "device_add",
Markus Armbrusterc7e4e8c2010-02-10 20:47:28 +0100605 .args_type = "device:O",
606 .params = "driver[,prop=value][,...]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300607 .help = "add device, like -device on the command line",
Markus Armbruster8bc27242010-02-10 20:52:01 +0100608 .user_print = monitor_user_noop,
609 .mhandler.cmd_new = do_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300610 },
611
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200612STEXI
613@item device_add @var{config}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100614@findex device_add
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200615
616Add device.
617ETEXI
618
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300619 {
620 .name = "device_del",
621 .args_type = "id:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300622 .params = "device",
623 .help = "remove device",
Luiz Capitulinoa15fef22012-03-29 12:38:50 -0300624 .mhandler.cmd = hmp_device_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300625 },
626
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200627STEXI
628@item device_del @var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100629@findex device_del
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200630
631Remove device @var{id}.
632ETEXI
633
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300634 {
635 .name = "cpu",
636 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300637 .params = "index",
638 .help = "set the default CPU",
Luiz Capitulino755f1962011-10-06 14:31:39 -0300639 .mhandler.cmd = hmp_cpu,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300640 },
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200641
Blue Swirl23130862009-06-06 08:22:04 +0000642STEXI
Markus Armbrusterc427ea92010-05-04 13:20:32 +0200643@item cpu @var{index}
644@findex cpu
Blue Swirl23130862009-06-06 08:22:04 +0000645Set the default CPU.
646ETEXI
647
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300648 {
649 .name = "mouse_move",
650 .args_type = "dx_str:s,dy_str:s,dz_str:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300651 .params = "dx dy [dz]",
652 .help = "send mouse move events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300653 .mhandler.cmd = do_mouse_move,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300654 },
655
Blue Swirl23130862009-06-06 08:22:04 +0000656STEXI
657@item mouse_move @var{dx} @var{dy} [@var{dz}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100658@findex mouse_move
Blue Swirl23130862009-06-06 08:22:04 +0000659Move the active mouse to the specified coordinates @var{dx} @var{dy}
660with optional scroll axis @var{dz}.
661ETEXI
662
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300663 {
664 .name = "mouse_button",
665 .args_type = "button_state:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300666 .params = "state",
667 .help = "change mouse button state (1=L, 2=M, 4=R)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300668 .mhandler.cmd = do_mouse_button,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300669 },
670
Blue Swirl23130862009-06-06 08:22:04 +0000671STEXI
672@item mouse_button @var{val}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100673@findex mouse_button
Blue Swirl23130862009-06-06 08:22:04 +0000674Change the active mouse button state @var{val} (1=L, 2=M, 4=R).
675ETEXI
676
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300677 {
678 .name = "mouse_set",
679 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300680 .params = "index",
681 .help = "set which mouse device receives events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300682 .mhandler.cmd = do_mouse_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300683 },
684
Blue Swirl23130862009-06-06 08:22:04 +0000685STEXI
686@item mouse_set @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100687@findex mouse_set
Blue Swirl23130862009-06-06 08:22:04 +0000688Set which mouse device receives events at given @var{index}, index
689can be obtained with
690@example
691info mice
692@end example
693ETEXI
694
695#ifdef HAS_AUDIO
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300696 {
697 .name = "wavcapture",
698 .args_type = "path:F,freq:i?,bits:i?,nchannels:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300699 .params = "path [frequency [bits [channels]]]",
700 .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300701 .mhandler.cmd = do_wav_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300702 },
Blue Swirl23130862009-06-06 08:22:04 +0000703#endif
704STEXI
705@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100706@findex wavcapture
Blue Swirl23130862009-06-06 08:22:04 +0000707Capture audio into @var{filename}. Using sample rate @var{frequency}
708bits per sample @var{bits} and number of channels @var{channels}.
709
710Defaults:
711@itemize @minus
712@item Sample rate = 44100 Hz - CD quality
713@item Bits = 16
714@item Number of channels = 2 - Stereo
715@end itemize
716ETEXI
717
718#ifdef HAS_AUDIO
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300719 {
720 .name = "stopcapture",
721 .args_type = "n:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300722 .params = "capture index",
723 .help = "stop capture",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300724 .mhandler.cmd = do_stop_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300725 },
Blue Swirl23130862009-06-06 08:22:04 +0000726#endif
727STEXI
728@item stopcapture @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100729@findex stopcapture
Blue Swirl23130862009-06-06 08:22:04 +0000730Stop capture with a given @var{index}, index can be obtained with
731@example
732info capture
733@end example
734ETEXI
735
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300736 {
737 .name = "memsave",
738 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300739 .params = "addr size file",
740 .help = "save to disk virtual memory dump starting at 'addr' of size 'size'",
Luiz Capitulino0cfd6a92011-11-22 16:32:37 -0200741 .mhandler.cmd = hmp_memsave,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300742 },
743
Blue Swirl23130862009-06-06 08:22:04 +0000744STEXI
745@item memsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100746@findex memsave
Blue Swirl23130862009-06-06 08:22:04 +0000747save to disk virtual memory dump starting at @var{addr} of size @var{size}.
748ETEXI
749
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300750 {
751 .name = "pmemsave",
752 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300753 .params = "addr size file",
754 .help = "save to disk physical memory dump starting at 'addr' of size 'size'",
Luiz Capitulino6d3962b2011-11-22 17:26:46 -0200755 .mhandler.cmd = hmp_pmemsave,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300756 },
757
Blue Swirl23130862009-06-06 08:22:04 +0000758STEXI
759@item pmemsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100760@findex pmemsave
Blue Swirl23130862009-06-06 08:22:04 +0000761save to disk physical memory dump starting at @var{addr} of size @var{size}.
762ETEXI
763
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300764 {
765 .name = "boot_set",
766 .args_type = "bootdevice:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300767 .params = "bootdevice",
768 .help = "define new values for the boot device list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300769 .mhandler.cmd = do_boot_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300770 },
771
Blue Swirl23130862009-06-06 08:22:04 +0000772STEXI
773@item boot_set @var{bootdevicelist}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100774@findex boot_set
Blue Swirl23130862009-06-06 08:22:04 +0000775
776Define new values for the boot device list. Those values will override
777the values specified on the command line through the @code{-boot} option.
778
779The values that can be specified here depend on the machine type, but are
780the same that can be specified in the @code{-boot} command line option.
781ETEXI
782
783#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300784 {
785 .name = "nmi",
Luiz Capitulinoe9b4b432011-04-29 12:11:50 -0300786 .args_type = "",
787 .params = "",
788 .help = "inject an NMI on all guest's CPUs",
Luiz Capitulinoab49ab52011-11-23 12:55:53 -0200789 .mhandler.cmd = hmp_inject_nmi,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300790 },
Blue Swirl23130862009-06-06 08:22:04 +0000791#endif
792STEXI
793@item nmi @var{cpu}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100794@findex nmi
Blue Swirl23130862009-06-06 08:22:04 +0000795Inject an NMI on the given CPU (x86 only).
796ETEXI
797
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300798 {
799 .name = "migrate",
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200800 .args_type = "detach:-d,blk:-b,inc:-i,uri:s",
801 .params = "[-d] [-b] [-i] uri",
802 .help = "migrate to URI (using -d to not wait for completion)"
803 "\n\t\t\t -b for migration without shared storage with"
804 " full copy of disk\n\t\t\t -i for migration without "
805 "shared storage with incremental copy of disk "
806 "(base image shared between src and destination)",
Luiz Capitulinoe1c37d02011-12-05 14:48:01 -0200807 .mhandler.cmd = hmp_migrate,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300808 },
809
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200810
Blue Swirl23130862009-06-06 08:22:04 +0000811STEXI
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200812@item migrate [-d] [-b] [-i] @var{uri}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100813@findex migrate
Blue Swirl23130862009-06-06 08:22:04 +0000814Migrate to @var{uri} (using -d to not wait for completion).
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200815 -b for migration with full copy of disk
816 -i for migration with incremental copy of disk (base image is shared)
Blue Swirl23130862009-06-06 08:22:04 +0000817ETEXI
818
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300819 {
820 .name = "migrate_cancel",
821 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300822 .params = "",
823 .help = "cancel the current VM migration",
Luiz Capitulino6cdedb02011-11-27 22:54:09 -0200824 .mhandler.cmd = hmp_migrate_cancel,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300825 },
826
Blue Swirl23130862009-06-06 08:22:04 +0000827STEXI
828@item migrate_cancel
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100829@findex migrate_cancel
Blue Swirl23130862009-06-06 08:22:04 +0000830Cancel the current VM migration.
Orit Wasserman9e1ba4c2012-08-06 21:42:54 +0300831
832ETEXI
833
834 {
835 .name = "migrate_set_cache_size",
836 .args_type = "value:o",
837 .params = "value",
838 .help = "set cache size (in bytes) for XBZRLE migrations,"
839 "the cache size will be rounded down to the nearest "
840 "power of 2.\n"
841 "The cache size affects the number of cache misses."
842 "In case of a high cache miss ratio you need to increase"
843 " the cache size",
844 .mhandler.cmd = hmp_migrate_set_cache_size,
845 },
846
847STEXI
848@item migrate_set_cache_size @var{value}
849@findex migrate_set_cache_size
850Set cache size to @var{value} (in bytes) for xbzrle migrations.
Blue Swirl23130862009-06-06 08:22:04 +0000851ETEXI
852
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300853 {
854 .name = "migrate_set_speed",
Jes Sorensened3d4a82010-10-21 17:15:48 +0200855 .args_type = "value:o",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300856 .params = "value",
Jes Sorensened3d4a82010-10-21 17:15:48 +0200857 .help = "set maximum speed (in bytes) for migrations. "
858 "Defaults to MB if no size suffix is specified, ie. B/K/M/G/T",
Luiz Capitulino3dc85382011-11-28 11:59:37 -0200859 .mhandler.cmd = hmp_migrate_set_speed,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300860 },
861
Blue Swirl23130862009-06-06 08:22:04 +0000862STEXI
863@item migrate_set_speed @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100864@findex migrate_set_speed
Blue Swirl23130862009-06-06 08:22:04 +0000865Set maximum speed to @var{value} (in bytes) for migrations.
866ETEXI
867
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300868 {
869 .name = "migrate_set_downtime",
Markus Armbrusterb0fbf7d2010-01-25 14:23:07 +0100870 .args_type = "value:T",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300871 .params = "value",
872 .help = "set maximum tolerated downtime (in seconds) for migrations",
Luiz Capitulino4f0a9932011-11-27 23:18:01 -0200873 .mhandler.cmd = hmp_migrate_set_downtime,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300874 },
Glauber Costa2ea42952009-05-28 15:22:58 -0400875
876STEXI
877@item migrate_set_downtime @var{second}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100878@findex migrate_set_downtime
Glauber Costa2ea42952009-05-28 15:22:58 -0400879Set maximum tolerated downtime (in seconds) for migration.
880ETEXI
881
Jes Sorensenf8882562010-12-16 13:52:16 +0100882 {
Orit Wasserman00458432012-08-06 21:42:48 +0300883 .name = "migrate_set_capability",
884 .args_type = "capability:s,state:b",
885 .params = "capability state",
886 .help = "Enable/Disable the usage of a capability for migration",
887 .mhandler.cmd = hmp_migrate_set_capability,
888 },
889
890STEXI
891@item migrate_set_capability @var{capability} @var{state}
892@findex migrate_set_capability
893Enable/Disable the usage of a capability @var{capability} for migration.
894ETEXI
895
896 {
Jes Sorensen2ea720d2011-03-09 16:54:34 +0100897 .name = "client_migrate_info",
898 .args_type = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?",
899 .params = "protocol hostname port tls-port cert-subject",
900 .help = "send migration info to spice/vnc client",
901 .user_print = monitor_user_noop,
Yonit Halperinedc5cb12011-10-17 10:03:18 +0200902 .mhandler.cmd_async = client_migrate_info,
903 .flags = MONITOR_CMD_ASYNC,
Jes Sorensenf8882562010-12-16 13:52:16 +0100904 },
905
906STEXI
Gerd Hoffmanne866e232010-04-23 13:28:21 +0200907@item client_migrate_info @var{protocol} @var{hostname} @var{port} @var{tls-port} @var{cert-subject}
908@findex client_migrate_info
909Set the spice/vnc connection info for the migration target. The spice/vnc
910server will ask the spice/vnc client to automatically reconnect using the
911new parameters (if specified) once the vm migration finished successfully.
912ETEXI
913
Wen Congyang783e9b42012-05-07 12:10:47 +0800914#if defined(CONFIG_HAVE_CORE_DUMP)
915 {
916 .name = "dump-guest-memory",
917 .args_type = "paging:-p,protocol:s,begin:i?,length:i?",
918 .params = "[-p] protocol [begin] [length]",
919 .help = "dump guest memory to file"
920 "\n\t\t\t begin(optional): the starting physical address"
921 "\n\t\t\t length(optional): the memory size, in bytes",
922 .user_print = monitor_user_noop,
923 .mhandler.cmd = hmp_dump_guest_memory,
924 },
925
926
927STEXI
928@item dump-guest-memory [-p] @var{protocol} @var{begin} @var{length}
929@findex dump-guest-memory
930Dump guest memory to @var{protocol}. The file can be processed with crash or
931gdb.
932 protocol: destination file(started with "file:") or destination file
933 descriptor (started with "fd:")
934 paging: do paging to get guest's memory mapping
935 begin: the starting physical address. It's optional, and should be
936 specified with length together.
937 length: the memory size, in bytes. It's optional, and should be specified
938 with begin together.
939ETEXI
940#endif
941
Gerd Hoffmanne866e232010-04-23 13:28:21 +0200942 {
Jes Sorensen2ea720d2011-03-09 16:54:34 +0100943 .name = "snapshot_blkdev",
Paolo Bonzini6cc2a412012-03-06 18:55:59 +0100944 .args_type = "reuse:-n,device:B,snapshot-file:s?,format:s?",
945 .params = "[-n] device [new-image-file] [format]",
Jes Sorensen2ea720d2011-03-09 16:54:34 +0100946 .help = "initiates a live snapshot\n\t\t\t"
947 "of device. If a new image file is specified, the\n\t\t\t"
948 "new image file will become the new root image.\n\t\t\t"
949 "If format is specified, the snapshot file will\n\t\t\t"
950 "be created in that format. Otherwise the\n\t\t\t"
Paolo Bonzini6cc2a412012-03-06 18:55:59 +0100951 "snapshot will be internal! (currently unsupported).\n\t\t\t"
952 "The default format is qcow2. The -n flag requests QEMU\n\t\t\t"
953 "to reuse the image found in new-image-file, instead of\n\t\t\t"
954 "recreating it from scratch.",
Luiz Capitulino6106e242011-11-25 16:15:19 -0200955 .mhandler.cmd = hmp_snapshot_blkdev,
Gerd Hoffmanne866e232010-04-23 13:28:21 +0200956 },
957
958STEXI
Jes Sorensenf8882562010-12-16 13:52:16 +0100959@item snapshot_blkdev
960@findex snapshot_blkdev
961Snapshot device, using snapshot file as target if provided
962ETEXI
963
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300964 {
965 .name = "drive_add",
966 .args_type = "pci_addr:s,opts:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300967 .params = "[[<domain>:]<bus>:]<slot>\n"
968 "[file=file][,if=type][,bus=n]\n"
Stefan Hajnoczifb0490f2011-11-17 13:40:32 +0000969 "[,unit=m][,media=d][,index=i]\n"
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300970 "[,cyls=c,heads=h,secs=s[,trans=t]]\n"
Stefan Hajnoczifb0490f2011-11-17 13:40:32 +0000971 "[,snapshot=on|off][,cache=on|off]\n"
972 "[,readonly=on|off][,copy-on-read=on|off]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300973 .help = "add drive to PCI storage controller",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300974 .mhandler.cmd = drive_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300975 },
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300976
Blue Swirl23130862009-06-06 08:22:04 +0000977STEXI
978@item drive_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100979@findex drive_add
Blue Swirl23130862009-06-06 08:22:04 +0000980Add drive to PCI storage controller.
981ETEXI
982
983#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300984 {
985 .name = "pci_add",
986 .args_type = "pci_addr:s,type:s,opts:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300987 .params = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...",
988 .help = "hot-add PCI device",
Markus Armbruster6c6a58a2010-05-12 10:53:00 +0200989 .mhandler.cmd = pci_device_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300990 },
Blue Swirl23130862009-06-06 08:22:04 +0000991#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300992
Blue Swirl23130862009-06-06 08:22:04 +0000993STEXI
994@item pci_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100995@findex pci_add
Blue Swirl23130862009-06-06 08:22:04 +0000996Hot-add PCI device.
997ETEXI
998
999#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001000 {
1001 .name = "pci_del",
1002 .args_type = "pci_addr:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001003 .params = "[[<domain>:]<bus>:]<slot>",
1004 .help = "hot remove PCI device",
Markus Armbrusterb752daf2010-05-12 10:53:01 +02001005 .mhandler.cmd = do_pci_device_hot_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001006 },
Blue Swirl23130862009-06-06 08:22:04 +00001007#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001008
Blue Swirl23130862009-06-06 08:22:04 +00001009STEXI
1010@item pci_del
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001011@findex pci_del
Blue Swirl23130862009-06-06 08:22:04 +00001012Hot remove PCI device.
1013ETEXI
1014
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001015 {
Isaku Yamahata2ae63bd2010-12-24 12:14:14 +09001016 .name = "pcie_aer_inject_error",
1017 .args_type = "advisory_non_fatal:-a,correctable:-c,"
1018 "id:s,error_status:s,"
1019 "header0:i?,header1:i?,header2:i?,header3:i?,"
1020 "prefix0:i?,prefix1:i?,prefix2:i?,prefix3:i?",
1021 .params = "[-a] [-c] id "
1022 "<error_status> [<tlp header> [<tlp header prefix>]]",
1023 .help = "inject pcie aer error\n\t\t\t"
1024 " -a for advisory non fatal error\n\t\t\t"
1025 " -c for correctable error\n\t\t\t"
1026 "<id> = qdev device id\n\t\t\t"
1027 "<error_status> = error string or 32bit\n\t\t\t"
1028 "<tlb header> = 32bit x 4\n\t\t\t"
1029 "<tlb header prefix> = 32bit x 4",
1030 .user_print = pcie_aer_inject_error_print,
Zhi Yong Wu1f3392b2011-11-30 12:39:47 +08001031 .mhandler.cmd_new = do_pcie_aer_inject_error,
Isaku Yamahata2ae63bd2010-12-24 12:14:14 +09001032 },
1033
1034STEXI
1035@item pcie_aer_inject_error
1036@findex pcie_aer_inject_error
1037Inject PCIe AER error
1038ETEXI
1039
1040 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001041 .name = "host_net_add",
1042 .args_type = "device:s,opts:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001043 .params = "tap|user|socket|vde|dump [options]",
1044 .help = "add host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001045 .mhandler.cmd = net_host_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001046 },
1047
Blue Swirl23130862009-06-06 08:22:04 +00001048STEXI
1049@item host_net_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001050@findex host_net_add
Blue Swirl23130862009-06-06 08:22:04 +00001051Add host VLAN client.
1052ETEXI
1053
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001054 {
1055 .name = "host_net_remove",
1056 .args_type = "vlan_id:i,device:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001057 .params = "vlan_id name",
1058 .help = "remove host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001059 .mhandler.cmd = net_host_device_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001060 },
1061
Blue Swirl23130862009-06-06 08:22:04 +00001062STEXI
1063@item host_net_remove
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001064@findex host_net_remove
Blue Swirl23130862009-06-06 08:22:04 +00001065Remove host VLAN client.
1066ETEXI
1067
Markus Armbrusterae82d322010-03-25 17:22:40 +01001068 {
1069 .name = "netdev_add",
1070 .args_type = "netdev:O",
1071 .params = "[user|tap|socket],id=str[,prop=value][,...]",
1072 .help = "add host network device",
Luiz Capitulino928059a2012-04-18 17:34:15 -03001073 .mhandler.cmd = hmp_netdev_add,
Markus Armbrusterae82d322010-03-25 17:22:40 +01001074 },
1075
1076STEXI
1077@item netdev_add
1078@findex netdev_add
1079Add host network device.
1080ETEXI
1081
1082 {
1083 .name = "netdev_del",
1084 .args_type = "id:s",
1085 .params = "id",
1086 .help = "remove host network device",
Luiz Capitulino5f964152012-04-16 14:36:32 -03001087 .mhandler.cmd = hmp_netdev_del,
Markus Armbrusterae82d322010-03-25 17:22:40 +01001088 },
1089
1090STEXI
1091@item netdev_del
1092@findex netdev_del
1093Remove host network device.
1094ETEXI
1095
Blue Swirl23130862009-06-06 08:22:04 +00001096#ifdef CONFIG_SLIRP
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001097 {
1098 .name = "hostfwd_add",
1099 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001100 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport",
1101 .help = "redirect TCP or UDP connections from host to guest (requires -net user)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001102 .mhandler.cmd = net_slirp_hostfwd_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001103 },
Markus Armbruster21413d62010-05-04 13:20:30 +02001104#endif
1105STEXI
1106@item hostfwd_add
1107@findex hostfwd_add
1108Redirect TCP or UDP connections from host to guest (requires -net user).
1109ETEXI
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001110
Markus Armbruster21413d62010-05-04 13:20:30 +02001111#ifdef CONFIG_SLIRP
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001112 {
1113 .name = "hostfwd_remove",
1114 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001115 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport",
1116 .help = "remove host-to-guest TCP or UDP redirection",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001117 .mhandler.cmd = net_slirp_hostfwd_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001118 },
1119
Blue Swirl23130862009-06-06 08:22:04 +00001120#endif
1121STEXI
Markus Armbruster21413d62010-05-04 13:20:30 +02001122@item hostfwd_remove
1123@findex hostfwd_remove
1124Remove host-to-guest TCP or UDP redirection.
Blue Swirl23130862009-06-06 08:22:04 +00001125ETEXI
1126
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001127 {
1128 .name = "balloon",
Luiz Capitulino3b0bd6e2009-12-18 13:25:05 -02001129 .args_type = "value:M",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001130 .params = "target",
Riccardo Magliocchetti3c056132010-05-19 18:49:28 +02001131 .help = "request VM to change its memory allocation (in MB)",
Luiz Capitulinod72f3262011-11-25 14:38:09 -02001132 .mhandler.cmd = hmp_balloon,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001133 },
1134
Blue Swirl23130862009-06-06 08:22:04 +00001135STEXI
1136@item balloon @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001137@findex balloon
Blue Swirl23130862009-06-06 08:22:04 +00001138Request VM to change its memory allocation to @var{value} (in MB).
1139ETEXI
1140
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001141 {
1142 .name = "set_link",
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001143 .args_type = "name:s,up:b",
1144 .params = "name on|off",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001145 .help = "change the link status of a network adapter",
Luiz Capitulino4b371562011-11-23 13:11:55 -02001146 .mhandler.cmd = hmp_set_link,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001147 },
1148
Blue Swirl23130862009-06-06 08:22:04 +00001149STEXI
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001150@item set_link @var{name} [on|off]
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001151@findex set_link
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001152Switch link @var{name} on (i.e. up) or off (i.e. down).
Blue Swirl23130862009-06-06 08:22:04 +00001153ETEXI
1154
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001155 {
1156 .name = "watchdog_action",
1157 .args_type = "action:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001158 .params = "[reset|shutdown|poweroff|pause|debug|none]",
1159 .help = "change watchdog action",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001160 .mhandler.cmd = do_watchdog_action,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001161 },
1162
Blue Swirl23130862009-06-06 08:22:04 +00001163STEXI
1164@item watchdog_action
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001165@findex watchdog_action
Blue Swirl23130862009-06-06 08:22:04 +00001166Change watchdog action.
1167ETEXI
1168
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001169 {
1170 .name = "acl_show",
1171 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001172 .params = "aclname",
1173 .help = "list rules in the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001174 .mhandler.cmd = do_acl_show,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001175 },
1176
Blue Swirl23130862009-06-06 08:22:04 +00001177STEXI
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001178@item acl_show @var{aclname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001179@findex acl_show
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001180List all the matching rules in the access control list, and the default
1181policy. There are currently two named access control lists,
1182@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client
1183certificate distinguished name, and SASL username respectively.
1184ETEXI
Blue Swirl23130862009-06-06 08:22:04 +00001185
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001186 {
1187 .name = "acl_policy",
1188 .args_type = "aclname:s,policy:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001189 .params = "aclname allow|deny",
1190 .help = "set default access control list policy",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001191 .mhandler.cmd = do_acl_policy,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001192 },
1193
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001194STEXI
Jan Kiszkacbbfacc2009-07-03 08:46:05 +02001195@item acl_policy @var{aclname} @code{allow|deny}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001196@findex acl_policy
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001197Set the default access control list policy, used in the event that
Blue Swirl23130862009-06-06 08:22:04 +00001198none of the explicit rules match. The default policy at startup is
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001199always @code{deny}.
1200ETEXI
1201
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001202 {
1203 .name = "acl_add",
1204 .args_type = "aclname:s,match:s,policy:s,index:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001205 .params = "aclname match allow|deny [index]",
1206 .help = "add a match rule to the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001207 .mhandler.cmd = do_acl_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001208 },
1209
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001210STEXI
Markus Armbruster0e4aec92010-05-04 13:20:31 +02001211@item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}]
1212@findex acl_add
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001213Add a match rule to the access control list, allowing or denying access.
1214The match will normally be an exact username or x509 distinguished name,
1215but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to
1216allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will
Blue Swirl23130862009-06-06 08:22:04 +00001217normally be appended to the end of the ACL, but can be inserted
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001218earlier in the list if the optional @var{index} parameter is supplied.
1219ETEXI
1220
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001221 {
1222 .name = "acl_remove",
1223 .args_type = "aclname:s,match:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001224 .params = "aclname match",
1225 .help = "remove a match rule from the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001226 .mhandler.cmd = do_acl_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001227 },
1228
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001229STEXI
1230@item acl_remove @var{aclname} @var{match}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001231@findex acl_remove
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001232Remove the specified match rule from the access control list.
1233ETEXI
1234
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001235 {
1236 .name = "acl_reset",
1237 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001238 .params = "aclname",
1239 .help = "reset the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001240 .mhandler.cmd = do_acl_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001241 },
1242
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001243STEXI
Markus Armbruster0e4aec92010-05-04 13:20:31 +02001244@item acl_reset @var{aclname}
1245@findex acl_reset
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001246Remove all matches from the access control list, and set the default
Blue Swirl23130862009-06-06 08:22:04 +00001247policy back to @code{deny}.
Blue Swirl23130862009-06-06 08:22:04 +00001248ETEXI
1249
Huang Ying79c4f6b2009-06-23 10:05:14 +08001250#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001251
1252 {
1253 .name = "mce",
Jin Dongming31ce5e02010-12-10 17:21:02 +09001254 .args_type = "broadcast:-b,cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l",
1255 .params = "[-b] cpu bank status mcgstatus addr misc",
1256 .help = "inject a MCE on the given CPU [and broadcast to other CPUs with -b option]",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001257 .mhandler.cmd = do_inject_mce,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001258 },
1259
Huang Ying79c4f6b2009-06-23 10:05:14 +08001260#endif
1261STEXI
1262@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001263@findex mce (x86)
Huang Ying79c4f6b2009-06-23 10:05:14 +08001264Inject an MCE on the given CPU (x86 only).
1265ETEXI
1266
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001267 {
1268 .name = "getfd",
1269 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001270 .params = "getfd name",
1271 .help = "receive a file descriptor via SCM rights and assign it a name",
Corey Bryant208c9d12012-06-22 14:36:09 -04001272 .mhandler.cmd = hmp_getfd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001273 },
1274
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001275STEXI
1276@item getfd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001277@findex getfd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001278If a file descriptor is passed alongside this command using the SCM_RIGHTS
1279mechanism on unix sockets, it is stored using the name @var{fdname} for
1280later use by other monitor commands.
1281ETEXI
1282
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001283 {
1284 .name = "closefd",
1285 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001286 .params = "closefd name",
1287 .help = "close a file descriptor previously passed via SCM rights",
Corey Bryant208c9d12012-06-22 14:36:09 -04001288 .mhandler.cmd = hmp_closefd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001289 },
1290
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001291STEXI
1292@item closefd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001293@findex closefd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001294Close the file descriptor previously assigned to @var{fdname} using the
1295@code{getfd} command. This is only needed if the file descriptor was never
1296used by another monitor command.
1297ETEXI
1298
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001299 {
1300 .name = "block_passwd",
1301 .args_type = "device:B,password:s",
1302 .params = "block_passwd device password",
1303 .help = "set the password of encrypted block devices",
Luiz Capitulinoa4dea8a2011-11-23 13:28:21 -02001304 .mhandler.cmd = hmp_block_passwd,
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001305 },
1306
1307STEXI
Zhi Yong Wu727f0052011-11-08 13:00:31 +08001308@item block_set_io_throttle @var{device} @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr}
1309@findex block_set_io_throttle
1310Change I/O throttle limits for a block drive to @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr}
1311ETEXI
1312
1313 {
1314 .name = "block_set_io_throttle",
1315 .args_type = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l",
1316 .params = "device bps bps_rd bps_wr iops iops_rd iops_wr",
1317 .help = "change I/O throttle limits for a block drive",
Luiz Capitulino80047da2011-12-14 16:49:14 -02001318 .mhandler.cmd = hmp_block_set_io_throttle,
Zhi Yong Wu727f0052011-11-08 13:00:31 +08001319 },
1320
1321STEXI
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001322@item block_passwd @var{device} @var{password}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001323@findex block_passwd
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001324Set the encrypted device @var{device} password to @var{password}
1325ETEXI
Jan Kiszkab40292e2010-05-31 14:43:31 -03001326
Jan Kiszka33572ec2010-05-31 14:43:30 -03001327 {
Gerd Hoffmann75721502010-10-07 12:22:54 +02001328 .name = "set_password",
1329 .args_type = "protocol:s,password:s,connected:s?",
1330 .params = "protocol password action-if-connected",
1331 .help = "set spice/vnc password",
Luiz Capitulinofbf796f2011-12-07 11:17:51 -02001332 .mhandler.cmd = hmp_set_password,
Gerd Hoffmann75721502010-10-07 12:22:54 +02001333 },
1334
1335STEXI
1336@item set_password [ vnc | spice ] password [ action-if-connected ]
1337@findex set_password
1338
1339Change spice/vnc password. Use zero to make the password stay valid
1340forever. @var{action-if-connected} specifies what should happen in
1341case a connection is established: @var{fail} makes the password change
1342fail. @var{disconnect} changes the password and disconnects the
1343client. @var{keep} changes the password and keeps the connection up.
1344@var{keep} is the default.
1345ETEXI
1346
1347 {
1348 .name = "expire_password",
1349 .args_type = "protocol:s,time:s",
1350 .params = "protocol time",
1351 .help = "set spice/vnc password expire-time",
Luiz Capitulino9ad53722011-12-07 11:47:57 -02001352 .mhandler.cmd = hmp_expire_password,
Gerd Hoffmann75721502010-10-07 12:22:54 +02001353 },
1354
1355STEXI
1356@item expire_password [ vnc | spice ] expire-time
1357@findex expire_password
1358
1359Specify when a password for spice/vnc becomes
1360invalid. @var{expire-time} accepts:
1361
1362@table @var
1363@item now
1364Invalidate password instantly.
1365
1366@item never
1367Password stays valid forever.
1368
1369@item +nsec
1370Password stays valid for @var{nsec} seconds starting now.
1371
1372@item nsec
1373Password is invalidated at the given time. @var{nsec} are the seconds
1374passed since 1970, i.e. unix epoch.
1375
1376@end table
1377ETEXI
1378
1379 {
Jan Kiszka33572ec2010-05-31 14:43:30 -03001380 .name = "info",
1381 .args_type = "item:s?",
1382 .params = "[subcommand]",
1383 .help = "show various information about the system state",
Luiz Capitulino1162daa2010-09-13 12:15:26 -03001384 .mhandler.cmd = do_info,
Jan Kiszka33572ec2010-05-31 14:43:30 -03001385 },
1386
1387STEXI
1388@item info @var{subcommand}
1389@findex info
1390Show various information about the system state.
1391
1392@table @option
1393@item info version
1394show the version of QEMU
Jan Kiszka33572ec2010-05-31 14:43:30 -03001395@item info network
1396show the various VLANs and the associated devices
1397@item info chardev
1398show the character devices
1399@item info block
1400show the block devices
1401@item info blockstats
1402show block device statistics
1403@item info registers
1404show the cpu registers
1405@item info cpus
1406show infos for each CPU
1407@item info history
1408show the command line history
1409@item info irq
1410show the interrupts statistics (if available)
1411@item info pic
1412show i8259 (PIC) state
1413@item info pci
1414show emulated PCI device info
1415@item info tlb
Max Filippov692f7372012-01-07 20:02:40 +04001416show virtual to physical memory mappings (i386, SH4, SPARC, PPC, and Xtensa only)
Jan Kiszka33572ec2010-05-31 14:43:30 -03001417@item info mem
1418show the active virtual memory mappings (i386 only)
Jan Kiszka33572ec2010-05-31 14:43:30 -03001419@item info jit
1420show dynamic compiler info
Jan Kiszka33572ec2010-05-31 14:43:30 -03001421@item info numa
1422show NUMA information
Jan Kiszkab40292e2010-05-31 14:43:31 -03001423@item info kvm
1424show KVM information
Jan Kiszka33572ec2010-05-31 14:43:30 -03001425@item info usb
1426show USB devices plugged on the virtual USB hub
1427@item info usbhost
1428show all USB host devices
1429@item info profile
1430show profiling information
1431@item info capture
1432show information about active capturing
1433@item info snapshots
1434show list of VM snapshots
1435@item info status
1436show the current VM status (running|paused)
1437@item info pcmcia
1438show guest PCMCIA status
1439@item info mice
1440show which guest mouse is receiving events
1441@item info vnc
1442show the vnc server status
1443@item info name
1444show the current VM name
1445@item info uuid
1446show the current VM UUID
1447@item info cpustats
1448show CPU statistics
1449@item info usernet
1450show user network stack connection states
1451@item info migrate
1452show migration status
Orit Wassermanbbf6da32012-08-06 21:42:47 +03001453@item info migrate_capabilities
1454show current migration capabilities
Orit Wasserman9e1ba4c2012-08-06 21:42:54 +03001455@item info migrate_cache_size
1456show current migration XBZRLE cache size
Jan Kiszka33572ec2010-05-31 14:43:30 -03001457@item info balloon
1458show balloon information
1459@item info qtree
1460show device tree
1461@item info qdm
1462show qdev device model list
1463@item info roms
1464show roms
1465@end table
1466ETEXI
1467
Lluís6d8a7642011-08-31 20:30:43 +02001468#ifdef CONFIG_TRACE_SIMPLE
Prerna Saxena22890ab2010-06-24 17:04:53 +05301469STEXI
1470@item info trace
1471show contents of trace buffer
Lluís31965ae2011-08-31 20:31:24 +02001472ETEXI
1473#endif
1474
1475STEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +05301476@item info trace-events
1477show available trace events and their state
1478ETEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +05301479
Blue Swirl23130862009-06-06 08:22:04 +00001480STEXI
1481@end table
1482ETEXI