blob: 45e5fd10f3abb975fe988b6bdd27292706d4153a [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 {
41 .name = "info",
42 .args_type = "item:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030043 .params = "[subcommand]",
44 .help = "show various information about the system state",
Luiz Capitulino13c74252009-10-07 13:41:55 -030045 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -020046 .mhandler.cmd_new = do_info,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -030047 },
48
Blue Swirl23130862009-06-06 08:22:04 +000049STEXI
50@item info @var{subcommand}
Stefan Weil70fcbbe2010-02-05 23:52:04 +010051@findex info
Blue Swirl23130862009-06-06 08:22:04 +000052Show various information about the system state.
53
54@table @option
55@item info version
56show the version of QEMU
57@item info network
58show the various VLANs and the associated devices
59@item info chardev
60show the character devices
61@item info block
62show the block devices
63@item info block
64show block device statistics
65@item info registers
66show the cpu registers
67@item info cpus
68show infos for each CPU
69@item info history
70show the command line history
71@item info irq
72show the interrupts statistics (if available)
73@item info pic
74show i8259 (PIC) state
75@item info pci
76show emulated PCI device info
77@item info tlb
78show virtual to physical memory mappings (i386 only)
79@item info mem
80show the active virtual memory mappings (i386 only)
81@item info hpet
82show state of HPET (i386 only)
Blue Swirl23130862009-06-06 08:22:04 +000083@item info kvm
84show KVM information
85@item info usb
86show USB devices plugged on the virtual USB hub
87@item info usbhost
88show all USB host devices
89@item info profile
90show profiling information
91@item info capture
92show information about active capturing
93@item info snapshots
94show list of VM snapshots
95@item info status
96show the current VM status (running|paused)
97@item info pcmcia
98show guest PCMCIA status
99@item info mice
100show which guest mouse is receiving events
101@item info vnc
102show the vnc server status
103@item info name
104show the current VM name
105@item info uuid
106show the current VM UUID
107@item info cpustats
108show CPU statistics
Jan Kiszka6dbe5532009-06-24 14:42:29 +0200109@item info usernet
110show user network stack connection states
Blue Swirl23130862009-06-06 08:22:04 +0000111@item info migrate
112show migration status
113@item info balloon
114show balloon information
115@item info qtree
116show device tree
117@end table
118ETEXI
119
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300120 {
121 .name = "q|quit",
122 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300123 .params = "",
124 .help = "quit the emulator",
Luiz Capitulinob223f352009-10-07 13:41:56 -0300125 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200126 .mhandler.cmd_new = do_quit,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300127 },
128
Blue Swirl23130862009-06-06 08:22:04 +0000129STEXI
130@item q or quit
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100131@findex quit
Blue Swirl23130862009-06-06 08:22:04 +0000132Quit the emulator.
133ETEXI
134
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300135 {
136 .name = "eject",
Luiz Capitulino78d714e2009-12-14 18:53:21 -0200137 .args_type = "force:-f,device:B",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300138 .params = "[-f] device",
139 .help = "eject a removable medium (use -f to force it)",
Luiz Capitulinoe1c923a2009-10-16 12:23:49 -0300140 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200141 .mhandler.cmd_new = do_eject,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300142 },
143
Blue Swirl23130862009-06-06 08:22:04 +0000144STEXI
145@item eject [-f] @var{device}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100146@findex eject
Blue Swirl23130862009-06-06 08:22:04 +0000147Eject a removable medium (use -f to force it).
148ETEXI
149
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300150 {
151 .name = "change",
152 .args_type = "device:B,target:F,arg:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300153 .params = "device filename [format]",
154 .help = "change a removable medium, optional format",
Markus Armbrusterec3b82a2009-12-07 21:37:09 +0100155 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200156 .mhandler.cmd_new = do_change,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300157 },
158
Blue Swirl23130862009-06-06 08:22:04 +0000159STEXI
160@item change @var{device} @var{setting}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100161@findex change
Blue Swirl23130862009-06-06 08:22:04 +0000162
163Change the configuration of a device.
164
165@table @option
166@item change @var{diskdevice} @var{filename} [@var{format}]
167Change the medium for a removable disk device to point to @var{filename}. eg
168
169@example
170(qemu) change ide1-cd0 /path/to/some.iso
171@end example
172
173@var{format} is optional.
174
175@item change vnc @var{display},@var{options}
176Change the configuration of the VNC server. The valid syntax for @var{display}
177and @var{options} are described at @ref{sec_invocation}. eg
178
179@example
180(qemu) change vnc localhost:1
181@end example
182
183@item change vnc password [@var{password}]
184
185Change the password associated with the VNC server. If the new password is not
186supplied, the monitor will prompt for it to be entered. VNC passwords are only
187significant up to 8 letters. eg
188
189@example
190(qemu) change vnc password
191Password: ********
192@end example
193
194@end table
195ETEXI
196
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300197 {
198 .name = "screendump",
199 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300200 .params = "filename",
201 .help = "save screen into PPM image 'filename'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300202 .mhandler.cmd = do_screen_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300203 },
204
Blue Swirl23130862009-06-06 08:22:04 +0000205STEXI
206@item screendump @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100207@findex screendump
Blue Swirl23130862009-06-06 08:22:04 +0000208Save screen into PPM image @var{filename}.
209ETEXI
210
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300211 {
212 .name = "logfile",
213 .args_type = "filename:F",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300214 .params = "filename",
215 .help = "output logs to 'filename'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300216 .mhandler.cmd = do_logfile,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300217 },
218
Blue Swirl23130862009-06-06 08:22:04 +0000219STEXI
220@item logfile @var{filename}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100221@findex logfile
Blue Swirl23130862009-06-06 08:22:04 +0000222Output logs to @var{filename}.
223ETEXI
224
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300225 {
226 .name = "log",
227 .args_type = "items:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300228 .params = "item1[,...]",
229 .help = "activate logging of the specified items to '/tmp/qemu.log'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300230 .mhandler.cmd = do_log,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300231 },
232
Blue Swirl23130862009-06-06 08:22:04 +0000233STEXI
234@item log @var{item1}[,...]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100235@findex log
Blue Swirl23130862009-06-06 08:22:04 +0000236Activate logging of the specified items to @file{/tmp/qemu.log}.
237ETEXI
238
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300239 {
240 .name = "savevm",
241 .args_type = "name:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300242 .params = "[tag|id]",
243 .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300244 .mhandler.cmd = do_savevm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300245 },
246
Blue Swirl23130862009-06-06 08:22:04 +0000247STEXI
248@item savevm [@var{tag}|@var{id}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100249@findex savevm
Blue Swirl23130862009-06-06 08:22:04 +0000250Create a snapshot of the whole virtual machine. If @var{tag} is
251provided, it is used as human readable identifier. If there is already
252a snapshot with the same tag or ID, it is replaced. More info at
253@ref{vm_snapshots}.
254ETEXI
255
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300256 {
257 .name = "loadvm",
258 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300259 .params = "tag|id",
260 .help = "restore a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300261 .mhandler.cmd = do_loadvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300262 },
263
Blue Swirl23130862009-06-06 08:22:04 +0000264STEXI
265@item loadvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100266@findex loadvm
Blue Swirl23130862009-06-06 08:22:04 +0000267Set the whole virtual machine to the snapshot identified by the tag
268@var{tag} or the unique snapshot ID @var{id}.
269ETEXI
270
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300271 {
272 .name = "delvm",
273 .args_type = "name:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300274 .params = "tag|id",
275 .help = "delete a VM snapshot from its tag or id",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300276 .mhandler.cmd = do_delvm,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300277 },
278
Blue Swirl23130862009-06-06 08:22:04 +0000279STEXI
280@item delvm @var{tag}|@var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100281@findex delvm
Blue Swirl23130862009-06-06 08:22:04 +0000282Delete the snapshot identified by @var{tag} or @var{id}.
283ETEXI
284
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300285 {
286 .name = "singlestep",
287 .args_type = "option:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300288 .params = "[on|off]",
289 .help = "run emulation in singlestep mode or switch to normal mode",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300290 .mhandler.cmd = do_singlestep,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300291 },
292
Blue Swirl23130862009-06-06 08:22:04 +0000293STEXI
294@item singlestep [off]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100295@findex singlestep
Blue Swirl23130862009-06-06 08:22:04 +0000296Run the emulation in single step mode.
297If called with option off, the emulation returns to normal mode.
298ETEXI
299
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300300 {
301 .name = "stop",
302 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300303 .params = "",
304 .help = "stop emulation",
Luiz Capitulinoe0c97bd2009-10-07 13:41:57 -0300305 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200306 .mhandler.cmd_new = do_stop,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300307 },
308
Blue Swirl23130862009-06-06 08:22:04 +0000309STEXI
310@item stop
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100311@findex stop
Blue Swirl23130862009-06-06 08:22:04 +0000312Stop emulation.
313ETEXI
314
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300315 {
316 .name = "c|cont",
317 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300318 .params = "",
319 .help = "resume emulation",
Luiz Capitulinoa1f896a2009-10-07 13:42:00 -0300320 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200321 .mhandler.cmd_new = do_cont,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300322 },
323
Blue Swirl23130862009-06-06 08:22:04 +0000324STEXI
325@item c or cont
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100326@findex cont
Blue Swirl23130862009-06-06 08:22:04 +0000327Resume emulation.
328ETEXI
329
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300330 {
331 .name = "gdbserver",
332 .args_type = "device:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300333 .params = "[device]",
334 .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300335 .mhandler.cmd = do_gdbserver,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300336 },
337
Blue Swirl23130862009-06-06 08:22:04 +0000338STEXI
339@item gdbserver [@var{port}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100340@findex gdbserver
Blue Swirl23130862009-06-06 08:22:04 +0000341Start gdbserver session (default @var{port}=1234)
342ETEXI
343
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300344 {
345 .name = "x",
346 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300347 .params = "/fmt addr",
348 .help = "virtual memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300349 .mhandler.cmd = do_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300350 },
351
Blue Swirl23130862009-06-06 08:22:04 +0000352STEXI
353@item x/fmt @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100354@findex x
Blue Swirl23130862009-06-06 08:22:04 +0000355Virtual memory dump starting at @var{addr}.
356ETEXI
357
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300358 {
359 .name = "xp",
360 .args_type = "fmt:/,addr:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300361 .params = "/fmt addr",
362 .help = "physical memory dump starting at 'addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300363 .mhandler.cmd = do_physical_memory_dump,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300364 },
365
Blue Swirl23130862009-06-06 08:22:04 +0000366STEXI
367@item xp /@var{fmt} @var{addr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100368@findex xp
Blue Swirl23130862009-06-06 08:22:04 +0000369Physical memory dump starting at @var{addr}.
370
371@var{fmt} is a format which tells the command how to format the
372data. Its syntax is: @option{/@{count@}@{format@}@{size@}}
373
374@table @var
375@item count
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100376@findex count
Blue Swirl23130862009-06-06 08:22:04 +0000377is the number of items to be dumped.
378
379@item format
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100380@findex format
Blue Swirl23130862009-06-06 08:22:04 +0000381can be x (hex), d (signed decimal), u (unsigned decimal), o (octal),
382c (char) or i (asm instruction).
383
384@item size
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100385@findex size
Blue Swirl23130862009-06-06 08:22:04 +0000386can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86,
387@code{h} or @code{w} can be specified with the @code{i} format to
388respectively select 16 or 32 bit code instruction size.
389
390@end table
391
392Examples:
393@itemize
394@item
395Dump 10 instructions at the current instruction pointer:
396@example
397(qemu) x/10i $eip
3980x90107063: ret
3990x90107064: sti
4000x90107065: lea 0x0(%esi,1),%esi
4010x90107069: lea 0x0(%edi,1),%edi
4020x90107070: ret
4030x90107071: jmp 0x90107080
4040x90107073: nop
4050x90107074: nop
4060x90107075: nop
4070x90107076: nop
408@end example
409
410@item
411Dump 80 16 bit values at the start of the video memory.
412@smallexample
413(qemu) xp/80hx 0xb8000
4140x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42
4150x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41
4160x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72
4170x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73
4180x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20
4190x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720
4200x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4210x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4220x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
4230x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
424@end smallexample
425@end itemize
426ETEXI
427
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300428 {
429 .name = "p|print",
430 .args_type = "fmt:/,val:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300431 .params = "/fmt expr",
432 .help = "print expression value (use $reg for CPU register access)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300433 .mhandler.cmd = do_print,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300434 },
435
Blue Swirl23130862009-06-06 08:22:04 +0000436STEXI
437@item p or print/@var{fmt} @var{expr}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100438@findex print
Blue Swirl23130862009-06-06 08:22:04 +0000439
440Print expression value. Only the @var{format} part of @var{fmt} is
441used.
442ETEXI
443
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300444 {
445 .name = "i",
446 .args_type = "fmt:/,addr:i,index:i.",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300447 .params = "/fmt addr",
448 .help = "I/O port read",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300449 .mhandler.cmd = do_ioport_read,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300450 },
451
Blue Swirl23130862009-06-06 08:22:04 +0000452STEXI
453Read I/O port.
454ETEXI
455
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300456 {
457 .name = "o",
458 .args_type = "fmt:/,addr:i,val:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300459 .params = "/fmt addr value",
460 .help = "I/O port write",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300461 .mhandler.cmd = do_ioport_write,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300462 },
463
Jan Kiszkaf1147842009-07-14 10:20:11 +0200464STEXI
465Write to I/O port.
466ETEXI
Blue Swirl23130862009-06-06 08:22:04 +0000467
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300468 {
469 .name = "sendkey",
470 .args_type = "string:s,hold_time:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300471 .params = "keys [hold_ms]",
472 .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300473 .mhandler.cmd = do_sendkey,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300474 },
475
Blue Swirl23130862009-06-06 08:22:04 +0000476STEXI
477@item sendkey @var{keys}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100478@findex sendkey
Blue Swirl23130862009-06-06 08:22:04 +0000479
480Send @var{keys} to the emulator. @var{keys} could be the name of the
481key or @code{#} followed by the raw value in either decimal or hexadecimal
482format. Use @code{-} to press several keys simultaneously. Example:
483@example
484sendkey ctrl-alt-f1
485@end example
486
487This command is useful to send keys that your graphical user interface
488intercepts at low level, such as @code{ctrl-alt-f1} in X Window.
489ETEXI
490
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300491 {
492 .name = "system_reset",
493 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300494 .params = "",
495 .help = "reset the system",
Luiz Capitulinoc80d2592009-10-07 13:41:58 -0300496 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200497 .mhandler.cmd_new = do_system_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300498 },
499
Blue Swirl23130862009-06-06 08:22:04 +0000500STEXI
501@item system_reset
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100502@findex system_reset
Blue Swirl23130862009-06-06 08:22:04 +0000503
504Reset the system.
505ETEXI
506
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300507 {
508 .name = "system_powerdown",
509 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300510 .params = "",
511 .help = "send system power down event",
Luiz Capitulino43076662009-10-07 13:41:59 -0300512 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200513 .mhandler.cmd_new = do_system_powerdown,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300514 },
515
Blue Swirl23130862009-06-06 08:22:04 +0000516STEXI
517@item system_powerdown
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100518@findex system_powerdown
Blue Swirl23130862009-06-06 08:22:04 +0000519
520Power down the system (if supported).
521ETEXI
522
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300523 {
524 .name = "sum",
525 .args_type = "start:i,size:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300526 .params = "addr size",
527 .help = "compute the checksum of a memory region",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300528 .mhandler.cmd = do_sum,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300529 },
530
Blue Swirl23130862009-06-06 08:22:04 +0000531STEXI
532@item sum @var{addr} @var{size}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100533@findex sum
Blue Swirl23130862009-06-06 08:22:04 +0000534
535Compute the checksum of a memory region.
536ETEXI
537
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300538 {
539 .name = "usb_add",
540 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300541 .params = "device",
542 .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300543 .mhandler.cmd = do_usb_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300544 },
545
Blue Swirl23130862009-06-06 08:22:04 +0000546STEXI
547@item usb_add @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100548@findex usb_add
Blue Swirl23130862009-06-06 08:22:04 +0000549
550Add the USB device @var{devname}. For details of available devices see
551@ref{usb_devices}
552ETEXI
553
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300554 {
555 .name = "usb_del",
556 .args_type = "devname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300557 .params = "device",
558 .help = "remove USB device 'bus.addr'",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300559 .mhandler.cmd = do_usb_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300560 },
561
Blue Swirl23130862009-06-06 08:22:04 +0000562STEXI
563@item usb_del @var{devname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100564@findex usb_del
Blue Swirl23130862009-06-06 08:22:04 +0000565
566Remove the USB device @var{devname} from the QEMU virtual USB
567hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor
568command @code{info usb} to see the devices you can remove.
569ETEXI
570
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300571 {
572 .name = "device_add",
Markus Armbrusterc7e4e8c2010-02-10 20:47:28 +0100573 .args_type = "device:O",
574 .params = "driver[,prop=value][,...]",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300575 .help = "add device, like -device on the command line",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300576 .mhandler.cmd = do_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300577 },
578
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200579STEXI
580@item device_add @var{config}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100581@findex device_add
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200582
583Add device.
584ETEXI
585
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300586 {
587 .name = "device_del",
588 .args_type = "id:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300589 .params = "device",
590 .help = "remove device",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300591 .mhandler.cmd = do_device_del,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300592 },
593
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200594STEXI
595@item device_del @var{id}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100596@findex device_del
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200597
598Remove device @var{id}.
599ETEXI
600
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300601 {
602 .name = "cpu",
603 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300604 .params = "index",
605 .help = "set the default CPU",
Markus Armbruster81a1b452010-01-20 13:07:35 +0100606 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200607 .mhandler.cmd_new = do_cpu_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300608 },
Gerd Hoffmann3418bd22009-09-25 21:42:41 +0200609
Blue Swirl23130862009-06-06 08:22:04 +0000610STEXI
611Set the default CPU.
612ETEXI
613
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300614 {
615 .name = "mouse_move",
616 .args_type = "dx_str:s,dy_str:s,dz_str:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300617 .params = "dx dy [dz]",
618 .help = "send mouse move events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300619 .mhandler.cmd = do_mouse_move,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300620 },
621
Blue Swirl23130862009-06-06 08:22:04 +0000622STEXI
623@item mouse_move @var{dx} @var{dy} [@var{dz}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100624@findex mouse_move
Blue Swirl23130862009-06-06 08:22:04 +0000625Move the active mouse to the specified coordinates @var{dx} @var{dy}
626with optional scroll axis @var{dz}.
627ETEXI
628
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300629 {
630 .name = "mouse_button",
631 .args_type = "button_state:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300632 .params = "state",
633 .help = "change mouse button state (1=L, 2=M, 4=R)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300634 .mhandler.cmd = do_mouse_button,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300635 },
636
Blue Swirl23130862009-06-06 08:22:04 +0000637STEXI
638@item mouse_button @var{val}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100639@findex mouse_button
Blue Swirl23130862009-06-06 08:22:04 +0000640Change the active mouse button state @var{val} (1=L, 2=M, 4=R).
641ETEXI
642
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300643 {
644 .name = "mouse_set",
645 .args_type = "index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300646 .params = "index",
647 .help = "set which mouse device receives events",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300648 .mhandler.cmd = do_mouse_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300649 },
650
Blue Swirl23130862009-06-06 08:22:04 +0000651STEXI
652@item mouse_set @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100653@findex mouse_set
Blue Swirl23130862009-06-06 08:22:04 +0000654Set which mouse device receives events at given @var{index}, index
655can be obtained with
656@example
657info mice
658@end example
659ETEXI
660
661#ifdef HAS_AUDIO
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300662 {
663 .name = "wavcapture",
664 .args_type = "path:F,freq:i?,bits:i?,nchannels:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300665 .params = "path [frequency [bits [channels]]]",
666 .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300667 .mhandler.cmd = do_wav_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300668 },
Blue Swirl23130862009-06-06 08:22:04 +0000669#endif
670STEXI
671@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100672@findex wavcapture
Blue Swirl23130862009-06-06 08:22:04 +0000673Capture audio into @var{filename}. Using sample rate @var{frequency}
674bits per sample @var{bits} and number of channels @var{channels}.
675
676Defaults:
677@itemize @minus
678@item Sample rate = 44100 Hz - CD quality
679@item Bits = 16
680@item Number of channels = 2 - Stereo
681@end itemize
682ETEXI
683
684#ifdef HAS_AUDIO
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300685 {
686 .name = "stopcapture",
687 .args_type = "n:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300688 .params = "capture index",
689 .help = "stop capture",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300690 .mhandler.cmd = do_stop_capture,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300691 },
Blue Swirl23130862009-06-06 08:22:04 +0000692#endif
693STEXI
694@item stopcapture @var{index}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100695@findex stopcapture
Blue Swirl23130862009-06-06 08:22:04 +0000696Stop capture with a given @var{index}, index can be obtained with
697@example
698info capture
699@end example
700ETEXI
701
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300702 {
703 .name = "memsave",
704 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300705 .params = "addr size file",
706 .help = "save to disk virtual memory dump starting at 'addr' of size 'size'",
Luiz Capitulino57e09452009-10-16 12:23:43 -0300707 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200708 .mhandler.cmd_new = do_memory_save,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300709 },
710
Blue Swirl23130862009-06-06 08:22:04 +0000711STEXI
712@item memsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100713@findex memsave
Blue Swirl23130862009-06-06 08:22:04 +0000714save to disk virtual memory dump starting at @var{addr} of size @var{size}.
715ETEXI
716
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300717 {
718 .name = "pmemsave",
719 .args_type = "val:l,size:i,filename:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300720 .params = "addr size file",
721 .help = "save to disk physical memory dump starting at 'addr' of size 'size'",
Luiz Capitulino18f5a8b2009-10-16 12:23:44 -0300722 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200723 .mhandler.cmd_new = do_physical_memory_save,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300724 },
725
Blue Swirl23130862009-06-06 08:22:04 +0000726STEXI
727@item pmemsave @var{addr} @var{size} @var{file}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100728@findex pmemsave
Blue Swirl23130862009-06-06 08:22:04 +0000729save to disk physical memory dump starting at @var{addr} of size @var{size}.
730ETEXI
731
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300732 {
733 .name = "boot_set",
734 .args_type = "bootdevice:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300735 .params = "bootdevice",
736 .help = "define new values for the boot device list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300737 .mhandler.cmd = do_boot_set,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300738 },
739
Blue Swirl23130862009-06-06 08:22:04 +0000740STEXI
741@item boot_set @var{bootdevicelist}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100742@findex boot_set
Blue Swirl23130862009-06-06 08:22:04 +0000743
744Define new values for the boot device list. Those values will override
745the values specified on the command line through the @code{-boot} option.
746
747The values that can be specified here depend on the machine type, but are
748the same that can be specified in the @code{-boot} command line option.
749ETEXI
750
751#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300752 {
753 .name = "nmi",
754 .args_type = "cpu_index:i",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300755 .params = "cpu",
756 .help = "inject an NMI on the given CPU",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300757 .mhandler.cmd = do_inject_nmi,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300758 },
Blue Swirl23130862009-06-06 08:22:04 +0000759#endif
760STEXI
761@item nmi @var{cpu}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100762@findex nmi
Blue Swirl23130862009-06-06 08:22:04 +0000763Inject an NMI on the given CPU (x86 only).
764ETEXI
765
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300766 {
767 .name = "migrate",
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200768 .args_type = "detach:-d,blk:-b,inc:-i,uri:s",
769 .params = "[-d] [-b] [-i] uri",
770 .help = "migrate to URI (using -d to not wait for completion)"
771 "\n\t\t\t -b for migration without shared storage with"
772 " full copy of disk\n\t\t\t -i for migration without "
773 "shared storage with incremental copy of disk "
774 "(base image shared between src and destination)",
775 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200776 .mhandler.cmd_new = do_migrate,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300777 },
778
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200779
Blue Swirl23130862009-06-06 08:22:04 +0000780STEXI
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200781@item migrate [-d] [-b] [-i] @var{uri}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100782@findex migrate
Blue Swirl23130862009-06-06 08:22:04 +0000783Migrate to @var{uri} (using -d to not wait for completion).
lirans@il.ibm.comfbc3d962009-11-02 15:41:13 +0200784 -b for migration with full copy of disk
785 -i for migration with incremental copy of disk (base image is shared)
Blue Swirl23130862009-06-06 08:22:04 +0000786ETEXI
787
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300788 {
789 .name = "migrate_cancel",
790 .args_type = "",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300791 .params = "",
792 .help = "cancel the current VM migration",
Luiz Capitulino911d2962009-10-16 12:23:47 -0300793 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200794 .mhandler.cmd_new = do_migrate_cancel,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300795 },
796
Blue Swirl23130862009-06-06 08:22:04 +0000797STEXI
798@item migrate_cancel
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100799@findex migrate_cancel
Blue Swirl23130862009-06-06 08:22:04 +0000800Cancel the current VM migration.
801ETEXI
802
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300803 {
804 .name = "migrate_set_speed",
Markus Armbruster5667c492010-01-25 14:23:04 +0100805 .args_type = "value:b",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300806 .params = "value",
807 .help = "set maximum speed (in bytes) for migrations",
Markus Armbruster5fd90832010-01-25 14:23:05 +0100808 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200809 .mhandler.cmd_new = do_migrate_set_speed,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300810 },
811
Blue Swirl23130862009-06-06 08:22:04 +0000812STEXI
813@item migrate_set_speed @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100814@findex migrate_set_speed
Blue Swirl23130862009-06-06 08:22:04 +0000815Set maximum speed to @var{value} (in bytes) for migrations.
816ETEXI
817
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300818 {
819 .name = "migrate_set_downtime",
Markus Armbrusterb0fbf7d2010-01-25 14:23:07 +0100820 .args_type = "value:T",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300821 .params = "value",
822 .help = "set maximum tolerated downtime (in seconds) for migrations",
Markus Armbrusterc6027f52010-01-25 14:23:08 +0100823 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200824 .mhandler.cmd_new = do_migrate_set_downtime,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300825 },
Glauber Costa2ea42952009-05-28 15:22:58 -0400826
827STEXI
828@item migrate_set_downtime @var{second}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100829@findex migrate_set_downtime
Glauber Costa2ea42952009-05-28 15:22:58 -0400830Set maximum tolerated downtime (in seconds) for migration.
831ETEXI
832
Blue Swirl23130862009-06-06 08:22:04 +0000833#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300834 {
835 .name = "drive_add",
836 .args_type = "pci_addr:s,opts:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300837 .params = "[[<domain>:]<bus>:]<slot>\n"
838 "[file=file][,if=type][,bus=n]\n"
839 "[,unit=m][,media=d][index=i]\n"
840 "[,cyls=c,heads=h,secs=s[,trans=t]]\n"
841 "[snapshot=on|off][,cache=on|off]",
842 .help = "add drive to PCI storage controller",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300843 .mhandler.cmd = drive_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300844 },
Blue Swirl23130862009-06-06 08:22:04 +0000845#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300846
Blue Swirl23130862009-06-06 08:22:04 +0000847STEXI
848@item drive_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100849@findex drive_add
Blue Swirl23130862009-06-06 08:22:04 +0000850Add drive to PCI storage controller.
851ETEXI
852
853#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300854 {
855 .name = "pci_add",
856 .args_type = "pci_addr:s,type:s,opts:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300857 .params = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...",
858 .help = "hot-add PCI device",
Luiz Capitulino7a344f72009-12-10 17:16:09 -0200859 .user_print = pci_device_hot_add_print,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200860 .mhandler.cmd_new = pci_device_hot_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300861 },
Blue Swirl23130862009-06-06 08:22:04 +0000862#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300863
Blue Swirl23130862009-06-06 08:22:04 +0000864STEXI
865@item pci_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100866@findex pci_add
Blue Swirl23130862009-06-06 08:22:04 +0000867Hot-add PCI device.
868ETEXI
869
870#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300871 {
872 .name = "pci_del",
873 .args_type = "pci_addr:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300874 .params = "[[<domain>:]<bus>:]<slot>",
875 .help = "hot remove PCI device",
Luiz Capitulino6848d822009-10-16 12:23:48 -0300876 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -0200877 .mhandler.cmd_new = do_pci_device_hot_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300878 },
Blue Swirl23130862009-06-06 08:22:04 +0000879#endif
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300880
Blue Swirl23130862009-06-06 08:22:04 +0000881STEXI
882@item pci_del
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100883@findex pci_del
Blue Swirl23130862009-06-06 08:22:04 +0000884Hot remove PCI device.
885ETEXI
886
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300887 {
888 .name = "host_net_add",
889 .args_type = "device:s,opts:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300890 .params = "tap|user|socket|vde|dump [options]",
891 .help = "add host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300892 .mhandler.cmd = net_host_device_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300893 },
894
Blue Swirl23130862009-06-06 08:22:04 +0000895STEXI
896@item host_net_add
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100897@findex host_net_add
Blue Swirl23130862009-06-06 08:22:04 +0000898Add host VLAN client.
899ETEXI
900
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300901 {
902 .name = "host_net_remove",
903 .args_type = "vlan_id:i,device:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300904 .params = "vlan_id name",
905 .help = "remove host VLAN client",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300906 .mhandler.cmd = net_host_device_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300907 },
908
Blue Swirl23130862009-06-06 08:22:04 +0000909STEXI
910@item host_net_remove
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100911@findex host_net_remove
Blue Swirl23130862009-06-06 08:22:04 +0000912Remove host VLAN client.
913ETEXI
914
915#ifdef CONFIG_SLIRP
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300916 {
917 .name = "hostfwd_add",
918 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300919 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport",
920 .help = "redirect TCP or UDP connections from host to guest (requires -net user)",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300921 .mhandler.cmd = net_slirp_hostfwd_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300922 },
923
924 {
925 .name = "hostfwd_remove",
926 .args_type = "arg1:s,arg2:s?,arg3:s?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300927 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport",
928 .help = "remove host-to-guest TCP or UDP redirection",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300929 .mhandler.cmd = net_slirp_hostfwd_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300930 },
931
Blue Swirl23130862009-06-06 08:22:04 +0000932#endif
933STEXI
934@item host_net_redir
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100935@findex host_net_redir
Blue Swirl23130862009-06-06 08:22:04 +0000936Redirect TCP or UDP connections from host to guest (requires -net user).
937ETEXI
938
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300939 {
940 .name = "balloon",
Luiz Capitulino3b0bd6e2009-12-18 13:25:05 -0200941 .args_type = "value:M",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300942 .params = "target",
943 .help = "request VM to change it's memory allocation (in MB)",
Luiz Capitulino83fb1de2009-10-07 13:42:01 -0300944 .user_print = monitor_user_noop,
Adam Litke625a5be2010-01-26 14:17:35 -0600945 .mhandler.cmd_async = do_balloon,
946 .async = 1,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300947 },
948
Blue Swirl23130862009-06-06 08:22:04 +0000949STEXI
950@item balloon @var{value}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100951@findex balloon
Blue Swirl23130862009-06-06 08:22:04 +0000952Request VM to change its memory allocation to @var{value} (in MB).
953ETEXI
954
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300955 {
956 .name = "set_link",
957 .args_type = "name:s,up_or_down:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300958 .params = "name up|down",
959 .help = "change the link status of a network adapter",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300960 .mhandler.cmd = do_set_link,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300961 },
962
Blue Swirl23130862009-06-06 08:22:04 +0000963STEXI
964@item set_link @var{name} [up|down]
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100965@findex set_link
Blue Swirl23130862009-06-06 08:22:04 +0000966Set link @var{name} up or down.
967ETEXI
968
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300969 {
970 .name = "watchdog_action",
971 .args_type = "action:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300972 .params = "[reset|shutdown|poweroff|pause|debug|none]",
973 .help = "change watchdog action",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300974 .mhandler.cmd = do_watchdog_action,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300975 },
976
Blue Swirl23130862009-06-06 08:22:04 +0000977STEXI
978@item watchdog_action
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100979@findex watchdog_action
Blue Swirl23130862009-06-06 08:22:04 +0000980Change watchdog action.
981ETEXI
982
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300983 {
984 .name = "acl_show",
985 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300986 .params = "aclname",
987 .help = "list rules in the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -0300988 .mhandler.cmd = do_acl_show,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -0300989 },
990
Blue Swirl23130862009-06-06 08:22:04 +0000991STEXI
Jan Kiszka15dfcd42009-06-25 08:22:08 +0200992@item acl_show @var{aclname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +0100993@findex acl_show
Jan Kiszka15dfcd42009-06-25 08:22:08 +0200994List all the matching rules in the access control list, and the default
995policy. There are currently two named access control lists,
996@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client
997certificate distinguished name, and SASL username respectively.
998ETEXI
Blue Swirl23130862009-06-06 08:22:04 +0000999
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001000 {
1001 .name = "acl_policy",
1002 .args_type = "aclname:s,policy:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001003 .params = "aclname allow|deny",
1004 .help = "set default access control list policy",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001005 .mhandler.cmd = do_acl_policy,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001006 },
1007
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001008STEXI
Jan Kiszkacbbfacc2009-07-03 08:46:05 +02001009@item acl_policy @var{aclname} @code{allow|deny}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001010@findex acl_policy
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001011Set the default access control list policy, used in the event that
Blue Swirl23130862009-06-06 08:22:04 +00001012none of the explicit rules match. The default policy at startup is
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001013always @code{deny}.
1014ETEXI
1015
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001016 {
1017 .name = "acl_add",
1018 .args_type = "aclname:s,match:s,policy:s,index:i?",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001019 .params = "aclname match allow|deny [index]",
1020 .help = "add a match rule to the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001021 .mhandler.cmd = do_acl_add,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001022 },
1023
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001024STEXI
1025@item acl_allow @var{aclname} @var{match} @code{allow|deny} [@var{index}]
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001026@findex acl_allow
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001027Add a match rule to the access control list, allowing or denying access.
1028The match will normally be an exact username or x509 distinguished name,
1029but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to
1030allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will
Blue Swirl23130862009-06-06 08:22:04 +00001031normally be appended to the end of the ACL, but can be inserted
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001032earlier in the list if the optional @var{index} parameter is supplied.
1033ETEXI
1034
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001035 {
1036 .name = "acl_remove",
1037 .args_type = "aclname:s,match:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001038 .params = "aclname match",
1039 .help = "remove a match rule from the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001040 .mhandler.cmd = do_acl_remove,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001041 },
1042
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001043STEXI
1044@item acl_remove @var{aclname} @var{match}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001045@findex acl_remove
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001046Remove the specified match rule from the access control list.
1047ETEXI
1048
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001049 {
1050 .name = "acl_reset",
1051 .args_type = "aclname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001052 .params = "aclname",
1053 .help = "reset the access control list",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001054 .mhandler.cmd = do_acl_reset,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001055 },
1056
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001057STEXI
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001058@item acl_remove @var{aclname}
Jan Kiszka15dfcd42009-06-25 08:22:08 +02001059Remove all matches from the access control list, and set the default
Blue Swirl23130862009-06-06 08:22:04 +00001060policy back to @code{deny}.
Blue Swirl23130862009-06-06 08:22:04 +00001061ETEXI
1062
Huang Ying79c4f6b2009-06-23 10:05:14 +08001063#if defined(TARGET_I386)
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001064
1065 {
1066 .name = "mce",
1067 .args_type = "cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001068 .params = "cpu bank status mcgstatus addr misc",
1069 .help = "inject a MCE on the given CPU",
Luiz Capitulinoaf4ce882009-10-07 13:41:52 -03001070 .mhandler.cmd = do_inject_mce,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001071 },
1072
Huang Ying79c4f6b2009-06-23 10:05:14 +08001073#endif
1074STEXI
1075@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001076@findex mce (x86)
Huang Ying79c4f6b2009-06-23 10:05:14 +08001077Inject an MCE on the given CPU (x86 only).
1078ETEXI
1079
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001080 {
1081 .name = "getfd",
1082 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001083 .params = "getfd name",
1084 .help = "receive a file descriptor via SCM rights and assign it a name",
Luiz Capitulinof0d60002009-10-16 12:23:50 -03001085 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -02001086 .mhandler.cmd_new = do_getfd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001087 },
1088
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001089STEXI
1090@item getfd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001091@findex getfd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001092If a file descriptor is passed alongside this command using the SCM_RIGHTS
1093mechanism on unix sockets, it is stored using the name @var{fdname} for
1094later use by other monitor commands.
1095ETEXI
1096
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001097 {
1098 .name = "closefd",
1099 .args_type = "fdname:s",
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001100 .params = "closefd name",
1101 .help = "close a file descriptor previously passed via SCM rights",
Luiz Capitulino18f3a512009-10-16 12:23:51 -03001102 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -02001103 .mhandler.cmd_new = do_closefd,
Luiz Capitulinod7f9b682009-10-07 13:41:50 -03001104 },
1105
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001106STEXI
1107@item closefd @var{fdname}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001108@findex closefd
Mark McLoughlinf07918f2009-07-22 09:11:40 +01001109Close the file descriptor previously assigned to @var{fdname} using the
1110@code{getfd} command. This is only needed if the file descriptor was never
1111used by another monitor command.
1112ETEXI
1113
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001114 {
1115 .name = "block_passwd",
1116 .args_type = "device:B,password:s",
1117 .params = "block_passwd device password",
1118 .help = "set the password of encrypted block devices",
1119 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -02001120 .mhandler.cmd_new = do_block_set_passwd,
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001121 },
1122
1123STEXI
1124@item block_passwd @var{device} @var{password}
Stefan Weil70fcbbe2010-02-05 23:52:04 +01001125@findex block_passwd
Luiz Capitulinoa3a55a22009-12-04 15:24:09 -02001126Set the encrypted device @var{device} password to @var{password}
1127ETEXI
1128
Luiz Capitulino4a7e1192010-02-04 18:10:05 -02001129 {
1130 .name = "qmp_capabilities",
1131 .args_type = "",
1132 .params = "",
1133 .help = "enable QMP capabilities",
1134 .user_print = monitor_user_noop,
Luiz Capitulino261394d2010-02-10 23:50:02 -02001135 .mhandler.cmd_new = do_qmp_capabilities,
Luiz Capitulino4a7e1192010-02-04 18:10:05 -02001136 },
1137
1138STEXI
1139@item qmp_capabilities
1140Enable the specified QMP capabilities
1141ETEXI
1142
Blue Swirl23130862009-06-06 08:22:04 +00001143STEXI
1144@end table
1145ETEXI