]> git.proxmox.com Git - qemu.git/blob - qemu-monitor.hx
monitor: Reorder info documentation
[qemu.git] / qemu-monitor.hx
1 HXCOMM Use DEFHEADING() to define headings in both help text and texi
2 HXCOMM Text between STEXI and ETEXI are copied to texi version and
3 HXCOMM discarded from C version
4 HXCOMM DEF(command, args, callback, arg_string, help) is used to construct
5 HXCOMM monitor commands
6 HXCOMM HXCOMM can be used for comments, discarded from both texi and C
7
8 STEXI
9 @table @option
10 ETEXI
11
12 {
13 .name = "help|?",
14 .args_type = "name:s?",
15 .params = "[cmd]",
16 .help = "show the help",
17 .mhandler.cmd = do_help_cmd,
18 },
19
20 STEXI
21 @item help or ? [@var{cmd}]
22 @findex help
23 Show the help for all commands or just for command @var{cmd}.
24 ETEXI
25
26 {
27 .name = "commit",
28 .args_type = "device:B",
29 .params = "device|all",
30 .help = "commit changes to the disk images (if -snapshot is used) or backing files",
31 .mhandler.cmd = do_commit,
32 },
33
34 STEXI
35 @item commit
36 @findex commit
37 Commit changes to the disk images (if -snapshot is used) or backing files.
38 ETEXI
39
40 {
41 .name = "q|quit",
42 .args_type = "",
43 .params = "",
44 .help = "quit the emulator",
45 .user_print = monitor_user_noop,
46 .mhandler.cmd_new = do_quit,
47 },
48
49 STEXI
50 @item q or quit
51 @findex quit
52 Quit the emulator.
53 ETEXI
54
55 {
56 .name = "eject",
57 .args_type = "force:-f,device:B",
58 .params = "[-f] device",
59 .help = "eject a removable medium (use -f to force it)",
60 .user_print = monitor_user_noop,
61 .mhandler.cmd_new = do_eject,
62 },
63
64 STEXI
65 @item eject [-f] @var{device}
66 @findex eject
67 Eject a removable medium (use -f to force it).
68 ETEXI
69
70 {
71 .name = "change",
72 .args_type = "device:B,target:F,arg:s?",
73 .params = "device filename [format]",
74 .help = "change a removable medium, optional format",
75 .user_print = monitor_user_noop,
76 .mhandler.cmd_new = do_change,
77 },
78
79 STEXI
80 @item change @var{device} @var{setting}
81 @findex change
82
83 Change the configuration of a device.
84
85 @table @option
86 @item change @var{diskdevice} @var{filename} [@var{format}]
87 Change the medium for a removable disk device to point to @var{filename}. eg
88
89 @example
90 (qemu) change ide1-cd0 /path/to/some.iso
91 @end example
92
93 @var{format} is optional.
94
95 @item change vnc @var{display},@var{options}
96 Change the configuration of the VNC server. The valid syntax for @var{display}
97 and @var{options} are described at @ref{sec_invocation}. eg
98
99 @example
100 (qemu) change vnc localhost:1
101 @end example
102
103 @item change vnc password [@var{password}]
104
105 Change the password associated with the VNC server. If the new password is not
106 supplied, the monitor will prompt for it to be entered. VNC passwords are only
107 significant up to 8 letters. eg
108
109 @example
110 (qemu) change vnc password
111 Password: ********
112 @end example
113
114 @end table
115 ETEXI
116
117 {
118 .name = "screendump",
119 .args_type = "filename:F",
120 .params = "filename",
121 .help = "save screen into PPM image 'filename'",
122 .user_print = monitor_user_noop,
123 .mhandler.cmd_new = do_screen_dump,
124 },
125
126 STEXI
127 @item screendump @var{filename}
128 @findex screendump
129 Save screen into PPM image @var{filename}.
130 ETEXI
131
132 {
133 .name = "logfile",
134 .args_type = "filename:F",
135 .params = "filename",
136 .help = "output logs to 'filename'",
137 .mhandler.cmd = do_logfile,
138 },
139
140 STEXI
141 @item logfile @var{filename}
142 @findex logfile
143 Output logs to @var{filename}.
144 ETEXI
145
146 {
147 .name = "log",
148 .args_type = "items:s",
149 .params = "item1[,...]",
150 .help = "activate logging of the specified items to '/tmp/qemu.log'",
151 .mhandler.cmd = do_log,
152 },
153
154 STEXI
155 @item log @var{item1}[,...]
156 @findex log
157 Activate logging of the specified items to @file{/tmp/qemu.log}.
158 ETEXI
159
160 {
161 .name = "savevm",
162 .args_type = "name:s?",
163 .params = "[tag|id]",
164 .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created",
165 .mhandler.cmd = do_savevm,
166 },
167
168 STEXI
169 @item savevm [@var{tag}|@var{id}]
170 @findex savevm
171 Create a snapshot of the whole virtual machine. If @var{tag} is
172 provided, it is used as human readable identifier. If there is already
173 a snapshot with the same tag or ID, it is replaced. More info at
174 @ref{vm_snapshots}.
175 ETEXI
176
177 {
178 .name = "loadvm",
179 .args_type = "name:s",
180 .params = "tag|id",
181 .help = "restore a VM snapshot from its tag or id",
182 .mhandler.cmd = do_loadvm,
183 },
184
185 STEXI
186 @item loadvm @var{tag}|@var{id}
187 @findex loadvm
188 Set the whole virtual machine to the snapshot identified by the tag
189 @var{tag} or the unique snapshot ID @var{id}.
190 ETEXI
191
192 {
193 .name = "delvm",
194 .args_type = "name:s",
195 .params = "tag|id",
196 .help = "delete a VM snapshot from its tag or id",
197 .mhandler.cmd = do_delvm,
198 },
199
200 STEXI
201 @item delvm @var{tag}|@var{id}
202 @findex delvm
203 Delete the snapshot identified by @var{tag} or @var{id}.
204 ETEXI
205
206 {
207 .name = "singlestep",
208 .args_type = "option:s?",
209 .params = "[on|off]",
210 .help = "run emulation in singlestep mode or switch to normal mode",
211 .mhandler.cmd = do_singlestep,
212 },
213
214 STEXI
215 @item singlestep [off]
216 @findex singlestep
217 Run the emulation in single step mode.
218 If called with option off, the emulation returns to normal mode.
219 ETEXI
220
221 {
222 .name = "stop",
223 .args_type = "",
224 .params = "",
225 .help = "stop emulation",
226 .user_print = monitor_user_noop,
227 .mhandler.cmd_new = do_stop,
228 },
229
230 STEXI
231 @item stop
232 @findex stop
233 Stop emulation.
234 ETEXI
235
236 {
237 .name = "c|cont",
238 .args_type = "",
239 .params = "",
240 .help = "resume emulation",
241 .user_print = monitor_user_noop,
242 .mhandler.cmd_new = do_cont,
243 },
244
245 STEXI
246 @item c or cont
247 @findex cont
248 Resume emulation.
249 ETEXI
250
251 {
252 .name = "gdbserver",
253 .args_type = "device:s?",
254 .params = "[device]",
255 .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'",
256 .mhandler.cmd = do_gdbserver,
257 },
258
259 STEXI
260 @item gdbserver [@var{port}]
261 @findex gdbserver
262 Start gdbserver session (default @var{port}=1234)
263 ETEXI
264
265 {
266 .name = "x",
267 .args_type = "fmt:/,addr:l",
268 .params = "/fmt addr",
269 .help = "virtual memory dump starting at 'addr'",
270 .mhandler.cmd = do_memory_dump,
271 },
272
273 STEXI
274 @item x/fmt @var{addr}
275 @findex x
276 Virtual memory dump starting at @var{addr}.
277 ETEXI
278
279 {
280 .name = "xp",
281 .args_type = "fmt:/,addr:l",
282 .params = "/fmt addr",
283 .help = "physical memory dump starting at 'addr'",
284 .mhandler.cmd = do_physical_memory_dump,
285 },
286
287 STEXI
288 @item xp /@var{fmt} @var{addr}
289 @findex xp
290 Physical memory dump starting at @var{addr}.
291
292 @var{fmt} is a format which tells the command how to format the
293 data. Its syntax is: @option{/@{count@}@{format@}@{size@}}
294
295 @table @var
296 @item count
297 is the number of items to be dumped.
298
299 @item format
300 can be x (hex), d (signed decimal), u (unsigned decimal), o (octal),
301 c (char) or i (asm instruction).
302
303 @item size
304 can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86,
305 @code{h} or @code{w} can be specified with the @code{i} format to
306 respectively select 16 or 32 bit code instruction size.
307
308 @end table
309
310 Examples:
311 @itemize
312 @item
313 Dump 10 instructions at the current instruction pointer:
314 @example
315 (qemu) x/10i $eip
316 0x90107063: ret
317 0x90107064: sti
318 0x90107065: lea 0x0(%esi,1),%esi
319 0x90107069: lea 0x0(%edi,1),%edi
320 0x90107070: ret
321 0x90107071: jmp 0x90107080
322 0x90107073: nop
323 0x90107074: nop
324 0x90107075: nop
325 0x90107076: nop
326 @end example
327
328 @item
329 Dump 80 16 bit values at the start of the video memory.
330 @smallexample
331 (qemu) xp/80hx 0xb8000
332 0x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42
333 0x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41
334 0x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72
335 0x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73
336 0x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20
337 0x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720
338 0x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
339 0x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
340 0x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
341 0x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720
342 @end smallexample
343 @end itemize
344 ETEXI
345
346 {
347 .name = "p|print",
348 .args_type = "fmt:/,val:l",
349 .params = "/fmt expr",
350 .help = "print expression value (use $reg for CPU register access)",
351 .mhandler.cmd = do_print,
352 },
353
354 STEXI
355 @item p or print/@var{fmt} @var{expr}
356 @findex print
357
358 Print expression value. Only the @var{format} part of @var{fmt} is
359 used.
360 ETEXI
361
362 {
363 .name = "i",
364 .args_type = "fmt:/,addr:i,index:i.",
365 .params = "/fmt addr",
366 .help = "I/O port read",
367 .mhandler.cmd = do_ioport_read,
368 },
369
370 STEXI
371 Read I/O port.
372 ETEXI
373
374 {
375 .name = "o",
376 .args_type = "fmt:/,addr:i,val:i",
377 .params = "/fmt addr value",
378 .help = "I/O port write",
379 .mhandler.cmd = do_ioport_write,
380 },
381
382 STEXI
383 Write to I/O port.
384 ETEXI
385
386 {
387 .name = "sendkey",
388 .args_type = "string:s,hold_time:i?",
389 .params = "keys [hold_ms]",
390 .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)",
391 .mhandler.cmd = do_sendkey,
392 },
393
394 STEXI
395 @item sendkey @var{keys}
396 @findex sendkey
397
398 Send @var{keys} to the emulator. @var{keys} could be the name of the
399 key or @code{#} followed by the raw value in either decimal or hexadecimal
400 format. Use @code{-} to press several keys simultaneously. Example:
401 @example
402 sendkey ctrl-alt-f1
403 @end example
404
405 This command is useful to send keys that your graphical user interface
406 intercepts at low level, such as @code{ctrl-alt-f1} in X Window.
407 ETEXI
408
409 {
410 .name = "system_reset",
411 .args_type = "",
412 .params = "",
413 .help = "reset the system",
414 .user_print = monitor_user_noop,
415 .mhandler.cmd_new = do_system_reset,
416 },
417
418 STEXI
419 @item system_reset
420 @findex system_reset
421
422 Reset the system.
423 ETEXI
424
425 {
426 .name = "system_powerdown",
427 .args_type = "",
428 .params = "",
429 .help = "send system power down event",
430 .user_print = monitor_user_noop,
431 .mhandler.cmd_new = do_system_powerdown,
432 },
433
434 STEXI
435 @item system_powerdown
436 @findex system_powerdown
437
438 Power down the system (if supported).
439 ETEXI
440
441 {
442 .name = "sum",
443 .args_type = "start:i,size:i",
444 .params = "addr size",
445 .help = "compute the checksum of a memory region",
446 .mhandler.cmd = do_sum,
447 },
448
449 STEXI
450 @item sum @var{addr} @var{size}
451 @findex sum
452
453 Compute the checksum of a memory region.
454 ETEXI
455
456 {
457 .name = "usb_add",
458 .args_type = "devname:s",
459 .params = "device",
460 .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')",
461 .mhandler.cmd = do_usb_add,
462 },
463
464 STEXI
465 @item usb_add @var{devname}
466 @findex usb_add
467
468 Add the USB device @var{devname}. For details of available devices see
469 @ref{usb_devices}
470 ETEXI
471
472 {
473 .name = "usb_del",
474 .args_type = "devname:s",
475 .params = "device",
476 .help = "remove USB device 'bus.addr'",
477 .mhandler.cmd = do_usb_del,
478 },
479
480 STEXI
481 @item usb_del @var{devname}
482 @findex usb_del
483
484 Remove the USB device @var{devname} from the QEMU virtual USB
485 hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor
486 command @code{info usb} to see the devices you can remove.
487 ETEXI
488
489 {
490 .name = "device_add",
491 .args_type = "device:O",
492 .params = "driver[,prop=value][,...]",
493 .help = "add device, like -device on the command line",
494 .user_print = monitor_user_noop,
495 .mhandler.cmd_new = do_device_add,
496 },
497
498 STEXI
499 @item device_add @var{config}
500 @findex device_add
501
502 Add device.
503 ETEXI
504
505 {
506 .name = "device_del",
507 .args_type = "id:s",
508 .params = "device",
509 .help = "remove device",
510 .user_print = monitor_user_noop,
511 .mhandler.cmd_new = do_device_del,
512 },
513
514 STEXI
515 @item device_del @var{id}
516 @findex device_del
517
518 Remove device @var{id}.
519 ETEXI
520
521 {
522 .name = "cpu",
523 .args_type = "index:i",
524 .params = "index",
525 .help = "set the default CPU",
526 .user_print = monitor_user_noop,
527 .mhandler.cmd_new = do_cpu_set,
528 },
529
530 STEXI
531 @item cpu @var{index}
532 @findex cpu
533 Set the default CPU.
534 ETEXI
535
536 {
537 .name = "mouse_move",
538 .args_type = "dx_str:s,dy_str:s,dz_str:s?",
539 .params = "dx dy [dz]",
540 .help = "send mouse move events",
541 .mhandler.cmd = do_mouse_move,
542 },
543
544 STEXI
545 @item mouse_move @var{dx} @var{dy} [@var{dz}]
546 @findex mouse_move
547 Move the active mouse to the specified coordinates @var{dx} @var{dy}
548 with optional scroll axis @var{dz}.
549 ETEXI
550
551 {
552 .name = "mouse_button",
553 .args_type = "button_state:i",
554 .params = "state",
555 .help = "change mouse button state (1=L, 2=M, 4=R)",
556 .mhandler.cmd = do_mouse_button,
557 },
558
559 STEXI
560 @item mouse_button @var{val}
561 @findex mouse_button
562 Change the active mouse button state @var{val} (1=L, 2=M, 4=R).
563 ETEXI
564
565 {
566 .name = "mouse_set",
567 .args_type = "index:i",
568 .params = "index",
569 .help = "set which mouse device receives events",
570 .mhandler.cmd = do_mouse_set,
571 },
572
573 STEXI
574 @item mouse_set @var{index}
575 @findex mouse_set
576 Set which mouse device receives events at given @var{index}, index
577 can be obtained with
578 @example
579 info mice
580 @end example
581 ETEXI
582
583 #ifdef HAS_AUDIO
584 {
585 .name = "wavcapture",
586 .args_type = "path:F,freq:i?,bits:i?,nchannels:i?",
587 .params = "path [frequency [bits [channels]]]",
588 .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)",
589 .mhandler.cmd = do_wav_capture,
590 },
591 #endif
592 STEXI
593 @item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]]
594 @findex wavcapture
595 Capture audio into @var{filename}. Using sample rate @var{frequency}
596 bits per sample @var{bits} and number of channels @var{channels}.
597
598 Defaults:
599 @itemize @minus
600 @item Sample rate = 44100 Hz - CD quality
601 @item Bits = 16
602 @item Number of channels = 2 - Stereo
603 @end itemize
604 ETEXI
605
606 #ifdef HAS_AUDIO
607 {
608 .name = "stopcapture",
609 .args_type = "n:i",
610 .params = "capture index",
611 .help = "stop capture",
612 .mhandler.cmd = do_stop_capture,
613 },
614 #endif
615 STEXI
616 @item stopcapture @var{index}
617 @findex stopcapture
618 Stop capture with a given @var{index}, index can be obtained with
619 @example
620 info capture
621 @end example
622 ETEXI
623
624 {
625 .name = "memsave",
626 .args_type = "val:l,size:i,filename:s",
627 .params = "addr size file",
628 .help = "save to disk virtual memory dump starting at 'addr' of size 'size'",
629 .user_print = monitor_user_noop,
630 .mhandler.cmd_new = do_memory_save,
631 },
632
633 STEXI
634 @item memsave @var{addr} @var{size} @var{file}
635 @findex memsave
636 save to disk virtual memory dump starting at @var{addr} of size @var{size}.
637 ETEXI
638
639 {
640 .name = "pmemsave",
641 .args_type = "val:l,size:i,filename:s",
642 .params = "addr size file",
643 .help = "save to disk physical memory dump starting at 'addr' of size 'size'",
644 .user_print = monitor_user_noop,
645 .mhandler.cmd_new = do_physical_memory_save,
646 },
647
648 STEXI
649 @item pmemsave @var{addr} @var{size} @var{file}
650 @findex pmemsave
651 save to disk physical memory dump starting at @var{addr} of size @var{size}.
652 ETEXI
653
654 {
655 .name = "boot_set",
656 .args_type = "bootdevice:s",
657 .params = "bootdevice",
658 .help = "define new values for the boot device list",
659 .mhandler.cmd = do_boot_set,
660 },
661
662 STEXI
663 @item boot_set @var{bootdevicelist}
664 @findex boot_set
665
666 Define new values for the boot device list. Those values will override
667 the values specified on the command line through the @code{-boot} option.
668
669 The values that can be specified here depend on the machine type, but are
670 the same that can be specified in the @code{-boot} command line option.
671 ETEXI
672
673 #if defined(TARGET_I386)
674 {
675 .name = "nmi",
676 .args_type = "cpu_index:i",
677 .params = "cpu",
678 .help = "inject an NMI on the given CPU",
679 .mhandler.cmd = do_inject_nmi,
680 },
681 #endif
682 STEXI
683 @item nmi @var{cpu}
684 @findex nmi
685 Inject an NMI on the given CPU (x86 only).
686 ETEXI
687
688 {
689 .name = "migrate",
690 .args_type = "detach:-d,blk:-b,inc:-i,uri:s",
691 .params = "[-d] [-b] [-i] uri",
692 .help = "migrate to URI (using -d to not wait for completion)"
693 "\n\t\t\t -b for migration without shared storage with"
694 " full copy of disk\n\t\t\t -i for migration without "
695 "shared storage with incremental copy of disk "
696 "(base image shared between src and destination)",
697 .user_print = monitor_user_noop,
698 .mhandler.cmd_new = do_migrate,
699 },
700
701
702 STEXI
703 @item migrate [-d] [-b] [-i] @var{uri}
704 @findex migrate
705 Migrate to @var{uri} (using -d to not wait for completion).
706 -b for migration with full copy of disk
707 -i for migration with incremental copy of disk (base image is shared)
708 ETEXI
709
710 {
711 .name = "migrate_cancel",
712 .args_type = "",
713 .params = "",
714 .help = "cancel the current VM migration",
715 .user_print = monitor_user_noop,
716 .mhandler.cmd_new = do_migrate_cancel,
717 },
718
719 STEXI
720 @item migrate_cancel
721 @findex migrate_cancel
722 Cancel the current VM migration.
723 ETEXI
724
725 {
726 .name = "migrate_set_speed",
727 .args_type = "value:f",
728 .params = "value",
729 .help = "set maximum speed (in bytes) for migrations",
730 .user_print = monitor_user_noop,
731 .mhandler.cmd_new = do_migrate_set_speed,
732 },
733
734 STEXI
735 @item migrate_set_speed @var{value}
736 @findex migrate_set_speed
737 Set maximum speed to @var{value} (in bytes) for migrations.
738 ETEXI
739
740 {
741 .name = "migrate_set_downtime",
742 .args_type = "value:T",
743 .params = "value",
744 .help = "set maximum tolerated downtime (in seconds) for migrations",
745 .user_print = monitor_user_noop,
746 .mhandler.cmd_new = do_migrate_set_downtime,
747 },
748
749 STEXI
750 @item migrate_set_downtime @var{second}
751 @findex migrate_set_downtime
752 Set maximum tolerated downtime (in seconds) for migration.
753 ETEXI
754
755 #if defined(TARGET_I386)
756 {
757 .name = "drive_add",
758 .args_type = "pci_addr:s,opts:s",
759 .params = "[[<domain>:]<bus>:]<slot>\n"
760 "[file=file][,if=type][,bus=n]\n"
761 "[,unit=m][,media=d][index=i]\n"
762 "[,cyls=c,heads=h,secs=s[,trans=t]]\n"
763 "[snapshot=on|off][,cache=on|off]",
764 .help = "add drive to PCI storage controller",
765 .mhandler.cmd = drive_hot_add,
766 },
767 #endif
768
769 STEXI
770 @item drive_add
771 @findex drive_add
772 Add drive to PCI storage controller.
773 ETEXI
774
775 #if defined(TARGET_I386)
776 {
777 .name = "pci_add",
778 .args_type = "pci_addr:s,type:s,opts:s?",
779 .params = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...",
780 .help = "hot-add PCI device",
781 .mhandler.cmd = pci_device_hot_add,
782 },
783 #endif
784
785 STEXI
786 @item pci_add
787 @findex pci_add
788 Hot-add PCI device.
789 ETEXI
790
791 #if defined(TARGET_I386)
792 {
793 .name = "pci_del",
794 .args_type = "pci_addr:s",
795 .params = "[[<domain>:]<bus>:]<slot>",
796 .help = "hot remove PCI device",
797 .mhandler.cmd = do_pci_device_hot_remove,
798 },
799 #endif
800
801 STEXI
802 @item pci_del
803 @findex pci_del
804 Hot remove PCI device.
805 ETEXI
806
807 {
808 .name = "host_net_add",
809 .args_type = "device:s,opts:s?",
810 .params = "tap|user|socket|vde|dump [options]",
811 .help = "add host VLAN client",
812 .mhandler.cmd = net_host_device_add,
813 },
814
815 STEXI
816 @item host_net_add
817 @findex host_net_add
818 Add host VLAN client.
819 ETEXI
820
821 {
822 .name = "host_net_remove",
823 .args_type = "vlan_id:i,device:s",
824 .params = "vlan_id name",
825 .help = "remove host VLAN client",
826 .mhandler.cmd = net_host_device_remove,
827 },
828
829 STEXI
830 @item host_net_remove
831 @findex host_net_remove
832 Remove host VLAN client.
833 ETEXI
834
835 {
836 .name = "netdev_add",
837 .args_type = "netdev:O",
838 .params = "[user|tap|socket],id=str[,prop=value][,...]",
839 .help = "add host network device",
840 .user_print = monitor_user_noop,
841 .mhandler.cmd_new = do_netdev_add,
842 },
843
844 STEXI
845 @item netdev_add
846 @findex netdev_add
847 Add host network device.
848 ETEXI
849
850 {
851 .name = "netdev_del",
852 .args_type = "id:s",
853 .params = "id",
854 .help = "remove host network device",
855 .user_print = monitor_user_noop,
856 .mhandler.cmd_new = do_netdev_del,
857 },
858
859 STEXI
860 @item netdev_del
861 @findex netdev_del
862 Remove host network device.
863 ETEXI
864
865 #ifdef CONFIG_SLIRP
866 {
867 .name = "hostfwd_add",
868 .args_type = "arg1:s,arg2:s?,arg3:s?",
869 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport",
870 .help = "redirect TCP or UDP connections from host to guest (requires -net user)",
871 .mhandler.cmd = net_slirp_hostfwd_add,
872 },
873 #endif
874 STEXI
875 @item hostfwd_add
876 @findex hostfwd_add
877 Redirect TCP or UDP connections from host to guest (requires -net user).
878 ETEXI
879
880 #ifdef CONFIG_SLIRP
881 {
882 .name = "hostfwd_remove",
883 .args_type = "arg1:s,arg2:s?,arg3:s?",
884 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport",
885 .help = "remove host-to-guest TCP or UDP redirection",
886 .mhandler.cmd = net_slirp_hostfwd_remove,
887 },
888
889 #endif
890 STEXI
891 @item hostfwd_remove
892 @findex hostfwd_remove
893 Remove host-to-guest TCP or UDP redirection.
894 ETEXI
895
896 {
897 .name = "balloon",
898 .args_type = "value:M",
899 .params = "target",
900 .help = "request VM to change its memory allocation (in MB)",
901 .user_print = monitor_user_noop,
902 .mhandler.cmd_async = do_balloon,
903 .async = 1,
904 },
905
906 STEXI
907 @item balloon @var{value}
908 @findex balloon
909 Request VM to change its memory allocation to @var{value} (in MB).
910 ETEXI
911
912 {
913 .name = "set_link",
914 .args_type = "name:s,up:b",
915 .params = "name on|off",
916 .help = "change the link status of a network adapter",
917 .user_print = monitor_user_noop,
918 .mhandler.cmd_new = do_set_link,
919 },
920
921 STEXI
922 @item set_link @var{name} [on|off]
923 @findex set_link
924 Switch link @var{name} on (i.e. up) or off (i.e. down).
925 ETEXI
926
927 {
928 .name = "watchdog_action",
929 .args_type = "action:s",
930 .params = "[reset|shutdown|poweroff|pause|debug|none]",
931 .help = "change watchdog action",
932 .mhandler.cmd = do_watchdog_action,
933 },
934
935 STEXI
936 @item watchdog_action
937 @findex watchdog_action
938 Change watchdog action.
939 ETEXI
940
941 {
942 .name = "acl_show",
943 .args_type = "aclname:s",
944 .params = "aclname",
945 .help = "list rules in the access control list",
946 .mhandler.cmd = do_acl_show,
947 },
948
949 STEXI
950 @item acl_show @var{aclname}
951 @findex acl_show
952 List all the matching rules in the access control list, and the default
953 policy. There are currently two named access control lists,
954 @var{vnc.x509dname} and @var{vnc.username} matching on the x509 client
955 certificate distinguished name, and SASL username respectively.
956 ETEXI
957
958 {
959 .name = "acl_policy",
960 .args_type = "aclname:s,policy:s",
961 .params = "aclname allow|deny",
962 .help = "set default access control list policy",
963 .mhandler.cmd = do_acl_policy,
964 },
965
966 STEXI
967 @item acl_policy @var{aclname} @code{allow|deny}
968 @findex acl_policy
969 Set the default access control list policy, used in the event that
970 none of the explicit rules match. The default policy at startup is
971 always @code{deny}.
972 ETEXI
973
974 {
975 .name = "acl_add",
976 .args_type = "aclname:s,match:s,policy:s,index:i?",
977 .params = "aclname match allow|deny [index]",
978 .help = "add a match rule to the access control list",
979 .mhandler.cmd = do_acl_add,
980 },
981
982 STEXI
983 @item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}]
984 @findex acl_add
985 Add a match rule to the access control list, allowing or denying access.
986 The match will normally be an exact username or x509 distinguished name,
987 but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to
988 allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will
989 normally be appended to the end of the ACL, but can be inserted
990 earlier in the list if the optional @var{index} parameter is supplied.
991 ETEXI
992
993 {
994 .name = "acl_remove",
995 .args_type = "aclname:s,match:s",
996 .params = "aclname match",
997 .help = "remove a match rule from the access control list",
998 .mhandler.cmd = do_acl_remove,
999 },
1000
1001 STEXI
1002 @item acl_remove @var{aclname} @var{match}
1003 @findex acl_remove
1004 Remove the specified match rule from the access control list.
1005 ETEXI
1006
1007 {
1008 .name = "acl_reset",
1009 .args_type = "aclname:s",
1010 .params = "aclname",
1011 .help = "reset the access control list",
1012 .mhandler.cmd = do_acl_reset,
1013 },
1014
1015 STEXI
1016 @item acl_reset @var{aclname}
1017 @findex acl_reset
1018 Remove all matches from the access control list, and set the default
1019 policy back to @code{deny}.
1020 ETEXI
1021
1022 #if defined(TARGET_I386)
1023
1024 {
1025 .name = "mce",
1026 .args_type = "cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l",
1027 .params = "cpu bank status mcgstatus addr misc",
1028 .help = "inject a MCE on the given CPU",
1029 .mhandler.cmd = do_inject_mce,
1030 },
1031
1032 #endif
1033 STEXI
1034 @item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc}
1035 @findex mce (x86)
1036 Inject an MCE on the given CPU (x86 only).
1037 ETEXI
1038
1039 {
1040 .name = "getfd",
1041 .args_type = "fdname:s",
1042 .params = "getfd name",
1043 .help = "receive a file descriptor via SCM rights and assign it a name",
1044 .user_print = monitor_user_noop,
1045 .mhandler.cmd_new = do_getfd,
1046 },
1047
1048 STEXI
1049 @item getfd @var{fdname}
1050 @findex getfd
1051 If a file descriptor is passed alongside this command using the SCM_RIGHTS
1052 mechanism on unix sockets, it is stored using the name @var{fdname} for
1053 later use by other monitor commands.
1054 ETEXI
1055
1056 {
1057 .name = "closefd",
1058 .args_type = "fdname:s",
1059 .params = "closefd name",
1060 .help = "close a file descriptor previously passed via SCM rights",
1061 .user_print = monitor_user_noop,
1062 .mhandler.cmd_new = do_closefd,
1063 },
1064
1065 STEXI
1066 @item closefd @var{fdname}
1067 @findex closefd
1068 Close the file descriptor previously assigned to @var{fdname} using the
1069 @code{getfd} command. This is only needed if the file descriptor was never
1070 used by another monitor command.
1071 ETEXI
1072
1073 {
1074 .name = "block_passwd",
1075 .args_type = "device:B,password:s",
1076 .params = "block_passwd device password",
1077 .help = "set the password of encrypted block devices",
1078 .user_print = monitor_user_noop,
1079 .mhandler.cmd_new = do_block_set_passwd,
1080 },
1081
1082 STEXI
1083 @item block_passwd @var{device} @var{password}
1084 @findex block_passwd
1085 Set the encrypted device @var{device} password to @var{password}
1086 ETEXI
1087
1088 {
1089 .name = "qmp_capabilities",
1090 .args_type = "",
1091 .params = "",
1092 .help = "enable QMP capabilities",
1093 .user_print = monitor_user_noop,
1094 .mhandler.cmd_new = do_qmp_capabilities,
1095 },
1096
1097 STEXI
1098 @item qmp_capabilities
1099 @findex qmp_capabilities
1100 Enable the specified QMP capabilities
1101 ETEXI
1102
1103
1104 HXCOMM Keep the 'info' command at the end!
1105 HXCOMM This is required for the QMP documentation layout.
1106
1107 {
1108 .name = "info",
1109 .args_type = "item:s?",
1110 .params = "[subcommand]",
1111 .help = "show various information about the system state",
1112 .user_print = monitor_user_noop,
1113 .mhandler.cmd_new = do_info,
1114 },
1115
1116 STEXI
1117 @item info @var{subcommand}
1118 @findex info
1119 Show various information about the system state.
1120
1121 @table @option
1122 @item info version
1123 show the version of QEMU
1124 @item info commands
1125 list QMP available commands
1126 @item info network
1127 show the various VLANs and the associated devices
1128 @item info chardev
1129 show the character devices
1130 @item info block
1131 show the block devices
1132 @item info blockstats
1133 show block device statistics
1134 @item info registers
1135 show the cpu registers
1136 @item info cpus
1137 show infos for each CPU
1138 @item info history
1139 show the command line history
1140 @item info irq
1141 show the interrupts statistics (if available)
1142 @item info pic
1143 show i8259 (PIC) state
1144 @item info pci
1145 show emulated PCI device info
1146 @item info tlb
1147 show virtual to physical memory mappings (i386 only)
1148 @item info mem
1149 show the active virtual memory mappings (i386 only)
1150 @item info hpet
1151 show state of HPET (i386 only)
1152 @item info jit
1153 show dynamic compiler info
1154 @item info kvm
1155 show KVM information
1156 @item info numa
1157 show NUMA information
1158 @item info usb
1159 show USB devices plugged on the virtual USB hub
1160 @item info usbhost
1161 show all USB host devices
1162 @item info profile
1163 show profiling information
1164 @item info capture
1165 show information about active capturing
1166 @item info snapshots
1167 show list of VM snapshots
1168 @item info status
1169 show the current VM status (running|paused)
1170 @item info pcmcia
1171 show guest PCMCIA status
1172 @item info mice
1173 show which guest mouse is receiving events
1174 @item info vnc
1175 show the vnc server status
1176 @item info name
1177 show the current VM name
1178 @item info uuid
1179 show the current VM UUID
1180 @item info cpustats
1181 show CPU statistics
1182 @item info usernet
1183 show user network stack connection states
1184 @item info migrate
1185 show migration status
1186 @item info balloon
1187 show balloon information
1188 @item info qtree
1189 show device tree
1190 @item info qdm
1191 show qdev device model list
1192 @item info roms
1193 show roms
1194 @end table
1195 ETEXI
1196
1197 HXCOMM DO NOT add new commands after 'info', move your addition before it!
1198
1199 STEXI
1200 @end table
1201 ETEXI