blob: 4d5e2b5142fd0abba73b5cccf310b87f1e64a4d3 [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|?",
Wenchao Xia129be002013-08-27 20:38:26 +080014 .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",
Paolo Bonzini6e37fb82012-09-28 17:22:51 +0200102 .args_type = "force:-f,device:B",
103 .params = "[-f] device",
104 .help = "stop an active background block operation (use -f"
105 "\n\t\t\t if the operation is currently paused)",
Stefan Hajnoczi370521a2012-01-18 14:40:48 +0000106 .mhandler.cmd = hmp_block_job_cancel,
107 },
108
109STEXI
110@item block_job_cancel
111@findex block_job_cancel
Paolo Bonziniaeae8832012-10-18 16:49:21 +0200112Stop an active background block operation (streaming, mirroring).
113ETEXI
114
115 {
116 .name = "block_job_complete",
117 .args_type = "device:B",
118 .params = "device",
119 .help = "stop an active background block operation",
120 .mhandler.cmd = hmp_block_job_complete,
121 },
122
123STEXI
124@item block_job_complete
125@findex block_job_complete
126Manually trigger completion of an active background block operation.
127For mirroring, this will switch the device to the destination path.
Stefan Hajnoczi370521a2012-01-18 14:40:48 +0000128ETEXI
129
130 {
Paolo Bonzini6e37fb82012-09-28 17:22:51 +0200131 .name = "block_job_pause",
132 .args_type = "device:B",
133 .params = "device",
134 .help = "pause an active background block operation",
135 .mhandler.cmd = hmp_block_job_pause,
136 },
137
138STEXI
139@item block_job_pause
140@findex block_job_pause
141Pause an active block streaming operation.
142ETEXI
143
144 {
145 .name = "block_job_resume",
146 .args_type = "device:B",
147 .params = "device",
148 .help = "resume a paused background block operation",
149 .mhandler.cmd = hmp_block_job_resume,
150 },
151
152STEXI
153@item block_job_resume
154@findex block_job_resume
155Resume a paused block streaming operation.
156ETEXI
157
158 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300159 .name = "eject",
Luiz Capitulino78d714e2009-12-14 18:53:21 -0200160 .args_type = "force:-f,device:B",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300161 .params = "[-f] device",
162 .help = "eject a removable medium (use -f to force it)",
Luiz Capitulinoc245b6a2011-12-07 16:02:36 -0200163 .mhandler.cmd = hmp_eject,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300164 },
165
Blue Swirl23130862009-06-06 08:22:04 +0000166STEXI
167@item eject [-f] @var{device}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100168@findex eject
Blue Swirl23130862009-06-06 08:22:04 +0000169Eject a removable medium (use -f to force it).
170ETEXI
171
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300172 {
Ryan Harper9063f812010-11-12 11:07:13 -0600173 .name = "drive_del",
174 .args_type = "id:s",
175 .params = "device",
176 .help = "remove host block device",
177 .user_print = monitor_user_noop,
178 .mhandler.cmd_new = do_drive_del,
179 },
180
181STEXI
182@item drive_del @var{device}
183@findex drive_del
184Remove host block device. The result is that guest generated IO is no longer
185submitted against the host device underlying the disk. Once a drive has
186been deleted, the QEMU Block layer returns -EIO which results in IO
187errors in the guest for applications that are reading/writing to the device.
Stefan Hajnoczi293c51a2013-06-05 10:33:14 +0200188These errors are always reported to the guest, regardless of the drive's error
189actions (drive options rerror, werror).
Ryan Harper9063f812010-11-12 11:07:13 -0600190ETEXI
191
192 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300193 .name = "change",
194 .args_type = "device:B,target:F,arg:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300195 .params = "device filename [format]",
196 .help = "change a removable medium, optional format",
Luiz Capitulino333a96e2011-12-08 11:13:50 -0200197 .mhandler.cmd = hmp_change,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300198 },
199
Blue Swirl23130862009-06-06 08:22:04 +0000200STEXI
201@item change @var{device} @var{setting}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100202@findex change
Blue Swirl23130862009-06-06 08:22:04 +0000203
204Change the configuration of a device.
205
206@table @option
207@item change @var{diskdevice} @var{filename} [@var{format}]
208Change the medium for a removable disk device to point to @var{filename}. eg
209
210@example
211(qemu) change ide1-cd0 /path/to/some.iso
212@end example
213
214@var{format} is optional.
215
216@item change vnc @var{display},@var{options}
217Change the configuration of the VNC server. The valid syntax for @var{display}
218and @var{options} are described at @ref{sec_invocation}. eg
219
220@example
221(qemu) change vnc localhost:1
222@end example
223
224@item change vnc password [@var{password}]
225
226Change the password associated with the VNC server. If the new password is not
227supplied, the monitor will prompt for it to be entered. VNC passwords are only
228significant up to 8 letters. eg
229
230@example
231(qemu) change vnc password
232Password: ********
233@end example
234
235@end table
236ETEXI
237
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300238 {
239 .name = "screendump",
240 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300241 .params = "filename",
242 .help = "save screen into PPM image 'filename'",
Luiz Capitulinoad39cf62012-05-24 13:48:23 -0300243 .mhandler.cmd = hmp_screen_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300244 },
245
Blue Swirl23130862009-06-06 08:22:04 +0000246STEXI
247@item screendump @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100248@findex screendump
Blue Swirl23130862009-06-06 08:22:04 +0000249Save screen into PPM image @var{filename}.
250ETEXI
251
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300252 {
253 .name = "logfile",
254 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300255 .params = "filename",
256 .help = "output logs to 'filename'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300257 .mhandler.cmd = do_logfile,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300258 },
259
Blue Swirl23130862009-06-06 08:22:04 +0000260STEXI
261@item logfile @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100262@findex logfile
Blue Swirl23130862009-06-06 08:22:04 +0000263Output logs to @var{filename}.
264ETEXI
265
Prerna Saxena22890ab2010-06-24 17:04:53 +0530266 {
267 .name = "trace-event",
268 .args_type = "name:s,option:b",
269 .params = "name on|off",
270 .help = "changes status of a specific trace event",
LluĂ­sfc764102011-08-31 20:31:18 +0200271 .mhandler.cmd = do_trace_event_set_state,
Prerna Saxena22890ab2010-06-24 17:04:53 +0530272 },
273
274STEXI
275@item trace-event
276@findex trace-event
277changes status of a trace event
278ETEXI
Stefan Hajnoczic5ceb522010-07-13 09:26:33 +0100279
Michael Rothc45a8162011-10-02 08:44:37 -0500280#if defined(CONFIG_TRACE_SIMPLE)
Stefan Hajnoczic5ceb522010-07-13 09:26:33 +0100281 {
282 .name = "trace-file",
283 .args_type = "op:s?,arg:F?",
284 .params = "on|off|flush|set [arg]",
285 .help = "open, close, or flush trace file, or set a new file name",
286 .mhandler.cmd = do_trace_file,
287 },
288
289STEXI
290@item trace-file on|off|flush
291@findex trace-file
292Open, close, or flush the trace file. If no argument is given, the status of the trace file is displayed.
293ETEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +0530294#endif
295
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300296 {
297 .name = "log",
298 .args_type = "items:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300299 .params = "item1[,...]",
Peter Maydell989b6972013-02-26 17:52:40 +0000300 .help = "activate logging of the specified items",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300301 .mhandler.cmd = do_log,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300302 },
303
Blue Swirl23130862009-06-06 08:22:04 +0000304STEXI
305@item log @var{item1}[,...]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100306@findex log
Peter Maydell989b6972013-02-26 17:52:40 +0000307Activate logging of the specified items.
Blue Swirl23130862009-06-06 08:22:04 +0000308ETEXI
309
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300310 {
311 .name = "savevm",
312 .args_type = "name:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300313 .params = "[tag|id]",
314 .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300315 .mhandler.cmd = do_savevm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300316 },
317
Blue Swirl23130862009-06-06 08:22:04 +0000318STEXI
319@item savevm [@var{tag}|@var{id}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100320@findex savevm
Blue Swirl23130862009-06-06 08:22:04 +0000321Create a snapshot of the whole virtual machine. If @var{tag} is
322provided, it is used as human readable identifier. If there is already
323a snapshot with the same tag or ID, it is replaced. More info at
324@ref{vm_snapshots}.
325ETEXI
326
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300327 {
328 .name = "loadvm",
329 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300330 .params = "tag|id",
331 .help = "restore a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300332 .mhandler.cmd = do_loadvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300333 },
334
Blue Swirl23130862009-06-06 08:22:04 +0000335STEXI
336@item loadvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100337@findex loadvm
Blue Swirl23130862009-06-06 08:22:04 +0000338Set the whole virtual machine to the snapshot identified by the tag
339@var{tag} or the unique snapshot ID @var{id}.
340ETEXI
341
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300342 {
343 .name = "delvm",
344 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300345 .params = "tag|id",
346 .help = "delete a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300347 .mhandler.cmd = do_delvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300348 },
349
Blue Swirl23130862009-06-06 08:22:04 +0000350STEXI
351@item delvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100352@findex delvm
Blue Swirl23130862009-06-06 08:22:04 +0000353Delete the snapshot identified by @var{tag} or @var{id}.
354ETEXI
355
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300356 {
357 .name = "singlestep",
358 .args_type = "option:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300359 .params = "[on|off]",
360 .help = "run emulation in singlestep mode or switch to normal mode",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300361 .mhandler.cmd = do_singlestep,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300362 },
363
Blue Swirl23130862009-06-06 08:22:04 +0000364STEXI
365@item singlestep [off]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100366@findex singlestep
Blue Swirl23130862009-06-06 08:22:04 +0000367Run the emulation in single step mode.
368If called with option off, the emulation returns to normal mode.
369ETEXI
370
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300371 {
372 .name = "stop",
373 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300374 .params = "",
375 .help = "stop emulation",
Luiz Capitulino5f158f22011-09-15 14:34:39 -0300376 .mhandler.cmd = hmp_stop,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300377 },
378
Blue Swirl23130862009-06-06 08:22:04 +0000379STEXI
380@item stop
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100381@findex stop
Blue Swirl23130862009-06-06 08:22:04 +0000382Stop emulation.
383ETEXI
384
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300385 {
386 .name = "c|cont",
387 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300388 .params = "",
389 .help = "resume emulation",
Luiz Capitulinoe42e8182011-11-22 17:58:31 -0200390 .mhandler.cmd = hmp_cont,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300391 },
392
Blue Swirl23130862009-06-06 08:22:04 +0000393STEXI
394@item c or cont
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100395@findex cont
Blue Swirl23130862009-06-06 08:22:04 +0000396Resume emulation.
397ETEXI
398
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300399 {
Gerd Hoffmann9b9df252012-02-23 13:45:21 +0100400 .name = "system_wakeup",
401 .args_type = "",
402 .params = "",
403 .help = "wakeup guest from suspend",
404 .mhandler.cmd = hmp_system_wakeup,
405 },
406
407STEXI
408@item system_wakeup
409@findex system_wakeup
410Wakeup guest from suspend.
411ETEXI
412
413 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300414 .name = "gdbserver",
415 .args_type = "device:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300416 .params = "[device]",
417 .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300418 .mhandler.cmd = do_gdbserver,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300419 },
420
Blue Swirl23130862009-06-06 08:22:04 +0000421STEXI
422@item gdbserver [@var{port}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100423@findex gdbserver
Blue Swirl23130862009-06-06 08:22:04 +0000424Start gdbserver session (default @var{port}=1234)
425ETEXI
426
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300427 {
428 .name = "x",
429 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300430 .params = "/fmt addr",
431 .help = "virtual memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300432 .mhandler.cmd = do_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300433 },
434
Blue Swirl23130862009-06-06 08:22:04 +0000435STEXI
436@item x/fmt @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100437@findex x
Blue Swirl23130862009-06-06 08:22:04 +0000438Virtual memory dump starting at @var{addr}.
439ETEXI
440
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300441 {
442 .name = "xp",
443 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300444 .params = "/fmt addr",
445 .help = "physical memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300446 .mhandler.cmd = do_physical_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300447 },
448
Blue Swirl23130862009-06-06 08:22:04 +0000449STEXI
450@item xp /@var{fmt} @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100451@findex xp
Blue Swirl23130862009-06-06 08:22:04 +0000452Physical memory dump starting at @var{addr}.
453
454@var{fmt} is a format which tells the command how to format the
455data. Its syntax is: @option{/@{count@}@{format@}@{size@}}
456
457@table @var
458@item count
459is the number of items to be dumped.
460
461@item format
462can be x (hex), d (signed decimal), u (unsigned decimal), o (octal),
463c (char) or i (asm instruction).
464
465@item size
466can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86,
467@code{h} or @code{w} can be specified with the @code{i} format to
468respectively select 16 or 32 bit code instruction size.
469
470@end table
471
472Examples:
473@itemize
474@item
475Dump 10 instructions at the current instruction pointer:
476@example
477(qemu) x/10i $eip
4780x90107063: ret
4790x90107064: sti
4800x90107065: lea 0x0(%esi,1),%esi
4810x90107069: lea 0x0(%edi,1),%edi
4820x90107070: ret
4830x90107071: jmp 0x90107080
4840x90107073: nop
4850x90107074: nop
4860x90107075: nop
4870x90107076: nop
488@end example
489
490@item
491Dump 80 16 bit values at the start of the video memory.
492@smallexample
493(qemu) xp/80hx 0xb8000
4940x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42
4950x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41
4960x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72
4970x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73
4980x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20
4990x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720
5000x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
5010x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
5020x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
5030x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
504@end smallexample
505@end itemize
506ETEXI
507
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300508 {
509 .name = "p|print",
510 .args_type = "fmt:/,val:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300511 .params = "/fmt expr",
512 .help = "print expression value (use $reg for CPU register access)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300513 .mhandler.cmd = do_print,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300514 },
515
Blue Swirl23130862009-06-06 08:22:04 +0000516STEXI
517@item p or print/@var{fmt} @var{expr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100518@findex print
Blue Swirl23130862009-06-06 08:22:04 +0000519
520Print expression value. Only the @var{format} part of @var{fmt} is
521used.
522ETEXI
523
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300524 {
525 .name = "i",
526 .args_type = "fmt:/,addr:i,index:i.",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300527 .params = "/fmt addr",
528 .help = "I/O port read",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300529 .mhandler.cmd = do_ioport_read,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300530 },
531
Blue Swirl23130862009-06-06 08:22:04 +0000532STEXI
533Read I/O port.
534ETEXI
535
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300536 {
537 .name = "o",
538 .args_type = "fmt:/,addr:i,val:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300539 .params = "/fmt addr value",
540 .help = "I/O port write",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300541 .mhandler.cmd = do_ioport_write,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300542 },
543
Jan Kiszkaf1147842009-07-14 10:20:11 +0200544STEXI
545Write to I/O port.
546ETEXI
Blue Swirl23130862009-06-06 08:22:04 +0000547
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300548 {
549 .name = "sendkey",
Amos Kong2ef20c12012-08-31 10:56:22 +0800550 .args_type = "keys:s,hold-time:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300551 .params = "keys [hold_ms]",
552 .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)",
Amos Konge4c8f002012-08-31 10:56:26 +0800553 .mhandler.cmd = hmp_send_key,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300554 },
555
Blue Swirl23130862009-06-06 08:22:04 +0000556STEXI
557@item sendkey @var{keys}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100558@findex sendkey
Blue Swirl23130862009-06-06 08:22:04 +0000559
Amos Kong886cc702012-08-31 10:56:20 +0800560Send @var{keys} to the guest. @var{keys} could be the name of the
561key or the raw value in hexadecimal format. Use @code{-} to press
562several keys simultaneously. Example:
Blue Swirl23130862009-06-06 08:22:04 +0000563@example
564sendkey ctrl-alt-f1
565@end example
566
567This command is useful to send keys that your graphical user interface
568intercepts at low level, such as @code{ctrl-alt-f1} in X Window.
569ETEXI
570
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300571 {
572 .name = "system_reset",
573 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300574 .params = "",
575 .help = "reset the system",
Luiz Capitulino38d22652011-09-15 14:41:46 -0300576 .mhandler.cmd = hmp_system_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300577 },
578
Blue Swirl23130862009-06-06 08:22:04 +0000579STEXI
580@item system_reset
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100581@findex system_reset
Blue Swirl23130862009-06-06 08:22:04 +0000582
583Reset the system.
584ETEXI
585
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300586 {
587 .name = "system_powerdown",
588 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300589 .params = "",
590 .help = "send system power down event",
Luiz Capitulino5bc465e2011-09-28 11:06:15 -0300591 .mhandler.cmd = hmp_system_powerdown,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300592 },
593
Blue Swirl23130862009-06-06 08:22:04 +0000594STEXI
595@item system_powerdown
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100596@findex system_powerdown
Blue Swirl23130862009-06-06 08:22:04 +0000597
598Power down the system (if supported).
599ETEXI
600
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300601 {
602 .name = "sum",
603 .args_type = "start:i,size:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300604 .params = "addr size",
605 .help = "compute the checksum of a memory region",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300606 .mhandler.cmd = do_sum,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300607 },
608
Blue Swirl23130862009-06-06 08:22:04 +0000609STEXI
610@item sum @var{addr} @var{size}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100611@findex sum
Blue Swirl23130862009-06-06 08:22:04 +0000612
613Compute the checksum of a memory region.
614ETEXI
615
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300616 {
617 .name = "usb_add",
618 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300619 .params = "device",
620 .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300621 .mhandler.cmd = do_usb_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300622 },
623
Blue Swirl23130862009-06-06 08:22:04 +0000624STEXI
625@item usb_add @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100626@findex usb_add
Blue Swirl23130862009-06-06 08:22:04 +0000627
628Add the USB device @var{devname}. For details of available devices see
629@ref{usb_devices}
630ETEXI
631
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300632 {
633 .name = "usb_del",
634 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300635 .params = "device",
636 .help = "remove USB device 'bus.addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300637 .mhandler.cmd = do_usb_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300638 },
639
Blue Swirl23130862009-06-06 08:22:04 +0000640STEXI
641@item usb_del @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100642@findex usb_del
Blue Swirl23130862009-06-06 08:22:04 +0000643
644Remove the USB device @var{devname} from the QEMU virtual USB
645hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor
646command @code{info usb} to see the devices you can remove.
647ETEXI
648
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300649 {
650 .name = "device_add",
Markus Armbrusterc7e4e8c2010-02-10 20:47:28 +0100651 .args_type = "device:O",
652 .params = "driver[,prop=value][,...]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300653 .help = "add device, like -device on the command line",
Markus Armbruster8bc27242010-02-10 20:52:01 +0100654 .user_print = monitor_user_noop,
655 .mhandler.cmd_new = do_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300656 },
657
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200658STEXI
659@item device_add @var{config}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100660@findex device_add
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200661
662Add device.
663ETEXI
664
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300665 {
666 .name = "device_del",
667 .args_type = "id:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300668 .params = "device",
669 .help = "remove device",
Luiz Capitulinoa15fef22012-03-29 12:38:50 -0300670 .mhandler.cmd = hmp_device_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300671 },
672
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200673STEXI
674@item device_del @var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100675@findex device_del
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200676
677Remove device @var{id}.
678ETEXI
679
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300680 {
681 .name = "cpu",
682 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300683 .params = "index",
684 .help = "set the default CPU",
Luiz Capitulino755f1962011-10-06 14:31:39 -0300685 .mhandler.cmd = hmp_cpu,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300686 },
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200687
Blue Swirl23130862009-06-06 08:22:04 +0000688STEXI
Markus Armbrusterc427ea92010-05-04 13:20:32 +0200689@item cpu @var{index}
690@findex cpu
Blue Swirl23130862009-06-06 08:22:04 +0000691Set the default CPU.
692ETEXI
693
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300694 {
695 .name = "mouse_move",
696 .args_type = "dx_str:s,dy_str:s,dz_str:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300697 .params = "dx dy [dz]",
698 .help = "send mouse move events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300699 .mhandler.cmd = do_mouse_move,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300700 },
701
Blue Swirl23130862009-06-06 08:22:04 +0000702STEXI
703@item mouse_move @var{dx} @var{dy} [@var{dz}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100704@findex mouse_move
Blue Swirl23130862009-06-06 08:22:04 +0000705Move the active mouse to the specified coordinates @var{dx} @var{dy}
706with optional scroll axis @var{dz}.
707ETEXI
708
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300709 {
710 .name = "mouse_button",
711 .args_type = "button_state:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300712 .params = "state",
713 .help = "change mouse button state (1=L, 2=M, 4=R)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300714 .mhandler.cmd = do_mouse_button,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300715 },
716
Blue Swirl23130862009-06-06 08:22:04 +0000717STEXI
718@item mouse_button @var{val}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100719@findex mouse_button
Blue Swirl23130862009-06-06 08:22:04 +0000720Change the active mouse button state @var{val} (1=L, 2=M, 4=R).
721ETEXI
722
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300723 {
724 .name = "mouse_set",
725 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300726 .params = "index",
727 .help = "set which mouse device receives events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300728 .mhandler.cmd = do_mouse_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300729 },
730
Blue Swirl23130862009-06-06 08:22:04 +0000731STEXI
732@item mouse_set @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100733@findex mouse_set
Blue Swirl23130862009-06-06 08:22:04 +0000734Set which mouse device receives events at given @var{index}, index
735can be obtained with
736@example
737info mice
738@end example
739ETEXI
740
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300741 {
742 .name = "wavcapture",
743 .args_type = "path:F,freq:i?,bits:i?,nchannels:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300744 .params = "path [frequency [bits [channels]]]",
745 .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300746 .mhandler.cmd = do_wav_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300747 },
Blue Swirl23130862009-06-06 08:22:04 +0000748STEXI
749@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100750@findex wavcapture
Blue Swirl23130862009-06-06 08:22:04 +0000751Capture audio into @var{filename}. Using sample rate @var{frequency}
752bits per sample @var{bits} and number of channels @var{channels}.
753
754Defaults:
755@itemize @minus
756@item Sample rate = 44100 Hz - CD quality
757@item Bits = 16
758@item Number of channels = 2 - Stereo
759@end itemize
760ETEXI
761
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300762 {
763 .name = "stopcapture",
764 .args_type = "n:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300765 .params = "capture index",
766 .help = "stop capture",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300767 .mhandler.cmd = do_stop_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300768 },
Blue Swirl23130862009-06-06 08:22:04 +0000769STEXI
770@item stopcapture @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100771@findex stopcapture
Blue Swirl23130862009-06-06 08:22:04 +0000772Stop capture with a given @var{index}, index can be obtained with
773@example
774info capture
775@end example
776ETEXI
777
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300778 {
779 .name = "memsave",
780 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300781 .params = "addr size file",
782 .help = "save to disk virtual memory dump starting at 'addr' of size 'size'",
Luiz Capitulino0cfd6a92011-11-22 16:32:37 -0200783 .mhandler.cmd = hmp_memsave,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300784 },
785
Blue Swirl23130862009-06-06 08:22:04 +0000786STEXI
787@item memsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100788@findex memsave
Blue Swirl23130862009-06-06 08:22:04 +0000789save to disk virtual memory dump starting at @var{addr} of size @var{size}.
790ETEXI
791
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300792 {
793 .name = "pmemsave",
794 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300795 .params = "addr size file",
796 .help = "save to disk physical memory dump starting at 'addr' of size 'size'",
Luiz Capitulino6d3962b2011-11-22 17:26:46 -0200797 .mhandler.cmd = hmp_pmemsave,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300798 },
799
Blue Swirl23130862009-06-06 08:22:04 +0000800STEXI
801@item pmemsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100802@findex pmemsave
Blue Swirl23130862009-06-06 08:22:04 +0000803save to disk physical memory dump starting at @var{addr} of size @var{size}.
804ETEXI
805
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300806 {
807 .name = "boot_set",
808 .args_type = "bootdevice:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300809 .params = "bootdevice",
810 .help = "define new values for the boot device list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300811 .mhandler.cmd = do_boot_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300812 },
813
Blue Swirl23130862009-06-06 08:22:04 +0000814STEXI
815@item boot_set @var{bootdevicelist}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100816@findex boot_set
Blue Swirl23130862009-06-06 08:22:04 +0000817
818Define new values for the boot device list. Those values will override
819the values specified on the command line through the @code{-boot} option.
820
821The values that can be specified here depend on the machine type, but are
822the same that can be specified in the @code{-boot} command line option.
823ETEXI
824
Eugene (jno) Dvurechenski7f7f9752012-12-05 15:50:07 +0100825#if defined(TARGET_I386) || defined(TARGET_S390X)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300826 {
827 .name = "nmi",
Luiz Capitulinoe9b4b432011-04-29 12:11:50 -0300828 .args_type = "",
829 .params = "",
830 .help = "inject an NMI on all guest's CPUs",
Luiz Capitulinoab49ab52011-11-23 12:55:53 -0200831 .mhandler.cmd = hmp_inject_nmi,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300832 },
Blue Swirl23130862009-06-06 08:22:04 +0000833#endif
834STEXI
835@item nmi @var{cpu}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100836@findex nmi
Eugene (jno) Dvurechenski7f7f9752012-12-05 15:50:07 +0100837Inject an NMI (x86) or RESTART (s390x) on the given CPU.
Lei Li1f590cf2013-01-25 00:03:20 +0800838
839ETEXI
840
841 {
Markus Armbruster3949e592013-02-06 21:27:24 +0100842 .name = "ringbuf_write",
Lei Li1f590cf2013-01-25 00:03:20 +0800843 .args_type = "device:s,data:s",
844 .params = "device data",
Markus Armbruster3949e592013-02-06 21:27:24 +0100845 .help = "Write to a ring buffer character device",
846 .mhandler.cmd = hmp_ringbuf_write,
Lei Li1f590cf2013-01-25 00:03:20 +0800847 },
848
849STEXI
Markus Armbruster3949e592013-02-06 21:27:24 +0100850@item ringbuf_write @var{device} @var{data}
851@findex ringbuf_write
852Write @var{data} to ring buffer character device @var{device}.
853@var{data} must be a UTF-8 string.
Lei Li1f590cf2013-01-25 00:03:20 +0800854
Blue Swirl23130862009-06-06 08:22:04 +0000855ETEXI
856
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300857 {
Markus Armbruster3949e592013-02-06 21:27:24 +0100858 .name = "ringbuf_read",
Lei Li49b6d722013-01-25 00:03:21 +0800859 .args_type = "device:s,size:i",
860 .params = "device size",
Markus Armbruster3949e592013-02-06 21:27:24 +0100861 .help = "Read from a ring buffer character device",
862 .mhandler.cmd = hmp_ringbuf_read,
Lei Li49b6d722013-01-25 00:03:21 +0800863 },
864
865STEXI
Markus Armbruster3949e592013-02-06 21:27:24 +0100866@item ringbuf_read @var{device}
867@findex ringbuf_read
868Read and print up to @var{size} bytes from ring buffer character
869device @var{device}.
Markus Armbruster543f3412013-02-06 21:27:26 +0100870Certain non-printable characters are printed \uXXXX, where XXXX is the
871character code in hexadecimal. Character \ is printed \\.
Markus Armbruster3949e592013-02-06 21:27:24 +0100872Bug: can screw up when the buffer contains invalid UTF-8 sequences,
873NUL characters, after the ring buffer lost data, and when reading
874stops because the size limit is reached.
Lei Li49b6d722013-01-25 00:03:21 +0800875
876ETEXI
877
878 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300879 .name = "migrate",
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200880 .args_type = "detach:-d,blk:-b,inc:-i,uri:s",
881 .params = "[-d] [-b] [-i] uri",
882 .help = "migrate to URI (using -d to not wait for completion)"
883 "\n\t\t\t -b for migration without shared storage with"
884 " full copy of disk\n\t\t\t -i for migration without "
885 "shared storage with incremental copy of disk "
886 "(base image shared between src and destination)",
Luiz Capitulinoe1c37d02011-12-05 14:48:01 -0200887 .mhandler.cmd = hmp_migrate,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300888 },
889
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200890
Blue Swirl23130862009-06-06 08:22:04 +0000891STEXI
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200892@item migrate [-d] [-b] [-i] @var{uri}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100893@findex migrate
Blue Swirl23130862009-06-06 08:22:04 +0000894Migrate to @var{uri} (using -d to not wait for completion).
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200895 -b for migration with full copy of disk
896 -i for migration with incremental copy of disk (base image is shared)
Blue Swirl23130862009-06-06 08:22:04 +0000897ETEXI
898
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300899 {
900 .name = "migrate_cancel",
901 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300902 .params = "",
903 .help = "cancel the current VM migration",
Luiz Capitulino6cdedb02011-11-27 22:54:09 -0200904 .mhandler.cmd = hmp_migrate_cancel,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300905 },
906
Blue Swirl23130862009-06-06 08:22:04 +0000907STEXI
908@item migrate_cancel
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100909@findex migrate_cancel
Blue Swirl23130862009-06-06 08:22:04 +0000910Cancel the current VM migration.
Orit Wasserman9e1ba4c2012-08-06 21:42:54 +0300911
912ETEXI
913
914 {
915 .name = "migrate_set_cache_size",
916 .args_type = "value:o",
917 .params = "value",
918 .help = "set cache size (in bytes) for XBZRLE migrations,"
919 "the cache size will be rounded down to the nearest "
920 "power of 2.\n"
921 "The cache size affects the number of cache misses."
922 "In case of a high cache miss ratio you need to increase"
923 " the cache size",
924 .mhandler.cmd = hmp_migrate_set_cache_size,
925 },
926
927STEXI
928@item migrate_set_cache_size @var{value}
929@findex migrate_set_cache_size
930Set cache size to @var{value} (in bytes) for xbzrle migrations.
Blue Swirl23130862009-06-06 08:22:04 +0000931ETEXI
932
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300933 {
934 .name = "migrate_set_speed",
Jes Sorensened3d4a82010-10-21 17:15:48 +0200935 .args_type = "value:o",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300936 .params = "value",
Jes Sorensened3d4a82010-10-21 17:15:48 +0200937 .help = "set maximum speed (in bytes) for migrations. "
938 "Defaults to MB if no size suffix is specified, ie. B/K/M/G/T",
Luiz Capitulino3dc85382011-11-28 11:59:37 -0200939 .mhandler.cmd = hmp_migrate_set_speed,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300940 },
941
Blue Swirl23130862009-06-06 08:22:04 +0000942STEXI
943@item migrate_set_speed @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100944@findex migrate_set_speed
Blue Swirl23130862009-06-06 08:22:04 +0000945Set maximum speed to @var{value} (in bytes) for migrations.
946ETEXI
947
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300948 {
949 .name = "migrate_set_downtime",
Markus Armbrusterb0fbf7d2010-01-25 14:23:07 +0100950 .args_type = "value:T",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300951 .params = "value",
952 .help = "set maximum tolerated downtime (in seconds) for migrations",
Luiz Capitulino4f0a9932011-11-27 23:18:01 -0200953 .mhandler.cmd = hmp_migrate_set_downtime,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300954 },
Glauber Costa2ea42952009-05-28 15:22:58 -0400955
956STEXI
957@item migrate_set_downtime @var{second}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100958@findex migrate_set_downtime
Glauber Costa2ea42952009-05-28 15:22:58 -0400959Set maximum tolerated downtime (in seconds) for migration.
960ETEXI
961
Jes Sorensenf8882562010-12-16 13:52:16 +0100962 {
Orit Wasserman00458432012-08-06 21:42:48 +0300963 .name = "migrate_set_capability",
964 .args_type = "capability:s,state:b",
965 .params = "capability state",
966 .help = "Enable/Disable the usage of a capability for migration",
967 .mhandler.cmd = hmp_migrate_set_capability,
968 },
969
970STEXI
971@item migrate_set_capability @var{capability} @var{state}
972@findex migrate_set_capability
973Enable/Disable the usage of a capability @var{capability} for migration.
974ETEXI
975
976 {
Jes Sorensen2ea720d2011-03-09 16:54:34 +0100977 .name = "client_migrate_info",
978 .args_type = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?",
979 .params = "protocol hostname port tls-port cert-subject",
980 .help = "send migration info to spice/vnc client",
981 .user_print = monitor_user_noop,
Yonit Halperinedc5cb12011-10-17 10:03:18 +0200982 .mhandler.cmd_async = client_migrate_info,
983 .flags = MONITOR_CMD_ASYNC,
Jes Sorensenf8882562010-12-16 13:52:16 +0100984 },
985
986STEXI
Gerd Hoffmanne866e232010-04-23 13:28:21 +0200987@item client_migrate_info @var{protocol} @var{hostname} @var{port} @var{tls-port} @var{cert-subject}
988@findex client_migrate_info
989Set the spice/vnc connection info for the migration target. The spice/vnc
990server will ask the spice/vnc client to automatically reconnect using the
991new parameters (if specified) once the vm migration finished successfully.
992ETEXI
993
Wen Congyang783e9b42012-05-07 12:10:47 +0800994 {
995 .name = "dump-guest-memory",
Luiz Capitulino75363762012-09-21 13:53:00 -0300996 .args_type = "paging:-p,filename:F,begin:i?,length:i?",
997 .params = "[-p] filename [begin] [length]",
Wen Congyang783e9b42012-05-07 12:10:47 +0800998 .help = "dump guest memory to file"
999 "\n\t\t\t begin(optional): the starting physical address"
1000 "\n\t\t\t length(optional): the memory size, in bytes",
Wen Congyang783e9b42012-05-07 12:10:47 +08001001 .mhandler.cmd = hmp_dump_guest_memory,
1002 },
1003
1004
1005STEXI
1006@item dump-guest-memory [-p] @var{protocol} @var{begin} @var{length}
1007@findex dump-guest-memory
1008Dump guest memory to @var{protocol}. The file can be processed with crash or
1009gdb.
Luiz Capitulino75363762012-09-21 13:53:00 -03001010 filename: dump file name
Wen Congyang783e9b42012-05-07 12:10:47 +08001011 paging: do paging to get guest's memory mapping
1012 begin: the starting physical address. It's optional, and should be
1013 specified with length together.
1014 length: the memory size, in bytes. It's optional, and should be specified
1015 with begin together.
1016ETEXI
Wen Congyang783e9b42012-05-07 12:10:47 +08001017
Gerd Hoffmanne866e232010-04-23 13:28:21 +02001018 {
Jes Sorensen2ea720d2011-03-09 16:54:34 +01001019 .name = "snapshot_blkdev",
Paolo Bonzini6cc2a412012-03-06 18:55:59 +01001020 .args_type = "reuse:-n,device:B,snapshot-file:s?,format:s?",
1021 .params = "[-n] device [new-image-file] [format]",
Jes Sorensen2ea720d2011-03-09 16:54:34 +01001022 .help = "initiates a live snapshot\n\t\t\t"
1023 "of device. If a new image file is specified, the\n\t\t\t"
1024 "new image file will become the new root image.\n\t\t\t"
1025 "If format is specified, the snapshot file will\n\t\t\t"
Wenchao Xia775ca882013-09-11 14:04:37 +08001026 "be created in that format.\n\t\t\t"
Paolo Bonzini6cc2a412012-03-06 18:55:59 +01001027 "The default format is qcow2. The -n flag requests QEMU\n\t\t\t"
1028 "to reuse the image found in new-image-file, instead of\n\t\t\t"
1029 "recreating it from scratch.",
Luiz Capitulino6106e242011-11-25 16:15:19 -02001030 .mhandler.cmd = hmp_snapshot_blkdev,
Gerd Hoffmanne866e232010-04-23 13:28:21 +02001031 },
1032
1033STEXI
Jes Sorensenf8882562010-12-16 13:52:16 +01001034@item snapshot_blkdev
1035@findex snapshot_blkdev
1036Snapshot device, using snapshot file as target if provided
1037ETEXI
1038
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001039 {
Wenchao Xia775ca882013-09-11 14:04:37 +08001040 .name = "snapshot_blkdev_internal",
1041 .args_type = "device:B,name:s",
1042 .params = "device name",
1043 .help = "take an internal snapshot of device.\n\t\t\t"
1044 "The format of the image used by device must\n\t\t\t"
1045 "support it, such as qcow2.\n\t\t\t",
1046 .mhandler.cmd = hmp_snapshot_blkdev_internal,
1047 },
1048
1049STEXI
1050@item snapshot_blkdev_internal
1051@findex snapshot_blkdev_internal
1052Take an internal snapshot on device if it support
1053ETEXI
1054
1055 {
Wenchao Xia7a4ed2e2013-09-11 14:04:38 +08001056 .name = "snapshot_delete_blkdev_internal",
1057 .args_type = "device:B,name:s,id:s?",
1058 .params = "device name [id]",
1059 .help = "delete an internal snapshot of device.\n\t\t\t"
1060 "If id is specified, qemu will try delete\n\t\t\t"
1061 "the snapshot matching both id and name.\n\t\t\t"
1062 "The format of the image used by device must\n\t\t\t"
1063 "support it, such as qcow2.\n\t\t\t",
1064 .mhandler.cmd = hmp_snapshot_delete_blkdev_internal,
1065 },
1066
1067STEXI
1068@item snapshot_delete_blkdev_internal
1069@findex snapshot_delete_blkdev_internal
1070Delete an internal snapshot on device if it support
1071ETEXI
1072
1073 {
Paolo Bonzinid9b902d2012-10-18 16:49:24 +02001074 .name = "drive_mirror",
1075 .args_type = "reuse:-n,full:-f,device:B,target:s,format:s?",
1076 .params = "[-n] [-f] device target [format]",
1077 .help = "initiates live storage\n\t\t\t"
1078 "migration for a device. The device's contents are\n\t\t\t"
1079 "copied to the new image file, including data that\n\t\t\t"
1080 "is written after the command is started.\n\t\t\t"
1081 "The -n flag requests QEMU to reuse the image found\n\t\t\t"
1082 "in new-image-file, instead of recreating it from scratch.\n\t\t\t"
1083 "The -f flag requests QEMU to copy the whole disk,\n\t\t\t"
1084 "so that the result does not need a backing file.\n\t\t\t",
1085 .mhandler.cmd = hmp_drive_mirror,
1086 },
1087STEXI
1088@item drive_mirror
1089@findex drive_mirror
1090Start mirroring a block device's writes to a new destination,
1091using the specified target.
1092ETEXI
1093
1094 {
Stefan Hajnoczide909302013-06-26 14:11:58 +02001095 .name = "drive_backup",
1096 .args_type = "reuse:-n,full:-f,device:B,target:s,format:s?",
1097 .params = "[-n] [-f] device target [format]",
1098 .help = "initiates a point-in-time\n\t\t\t"
1099 "copy for a device. The device's contents are\n\t\t\t"
1100 "copied to the new image file, excluding data that\n\t\t\t"
1101 "is written after the command is started.\n\t\t\t"
1102 "The -n flag requests QEMU to reuse the image found\n\t\t\t"
1103 "in new-image-file, instead of recreating it from scratch.\n\t\t\t"
1104 "The -f flag requests QEMU to copy the whole disk,\n\t\t\t"
1105 "so that the result does not need a backing file.\n\t\t\t",
1106 .mhandler.cmd = hmp_drive_backup,
1107 },
1108STEXI
1109@item drive_backup
1110@findex drive_backup
1111Start a point-in-time copy of a block device to a specificed target.
1112ETEXI
1113
1114 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001115 .name = "drive_add",
1116 .args_type = "pci_addr:s,opts:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001117 .params = "[[<domain>:]<bus>:]<slot>\n"
1118 "[file=file][,if=type][,bus=n]\n"
Stefan Hajnoczifb0490f2011-11-17 13:40:32 +00001119 "[,unit=m][,media=d][,index=i]\n"
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001120 "[,cyls=c,heads=h,secs=s[,trans=t]]\n"
Stefan Hajnoczifb0490f2011-11-17 13:40:32 +00001121 "[,snapshot=on|off][,cache=on|off]\n"
1122 "[,readonly=on|off][,copy-on-read=on|off]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001123 .help = "add drive to PCI storage controller",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001124 .mhandler.cmd = drive_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001125 },
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001126
Blue Swirl23130862009-06-06 08:22:04 +00001127STEXI
1128@item drive_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001129@findex drive_add
Blue Swirl23130862009-06-06 08:22:04 +00001130Add drive to PCI storage controller.
1131ETEXI
1132
David Gibson79ca6162013-06-06 18:48:45 +10001133#if defined(CONFIG_PCI_HOTPLUG_OLD)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001134 {
1135 .name = "pci_add",
1136 .args_type = "pci_addr:s,type:s,opts:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001137 .params = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...",
1138 .help = "hot-add PCI device",
Markus Armbruster6c6a58a2010-05-12 10:53:00 +02001139 .mhandler.cmd = pci_device_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001140 },
Blue Swirl23130862009-06-06 08:22:04 +00001141#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001142
Blue Swirl23130862009-06-06 08:22:04 +00001143STEXI
1144@item pci_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001145@findex pci_add
Blue Swirl23130862009-06-06 08:22:04 +00001146Hot-add PCI device.
1147ETEXI
1148
David Gibson79ca6162013-06-06 18:48:45 +10001149#if defined(CONFIG_PCI_HOTPLUG_OLD)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001150 {
1151 .name = "pci_del",
1152 .args_type = "pci_addr:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001153 .params = "[[<domain>:]<bus>:]<slot>",
1154 .help = "hot remove PCI device",
Markus Armbrusterb752daf2010-05-12 10:53:01 +02001155 .mhandler.cmd = do_pci_device_hot_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001156 },
Blue Swirl23130862009-06-06 08:22:04 +00001157#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001158
Blue Swirl23130862009-06-06 08:22:04 +00001159STEXI
1160@item pci_del
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001161@findex pci_del
Blue Swirl23130862009-06-06 08:22:04 +00001162Hot remove PCI device.
1163ETEXI
1164
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001165 {
Isaku Yamahata2ae63bd2010-12-24 12:14:14 +09001166 .name = "pcie_aer_inject_error",
1167 .args_type = "advisory_non_fatal:-a,correctable:-c,"
1168 "id:s,error_status:s,"
1169 "header0:i?,header1:i?,header2:i?,header3:i?,"
1170 "prefix0:i?,prefix1:i?,prefix2:i?,prefix3:i?",
1171 .params = "[-a] [-c] id "
1172 "<error_status> [<tlp header> [<tlp header prefix>]]",
1173 .help = "inject pcie aer error\n\t\t\t"
1174 " -a for advisory non fatal error\n\t\t\t"
1175 " -c for correctable error\n\t\t\t"
1176 "<id> = qdev device id\n\t\t\t"
1177 "<error_status> = error string or 32bit\n\t\t\t"
1178 "<tlb header> = 32bit x 4\n\t\t\t"
1179 "<tlb header prefix> = 32bit x 4",
1180 .user_print = pcie_aer_inject_error_print,
Zhi Yong Wu1f3392b2011-11-30 12:39:47 +08001181 .mhandler.cmd_new = do_pcie_aer_inject_error,
Isaku Yamahata2ae63bd2010-12-24 12:14:14 +09001182 },
1183
1184STEXI
1185@item pcie_aer_inject_error
1186@findex pcie_aer_inject_error
1187Inject PCIe AER error
1188ETEXI
1189
1190 {
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001191 .name = "host_net_add",
1192 .args_type = "device:s,opts:s?",
Vincenzo Maffione58952132013-11-06 11:44:06 +01001193 .params = "tap|user|socket|vde|netmap|dump [options]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001194 .help = "add host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001195 .mhandler.cmd = net_host_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001196 },
1197
Blue Swirl23130862009-06-06 08:22:04 +00001198STEXI
1199@item host_net_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001200@findex host_net_add
Blue Swirl23130862009-06-06 08:22:04 +00001201Add host VLAN client.
1202ETEXI
1203
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001204 {
1205 .name = "host_net_remove",
1206 .args_type = "vlan_id:i,device:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001207 .params = "vlan_id name",
1208 .help = "remove host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001209 .mhandler.cmd = net_host_device_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001210 },
1211
Blue Swirl23130862009-06-06 08:22:04 +00001212STEXI
1213@item host_net_remove
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001214@findex host_net_remove
Blue Swirl23130862009-06-06 08:22:04 +00001215Remove host VLAN client.
1216ETEXI
1217
Markus Armbrusterae82d322010-03-25 17:22:40 +01001218 {
1219 .name = "netdev_add",
1220 .args_type = "netdev:O",
Vincenzo Maffione58952132013-11-06 11:44:06 +01001221 .params = "[user|tap|socket|hubport|netmap],id=str[,prop=value][,...]",
Markus Armbrusterae82d322010-03-25 17:22:40 +01001222 .help = "add host network device",
Luiz Capitulino928059a2012-04-18 17:34:15 -03001223 .mhandler.cmd = hmp_netdev_add,
Markus Armbrusterae82d322010-03-25 17:22:40 +01001224 },
1225
1226STEXI
1227@item netdev_add
1228@findex netdev_add
1229Add host network device.
1230ETEXI
1231
1232 {
1233 .name = "netdev_del",
1234 .args_type = "id:s",
1235 .params = "id",
1236 .help = "remove host network device",
Luiz Capitulino5f964152012-04-16 14:36:32 -03001237 .mhandler.cmd = hmp_netdev_del,
Markus Armbrusterae82d322010-03-25 17:22:40 +01001238 },
1239
1240STEXI
1241@item netdev_del
1242@findex netdev_del
1243Remove host network device.
1244ETEXI
1245
Paolo Bonziniab2d0532013-12-20 23:21:09 +01001246 {
1247 .name = "object_del",
1248 .args_type = "id:s",
1249 .params = "id",
1250 .help = "destroy QOM object",
1251 .mhandler.cmd = hmp_object_del,
1252 },
1253
1254STEXI
1255@item object_del
1256@findex object_del
1257Destroy QOM object.
1258ETEXI
1259
Blue Swirl23130862009-06-06 08:22:04 +00001260#ifdef CONFIG_SLIRP
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001261 {
1262 .name = "hostfwd_add",
1263 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001264 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport",
1265 .help = "redirect TCP or UDP connections from host to guest (requires -net user)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001266 .mhandler.cmd = net_slirp_hostfwd_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001267 },
Markus Armbruster21413d62010-05-04 13:20:30 +02001268#endif
1269STEXI
1270@item hostfwd_add
1271@findex hostfwd_add
1272Redirect TCP or UDP connections from host to guest (requires -net user).
1273ETEXI
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001274
Markus Armbruster21413d62010-05-04 13:20:30 +02001275#ifdef CONFIG_SLIRP
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001276 {
1277 .name = "hostfwd_remove",
1278 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001279 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport",
1280 .help = "remove host-to-guest TCP or UDP redirection",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001281 .mhandler.cmd = net_slirp_hostfwd_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001282 },
1283
Blue Swirl23130862009-06-06 08:22:04 +00001284#endif
1285STEXI
Markus Armbruster21413d62010-05-04 13:20:30 +02001286@item hostfwd_remove
1287@findex hostfwd_remove
1288Remove host-to-guest TCP or UDP redirection.
Blue Swirl23130862009-06-06 08:22:04 +00001289ETEXI
1290
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001291 {
1292 .name = "balloon",
Luiz Capitulino3b0bd6e2009-12-18 13:25:05 -02001293 .args_type = "value:M",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001294 .params = "target",
Riccardo Magliocchetti3c056132010-05-19 18:49:28 +02001295 .help = "request VM to change its memory allocation (in MB)",
Luiz Capitulinod72f3262011-11-25 14:38:09 -02001296 .mhandler.cmd = hmp_balloon,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001297 },
1298
Blue Swirl23130862009-06-06 08:22:04 +00001299STEXI
1300@item balloon @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001301@findex balloon
Blue Swirl23130862009-06-06 08:22:04 +00001302Request VM to change its memory allocation to @var{value} (in MB).
1303ETEXI
1304
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001305 {
1306 .name = "set_link",
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001307 .args_type = "name:s,up:b",
1308 .params = "name on|off",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001309 .help = "change the link status of a network adapter",
Luiz Capitulino4b371562011-11-23 13:11:55 -02001310 .mhandler.cmd = hmp_set_link,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001311 },
1312
Blue Swirl23130862009-06-06 08:22:04 +00001313STEXI
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001314@item set_link @var{name} [on|off]
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001315@findex set_link
Markus Armbrusterc9b26a42010-03-26 09:07:10 +01001316Switch link @var{name} on (i.e. up) or off (i.e. down).
Blue Swirl23130862009-06-06 08:22:04 +00001317ETEXI
1318
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001319 {
1320 .name = "watchdog_action",
1321 .args_type = "action:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001322 .params = "[reset|shutdown|poweroff|pause|debug|none]",
1323 .help = "change watchdog action",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001324 .mhandler.cmd = do_watchdog_action,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001325 },
1326
Blue Swirl23130862009-06-06 08:22:04 +00001327STEXI
1328@item watchdog_action
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001329@findex watchdog_action
Blue Swirl23130862009-06-06 08:22:04 +00001330Change watchdog action.
1331ETEXI
1332
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001333 {
1334 .name = "acl_show",
1335 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001336 .params = "aclname",
1337 .help = "list rules in the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001338 .mhandler.cmd = do_acl_show,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001339 },
1340
Blue Swirl23130862009-06-06 08:22:04 +00001341STEXI
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001342@item acl_show @var{aclname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001343@findex acl_show
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001344List all the matching rules in the access control list, and the default
1345policy. There are currently two named access control lists,
1346@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client
1347certificate distinguished name, and SASL username respectively.
1348ETEXI
Blue Swirl23130862009-06-06 08:22:04 +00001349
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001350 {
1351 .name = "acl_policy",
1352 .args_type = "aclname:s,policy:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001353 .params = "aclname allow|deny",
1354 .help = "set default access control list policy",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001355 .mhandler.cmd = do_acl_policy,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001356 },
1357
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001358STEXI
Jan Kiszkacbbfacc2009-07-03 08:46:05 +02001359@item acl_policy @var{aclname} @code{allow|deny}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001360@findex acl_policy
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001361Set the default access control list policy, used in the event that
Blue Swirl23130862009-06-06 08:22:04 +00001362none of the explicit rules match. The default policy at startup is
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001363always @code{deny}.
1364ETEXI
1365
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001366 {
1367 .name = "acl_add",
1368 .args_type = "aclname:s,match:s,policy:s,index:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001369 .params = "aclname match allow|deny [index]",
1370 .help = "add a match rule to the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001371 .mhandler.cmd = do_acl_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001372 },
1373
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001374STEXI
Markus Armbruster0e4aec92010-05-04 13:20:31 +02001375@item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}]
1376@findex acl_add
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001377Add a match rule to the access control list, allowing or denying access.
1378The match will normally be an exact username or x509 distinguished name,
1379but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to
1380allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will
Blue Swirl23130862009-06-06 08:22:04 +00001381normally be appended to the end of the ACL, but can be inserted
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001382earlier in the list if the optional @var{index} parameter is supplied.
1383ETEXI
1384
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001385 {
1386 .name = "acl_remove",
1387 .args_type = "aclname:s,match:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001388 .params = "aclname match",
1389 .help = "remove a match rule from the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001390 .mhandler.cmd = do_acl_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001391 },
1392
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001393STEXI
1394@item acl_remove @var{aclname} @var{match}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001395@findex acl_remove
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001396Remove the specified match rule from the access control list.
1397ETEXI
1398
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001399 {
1400 .name = "acl_reset",
1401 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001402 .params = "aclname",
1403 .help = "reset the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001404 .mhandler.cmd = do_acl_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001405 },
1406
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001407STEXI
Markus Armbruster0e4aec92010-05-04 13:20:31 +02001408@item acl_reset @var{aclname}
1409@findex acl_reset
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001410Remove all matches from the access control list, and set the default
Blue Swirl23130862009-06-06 08:22:04 +00001411policy back to @code{deny}.
Blue Swirl23130862009-06-06 08:22:04 +00001412ETEXI
1413
Paolo Bonzini40577252012-08-23 11:53:04 +02001414 {
1415 .name = "nbd_server_start",
1416 .args_type = "all:-a,writable:-w,uri:s",
1417 .params = "nbd_server_start [-a] [-w] host:port",
1418 .help = "serve block devices on the given host and port",
1419 .mhandler.cmd = hmp_nbd_server_start,
1420 },
1421STEXI
1422@item nbd_server_start @var{host}:@var{port}
1423@findex nbd_server_start
1424Start an NBD server on the given host and/or port. If the @option{-a}
1425option is included, all of the virtual machine's block devices that
1426have an inserted media on them are automatically exported; in this case,
1427the @option{-w} option makes the devices writable too.
1428ETEXI
1429
1430 {
1431 .name = "nbd_server_add",
1432 .args_type = "writable:-w,device:B",
1433 .params = "nbd_server_add [-w] device",
1434 .help = "export a block device via NBD",
1435 .mhandler.cmd = hmp_nbd_server_add,
1436 },
1437STEXI
1438@item nbd_server_add @var{device}
1439@findex nbd_server_add
1440Export a block device through QEMU's NBD server, which must be started
1441beforehand with @command{nbd_server_start}. The @option{-w} option makes the
1442exported device writable too.
1443ETEXI
1444
1445 {
1446 .name = "nbd_server_stop",
1447 .args_type = "",
1448 .params = "nbd_server_stop",
1449 .help = "stop serving block devices using the NBD protocol",
1450 .mhandler.cmd = hmp_nbd_server_stop,
1451 },
1452STEXI
1453@item nbd_server_stop
1454@findex nbd_server_stop
1455Stop the QEMU embedded NBD server.
1456ETEXI
1457
1458
Huang Ying79c4f6b2009-06-23 10:05:14 +08001459#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001460
1461 {
1462 .name = "mce",
Jin Dongming31ce5e02010-12-10 17:21:02 +09001463 .args_type = "broadcast:-b,cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l",
1464 .params = "[-b] cpu bank status mcgstatus addr misc",
1465 .help = "inject a MCE on the given CPU [and broadcast to other CPUs with -b option]",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001466 .mhandler.cmd = do_inject_mce,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001467 },
1468
Huang Ying79c4f6b2009-06-23 10:05:14 +08001469#endif
1470STEXI
1471@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001472@findex mce (x86)
Huang Ying79c4f6b2009-06-23 10:05:14 +08001473Inject an MCE on the given CPU (x86 only).
1474ETEXI
1475
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001476 {
1477 .name = "getfd",
1478 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001479 .params = "getfd name",
1480 .help = "receive a file descriptor via SCM rights and assign it a name",
Corey Bryant208c9d12012-06-22 14:36:09 -04001481 .mhandler.cmd = hmp_getfd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001482 },
1483
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001484STEXI
1485@item getfd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001486@findex getfd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001487If a file descriptor is passed alongside this command using the SCM_RIGHTS
1488mechanism on unix sockets, it is stored using the name @var{fdname} for
1489later use by other monitor commands.
1490ETEXI
1491
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001492 {
1493 .name = "closefd",
1494 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001495 .params = "closefd name",
1496 .help = "close a file descriptor previously passed via SCM rights",
Corey Bryant208c9d12012-06-22 14:36:09 -04001497 .mhandler.cmd = hmp_closefd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001498 },
1499
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001500STEXI
1501@item closefd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001502@findex closefd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001503Close the file descriptor previously assigned to @var{fdname} using the
1504@code{getfd} command. This is only needed if the file descriptor was never
1505used by another monitor command.
1506ETEXI
1507
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001508 {
1509 .name = "block_passwd",
1510 .args_type = "device:B,password:s",
1511 .params = "block_passwd device password",
1512 .help = "set the password of encrypted block devices",
Luiz Capitulinoa4dea8a2011-11-23 13:28:21 -02001513 .mhandler.cmd = hmp_block_passwd,
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001514 },
1515
1516STEXI
Zhi Yong Wu727f0052011-11-08 13:00:31 +08001517@item block_set_io_throttle @var{device} @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr}
1518@findex block_set_io_throttle
1519Change 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}
1520ETEXI
1521
1522 {
1523 .name = "block_set_io_throttle",
1524 .args_type = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l",
1525 .params = "device bps bps_rd bps_wr iops iops_rd iops_wr",
1526 .help = "change I/O throttle limits for a block drive",
Luiz Capitulino80047da2011-12-14 16:49:14 -02001527 .mhandler.cmd = hmp_block_set_io_throttle,
Zhi Yong Wu727f0052011-11-08 13:00:31 +08001528 },
1529
1530STEXI
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001531@item block_passwd @var{device} @var{password}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001532@findex block_passwd
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001533Set the encrypted device @var{device} password to @var{password}
1534ETEXI
Jan Kiszkab40292e2010-05-31 14:43:31 -03001535
Jan Kiszka33572ec2010-05-31 14:43:30 -03001536 {
Gerd Hoffmann75721502010-10-07 12:22:54 +02001537 .name = "set_password",
1538 .args_type = "protocol:s,password:s,connected:s?",
1539 .params = "protocol password action-if-connected",
1540 .help = "set spice/vnc password",
Luiz Capitulinofbf796f2011-12-07 11:17:51 -02001541 .mhandler.cmd = hmp_set_password,
Gerd Hoffmann75721502010-10-07 12:22:54 +02001542 },
1543
1544STEXI
1545@item set_password [ vnc | spice ] password [ action-if-connected ]
1546@findex set_password
1547
1548Change spice/vnc password. Use zero to make the password stay valid
1549forever. @var{action-if-connected} specifies what should happen in
1550case a connection is established: @var{fail} makes the password change
1551fail. @var{disconnect} changes the password and disconnects the
1552client. @var{keep} changes the password and keeps the connection up.
1553@var{keep} is the default.
1554ETEXI
1555
1556 {
1557 .name = "expire_password",
1558 .args_type = "protocol:s,time:s",
1559 .params = "protocol time",
1560 .help = "set spice/vnc password expire-time",
Luiz Capitulino9ad53722011-12-07 11:47:57 -02001561 .mhandler.cmd = hmp_expire_password,
Gerd Hoffmann75721502010-10-07 12:22:54 +02001562 },
1563
1564STEXI
1565@item expire_password [ vnc | spice ] expire-time
1566@findex expire_password
1567
1568Specify when a password for spice/vnc becomes
1569invalid. @var{expire-time} accepts:
1570
1571@table @var
1572@item now
1573Invalidate password instantly.
1574
1575@item never
1576Password stays valid forever.
1577
1578@item +nsec
1579Password stays valid for @var{nsec} seconds starting now.
1580
1581@item nsec
1582Password is invalidated at the given time. @var{nsec} are the seconds
1583passed since 1970, i.e. unix epoch.
1584
1585@end table
1586ETEXI
1587
Gerd Hoffmann46920822013-02-28 08:46:10 +01001588 {
1589 .name = "chardev-add",
1590 .args_type = "args:s",
1591 .params = "args",
1592 .help = "add chardev",
1593 .mhandler.cmd = hmp_chardev_add,
1594 },
1595
1596STEXI
1597@item chardev_add args
1598@findex chardev_add
1599
1600chardev_add accepts the same parameters as the -chardev command line switch.
1601
1602ETEXI
1603
1604 {
1605 .name = "chardev-remove",
1606 .args_type = "id:s",
1607 .params = "id",
1608 .help = "remove chardev",
1609 .mhandler.cmd = hmp_chardev_remove,
1610 },
1611
1612STEXI
1613@item chardev_remove id
1614@findex chardev_remove
1615
1616Removes the chardev @var{id}.
1617
1618ETEXI
Gerd Hoffmannf1088902012-12-19 10:33:40 +01001619
1620 {
Kevin Wolf587da2c2013-06-05 14:19:41 +02001621 .name = "qemu-io",
1622 .args_type = "device:B,command:s",
1623 .params = "[device] \"[command]\"",
1624 .help = "run a qemu-io command on a block device",
1625 .mhandler.cmd = hmp_qemu_io,
1626 },
1627
1628STEXI
1629@item qemu-io @var{device} @var{command}
1630@findex qemu-io
1631
1632Executes a qemu-io command on the given block device.
1633
1634ETEXI
1635
1636 {
Jason J. Herneabf23322013-12-11 13:24:14 -05001637 .name = "cpu-add",
1638 .args_type = "id:i",
1639 .params = "id",
1640 .help = "add cpu",
1641 .mhandler.cmd = hmp_cpu_add,
1642 },
1643
1644STEXI
1645@item cpu-add @var{id}
1646Add CPU with id @var{id}
1647ETEXI
1648
1649 {
Jan Kiszka33572ec2010-05-31 14:43:30 -03001650 .name = "info",
1651 .args_type = "item:s?",
1652 .params = "[subcommand]",
1653 .help = "show various information about the system state",
Wenchao Xia84c44612013-01-14 14:06:29 +08001654 .mhandler.cmd = do_info_help,
1655 .sub_table = info_cmds,
Jan Kiszka33572ec2010-05-31 14:43:30 -03001656 },
1657
1658STEXI
1659@item info @var{subcommand}
1660@findex info
1661Show various information about the system state.
1662
1663@table @option
1664@item info version
1665show the version of QEMU
Jan Kiszka33572ec2010-05-31 14:43:30 -03001666@item info network
1667show the various VLANs and the associated devices
1668@item info chardev
1669show the character devices
1670@item info block
1671show the block devices
1672@item info blockstats
1673show block device statistics
1674@item info registers
1675show the cpu registers
1676@item info cpus
1677show infos for each CPU
1678@item info history
1679show the command line history
1680@item info irq
1681show the interrupts statistics (if available)
1682@item info pic
1683show i8259 (PIC) state
1684@item info pci
1685show emulated PCI device info
1686@item info tlb
Max Filippov692f7372012-01-07 20:02:40 +04001687show virtual to physical memory mappings (i386, SH4, SPARC, PPC, and Xtensa only)
Jan Kiszka33572ec2010-05-31 14:43:30 -03001688@item info mem
1689show the active virtual memory mappings (i386 only)
Jan Kiszka33572ec2010-05-31 14:43:30 -03001690@item info jit
1691show dynamic compiler info
Jan Kiszka33572ec2010-05-31 14:43:30 -03001692@item info numa
1693show NUMA information
Jan Kiszkab40292e2010-05-31 14:43:31 -03001694@item info kvm
1695show KVM information
Jan Kiszka33572ec2010-05-31 14:43:30 -03001696@item info usb
1697show USB devices plugged on the virtual USB hub
1698@item info usbhost
1699show all USB host devices
1700@item info profile
1701show profiling information
1702@item info capture
1703show information about active capturing
1704@item info snapshots
1705show list of VM snapshots
1706@item info status
1707show the current VM status (running|paused)
1708@item info pcmcia
1709show guest PCMCIA status
1710@item info mice
1711show which guest mouse is receiving events
1712@item info vnc
1713show the vnc server status
1714@item info name
1715show the current VM name
1716@item info uuid
1717show the current VM UUID
1718@item info cpustats
1719show CPU statistics
1720@item info usernet
1721show user network stack connection states
1722@item info migrate
1723show migration status
Orit Wassermanbbf6da32012-08-06 21:42:47 +03001724@item info migrate_capabilities
1725show current migration capabilities
Orit Wasserman9e1ba4c2012-08-06 21:42:54 +03001726@item info migrate_cache_size
1727show current migration XBZRLE cache size
Jan Kiszka33572ec2010-05-31 14:43:30 -03001728@item info balloon
1729show balloon information
1730@item info qtree
1731show device tree
1732@item info qdm
1733show qdev device model list
1734@item info roms
1735show roms
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05001736@item info tpm
1737show the TPM device
Jan Kiszka33572ec2010-05-31 14:43:30 -03001738@end table
1739ETEXI
1740
LluĂ­s31965ae2011-08-31 20:31:24 +02001741STEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +05301742@item info trace-events
1743show available trace events and their state
1744ETEXI
Prerna Saxena22890ab2010-06-24 17:04:53 +05301745
Blue Swirl23130862009-06-06 08:22:04 +00001746STEXI
1747@end table
1748ETEXI