1HXCOMM 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 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 20STEXI 21@item help or ? [@var{cmd}] 22@findex help 23Show the help for all commands or just for command @var{cmd}. 24ETEXI 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 34STEXI 35@item commit 36@findex commit 37Commit changes to the disk images (if -snapshot is used) or backing files. 38ETEXI 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 = hmp_quit, 47 }, 48 49STEXI 50@item q or quit 51@findex quit 52Quit the emulator. 53ETEXI 54 55 { 56 .name = "block_resize", 57 .args_type = "device:B,size:o", 58 .params = "device size", 59 .help = "resize a block image", 60 .mhandler.cmd = hmp_block_resize, 61 }, 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 72 { 73 .name = "block_stream", 74 .args_type = "device:B,speed:o?,base:s?", 75 .params = "device [speed [base]]", 76 .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 85 86 { 87 .name = "block_job_set_speed", 88 .args_type = "device:B,speed:o", 89 .params = "device speed", 90 .help = "set maximum speed for a background block operation", 91 .mhandler.cmd = hmp_block_job_set_speed, 92 }, 93 94STEXI 95@item block_job_set_speed 96@findex block_job_set_speed 97Set maximum speed for a background block operation. 98ETEXI 99 100 { 101 .name = "block_job_cancel", 102 .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)", 106 .mhandler.cmd = hmp_block_job_cancel, 107 }, 108 109STEXI 110@item block_job_cancel 111@findex block_job_cancel 112Stop an active block streaming operation. 113ETEXI 114 115 { 116 .name = "block_job_pause", 117 .args_type = "device:B", 118 .params = "device", 119 .help = "pause an active background block operation", 120 .mhandler.cmd = hmp_block_job_pause, 121 }, 122 123STEXI 124@item block_job_pause 125@findex block_job_pause 126Pause an active block streaming operation. 127ETEXI 128 129 { 130 .name = "block_job_resume", 131 .args_type = "device:B", 132 .params = "device", 133 .help = "resume a paused background block operation", 134 .mhandler.cmd = hmp_block_job_resume, 135 }, 136 137STEXI 138@item block_job_resume 139@findex block_job_resume 140Resume a paused block streaming operation. 141ETEXI 142 143 { 144 .name = "eject", 145 .args_type = "force:-f,device:B", 146 .params = "[-f] device", 147 .help = "eject a removable medium (use -f to force it)", 148 .mhandler.cmd = hmp_eject, 149 }, 150 151STEXI 152@item eject [-f] @var{device} 153@findex eject 154Eject a removable medium (use -f to force it). 155ETEXI 156 157 { 158 .name = "drive_del", 159 .args_type = "id:s", 160 .params = "device", 161 .help = "remove host block device", 162 .user_print = monitor_user_noop, 163 .mhandler.cmd_new = do_drive_del, 164 }, 165 166STEXI 167@item drive_del @var{device} 168@findex drive_del 169Remove host block device. The result is that guest generated IO is no longer 170submitted against the host device underlying the disk. Once a drive has 171been deleted, the QEMU Block layer returns -EIO which results in IO 172errors in the guest for applications that are reading/writing to the device. 173ETEXI 174 175 { 176 .name = "change", 177 .args_type = "device:B,target:F,arg:s?", 178 .params = "device filename [format]", 179 .help = "change a removable medium, optional format", 180 .mhandler.cmd = hmp_change, 181 }, 182 183STEXI 184@item change @var{device} @var{setting} 185@findex change 186 187Change the configuration of a device. 188 189@table @option 190@item change @var{diskdevice} @var{filename} [@var{format}] 191Change the medium for a removable disk device to point to @var{filename}. eg 192 193@example 194(qemu) change ide1-cd0 /path/to/some.iso 195@end example 196 197@var{format} is optional. 198 199@item change vnc @var{display},@var{options} 200Change the configuration of the VNC server. The valid syntax for @var{display} 201and @var{options} are described at @ref{sec_invocation}. eg 202 203@example 204(qemu) change vnc localhost:1 205@end example 206 207@item change vnc password [@var{password}] 208 209Change the password associated with the VNC server. If the new password is not 210supplied, the monitor will prompt for it to be entered. VNC passwords are only 211significant up to 8 letters. eg 212 213@example 214(qemu) change vnc password 215Password: ******** 216@end example 217 218@end table 219ETEXI 220 221 { 222 .name = "screendump", 223 .args_type = "filename:F", 224 .params = "filename", 225 .help = "save screen into PPM image 'filename'", 226 .mhandler.cmd = hmp_screen_dump, 227 }, 228 229STEXI 230@item screendump @var{filename} 231@findex screendump 232Save screen into PPM image @var{filename}. 233ETEXI 234 235 { 236 .name = "logfile", 237 .args_type = "filename:F", 238 .params = "filename", 239 .help = "output logs to 'filename'", 240 .mhandler.cmd = do_logfile, 241 }, 242 243STEXI 244@item logfile @var{filename} 245@findex logfile 246Output logs to @var{filename}. 247ETEXI 248 249 { 250 .name = "trace-event", 251 .args_type = "name:s,option:b", 252 .params = "name on|off", 253 .help = "changes status of a specific trace event", 254 .mhandler.cmd = do_trace_event_set_state, 255 }, 256 257STEXI 258@item trace-event 259@findex trace-event 260changes status of a trace event 261ETEXI 262 263#if defined(CONFIG_TRACE_SIMPLE) 264 { 265 .name = "trace-file", 266 .args_type = "op:s?,arg:F?", 267 .params = "on|off|flush|set [arg]", 268 .help = "open, close, or flush trace file, or set a new file name", 269 .mhandler.cmd = do_trace_file, 270 }, 271 272STEXI 273@item trace-file on|off|flush 274@findex trace-file 275Open, close, or flush the trace file. If no argument is given, the status of the trace file is displayed. 276ETEXI 277#endif 278 279 { 280 .name = "log", 281 .args_type = "items:s", 282 .params = "item1[,...]", 283 .help = "activate logging of the specified items to '/tmp/qemu.log'", 284 .mhandler.cmd = do_log, 285 }, 286 287STEXI 288@item log @var{item1}[,...] 289@findex log 290Activate logging of the specified items to @file{/tmp/qemu.log}. 291ETEXI 292 293 { 294 .name = "savevm", 295 .args_type = "name:s?", 296 .params = "[tag|id]", 297 .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created", 298 .mhandler.cmd = do_savevm, 299 }, 300 301STEXI 302@item savevm [@var{tag}|@var{id}] 303@findex savevm 304Create a snapshot of the whole virtual machine. If @var{tag} is 305provided, it is used as human readable identifier. If there is already 306a snapshot with the same tag or ID, it is replaced. More info at 307@ref{vm_snapshots}. 308ETEXI 309 310 { 311 .name = "loadvm", 312 .args_type = "name:s", 313 .params = "tag|id", 314 .help = "restore a VM snapshot from its tag or id", 315 .mhandler.cmd = do_loadvm, 316 }, 317 318STEXI 319@item loadvm @var{tag}|@var{id} 320@findex loadvm 321Set the whole virtual machine to the snapshot identified by the tag 322@var{tag} or the unique snapshot ID @var{id}. 323ETEXI 324 325 { 326 .name = "delvm", 327 .args_type = "name:s", 328 .params = "tag|id", 329 .help = "delete a VM snapshot from its tag or id", 330 .mhandler.cmd = do_delvm, 331 }, 332 333STEXI 334@item delvm @var{tag}|@var{id} 335@findex delvm 336Delete the snapshot identified by @var{tag} or @var{id}. 337ETEXI 338 339 { 340 .name = "singlestep", 341 .args_type = "option:s?", 342 .params = "[on|off]", 343 .help = "run emulation in singlestep mode or switch to normal mode", 344 .mhandler.cmd = do_singlestep, 345 }, 346 347STEXI 348@item singlestep [off] 349@findex singlestep 350Run the emulation in single step mode. 351If called with option off, the emulation returns to normal mode. 352ETEXI 353 354 { 355 .name = "stop", 356 .args_type = "", 357 .params = "", 358 .help = "stop emulation", 359 .mhandler.cmd = hmp_stop, 360 }, 361 362STEXI 363@item stop 364@findex stop 365Stop emulation. 366ETEXI 367 368 { 369 .name = "c|cont", 370 .args_type = "", 371 .params = "", 372 .help = "resume emulation", 373 .mhandler.cmd = hmp_cont, 374 }, 375 376STEXI 377@item c or cont 378@findex cont 379Resume emulation. 380ETEXI 381 382 { 383 .name = "system_wakeup", 384 .args_type = "", 385 .params = "", 386 .help = "wakeup guest from suspend", 387 .mhandler.cmd = hmp_system_wakeup, 388 }, 389 390STEXI 391@item system_wakeup 392@findex system_wakeup 393Wakeup guest from suspend. 394ETEXI 395 396 { 397 .name = "gdbserver", 398 .args_type = "device:s?", 399 .params = "[device]", 400 .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'", 401 .mhandler.cmd = do_gdbserver, 402 }, 403 404STEXI 405@item gdbserver [@var{port}] 406@findex gdbserver 407Start gdbserver session (default @var{port}=1234) 408ETEXI 409 410 { 411 .name = "x", 412 .args_type = "fmt:/,addr:l", 413 .params = "/fmt addr", 414 .help = "virtual memory dump starting at 'addr'", 415 .mhandler.cmd = do_memory_dump, 416 }, 417 418STEXI 419@item x/fmt @var{addr} 420@findex x 421Virtual memory dump starting at @var{addr}. 422ETEXI 423 424 { 425 .name = "xp", 426 .args_type = "fmt:/,addr:l", 427 .params = "/fmt addr", 428 .help = "physical memory dump starting at 'addr'", 429 .mhandler.cmd = do_physical_memory_dump, 430 }, 431 432STEXI 433@item xp /@var{fmt} @var{addr} 434@findex xp 435Physical memory dump starting at @var{addr}. 436 437@var{fmt} is a format which tells the command how to format the 438data. Its syntax is: @option{/@{count@}@{format@}@{size@}} 439 440@table @var 441@item count 442is the number of items to be dumped. 443 444@item format 445can be x (hex), d (signed decimal), u (unsigned decimal), o (octal), 446c (char) or i (asm instruction). 447 448@item size 449can be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86, 450@code{h} or @code{w} can be specified with the @code{i} format to 451respectively select 16 or 32 bit code instruction size. 452 453@end table 454 455Examples: 456@itemize 457@item 458Dump 10 instructions at the current instruction pointer: 459@example 460(qemu) x/10i $eip 4610x90107063: ret 4620x90107064: sti 4630x90107065: lea 0x0(%esi,1),%esi 4640x90107069: lea 0x0(%edi,1),%edi 4650x90107070: ret 4660x90107071: jmp 0x90107080 4670x90107073: nop 4680x90107074: nop 4690x90107075: nop 4700x90107076: nop 471@end example 472 473@item 474Dump 80 16 bit values at the start of the video memory. 475@smallexample 476(qemu) xp/80hx 0xb8000 4770x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42 4780x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41 4790x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72 4800x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73 4810x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20 4820x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720 4830x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 4840x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 4850x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 4860x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 487@end smallexample 488@end itemize 489ETEXI 490 491 { 492 .name = "p|print", 493 .args_type = "fmt:/,val:l", 494 .params = "/fmt expr", 495 .help = "print expression value (use $reg for CPU register access)", 496 .mhandler.cmd = do_print, 497 }, 498 499STEXI 500@item p or print/@var{fmt} @var{expr} 501@findex print 502 503Print expression value. Only the @var{format} part of @var{fmt} is 504used. 505ETEXI 506 507 { 508 .name = "i", 509 .args_type = "fmt:/,addr:i,index:i.", 510 .params = "/fmt addr", 511 .help = "I/O port read", 512 .mhandler.cmd = do_ioport_read, 513 }, 514 515STEXI 516Read I/O port. 517ETEXI 518 519 { 520 .name = "o", 521 .args_type = "fmt:/,addr:i,val:i", 522 .params = "/fmt addr value", 523 .help = "I/O port write", 524 .mhandler.cmd = do_ioport_write, 525 }, 526 527STEXI 528Write to I/O port. 529ETEXI 530 531 { 532 .name = "sendkey", 533 .args_type = "keys:s,hold-time:i?", 534 .params = "keys [hold_ms]", 535 .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)", 536 .mhandler.cmd = hmp_send_key, 537 }, 538 539STEXI 540@item sendkey @var{keys} 541@findex sendkey 542 543Send @var{keys} to the guest. @var{keys} could be the name of the 544key or the raw value in hexadecimal format. Use @code{-} to press 545several keys simultaneously. Example: 546@example 547sendkey ctrl-alt-f1 548@end example 549 550This command is useful to send keys that your graphical user interface 551intercepts at low level, such as @code{ctrl-alt-f1} in X Window. 552ETEXI 553 554 { 555 .name = "system_reset", 556 .args_type = "", 557 .params = "", 558 .help = "reset the system", 559 .mhandler.cmd = hmp_system_reset, 560 }, 561 562STEXI 563@item system_reset 564@findex system_reset 565 566Reset the system. 567ETEXI 568 569 { 570 .name = "system_powerdown", 571 .args_type = "", 572 .params = "", 573 .help = "send system power down event", 574 .mhandler.cmd = hmp_system_powerdown, 575 }, 576 577STEXI 578@item system_powerdown 579@findex system_powerdown 580 581Power down the system (if supported). 582ETEXI 583 584 { 585 .name = "sum", 586 .args_type = "start:i,size:i", 587 .params = "addr size", 588 .help = "compute the checksum of a memory region", 589 .mhandler.cmd = do_sum, 590 }, 591 592STEXI 593@item sum @var{addr} @var{size} 594@findex sum 595 596Compute the checksum of a memory region. 597ETEXI 598 599 { 600 .name = "usb_add", 601 .args_type = "devname:s", 602 .params = "device", 603 .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')", 604 .mhandler.cmd = do_usb_add, 605 }, 606 607STEXI 608@item usb_add @var{devname} 609@findex usb_add 610 611Add the USB device @var{devname}. For details of available devices see 612@ref{usb_devices} 613ETEXI 614 615 { 616 .name = "usb_del", 617 .args_type = "devname:s", 618 .params = "device", 619 .help = "remove USB device 'bus.addr'", 620 .mhandler.cmd = do_usb_del, 621 }, 622 623STEXI 624@item usb_del @var{devname} 625@findex usb_del 626 627Remove the USB device @var{devname} from the QEMU virtual USB 628hub. @var{devname} has the syntax @code{bus.addr}. Use the monitor 629command @code{info usb} to see the devices you can remove. 630ETEXI 631 632 { 633 .name = "device_add", 634 .args_type = "device:O", 635 .params = "driver[,prop=value][,...]", 636 .help = "add device, like -device on the command line", 637 .user_print = monitor_user_noop, 638 .mhandler.cmd_new = do_device_add, 639 }, 640 641STEXI 642@item device_add @var{config} 643@findex device_add 644 645Add device. 646ETEXI 647 648 { 649 .name = "device_del", 650 .args_type = "id:s", 651 .params = "device", 652 .help = "remove device", 653 .mhandler.cmd = hmp_device_del, 654 }, 655 656STEXI 657@item device_del @var{id} 658@findex device_del 659 660Remove device @var{id}. 661ETEXI 662 663 { 664 .name = "cpu", 665 .args_type = "index:i", 666 .params = "index", 667 .help = "set the default CPU", 668 .mhandler.cmd = hmp_cpu, 669 }, 670 671STEXI 672@item cpu @var{index} 673@findex cpu 674Set the default CPU. 675ETEXI 676 677 { 678 .name = "mouse_move", 679 .args_type = "dx_str:s,dy_str:s,dz_str:s?", 680 .params = "dx dy [dz]", 681 .help = "send mouse move events", 682 .mhandler.cmd = do_mouse_move, 683 }, 684 685STEXI 686@item mouse_move @var{dx} @var{dy} [@var{dz}] 687@findex mouse_move 688Move the active mouse to the specified coordinates @var{dx} @var{dy} 689with optional scroll axis @var{dz}. 690ETEXI 691 692 { 693 .name = "mouse_button", 694 .args_type = "button_state:i", 695 .params = "state", 696 .help = "change mouse button state (1=L, 2=M, 4=R)", 697 .mhandler.cmd = do_mouse_button, 698 }, 699 700STEXI 701@item mouse_button @var{val} 702@findex mouse_button 703Change the active mouse button state @var{val} (1=L, 2=M, 4=R). 704ETEXI 705 706 { 707 .name = "mouse_set", 708 .args_type = "index:i", 709 .params = "index", 710 .help = "set which mouse device receives events", 711 .mhandler.cmd = do_mouse_set, 712 }, 713 714STEXI 715@item mouse_set @var{index} 716@findex mouse_set 717Set which mouse device receives events at given @var{index}, index 718can be obtained with 719@example 720info mice 721@end example 722ETEXI 723 724#ifdef HAS_AUDIO 725 { 726 .name = "wavcapture", 727 .args_type = "path:F,freq:i?,bits:i?,nchannels:i?", 728 .params = "path [frequency [bits [channels]]]", 729 .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)", 730 .mhandler.cmd = do_wav_capture, 731 }, 732#endif 733STEXI 734@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]] 735@findex wavcapture 736Capture audio into @var{filename}. Using sample rate @var{frequency} 737bits per sample @var{bits} and number of channels @var{channels}. 738 739Defaults: 740@itemize @minus 741@item Sample rate = 44100 Hz - CD quality 742@item Bits = 16 743@item Number of channels = 2 - Stereo 744@end itemize 745ETEXI 746 747#ifdef HAS_AUDIO 748 { 749 .name = "stopcapture", 750 .args_type = "n:i", 751 .params = "capture index", 752 .help = "stop capture", 753 .mhandler.cmd = do_stop_capture, 754 }, 755#endif 756STEXI 757@item stopcapture @var{index} 758@findex stopcapture 759Stop capture with a given @var{index}, index can be obtained with 760@example 761info capture 762@end example 763ETEXI 764 765 { 766 .name = "memsave", 767 .args_type = "val:l,size:i,filename:s", 768 .params = "addr size file", 769 .help = "save to disk virtual memory dump starting at 'addr' of size 'size'", 770 .mhandler.cmd = hmp_memsave, 771 }, 772 773STEXI 774@item memsave @var{addr} @var{size} @var{file} 775@findex memsave 776save to disk virtual memory dump starting at @var{addr} of size @var{size}. 777ETEXI 778 779 { 780 .name = "pmemsave", 781 .args_type = "val:l,size:i,filename:s", 782 .params = "addr size file", 783 .help = "save to disk physical memory dump starting at 'addr' of size 'size'", 784 .mhandler.cmd = hmp_pmemsave, 785 }, 786 787STEXI 788@item pmemsave @var{addr} @var{size} @var{file} 789@findex pmemsave 790save to disk physical memory dump starting at @var{addr} of size @var{size}. 791ETEXI 792 793 { 794 .name = "boot_set", 795 .args_type = "bootdevice:s", 796 .params = "bootdevice", 797 .help = "define new values for the boot device list", 798 .mhandler.cmd = do_boot_set, 799 }, 800 801STEXI 802@item boot_set @var{bootdevicelist} 803@findex boot_set 804 805Define new values for the boot device list. Those values will override 806the values specified on the command line through the @code{-boot} option. 807 808The values that can be specified here depend on the machine type, but are 809the same that can be specified in the @code{-boot} command line option. 810ETEXI 811 812#if defined(TARGET_I386) 813 { 814 .name = "nmi", 815 .args_type = "", 816 .params = "", 817 .help = "inject an NMI on all guest's CPUs", 818 .mhandler.cmd = hmp_inject_nmi, 819 }, 820#endif 821STEXI 822@item nmi @var{cpu} 823@findex nmi 824Inject an NMI on the given CPU (x86 only). 825ETEXI 826 827 { 828 .name = "migrate", 829 .args_type = "detach:-d,blk:-b,inc:-i,uri:s", 830 .params = "[-d] [-b] [-i] uri", 831 .help = "migrate to URI (using -d to not wait for completion)" 832 "\n\t\t\t -b for migration without shared storage with" 833 " full copy of disk\n\t\t\t -i for migration without " 834 "shared storage with incremental copy of disk " 835 "(base image shared between src and destination)", 836 .mhandler.cmd = hmp_migrate, 837 }, 838 839 840STEXI 841@item migrate [-d] [-b] [-i] @var{uri} 842@findex migrate 843Migrate to @var{uri} (using -d to not wait for completion). 844 -b for migration with full copy of disk 845 -i for migration with incremental copy of disk (base image is shared) 846ETEXI 847 848 { 849 .name = "migrate_cancel", 850 .args_type = "", 851 .params = "", 852 .help = "cancel the current VM migration", 853 .mhandler.cmd = hmp_migrate_cancel, 854 }, 855 856STEXI 857@item migrate_cancel 858@findex migrate_cancel 859Cancel the current VM migration. 860 861ETEXI 862 863 { 864 .name = "migrate_set_cache_size", 865 .args_type = "value:o", 866 .params = "value", 867 .help = "set cache size (in bytes) for XBZRLE migrations," 868 "the cache size will be rounded down to the nearest " 869 "power of 2.\n" 870 "The cache size affects the number of cache misses." 871 "In case of a high cache miss ratio you need to increase" 872 " the cache size", 873 .mhandler.cmd = hmp_migrate_set_cache_size, 874 }, 875 876STEXI 877@item migrate_set_cache_size @var{value} 878@findex migrate_set_cache_size 879Set cache size to @var{value} (in bytes) for xbzrle migrations. 880ETEXI 881 882 { 883 .name = "migrate_set_speed", 884 .args_type = "value:o", 885 .params = "value", 886 .help = "set maximum speed (in bytes) for migrations. " 887 "Defaults to MB if no size suffix is specified, ie. B/K/M/G/T", 888 .mhandler.cmd = hmp_migrate_set_speed, 889 }, 890 891STEXI 892@item migrate_set_speed @var{value} 893@findex migrate_set_speed 894Set maximum speed to @var{value} (in bytes) for migrations. 895ETEXI 896 897 { 898 .name = "migrate_set_downtime", 899 .args_type = "value:T", 900 .params = "value", 901 .help = "set maximum tolerated downtime (in seconds) for migrations", 902 .mhandler.cmd = hmp_migrate_set_downtime, 903 }, 904 905STEXI 906@item migrate_set_downtime @var{second} 907@findex migrate_set_downtime 908Set maximum tolerated downtime (in seconds) for migration. 909ETEXI 910 911 { 912 .name = "migrate_set_capability", 913 .args_type = "capability:s,state:b", 914 .params = "capability state", 915 .help = "Enable/Disable the usage of a capability for migration", 916 .mhandler.cmd = hmp_migrate_set_capability, 917 }, 918 919STEXI 920@item migrate_set_capability @var{capability} @var{state} 921@findex migrate_set_capability 922Enable/Disable the usage of a capability @var{capability} for migration. 923ETEXI 924 925 { 926 .name = "client_migrate_info", 927 .args_type = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?", 928 .params = "protocol hostname port tls-port cert-subject", 929 .help = "send migration info to spice/vnc client", 930 .user_print = monitor_user_noop, 931 .mhandler.cmd_async = client_migrate_info, 932 .flags = MONITOR_CMD_ASYNC, 933 }, 934 935STEXI 936@item client_migrate_info @var{protocol} @var{hostname} @var{port} @var{tls-port} @var{cert-subject} 937@findex client_migrate_info 938Set the spice/vnc connection info for the migration target. The spice/vnc 939server will ask the spice/vnc client to automatically reconnect using the 940new parameters (if specified) once the vm migration finished successfully. 941ETEXI 942 943#if defined(CONFIG_HAVE_CORE_DUMP) 944 { 945 .name = "dump-guest-memory", 946 .args_type = "paging:-p,filename:F,begin:i?,length:i?", 947 .params = "[-p] filename [begin] [length]", 948 .help = "dump guest memory to file" 949 "\n\t\t\t begin(optional): the starting physical address" 950 "\n\t\t\t length(optional): the memory size, in bytes", 951 .mhandler.cmd = hmp_dump_guest_memory, 952 }, 953 954 955STEXI 956@item dump-guest-memory [-p] @var{protocol} @var{begin} @var{length} 957@findex dump-guest-memory 958Dump guest memory to @var{protocol}. The file can be processed with crash or 959gdb. 960 filename: dump file name 961 paging: do paging to get guest's memory mapping 962 begin: the starting physical address. It's optional, and should be 963 specified with length together. 964 length: the memory size, in bytes. It's optional, and should be specified 965 with begin together. 966ETEXI 967#endif 968 969 { 970 .name = "snapshot_blkdev", 971 .args_type = "reuse:-n,device:B,snapshot-file:s?,format:s?", 972 .params = "[-n] device [new-image-file] [format]", 973 .help = "initiates a live snapshot\n\t\t\t" 974 "of device. If a new image file is specified, the\n\t\t\t" 975 "new image file will become the new root image.\n\t\t\t" 976 "If format is specified, the snapshot file will\n\t\t\t" 977 "be created in that format. Otherwise the\n\t\t\t" 978 "snapshot will be internal! (currently unsupported).\n\t\t\t" 979 "The default format is qcow2. The -n flag requests QEMU\n\t\t\t" 980 "to reuse the image found in new-image-file, instead of\n\t\t\t" 981 "recreating it from scratch.", 982 .mhandler.cmd = hmp_snapshot_blkdev, 983 }, 984 985STEXI 986@item snapshot_blkdev 987@findex snapshot_blkdev 988Snapshot device, using snapshot file as target if provided 989ETEXI 990 991 { 992 .name = "drive_add", 993 .args_type = "pci_addr:s,opts:s", 994 .params = "[[<domain>:]<bus>:]<slot>\n" 995 "[file=file][,if=type][,bus=n]\n" 996 "[,unit=m][,media=d][,index=i]\n" 997 "[,cyls=c,heads=h,secs=s[,trans=t]]\n" 998 "[,snapshot=on|off][,cache=on|off]\n" 999 "[,readonly=on|off][,copy-on-read=on|off]", 1000 .help = "add drive to PCI storage controller", 1001 .mhandler.cmd = drive_hot_add, 1002 }, 1003 1004STEXI 1005@item drive_add 1006@findex drive_add 1007Add drive to PCI storage controller. 1008ETEXI 1009 1010#if defined(TARGET_I386) 1011 { 1012 .name = "pci_add", 1013 .args_type = "pci_addr:s,type:s,opts:s?", 1014 .params = "auto|[[<domain>:]<bus>:]<slot> nic|storage [[vlan=n][,macaddr=addr][,model=type]] [file=file][,if=type][,bus=nr]...", 1015 .help = "hot-add PCI device", 1016 .mhandler.cmd = pci_device_hot_add, 1017 }, 1018#endif 1019 1020STEXI 1021@item pci_add 1022@findex pci_add 1023Hot-add PCI device. 1024ETEXI 1025 1026#if defined(TARGET_I386) 1027 { 1028 .name = "pci_del", 1029 .args_type = "pci_addr:s", 1030 .params = "[[<domain>:]<bus>:]<slot>", 1031 .help = "hot remove PCI device", 1032 .mhandler.cmd = do_pci_device_hot_remove, 1033 }, 1034#endif 1035 1036STEXI 1037@item pci_del 1038@findex pci_del 1039Hot remove PCI device. 1040ETEXI 1041 1042 { 1043 .name = "pcie_aer_inject_error", 1044 .args_type = "advisory_non_fatal:-a,correctable:-c," 1045 "id:s,error_status:s," 1046 "header0:i?,header1:i?,header2:i?,header3:i?," 1047 "prefix0:i?,prefix1:i?,prefix2:i?,prefix3:i?", 1048 .params = "[-a] [-c] id " 1049 "<error_status> [<tlp header> [<tlp header prefix>]]", 1050 .help = "inject pcie aer error\n\t\t\t" 1051 " -a for advisory non fatal error\n\t\t\t" 1052 " -c for correctable error\n\t\t\t" 1053 "<id> = qdev device id\n\t\t\t" 1054 "<error_status> = error string or 32bit\n\t\t\t" 1055 "<tlb header> = 32bit x 4\n\t\t\t" 1056 "<tlb header prefix> = 32bit x 4", 1057 .user_print = pcie_aer_inject_error_print, 1058 .mhandler.cmd_new = do_pcie_aer_inject_error, 1059 }, 1060 1061STEXI 1062@item pcie_aer_inject_error 1063@findex pcie_aer_inject_error 1064Inject PCIe AER error 1065ETEXI 1066 1067 { 1068 .name = "host_net_add", 1069 .args_type = "device:s,opts:s?", 1070 .params = "tap|user|socket|vde|dump [options]", 1071 .help = "add host VLAN client", 1072 .mhandler.cmd = net_host_device_add, 1073 }, 1074 1075STEXI 1076@item host_net_add 1077@findex host_net_add 1078Add host VLAN client. 1079ETEXI 1080 1081 { 1082 .name = "host_net_remove", 1083 .args_type = "vlan_id:i,device:s", 1084 .params = "vlan_id name", 1085 .help = "remove host VLAN client", 1086 .mhandler.cmd = net_host_device_remove, 1087 }, 1088 1089STEXI 1090@item host_net_remove 1091@findex host_net_remove 1092Remove host VLAN client. 1093ETEXI 1094 1095 { 1096 .name = "netdev_add", 1097 .args_type = "netdev:O", 1098 .params = "[user|tap|socket],id=str[,prop=value][,...]", 1099 .help = "add host network device", 1100 .mhandler.cmd = hmp_netdev_add, 1101 }, 1102 1103STEXI 1104@item netdev_add 1105@findex netdev_add 1106Add host network device. 1107ETEXI 1108 1109 { 1110 .name = "netdev_del", 1111 .args_type = "id:s", 1112 .params = "id", 1113 .help = "remove host network device", 1114 .mhandler.cmd = hmp_netdev_del, 1115 }, 1116 1117STEXI 1118@item netdev_del 1119@findex netdev_del 1120Remove host network device. 1121ETEXI 1122 1123#ifdef CONFIG_SLIRP 1124 { 1125 .name = "hostfwd_add", 1126 .args_type = "arg1:s,arg2:s?,arg3:s?", 1127 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport", 1128 .help = "redirect TCP or UDP connections from host to guest (requires -net user)", 1129 .mhandler.cmd = net_slirp_hostfwd_add, 1130 }, 1131#endif 1132STEXI 1133@item hostfwd_add 1134@findex hostfwd_add 1135Redirect TCP or UDP connections from host to guest (requires -net user). 1136ETEXI 1137 1138#ifdef CONFIG_SLIRP 1139 { 1140 .name = "hostfwd_remove", 1141 .args_type = "arg1:s,arg2:s?,arg3:s?", 1142 .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport", 1143 .help = "remove host-to-guest TCP or UDP redirection", 1144 .mhandler.cmd = net_slirp_hostfwd_remove, 1145 }, 1146 1147#endif 1148STEXI 1149@item hostfwd_remove 1150@findex hostfwd_remove 1151Remove host-to-guest TCP or UDP redirection. 1152ETEXI 1153 1154 { 1155 .name = "balloon", 1156 .args_type = "value:M", 1157 .params = "target", 1158 .help = "request VM to change its memory allocation (in MB)", 1159 .mhandler.cmd = hmp_balloon, 1160 }, 1161 1162STEXI 1163@item balloon @var{value} 1164@findex balloon 1165Request VM to change its memory allocation to @var{value} (in MB). 1166ETEXI 1167 1168 { 1169 .name = "set_link", 1170 .args_type = "name:s,up:b", 1171 .params = "name on|off", 1172 .help = "change the link status of a network adapter", 1173 .mhandler.cmd = hmp_set_link, 1174 }, 1175 1176STEXI 1177@item set_link @var{name} [on|off] 1178@findex set_link 1179Switch link @var{name} on (i.e. up) or off (i.e. down). 1180ETEXI 1181 1182 { 1183 .name = "watchdog_action", 1184 .args_type = "action:s", 1185 .params = "[reset|shutdown|poweroff|pause|debug|none]", 1186 .help = "change watchdog action", 1187 .mhandler.cmd = do_watchdog_action, 1188 }, 1189 1190STEXI 1191@item watchdog_action 1192@findex watchdog_action 1193Change watchdog action. 1194ETEXI 1195 1196 { 1197 .name = "acl_show", 1198 .args_type = "aclname:s", 1199 .params = "aclname", 1200 .help = "list rules in the access control list", 1201 .mhandler.cmd = do_acl_show, 1202 }, 1203 1204STEXI 1205@item acl_show @var{aclname} 1206@findex acl_show 1207List all the matching rules in the access control list, and the default 1208policy. There are currently two named access control lists, 1209@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client 1210certificate distinguished name, and SASL username respectively. 1211ETEXI 1212 1213 { 1214 .name = "acl_policy", 1215 .args_type = "aclname:s,policy:s", 1216 .params = "aclname allow|deny", 1217 .help = "set default access control list policy", 1218 .mhandler.cmd = do_acl_policy, 1219 }, 1220 1221STEXI 1222@item acl_policy @var{aclname} @code{allow|deny} 1223@findex acl_policy 1224Set the default access control list policy, used in the event that 1225none of the explicit rules match. The default policy at startup is 1226always @code{deny}. 1227ETEXI 1228 1229 { 1230 .name = "acl_add", 1231 .args_type = "aclname:s,match:s,policy:s,index:i?", 1232 .params = "aclname match allow|deny [index]", 1233 .help = "add a match rule to the access control list", 1234 .mhandler.cmd = do_acl_add, 1235 }, 1236 1237STEXI 1238@item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}] 1239@findex acl_add 1240Add a match rule to the access control list, allowing or denying access. 1241The match will normally be an exact username or x509 distinguished name, 1242but can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to 1243allow all users in the @code{EXAMPLE.COM} kerberos realm. The match will 1244normally be appended to the end of the ACL, but can be inserted 1245earlier in the list if the optional @var{index} parameter is supplied. 1246ETEXI 1247 1248 { 1249 .name = "acl_remove", 1250 .args_type = "aclname:s,match:s", 1251 .params = "aclname match", 1252 .help = "remove a match rule from the access control list", 1253 .mhandler.cmd = do_acl_remove, 1254 }, 1255 1256STEXI 1257@item acl_remove @var{aclname} @var{match} 1258@findex acl_remove 1259Remove the specified match rule from the access control list. 1260ETEXI 1261 1262 { 1263 .name = "acl_reset", 1264 .args_type = "aclname:s", 1265 .params = "aclname", 1266 .help = "reset the access control list", 1267 .mhandler.cmd = do_acl_reset, 1268 }, 1269 1270STEXI 1271@item acl_reset @var{aclname} 1272@findex acl_reset 1273Remove all matches from the access control list, and set the default 1274policy back to @code{deny}. 1275ETEXI 1276 1277#if defined(TARGET_I386) 1278 1279 { 1280 .name = "mce", 1281 .args_type = "broadcast:-b,cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l", 1282 .params = "[-b] cpu bank status mcgstatus addr misc", 1283 .help = "inject a MCE on the given CPU [and broadcast to other CPUs with -b option]", 1284 .mhandler.cmd = do_inject_mce, 1285 }, 1286 1287#endif 1288STEXI 1289@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc} 1290@findex mce (x86) 1291Inject an MCE on the given CPU (x86 only). 1292ETEXI 1293 1294 { 1295 .name = "getfd", 1296 .args_type = "fdname:s", 1297 .params = "getfd name", 1298 .help = "receive a file descriptor via SCM rights and assign it a name", 1299 .mhandler.cmd = hmp_getfd, 1300 }, 1301 1302STEXI 1303@item getfd @var{fdname} 1304@findex getfd 1305If a file descriptor is passed alongside this command using the SCM_RIGHTS 1306mechanism on unix sockets, it is stored using the name @var{fdname} for 1307later use by other monitor commands. 1308ETEXI 1309 1310 { 1311 .name = "closefd", 1312 .args_type = "fdname:s", 1313 .params = "closefd name", 1314 .help = "close a file descriptor previously passed via SCM rights", 1315 .mhandler.cmd = hmp_closefd, 1316 }, 1317 1318STEXI 1319@item closefd @var{fdname} 1320@findex closefd 1321Close the file descriptor previously assigned to @var{fdname} using the 1322@code{getfd} command. This is only needed if the file descriptor was never 1323used by another monitor command. 1324ETEXI 1325 1326 { 1327 .name = "block_passwd", 1328 .args_type = "device:B,password:s", 1329 .params = "block_passwd device password", 1330 .help = "set the password of encrypted block devices", 1331 .mhandler.cmd = hmp_block_passwd, 1332 }, 1333 1334STEXI 1335@item block_set_io_throttle @var{device} @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr} 1336@findex block_set_io_throttle 1337Change 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} 1338ETEXI 1339 1340 { 1341 .name = "block_set_io_throttle", 1342 .args_type = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l", 1343 .params = "device bps bps_rd bps_wr iops iops_rd iops_wr", 1344 .help = "change I/O throttle limits for a block drive", 1345 .mhandler.cmd = hmp_block_set_io_throttle, 1346 }, 1347 1348STEXI 1349@item block_passwd @var{device} @var{password} 1350@findex block_passwd 1351Set the encrypted device @var{device} password to @var{password} 1352ETEXI 1353 1354 { 1355 .name = "set_password", 1356 .args_type = "protocol:s,password:s,connected:s?", 1357 .params = "protocol password action-if-connected", 1358 .help = "set spice/vnc password", 1359 .mhandler.cmd = hmp_set_password, 1360 }, 1361 1362STEXI 1363@item set_password [ vnc | spice ] password [ action-if-connected ] 1364@findex set_password 1365 1366Change spice/vnc password. Use zero to make the password stay valid 1367forever. @var{action-if-connected} specifies what should happen in 1368case a connection is established: @var{fail} makes the password change 1369fail. @var{disconnect} changes the password and disconnects the 1370client. @var{keep} changes the password and keeps the connection up. 1371@var{keep} is the default. 1372ETEXI 1373 1374 { 1375 .name = "expire_password", 1376 .args_type = "protocol:s,time:s", 1377 .params = "protocol time", 1378 .help = "set spice/vnc password expire-time", 1379 .mhandler.cmd = hmp_expire_password, 1380 }, 1381 1382STEXI 1383@item expire_password [ vnc | spice ] expire-time 1384@findex expire_password 1385 1386Specify when a password for spice/vnc becomes 1387invalid. @var{expire-time} accepts: 1388 1389@table @var 1390@item now 1391Invalidate password instantly. 1392 1393@item never 1394Password stays valid forever. 1395 1396@item +nsec 1397Password stays valid for @var{nsec} seconds starting now. 1398 1399@item nsec 1400Password is invalidated at the given time. @var{nsec} are the seconds 1401passed since 1970, i.e. unix epoch. 1402 1403@end table 1404ETEXI 1405 1406 { 1407 .name = "info", 1408 .args_type = "item:s?", 1409 .params = "[subcommand]", 1410 .help = "show various information about the system state", 1411 .mhandler.cmd = do_info, 1412 }, 1413 1414STEXI 1415@item info @var{subcommand} 1416@findex info 1417Show various information about the system state. 1418 1419@table @option 1420@item info version 1421show the version of QEMU 1422@item info network 1423show the various VLANs and the associated devices 1424@item info chardev 1425show the character devices 1426@item info block 1427show the block devices 1428@item info blockstats 1429show block device statistics 1430@item info registers 1431show the cpu registers 1432@item info cpus 1433show infos for each CPU 1434@item info history 1435show the command line history 1436@item info irq 1437show the interrupts statistics (if available) 1438@item info pic 1439show i8259 (PIC) state 1440@item info pci 1441show emulated PCI device info 1442@item info tlb 1443show virtual to physical memory mappings (i386, SH4, SPARC, PPC, and Xtensa only) 1444@item info mem 1445show the active virtual memory mappings (i386 only) 1446@item info jit 1447show dynamic compiler info 1448@item info numa 1449show NUMA information 1450@item info kvm 1451show KVM information 1452@item info usb 1453show USB devices plugged on the virtual USB hub 1454@item info usbhost 1455show all USB host devices 1456@item info profile 1457show profiling information 1458@item info capture 1459show information about active capturing 1460@item info snapshots 1461show list of VM snapshots 1462@item info status 1463show the current VM status (running|paused) 1464@item info pcmcia 1465show guest PCMCIA status 1466@item info mice 1467show which guest mouse is receiving events 1468@item info vnc 1469show the vnc server status 1470@item info name 1471show the current VM name 1472@item info uuid 1473show the current VM UUID 1474@item info cpustats 1475show CPU statistics 1476@item info usernet 1477show user network stack connection states 1478@item info migrate 1479show migration status 1480@item info migrate_capabilities 1481show current migration capabilities 1482@item info migrate_cache_size 1483show current migration XBZRLE cache size 1484@item info balloon 1485show balloon information 1486@item info qtree 1487show device tree 1488@item info qdm 1489show qdev device model list 1490@item info roms 1491show roms 1492@end table 1493ETEXI 1494 1495#ifdef CONFIG_TRACE_SIMPLE 1496STEXI 1497@item info trace 1498show contents of trace buffer 1499ETEXI 1500#endif 1501 1502STEXI 1503@item info trace-events 1504show available trace events and their state 1505ETEXI 1506 1507STEXI 1508@end table 1509ETEXI 1510