12313086aSBlue SwirlHXCOMM Use DEFHEADING() to define headings in both help text and texi 22313086aSBlue SwirlHXCOMM Text between STEXI and ETEXI are copied to texi version and 32313086aSBlue SwirlHXCOMM discarded from C version 42313086aSBlue SwirlHXCOMM DEF(command, args, callback, arg_string, help) is used to construct 52313086aSBlue SwirlHXCOMM monitor commands 62313086aSBlue SwirlHXCOMM HXCOMM can be used for comments, discarded from both texi and C 72313086aSBlue Swirl 82313086aSBlue SwirlSTEXI 92313086aSBlue Swirl@table @option 102313086aSBlue SwirlETEXI 112313086aSBlue Swirl 12d7f9b689SLuiz Capitulino { 13d7f9b689SLuiz Capitulino .name = "help|?", 14129be006SWenchao Xia .args_type = "name:S?", 15d7f9b689SLuiz Capitulino .params = "[cmd]", 16d7f9b689SLuiz Capitulino .help = "show the help", 17af4ce882SLuiz Capitulino .mhandler.cmd = do_help_cmd, 18d7f9b689SLuiz Capitulino }, 19d7f9b689SLuiz Capitulino 202313086aSBlue SwirlSTEXI 212313086aSBlue Swirl@item help or ? [@var{cmd}] 2270fcbbe7SStefan Weil@findex help 232313086aSBlue SwirlShow the help for all commands or just for command @var{cmd}. 242313086aSBlue SwirlETEXI 252313086aSBlue Swirl 26d7f9b689SLuiz Capitulino { 27d7f9b689SLuiz Capitulino .name = "commit", 28d7f9b689SLuiz Capitulino .args_type = "device:B", 29d7f9b689SLuiz Capitulino .params = "device|all", 30d7f9b689SLuiz Capitulino .help = "commit changes to the disk images (if -snapshot is used) or backing files", 313e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_commit, 32d7f9b689SLuiz Capitulino }, 33d7f9b689SLuiz Capitulino 342313086aSBlue SwirlSTEXI 352313086aSBlue Swirl@item commit 3670fcbbe7SStefan Weil@findex commit 372313086aSBlue SwirlCommit changes to the disk images (if -snapshot is used) or backing files. 3837222900SJeff CodyIf the backing file is smaller than the snapshot, then the backing file will be 3937222900SJeff Codyresized to be the same size as the snapshot. If the snapshot is smaller than 4037222900SJeff Codythe backing file, the backing file will not be truncated. If you want the 4137222900SJeff Codybacking file to match the size of the smaller snapshot, you can safely truncate 4237222900SJeff Codyit yourself once the commit operation successfully completes. 432313086aSBlue SwirlETEXI 442313086aSBlue Swirl 45d7f9b689SLuiz Capitulino { 46d7f9b689SLuiz Capitulino .name = "q|quit", 47d7f9b689SLuiz Capitulino .args_type = "", 48d7f9b689SLuiz Capitulino .params = "", 49d7f9b689SLuiz Capitulino .help = "quit the emulator", 50b223f35fSLuiz Capitulino .user_print = monitor_user_noop, 517a7f325eSLuiz Capitulino .mhandler.cmd = hmp_quit, 52d7f9b689SLuiz Capitulino }, 53d7f9b689SLuiz Capitulino 542313086aSBlue SwirlSTEXI 552313086aSBlue Swirl@item q or quit 5670fcbbe7SStefan Weil@findex quit 572313086aSBlue SwirlQuit the emulator. 582313086aSBlue SwirlETEXI 592313086aSBlue Swirl 60d7f9b689SLuiz Capitulino { 616d4a2b3aSChristoph Hellwig .name = "block_resize", 626d4a2b3aSChristoph Hellwig .args_type = "device:B,size:o", 636d4a2b3aSChristoph Hellwig .params = "device size", 646d4a2b3aSChristoph Hellwig .help = "resize a block image", 655e7caacbSLuiz Capitulino .mhandler.cmd = hmp_block_resize, 666d4a2b3aSChristoph Hellwig }, 676d4a2b3aSChristoph Hellwig 686d4a2b3aSChristoph HellwigSTEXI 696d4a2b3aSChristoph Hellwig@item block_resize 706d4a2b3aSChristoph Hellwig@findex block_resize 716d4a2b3aSChristoph HellwigResize a block image while a guest is running. Usually requires guest 726d4a2b3aSChristoph Hellwigaction to see the updated size. Resize to a lower size is supported, 736d4a2b3aSChristoph Hellwigbut should be used with extreme caution. Note that this command only 746d4a2b3aSChristoph Hellwigresizes image files, it can not resize block devices like LVM volumes. 756d4a2b3aSChristoph HellwigETEXI 766d4a2b3aSChristoph Hellwig 7712bd451fSStefan Hajnoczi { 7812bd451fSStefan Hajnoczi .name = "block_stream", 79c83c66c3SStefan Hajnoczi .args_type = "device:B,speed:o?,base:s?", 80c83c66c3SStefan Hajnoczi .params = "device [speed [base]]", 8112bd451fSStefan Hajnoczi .help = "copy data from a backing file into a block device", 8212bd451fSStefan Hajnoczi .mhandler.cmd = hmp_block_stream, 8312bd451fSStefan Hajnoczi }, 8412bd451fSStefan Hajnoczi 8512bd451fSStefan HajnocziSTEXI 8612bd451fSStefan Hajnoczi@item block_stream 8712bd451fSStefan Hajnoczi@findex block_stream 8812bd451fSStefan HajnocziCopy data from a backing file into a block device. 8912bd451fSStefan HajnocziETEXI 906d4a2b3aSChristoph Hellwig 916d4a2b3aSChristoph Hellwig { 922d47c6e9SStefan Hajnoczi .name = "block_job_set_speed", 93882ec7ceSStefan Hajnoczi .args_type = "device:B,speed:o", 94882ec7ceSStefan Hajnoczi .params = "device speed", 952d47c6e9SStefan Hajnoczi .help = "set maximum speed for a background block operation", 962d47c6e9SStefan Hajnoczi .mhandler.cmd = hmp_block_job_set_speed, 972d47c6e9SStefan Hajnoczi }, 982d47c6e9SStefan Hajnoczi 992d47c6e9SStefan HajnocziSTEXI 1004451b799SPaolo Bonzini@item block_job_set_speed 1014451b799SPaolo Bonzini@findex block_job_set_speed 1022d47c6e9SStefan HajnocziSet maximum speed for a background block operation. 1032d47c6e9SStefan HajnocziETEXI 1042d47c6e9SStefan Hajnoczi 1052d47c6e9SStefan Hajnoczi { 106370521a1SStefan Hajnoczi .name = "block_job_cancel", 1076e37fb81SPaolo Bonzini .args_type = "force:-f,device:B", 1086e37fb81SPaolo Bonzini .params = "[-f] device", 1096e37fb81SPaolo Bonzini .help = "stop an active background block operation (use -f" 1106e37fb81SPaolo Bonzini "\n\t\t\t if the operation is currently paused)", 111370521a1SStefan Hajnoczi .mhandler.cmd = hmp_block_job_cancel, 112370521a1SStefan Hajnoczi }, 113370521a1SStefan Hajnoczi 114370521a1SStefan HajnocziSTEXI 115370521a1SStefan Hajnoczi@item block_job_cancel 116370521a1SStefan Hajnoczi@findex block_job_cancel 117aeae883bSPaolo BonziniStop an active background block operation (streaming, mirroring). 118aeae883bSPaolo BonziniETEXI 119aeae883bSPaolo Bonzini 120aeae883bSPaolo Bonzini { 121aeae883bSPaolo Bonzini .name = "block_job_complete", 122aeae883bSPaolo Bonzini .args_type = "device:B", 123aeae883bSPaolo Bonzini .params = "device", 124aeae883bSPaolo Bonzini .help = "stop an active background block operation", 125aeae883bSPaolo Bonzini .mhandler.cmd = hmp_block_job_complete, 126aeae883bSPaolo Bonzini }, 127aeae883bSPaolo Bonzini 128aeae883bSPaolo BonziniSTEXI 129aeae883bSPaolo Bonzini@item block_job_complete 130aeae883bSPaolo Bonzini@findex block_job_complete 131aeae883bSPaolo BonziniManually trigger completion of an active background block operation. 132aeae883bSPaolo BonziniFor mirroring, this will switch the device to the destination path. 133370521a1SStefan HajnocziETEXI 134370521a1SStefan Hajnoczi 135370521a1SStefan Hajnoczi { 1366e37fb81SPaolo Bonzini .name = "block_job_pause", 1376e37fb81SPaolo Bonzini .args_type = "device:B", 1386e37fb81SPaolo Bonzini .params = "device", 1396e37fb81SPaolo Bonzini .help = "pause an active background block operation", 1406e37fb81SPaolo Bonzini .mhandler.cmd = hmp_block_job_pause, 1416e37fb81SPaolo Bonzini }, 1426e37fb81SPaolo Bonzini 1436e37fb81SPaolo BonziniSTEXI 1446e37fb81SPaolo Bonzini@item block_job_pause 1456e37fb81SPaolo Bonzini@findex block_job_pause 1466e37fb81SPaolo BonziniPause an active block streaming operation. 1476e37fb81SPaolo BonziniETEXI 1486e37fb81SPaolo Bonzini 1496e37fb81SPaolo Bonzini { 1506e37fb81SPaolo Bonzini .name = "block_job_resume", 1516e37fb81SPaolo Bonzini .args_type = "device:B", 1526e37fb81SPaolo Bonzini .params = "device", 1536e37fb81SPaolo Bonzini .help = "resume a paused background block operation", 1546e37fb81SPaolo Bonzini .mhandler.cmd = hmp_block_job_resume, 1556e37fb81SPaolo Bonzini }, 1566e37fb81SPaolo Bonzini 1576e37fb81SPaolo BonziniSTEXI 1586e37fb81SPaolo Bonzini@item block_job_resume 1596e37fb81SPaolo Bonzini@findex block_job_resume 1606e37fb81SPaolo BonziniResume a paused block streaming operation. 1616e37fb81SPaolo BonziniETEXI 1626e37fb81SPaolo Bonzini 1636e37fb81SPaolo Bonzini { 164d7f9b689SLuiz Capitulino .name = "eject", 16578d714e0SLuiz Capitulino .args_type = "force:-f,device:B", 166d7f9b689SLuiz Capitulino .params = "[-f] device", 167d7f9b689SLuiz Capitulino .help = "eject a removable medium (use -f to force it)", 168c245b6a3SLuiz Capitulino .mhandler.cmd = hmp_eject, 169d7f9b689SLuiz Capitulino }, 170d7f9b689SLuiz Capitulino 1712313086aSBlue SwirlSTEXI 1722313086aSBlue Swirl@item eject [-f] @var{device} 17370fcbbe7SStefan Weil@findex eject 1742313086aSBlue SwirlEject a removable medium (use -f to force it). 1752313086aSBlue SwirlETEXI 1762313086aSBlue Swirl 177d7f9b689SLuiz Capitulino { 1789063f814SRyan Harper .name = "drive_del", 179f7bdc41aSHani Benhabiles .args_type = "id:B", 1809063f814SRyan Harper .params = "device", 1819063f814SRyan Harper .help = "remove host block device", 1829063f814SRyan Harper .user_print = monitor_user_noop, 1833e5a50d6SMarkus Armbruster .mhandler.cmd_new = hmp_drive_del, 1849063f814SRyan Harper }, 1859063f814SRyan Harper 1869063f814SRyan HarperSTEXI 1879063f814SRyan Harper@item drive_del @var{device} 1889063f814SRyan Harper@findex drive_del 1899063f814SRyan HarperRemove host block device. The result is that guest generated IO is no longer 1909063f814SRyan Harpersubmitted against the host device underlying the disk. Once a drive has 1919063f814SRyan Harperbeen deleted, the QEMU Block layer returns -EIO which results in IO 1929063f814SRyan Harpererrors in the guest for applications that are reading/writing to the device. 193293c51a6SStefan HajnocziThese errors are always reported to the guest, regardless of the drive's error 194293c51a6SStefan Hajnocziactions (drive options rerror, werror). 1959063f814SRyan HarperETEXI 1969063f814SRyan Harper 1979063f814SRyan Harper { 198d7f9b689SLuiz Capitulino .name = "change", 199d7f9b689SLuiz Capitulino .args_type = "device:B,target:F,arg:s?", 200d7f9b689SLuiz Capitulino .params = "device filename [format]", 201d7f9b689SLuiz Capitulino .help = "change a removable medium, optional format", 202333a96ecSLuiz Capitulino .mhandler.cmd = hmp_change, 203d7f9b689SLuiz Capitulino }, 204d7f9b689SLuiz Capitulino 2052313086aSBlue SwirlSTEXI 2062313086aSBlue Swirl@item change @var{device} @var{setting} 20770fcbbe7SStefan Weil@findex change 2082313086aSBlue Swirl 2092313086aSBlue SwirlChange the configuration of a device. 2102313086aSBlue Swirl 2112313086aSBlue Swirl@table @option 2122313086aSBlue Swirl@item change @var{diskdevice} @var{filename} [@var{format}] 2132313086aSBlue SwirlChange the medium for a removable disk device to point to @var{filename}. eg 2142313086aSBlue Swirl 2152313086aSBlue Swirl@example 2162313086aSBlue Swirl(qemu) change ide1-cd0 /path/to/some.iso 2172313086aSBlue Swirl@end example 2182313086aSBlue Swirl 2192313086aSBlue Swirl@var{format} is optional. 2202313086aSBlue Swirl 2212313086aSBlue Swirl@item change vnc @var{display},@var{options} 2222313086aSBlue SwirlChange the configuration of the VNC server. The valid syntax for @var{display} 2232313086aSBlue Swirland @var{options} are described at @ref{sec_invocation}. eg 2242313086aSBlue Swirl 2252313086aSBlue Swirl@example 2262313086aSBlue Swirl(qemu) change vnc localhost:1 2272313086aSBlue Swirl@end example 2282313086aSBlue Swirl 2292313086aSBlue Swirl@item change vnc password [@var{password}] 2302313086aSBlue Swirl 2312313086aSBlue SwirlChange the password associated with the VNC server. If the new password is not 2322313086aSBlue Swirlsupplied, the monitor will prompt for it to be entered. VNC passwords are only 2332313086aSBlue Swirlsignificant up to 8 letters. eg 2342313086aSBlue Swirl 2352313086aSBlue Swirl@example 2362313086aSBlue Swirl(qemu) change vnc password 2372313086aSBlue SwirlPassword: ******** 2382313086aSBlue Swirl@end example 2392313086aSBlue Swirl 2402313086aSBlue Swirl@end table 2412313086aSBlue SwirlETEXI 2422313086aSBlue Swirl 243d7f9b689SLuiz Capitulino { 244d7f9b689SLuiz Capitulino .name = "screendump", 245d7f9b689SLuiz Capitulino .args_type = "filename:F", 246d7f9b689SLuiz Capitulino .params = "filename", 247d7f9b689SLuiz Capitulino .help = "save screen into PPM image 'filename'", 2483e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_screendump, 249d7f9b689SLuiz Capitulino }, 250d7f9b689SLuiz Capitulino 2512313086aSBlue SwirlSTEXI 2522313086aSBlue Swirl@item screendump @var{filename} 25370fcbbe7SStefan Weil@findex screendump 2542313086aSBlue SwirlSave screen into PPM image @var{filename}. 2552313086aSBlue SwirlETEXI 2562313086aSBlue Swirl 257d7f9b689SLuiz Capitulino { 258d7f9b689SLuiz Capitulino .name = "logfile", 259d7f9b689SLuiz Capitulino .args_type = "filename:F", 260d7f9b689SLuiz Capitulino .params = "filename", 261d7f9b689SLuiz Capitulino .help = "output logs to 'filename'", 2623e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_logfile, 263d7f9b689SLuiz Capitulino }, 264d7f9b689SLuiz Capitulino 2652313086aSBlue SwirlSTEXI 2662313086aSBlue Swirl@item logfile @var{filename} 26770fcbbe7SStefan Weil@findex logfile 2682313086aSBlue SwirlOutput logs to @var{filename}. 2692313086aSBlue SwirlETEXI 2702313086aSBlue Swirl 27122890ab5SPrerna Saxena { 27222890ab5SPrerna Saxena .name = "trace-event", 27322890ab5SPrerna Saxena .args_type = "name:s,option:b", 27422890ab5SPrerna Saxena .params = "name on|off", 27522890ab5SPrerna Saxena .help = "changes status of a specific trace event", 2763e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_trace_event, 27722890ab5SPrerna Saxena }, 27822890ab5SPrerna Saxena 27922890ab5SPrerna SaxenaSTEXI 28022890ab5SPrerna Saxena@item trace-event 28122890ab5SPrerna Saxena@findex trace-event 28222890ab5SPrerna Saxenachanges status of a trace event 28322890ab5SPrerna SaxenaETEXI 284c5ceb523SStefan Hajnoczi 285c45a8168SMichael Roth#if defined(CONFIG_TRACE_SIMPLE) 286c5ceb523SStefan Hajnoczi { 287c5ceb523SStefan Hajnoczi .name = "trace-file", 288c5ceb523SStefan Hajnoczi .args_type = "op:s?,arg:F?", 289c5ceb523SStefan Hajnoczi .params = "on|off|flush|set [arg]", 290c5ceb523SStefan Hajnoczi .help = "open, close, or flush trace file, or set a new file name", 2913e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_trace_file, 292c5ceb523SStefan Hajnoczi }, 293c5ceb523SStefan Hajnoczi 294c5ceb523SStefan HajnocziSTEXI 295c5ceb523SStefan Hajnoczi@item trace-file on|off|flush 296c5ceb523SStefan Hajnoczi@findex trace-file 297c5ceb523SStefan HajnocziOpen, close, or flush the trace file. If no argument is given, the status of the trace file is displayed. 298c5ceb523SStefan HajnocziETEXI 29922890ab5SPrerna Saxena#endif 30022890ab5SPrerna Saxena 301d7f9b689SLuiz Capitulino { 302d7f9b689SLuiz Capitulino .name = "log", 303d7f9b689SLuiz Capitulino .args_type = "items:s", 304d7f9b689SLuiz Capitulino .params = "item1[,...]", 305989b697dSPeter Maydell .help = "activate logging of the specified items", 3063e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_log, 307d7f9b689SLuiz Capitulino }, 308d7f9b689SLuiz Capitulino 3092313086aSBlue SwirlSTEXI 3102313086aSBlue Swirl@item log @var{item1}[,...] 31170fcbbe7SStefan Weil@findex log 312989b697dSPeter MaydellActivate logging of the specified items. 3132313086aSBlue SwirlETEXI 3142313086aSBlue Swirl 315d7f9b689SLuiz Capitulino { 316d7f9b689SLuiz Capitulino .name = "savevm", 317d7f9b689SLuiz Capitulino .args_type = "name:s?", 318d7f9b689SLuiz Capitulino .params = "[tag|id]", 319d7f9b689SLuiz Capitulino .help = "save a VM snapshot. If no tag or id are provided, a new snapshot is created", 3203e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_savevm, 321d7f9b689SLuiz Capitulino }, 322d7f9b689SLuiz Capitulino 3232313086aSBlue SwirlSTEXI 3242313086aSBlue Swirl@item savevm [@var{tag}|@var{id}] 32570fcbbe7SStefan Weil@findex savevm 3262313086aSBlue SwirlCreate a snapshot of the whole virtual machine. If @var{tag} is 3272313086aSBlue Swirlprovided, it is used as human readable identifier. If there is already 3282313086aSBlue Swirla snapshot with the same tag or ID, it is replaced. More info at 3292313086aSBlue Swirl@ref{vm_snapshots}. 3302313086aSBlue SwirlETEXI 3312313086aSBlue Swirl 332d7f9b689SLuiz Capitulino { 333d7f9b689SLuiz Capitulino .name = "loadvm", 334d7f9b689SLuiz Capitulino .args_type = "name:s", 335d7f9b689SLuiz Capitulino .params = "tag|id", 336d7f9b689SLuiz Capitulino .help = "restore a VM snapshot from its tag or id", 3373e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_loadvm, 338b21631f3SHani Benhabiles .command_completion = loadvm_completion, 339d7f9b689SLuiz Capitulino }, 340d7f9b689SLuiz Capitulino 3412313086aSBlue SwirlSTEXI 3422313086aSBlue Swirl@item loadvm @var{tag}|@var{id} 34370fcbbe7SStefan Weil@findex loadvm 3442313086aSBlue SwirlSet the whole virtual machine to the snapshot identified by the tag 3452313086aSBlue Swirl@var{tag} or the unique snapshot ID @var{id}. 3462313086aSBlue SwirlETEXI 3472313086aSBlue Swirl 348d7f9b689SLuiz Capitulino { 349d7f9b689SLuiz Capitulino .name = "delvm", 350d7f9b689SLuiz Capitulino .args_type = "name:s", 351d7f9b689SLuiz Capitulino .params = "tag|id", 352d7f9b689SLuiz Capitulino .help = "delete a VM snapshot from its tag or id", 3533e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_delvm, 354b21631f3SHani Benhabiles .command_completion = delvm_completion, 355d7f9b689SLuiz Capitulino }, 356d7f9b689SLuiz Capitulino 3572313086aSBlue SwirlSTEXI 3582313086aSBlue Swirl@item delvm @var{tag}|@var{id} 35970fcbbe7SStefan Weil@findex delvm 3602313086aSBlue SwirlDelete the snapshot identified by @var{tag} or @var{id}. 3612313086aSBlue SwirlETEXI 3622313086aSBlue Swirl 363d7f9b689SLuiz Capitulino { 364d7f9b689SLuiz Capitulino .name = "singlestep", 365d7f9b689SLuiz Capitulino .args_type = "option:s?", 366d7f9b689SLuiz Capitulino .params = "[on|off]", 367d7f9b689SLuiz Capitulino .help = "run emulation in singlestep mode or switch to normal mode", 3683e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_singlestep, 369d7f9b689SLuiz Capitulino }, 370d7f9b689SLuiz Capitulino 3712313086aSBlue SwirlSTEXI 3722313086aSBlue Swirl@item singlestep [off] 37370fcbbe7SStefan Weil@findex singlestep 3742313086aSBlue SwirlRun the emulation in single step mode. 3752313086aSBlue SwirlIf called with option off, the emulation returns to normal mode. 3762313086aSBlue SwirlETEXI 3772313086aSBlue Swirl 378d7f9b689SLuiz Capitulino { 379d7f9b689SLuiz Capitulino .name = "stop", 380d7f9b689SLuiz Capitulino .args_type = "", 381d7f9b689SLuiz Capitulino .params = "", 382d7f9b689SLuiz Capitulino .help = "stop emulation", 3835f158f21SLuiz Capitulino .mhandler.cmd = hmp_stop, 384d7f9b689SLuiz Capitulino }, 385d7f9b689SLuiz Capitulino 3862313086aSBlue SwirlSTEXI 3872313086aSBlue Swirl@item stop 38870fcbbe7SStefan Weil@findex stop 3892313086aSBlue SwirlStop emulation. 3902313086aSBlue SwirlETEXI 3912313086aSBlue Swirl 392d7f9b689SLuiz Capitulino { 393d7f9b689SLuiz Capitulino .name = "c|cont", 394d7f9b689SLuiz Capitulino .args_type = "", 395d7f9b689SLuiz Capitulino .params = "", 396d7f9b689SLuiz Capitulino .help = "resume emulation", 397e42e818bSLuiz Capitulino .mhandler.cmd = hmp_cont, 398d7f9b689SLuiz Capitulino }, 399d7f9b689SLuiz Capitulino 4002313086aSBlue SwirlSTEXI 4012313086aSBlue Swirl@item c or cont 40270fcbbe7SStefan Weil@findex cont 4032313086aSBlue SwirlResume emulation. 4042313086aSBlue SwirlETEXI 4052313086aSBlue Swirl 406d7f9b689SLuiz Capitulino { 4079b9df25aSGerd Hoffmann .name = "system_wakeup", 4089b9df25aSGerd Hoffmann .args_type = "", 4099b9df25aSGerd Hoffmann .params = "", 4109b9df25aSGerd Hoffmann .help = "wakeup guest from suspend", 4119b9df25aSGerd Hoffmann .mhandler.cmd = hmp_system_wakeup, 4129b9df25aSGerd Hoffmann }, 4139b9df25aSGerd Hoffmann 4149b9df25aSGerd HoffmannSTEXI 4159b9df25aSGerd Hoffmann@item system_wakeup 4169b9df25aSGerd Hoffmann@findex system_wakeup 4179b9df25aSGerd HoffmannWakeup guest from suspend. 4189b9df25aSGerd HoffmannETEXI 4199b9df25aSGerd Hoffmann 4209b9df25aSGerd Hoffmann { 421d7f9b689SLuiz Capitulino .name = "gdbserver", 422d7f9b689SLuiz Capitulino .args_type = "device:s?", 423d7f9b689SLuiz Capitulino .params = "[device]", 424d7f9b689SLuiz Capitulino .help = "start gdbserver on given device (default 'tcp::1234'), stop with 'none'", 4253e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_gdbserver, 426d7f9b689SLuiz Capitulino }, 427d7f9b689SLuiz Capitulino 4282313086aSBlue SwirlSTEXI 4292313086aSBlue Swirl@item gdbserver [@var{port}] 43070fcbbe7SStefan Weil@findex gdbserver 4312313086aSBlue SwirlStart gdbserver session (default @var{port}=1234) 4322313086aSBlue SwirlETEXI 4332313086aSBlue Swirl 434d7f9b689SLuiz Capitulino { 435d7f9b689SLuiz Capitulino .name = "x", 436d7f9b689SLuiz Capitulino .args_type = "fmt:/,addr:l", 437d7f9b689SLuiz Capitulino .params = "/fmt addr", 438d7f9b689SLuiz Capitulino .help = "virtual memory dump starting at 'addr'", 4393e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_memory_dump, 440d7f9b689SLuiz Capitulino }, 441d7f9b689SLuiz Capitulino 4422313086aSBlue SwirlSTEXI 4432313086aSBlue Swirl@item x/fmt @var{addr} 44470fcbbe7SStefan Weil@findex x 4452313086aSBlue SwirlVirtual memory dump starting at @var{addr}. 4462313086aSBlue SwirlETEXI 4472313086aSBlue Swirl 448d7f9b689SLuiz Capitulino { 449d7f9b689SLuiz Capitulino .name = "xp", 450d7f9b689SLuiz Capitulino .args_type = "fmt:/,addr:l", 451d7f9b689SLuiz Capitulino .params = "/fmt addr", 452d7f9b689SLuiz Capitulino .help = "physical memory dump starting at 'addr'", 4533e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_physical_memory_dump, 454d7f9b689SLuiz Capitulino }, 455d7f9b689SLuiz Capitulino 4562313086aSBlue SwirlSTEXI 4572313086aSBlue Swirl@item xp /@var{fmt} @var{addr} 45870fcbbe7SStefan Weil@findex xp 4592313086aSBlue SwirlPhysical memory dump starting at @var{addr}. 4602313086aSBlue Swirl 4612313086aSBlue Swirl@var{fmt} is a format which tells the command how to format the 4622313086aSBlue Swirldata. Its syntax is: @option{/@{count@}@{format@}@{size@}} 4632313086aSBlue Swirl 4642313086aSBlue Swirl@table @var 4652313086aSBlue Swirl@item count 4662313086aSBlue Swirlis the number of items to be dumped. 4672313086aSBlue Swirl 4682313086aSBlue Swirl@item format 4692313086aSBlue Swirlcan be x (hex), d (signed decimal), u (unsigned decimal), o (octal), 4702313086aSBlue Swirlc (char) or i (asm instruction). 4712313086aSBlue Swirl 4722313086aSBlue Swirl@item size 4732313086aSBlue Swirlcan be b (8 bits), h (16 bits), w (32 bits) or g (64 bits). On x86, 4742313086aSBlue Swirl@code{h} or @code{w} can be specified with the @code{i} format to 4752313086aSBlue Swirlrespectively select 16 or 32 bit code instruction size. 4762313086aSBlue Swirl 4772313086aSBlue Swirl@end table 4782313086aSBlue Swirl 4792313086aSBlue SwirlExamples: 4802313086aSBlue Swirl@itemize 4812313086aSBlue Swirl@item 4822313086aSBlue SwirlDump 10 instructions at the current instruction pointer: 4832313086aSBlue Swirl@example 4842313086aSBlue Swirl(qemu) x/10i $eip 4852313086aSBlue Swirl0x90107063: ret 4862313086aSBlue Swirl0x90107064: sti 4872313086aSBlue Swirl0x90107065: lea 0x0(%esi,1),%esi 4882313086aSBlue Swirl0x90107069: lea 0x0(%edi,1),%edi 4892313086aSBlue Swirl0x90107070: ret 4902313086aSBlue Swirl0x90107071: jmp 0x90107080 4912313086aSBlue Swirl0x90107073: nop 4922313086aSBlue Swirl0x90107074: nop 4932313086aSBlue Swirl0x90107075: nop 4942313086aSBlue Swirl0x90107076: nop 4952313086aSBlue Swirl@end example 4962313086aSBlue Swirl 4972313086aSBlue Swirl@item 4982313086aSBlue SwirlDump 80 16 bit values at the start of the video memory. 4992313086aSBlue Swirl@smallexample 5002313086aSBlue Swirl(qemu) xp/80hx 0xb8000 5012313086aSBlue Swirl0x000b8000: 0x0b50 0x0b6c 0x0b65 0x0b78 0x0b38 0x0b36 0x0b2f 0x0b42 5022313086aSBlue Swirl0x000b8010: 0x0b6f 0x0b63 0x0b68 0x0b73 0x0b20 0x0b56 0x0b47 0x0b41 5032313086aSBlue Swirl0x000b8020: 0x0b42 0x0b69 0x0b6f 0x0b73 0x0b20 0x0b63 0x0b75 0x0b72 5042313086aSBlue Swirl0x000b8030: 0x0b72 0x0b65 0x0b6e 0x0b74 0x0b2d 0x0b63 0x0b76 0x0b73 5052313086aSBlue Swirl0x000b8040: 0x0b20 0x0b30 0x0b35 0x0b20 0x0b4e 0x0b6f 0x0b76 0x0b20 5062313086aSBlue Swirl0x000b8050: 0x0b32 0x0b30 0x0b30 0x0b33 0x0720 0x0720 0x0720 0x0720 5072313086aSBlue Swirl0x000b8060: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 5082313086aSBlue Swirl0x000b8070: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 5092313086aSBlue Swirl0x000b8080: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 5102313086aSBlue Swirl0x000b8090: 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 0x0720 5112313086aSBlue Swirl@end smallexample 5122313086aSBlue Swirl@end itemize 5132313086aSBlue SwirlETEXI 5142313086aSBlue Swirl 515d7f9b689SLuiz Capitulino { 516d7f9b689SLuiz Capitulino .name = "p|print", 517d7f9b689SLuiz Capitulino .args_type = "fmt:/,val:l", 518d7f9b689SLuiz Capitulino .params = "/fmt expr", 519d7f9b689SLuiz Capitulino .help = "print expression value (use $reg for CPU register access)", 520af4ce882SLuiz Capitulino .mhandler.cmd = do_print, 521d7f9b689SLuiz Capitulino }, 522d7f9b689SLuiz Capitulino 5232313086aSBlue SwirlSTEXI 5242313086aSBlue Swirl@item p or print/@var{fmt} @var{expr} 52570fcbbe7SStefan Weil@findex print 5262313086aSBlue Swirl 5272313086aSBlue SwirlPrint expression value. Only the @var{format} part of @var{fmt} is 5282313086aSBlue Swirlused. 5292313086aSBlue SwirlETEXI 5302313086aSBlue Swirl 531d7f9b689SLuiz Capitulino { 532d7f9b689SLuiz Capitulino .name = "i", 533d7f9b689SLuiz Capitulino .args_type = "fmt:/,addr:i,index:i.", 534d7f9b689SLuiz Capitulino .params = "/fmt addr", 535d7f9b689SLuiz Capitulino .help = "I/O port read", 5363e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_ioport_read, 537d7f9b689SLuiz Capitulino }, 538d7f9b689SLuiz Capitulino 5392313086aSBlue SwirlSTEXI 5402313086aSBlue SwirlRead I/O port. 5412313086aSBlue SwirlETEXI 5422313086aSBlue Swirl 543d7f9b689SLuiz Capitulino { 544d7f9b689SLuiz Capitulino .name = "o", 545d7f9b689SLuiz Capitulino .args_type = "fmt:/,addr:i,val:i", 546d7f9b689SLuiz Capitulino .params = "/fmt addr value", 547d7f9b689SLuiz Capitulino .help = "I/O port write", 5483e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_ioport_write, 549d7f9b689SLuiz Capitulino }, 550d7f9b689SLuiz Capitulino 551f114784fSJan KiszkaSTEXI 552f114784fSJan KiszkaWrite to I/O port. 553f114784fSJan KiszkaETEXI 5542313086aSBlue Swirl 555d7f9b689SLuiz Capitulino { 556d7f9b689SLuiz Capitulino .name = "sendkey", 5572ef20c15SAmos Kong .args_type = "keys:s,hold-time:i?", 558d7f9b689SLuiz Capitulino .params = "keys [hold_ms]", 559d7f9b689SLuiz Capitulino .help = "send keys to the VM (e.g. 'sendkey ctrl-alt-f1', default hold time=100 ms)", 5603e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_sendkey, 56129136cd8SHani Benhabiles .command_completion = sendkey_completion, 562d7f9b689SLuiz Capitulino }, 563d7f9b689SLuiz Capitulino 5642313086aSBlue SwirlSTEXI 5652313086aSBlue Swirl@item sendkey @var{keys} 56670fcbbe7SStefan Weil@findex sendkey 5672313086aSBlue Swirl 568886cc706SAmos KongSend @var{keys} to the guest. @var{keys} could be the name of the 569886cc706SAmos Kongkey or the raw value in hexadecimal format. Use @code{-} to press 570886cc706SAmos Kongseveral keys simultaneously. Example: 5712313086aSBlue Swirl@example 5722313086aSBlue Swirlsendkey ctrl-alt-f1 5732313086aSBlue Swirl@end example 5742313086aSBlue Swirl 5752313086aSBlue SwirlThis command is useful to send keys that your graphical user interface 5762313086aSBlue Swirlintercepts at low level, such as @code{ctrl-alt-f1} in X Window. 5772313086aSBlue SwirlETEXI 5782313086aSBlue Swirl 579d7f9b689SLuiz Capitulino { 580d7f9b689SLuiz Capitulino .name = "system_reset", 581d7f9b689SLuiz Capitulino .args_type = "", 582d7f9b689SLuiz Capitulino .params = "", 583d7f9b689SLuiz Capitulino .help = "reset the system", 58438d22653SLuiz Capitulino .mhandler.cmd = hmp_system_reset, 585d7f9b689SLuiz Capitulino }, 586d7f9b689SLuiz Capitulino 5872313086aSBlue SwirlSTEXI 5882313086aSBlue Swirl@item system_reset 58970fcbbe7SStefan Weil@findex system_reset 5902313086aSBlue Swirl 5912313086aSBlue SwirlReset the system. 5922313086aSBlue SwirlETEXI 5932313086aSBlue Swirl 594d7f9b689SLuiz Capitulino { 595d7f9b689SLuiz Capitulino .name = "system_powerdown", 596d7f9b689SLuiz Capitulino .args_type = "", 597d7f9b689SLuiz Capitulino .params = "", 598d7f9b689SLuiz Capitulino .help = "send system power down event", 5995bc465e4SLuiz Capitulino .mhandler.cmd = hmp_system_powerdown, 600d7f9b689SLuiz Capitulino }, 601d7f9b689SLuiz Capitulino 6022313086aSBlue SwirlSTEXI 6032313086aSBlue Swirl@item system_powerdown 60470fcbbe7SStefan Weil@findex system_powerdown 6052313086aSBlue Swirl 6062313086aSBlue SwirlPower down the system (if supported). 6072313086aSBlue SwirlETEXI 6082313086aSBlue Swirl 609d7f9b689SLuiz Capitulino { 610d7f9b689SLuiz Capitulino .name = "sum", 611d7f9b689SLuiz Capitulino .args_type = "start:i,size:i", 612d7f9b689SLuiz Capitulino .params = "addr size", 613d7f9b689SLuiz Capitulino .help = "compute the checksum of a memory region", 6143e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_sum, 615d7f9b689SLuiz Capitulino }, 616d7f9b689SLuiz Capitulino 6172313086aSBlue SwirlSTEXI 6182313086aSBlue Swirl@item sum @var{addr} @var{size} 61970fcbbe7SStefan Weil@findex sum 6202313086aSBlue Swirl 6212313086aSBlue SwirlCompute the checksum of a memory region. 6222313086aSBlue SwirlETEXI 6232313086aSBlue Swirl 624d7f9b689SLuiz Capitulino { 625d7f9b689SLuiz Capitulino .name = "usb_add", 626d7f9b689SLuiz Capitulino .args_type = "devname:s", 627d7f9b689SLuiz Capitulino .params = "device", 628d7f9b689SLuiz Capitulino .help = "add USB device (e.g. 'host:bus.addr' or 'host:vendor_id:product_id')", 6293e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_usb_add, 630d7f9b689SLuiz Capitulino }, 631d7f9b689SLuiz Capitulino 6322313086aSBlue SwirlSTEXI 6332313086aSBlue Swirl@item usb_add @var{devname} 63470fcbbe7SStefan Weil@findex usb_add 6352313086aSBlue Swirl 6362313086aSBlue SwirlAdd the USB device @var{devname}. For details of available devices see 6372313086aSBlue Swirl@ref{usb_devices} 6382313086aSBlue SwirlETEXI 6392313086aSBlue Swirl 640d7f9b689SLuiz Capitulino { 641d7f9b689SLuiz Capitulino .name = "usb_del", 642d7f9b689SLuiz Capitulino .args_type = "devname:s", 643d7f9b689SLuiz Capitulino .params = "device", 644d7f9b689SLuiz Capitulino .help = "remove USB device 'bus.addr'", 6453e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_usb_del, 646d7f9b689SLuiz Capitulino }, 647d7f9b689SLuiz Capitulino 6482313086aSBlue SwirlSTEXI 6492313086aSBlue Swirl@item usb_del @var{devname} 65070fcbbe7SStefan Weil@findex usb_del 6512313086aSBlue Swirl 6522313086aSBlue SwirlRemove the USB device @var{devname} from the QEMU virtual USB 6532313086aSBlue Swirlhub. @var{devname} has the syntax @code{bus.addr}. Use the monitor 6542313086aSBlue Swirlcommand @code{info usb} to see the devices you can remove. 6552313086aSBlue SwirlETEXI 6562313086aSBlue Swirl 657d7f9b689SLuiz Capitulino { 658d7f9b689SLuiz Capitulino .name = "device_add", 659c7e4e8ceSMarkus Armbruster .args_type = "device:O", 660c7e4e8ceSMarkus Armbruster .params = "driver[,prop=value][,...]", 661d7f9b689SLuiz Capitulino .help = "add device, like -device on the command line", 6628bc27249SMarkus Armbruster .user_print = monitor_user_noop, 6638bc27249SMarkus Armbruster .mhandler.cmd_new = do_device_add, 6642da1b3abSHani Benhabiles .command_completion = device_add_completion, 665d7f9b689SLuiz Capitulino }, 666d7f9b689SLuiz Capitulino 6673418bd25SGerd HoffmannSTEXI 6683418bd25SGerd Hoffmann@item device_add @var{config} 66970fcbbe7SStefan Weil@findex device_add 6703418bd25SGerd Hoffmann 6713418bd25SGerd HoffmannAdd device. 6723418bd25SGerd HoffmannETEXI 6733418bd25SGerd Hoffmann 674d7f9b689SLuiz Capitulino { 675d7f9b689SLuiz Capitulino .name = "device_del", 676d7f9b689SLuiz Capitulino .args_type = "id:s", 677d7f9b689SLuiz Capitulino .params = "device", 678d7f9b689SLuiz Capitulino .help = "remove device", 679a15fef21SLuiz Capitulino .mhandler.cmd = hmp_device_del, 6802da1b3abSHani Benhabiles .command_completion = device_del_completion, 681d7f9b689SLuiz Capitulino }, 682d7f9b689SLuiz Capitulino 6833418bd25SGerd HoffmannSTEXI 6843418bd25SGerd Hoffmann@item device_del @var{id} 68570fcbbe7SStefan Weil@findex device_del 6863418bd25SGerd Hoffmann 6873418bd25SGerd HoffmannRemove device @var{id}. 6883418bd25SGerd HoffmannETEXI 6893418bd25SGerd Hoffmann 690d7f9b689SLuiz Capitulino { 691d7f9b689SLuiz Capitulino .name = "cpu", 692d7f9b689SLuiz Capitulino .args_type = "index:i", 693d7f9b689SLuiz Capitulino .params = "index", 694d7f9b689SLuiz Capitulino .help = "set the default CPU", 695755f1968SLuiz Capitulino .mhandler.cmd = hmp_cpu, 696d7f9b689SLuiz Capitulino }, 6973418bd25SGerd Hoffmann 6982313086aSBlue SwirlSTEXI 699c427ea9cSMarkus Armbruster@item cpu @var{index} 700c427ea9cSMarkus Armbruster@findex cpu 7012313086aSBlue SwirlSet the default CPU. 7022313086aSBlue SwirlETEXI 7032313086aSBlue Swirl 704d7f9b689SLuiz Capitulino { 705d7f9b689SLuiz Capitulino .name = "mouse_move", 706d7f9b689SLuiz Capitulino .args_type = "dx_str:s,dy_str:s,dz_str:s?", 707d7f9b689SLuiz Capitulino .params = "dx dy [dz]", 708d7f9b689SLuiz Capitulino .help = "send mouse move events", 7093e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_mouse_move, 710d7f9b689SLuiz Capitulino }, 711d7f9b689SLuiz Capitulino 7122313086aSBlue SwirlSTEXI 7132313086aSBlue Swirl@item mouse_move @var{dx} @var{dy} [@var{dz}] 71470fcbbe7SStefan Weil@findex mouse_move 7152313086aSBlue SwirlMove the active mouse to the specified coordinates @var{dx} @var{dy} 7162313086aSBlue Swirlwith optional scroll axis @var{dz}. 7172313086aSBlue SwirlETEXI 7182313086aSBlue Swirl 719d7f9b689SLuiz Capitulino { 720d7f9b689SLuiz Capitulino .name = "mouse_button", 721d7f9b689SLuiz Capitulino .args_type = "button_state:i", 722d7f9b689SLuiz Capitulino .params = "state", 723d7f9b689SLuiz Capitulino .help = "change mouse button state (1=L, 2=M, 4=R)", 7243e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_mouse_button, 725d7f9b689SLuiz Capitulino }, 726d7f9b689SLuiz Capitulino 7272313086aSBlue SwirlSTEXI 7282313086aSBlue Swirl@item mouse_button @var{val} 72970fcbbe7SStefan Weil@findex mouse_button 7302313086aSBlue SwirlChange the active mouse button state @var{val} (1=L, 2=M, 4=R). 7312313086aSBlue SwirlETEXI 7322313086aSBlue Swirl 733d7f9b689SLuiz Capitulino { 734d7f9b689SLuiz Capitulino .name = "mouse_set", 735d7f9b689SLuiz Capitulino .args_type = "index:i", 736d7f9b689SLuiz Capitulino .params = "index", 737d7f9b689SLuiz Capitulino .help = "set which mouse device receives events", 7383e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_mouse_set, 739d7f9b689SLuiz Capitulino }, 740d7f9b689SLuiz Capitulino 7412313086aSBlue SwirlSTEXI 7422313086aSBlue Swirl@item mouse_set @var{index} 74370fcbbe7SStefan Weil@findex mouse_set 7442313086aSBlue SwirlSet which mouse device receives events at given @var{index}, index 7452313086aSBlue Swirlcan be obtained with 7462313086aSBlue Swirl@example 7472313086aSBlue Swirlinfo mice 7482313086aSBlue Swirl@end example 7492313086aSBlue SwirlETEXI 7502313086aSBlue Swirl 751d7f9b689SLuiz Capitulino { 752d7f9b689SLuiz Capitulino .name = "wavcapture", 753d7f9b689SLuiz Capitulino .args_type = "path:F,freq:i?,bits:i?,nchannels:i?", 754d7f9b689SLuiz Capitulino .params = "path [frequency [bits [channels]]]", 755d7f9b689SLuiz Capitulino .help = "capture audio to a wave file (default frequency=44100 bits=16 channels=2)", 7563e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_wavcapture, 757d7f9b689SLuiz Capitulino }, 7582313086aSBlue SwirlSTEXI 7592313086aSBlue Swirl@item wavcapture @var{filename} [@var{frequency} [@var{bits} [@var{channels}]]] 76070fcbbe7SStefan Weil@findex wavcapture 7612313086aSBlue SwirlCapture audio into @var{filename}. Using sample rate @var{frequency} 7622313086aSBlue Swirlbits per sample @var{bits} and number of channels @var{channels}. 7632313086aSBlue Swirl 7642313086aSBlue SwirlDefaults: 7652313086aSBlue Swirl@itemize @minus 7662313086aSBlue Swirl@item Sample rate = 44100 Hz - CD quality 7672313086aSBlue Swirl@item Bits = 16 7682313086aSBlue Swirl@item Number of channels = 2 - Stereo 7692313086aSBlue Swirl@end itemize 7702313086aSBlue SwirlETEXI 7712313086aSBlue Swirl 772d7f9b689SLuiz Capitulino { 773d7f9b689SLuiz Capitulino .name = "stopcapture", 774d7f9b689SLuiz Capitulino .args_type = "n:i", 775d7f9b689SLuiz Capitulino .params = "capture index", 776d7f9b689SLuiz Capitulino .help = "stop capture", 7773e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_stopcapture, 778d7f9b689SLuiz Capitulino }, 7792313086aSBlue SwirlSTEXI 7802313086aSBlue Swirl@item stopcapture @var{index} 78170fcbbe7SStefan Weil@findex stopcapture 7822313086aSBlue SwirlStop capture with a given @var{index}, index can be obtained with 7832313086aSBlue Swirl@example 7842313086aSBlue Swirlinfo capture 7852313086aSBlue Swirl@end example 7862313086aSBlue SwirlETEXI 7872313086aSBlue Swirl 788d7f9b689SLuiz Capitulino { 789d7f9b689SLuiz Capitulino .name = "memsave", 790d7f9b689SLuiz Capitulino .args_type = "val:l,size:i,filename:s", 791d7f9b689SLuiz Capitulino .params = "addr size file", 792d7f9b689SLuiz Capitulino .help = "save to disk virtual memory dump starting at 'addr' of size 'size'", 7930cfd6a9aSLuiz Capitulino .mhandler.cmd = hmp_memsave, 794d7f9b689SLuiz Capitulino }, 795d7f9b689SLuiz Capitulino 7962313086aSBlue SwirlSTEXI 7972313086aSBlue Swirl@item memsave @var{addr} @var{size} @var{file} 79870fcbbe7SStefan Weil@findex memsave 7992313086aSBlue Swirlsave to disk virtual memory dump starting at @var{addr} of size @var{size}. 8002313086aSBlue SwirlETEXI 8012313086aSBlue Swirl 802d7f9b689SLuiz Capitulino { 803d7f9b689SLuiz Capitulino .name = "pmemsave", 804d7f9b689SLuiz Capitulino .args_type = "val:l,size:i,filename:s", 805d7f9b689SLuiz Capitulino .params = "addr size file", 806d7f9b689SLuiz Capitulino .help = "save to disk physical memory dump starting at 'addr' of size 'size'", 8076d3962bfSLuiz Capitulino .mhandler.cmd = hmp_pmemsave, 808d7f9b689SLuiz Capitulino }, 809d7f9b689SLuiz Capitulino 8102313086aSBlue SwirlSTEXI 8112313086aSBlue Swirl@item pmemsave @var{addr} @var{size} @var{file} 81270fcbbe7SStefan Weil@findex pmemsave 8132313086aSBlue Swirlsave to disk physical memory dump starting at @var{addr} of size @var{size}. 8142313086aSBlue SwirlETEXI 8152313086aSBlue Swirl 816d7f9b689SLuiz Capitulino { 817d7f9b689SLuiz Capitulino .name = "boot_set", 818d7f9b689SLuiz Capitulino .args_type = "bootdevice:s", 819d7f9b689SLuiz Capitulino .params = "bootdevice", 820d7f9b689SLuiz Capitulino .help = "define new values for the boot device list", 8213e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_boot_set, 822d7f9b689SLuiz Capitulino }, 823d7f9b689SLuiz Capitulino 8242313086aSBlue SwirlSTEXI 8252313086aSBlue Swirl@item boot_set @var{bootdevicelist} 82670fcbbe7SStefan Weil@findex boot_set 8272313086aSBlue Swirl 8282313086aSBlue SwirlDefine new values for the boot device list. Those values will override 8292313086aSBlue Swirlthe values specified on the command line through the @code{-boot} option. 8302313086aSBlue Swirl 8312313086aSBlue SwirlThe values that can be specified here depend on the machine type, but are 8322313086aSBlue Swirlthe same that can be specified in the @code{-boot} command line option. 8332313086aSBlue SwirlETEXI 8342313086aSBlue Swirl 835d7f9b689SLuiz Capitulino { 836d7f9b689SLuiz Capitulino .name = "nmi", 837e9b4b432SLuiz Capitulino .args_type = "", 838e9b4b432SLuiz Capitulino .params = "", 8399cb805fdSAlexey Kardashevskiy .help = "inject an NMI", 8403e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_nmi, 841d7f9b689SLuiz Capitulino }, 8422313086aSBlue SwirlSTEXI 8432313086aSBlue Swirl@item nmi @var{cpu} 84470fcbbe7SStefan Weil@findex nmi 8459cb805fdSAlexey KardashevskiyInject an NMI on the default CPU (x86/s390) or all CPUs (ppc64). 8461f590cf9SLei Li 8471f590cf9SLei LiETEXI 8481f590cf9SLei Li 8491f590cf9SLei Li { 8503949e594SMarkus Armbruster .name = "ringbuf_write", 8511f590cf9SLei Li .args_type = "device:s,data:s", 8521f590cf9SLei Li .params = "device data", 8533949e594SMarkus Armbruster .help = "Write to a ring buffer character device", 8543949e594SMarkus Armbruster .mhandler.cmd = hmp_ringbuf_write, 8558e597779SHani Benhabiles .command_completion = ringbuf_write_completion, 8561f590cf9SLei Li }, 8571f590cf9SLei Li 8581f590cf9SLei LiSTEXI 8593949e594SMarkus Armbruster@item ringbuf_write @var{device} @var{data} 8603949e594SMarkus Armbruster@findex ringbuf_write 8613949e594SMarkus ArmbrusterWrite @var{data} to ring buffer character device @var{device}. 8623949e594SMarkus Armbruster@var{data} must be a UTF-8 string. 8631f590cf9SLei Li 8642313086aSBlue SwirlETEXI 8652313086aSBlue Swirl 866d7f9b689SLuiz Capitulino { 8673949e594SMarkus Armbruster .name = "ringbuf_read", 86849b6d722SLei Li .args_type = "device:s,size:i", 86949b6d722SLei Li .params = "device size", 8703949e594SMarkus Armbruster .help = "Read from a ring buffer character device", 8713949e594SMarkus Armbruster .mhandler.cmd = hmp_ringbuf_read, 8728e597779SHani Benhabiles .command_completion = ringbuf_write_completion, 87349b6d722SLei Li }, 87449b6d722SLei Li 87549b6d722SLei LiSTEXI 8763949e594SMarkus Armbruster@item ringbuf_read @var{device} 8773949e594SMarkus Armbruster@findex ringbuf_read 8783949e594SMarkus ArmbrusterRead and print up to @var{size} bytes from ring buffer character 8793949e594SMarkus Armbrusterdevice @var{device}. 880543f3412SMarkus ArmbrusterCertain non-printable characters are printed \uXXXX, where XXXX is the 881543f3412SMarkus Armbrustercharacter code in hexadecimal. Character \ is printed \\. 8823949e594SMarkus ArmbrusterBug: can screw up when the buffer contains invalid UTF-8 sequences, 8833949e594SMarkus ArmbrusterNUL characters, after the ring buffer lost data, and when reading 8843949e594SMarkus Armbrusterstops because the size limit is reached. 88549b6d722SLei Li 88649b6d722SLei LiETEXI 88749b6d722SLei Li 88849b6d722SLei Li { 889d7f9b689SLuiz Capitulino .name = "migrate", 890fbc3d96cSlirans@il.ibm.com .args_type = "detach:-d,blk:-b,inc:-i,uri:s", 891fbc3d96cSlirans@il.ibm.com .params = "[-d] [-b] [-i] uri", 892fbc3d96cSlirans@il.ibm.com .help = "migrate to URI (using -d to not wait for completion)" 893fbc3d96cSlirans@il.ibm.com "\n\t\t\t -b for migration without shared storage with" 894fbc3d96cSlirans@il.ibm.com " full copy of disk\n\t\t\t -i for migration without " 895fbc3d96cSlirans@il.ibm.com "shared storage with incremental copy of disk " 896fbc3d96cSlirans@il.ibm.com "(base image shared between src and destination)", 897e1c37d0eSLuiz Capitulino .mhandler.cmd = hmp_migrate, 898d7f9b689SLuiz Capitulino }, 899d7f9b689SLuiz Capitulino 900fbc3d96cSlirans@il.ibm.com 9012313086aSBlue SwirlSTEXI 902fbc3d96cSlirans@il.ibm.com@item migrate [-d] [-b] [-i] @var{uri} 90370fcbbe7SStefan Weil@findex migrate 9042313086aSBlue SwirlMigrate to @var{uri} (using -d to not wait for completion). 905fbc3d96cSlirans@il.ibm.com -b for migration with full copy of disk 906fbc3d96cSlirans@il.ibm.com -i for migration with incremental copy of disk (base image is shared) 9072313086aSBlue SwirlETEXI 9082313086aSBlue Swirl 909d7f9b689SLuiz Capitulino { 910d7f9b689SLuiz Capitulino .name = "migrate_cancel", 911d7f9b689SLuiz Capitulino .args_type = "", 912d7f9b689SLuiz Capitulino .params = "", 913d7f9b689SLuiz Capitulino .help = "cancel the current VM migration", 9146cdedb07SLuiz Capitulino .mhandler.cmd = hmp_migrate_cancel, 915d7f9b689SLuiz Capitulino }, 916d7f9b689SLuiz Capitulino 9172313086aSBlue SwirlSTEXI 9182313086aSBlue Swirl@item migrate_cancel 91970fcbbe7SStefan Weil@findex migrate_cancel 9202313086aSBlue SwirlCancel the current VM migration. 9219e1ba4ccSOrit Wasserman 9229e1ba4ccSOrit WassermanETEXI 9239e1ba4ccSOrit Wasserman 9249e1ba4ccSOrit Wasserman { 925bf1ae1f4SDr. David Alan Gilbert .name = "migrate_incoming", 926bf1ae1f4SDr. David Alan Gilbert .args_type = "uri:s", 927bf1ae1f4SDr. David Alan Gilbert .params = "uri", 928bf1ae1f4SDr. David Alan Gilbert .help = "Continue an incoming migration from an -incoming defer", 929bf1ae1f4SDr. David Alan Gilbert .mhandler.cmd = hmp_migrate_incoming, 930bf1ae1f4SDr. David Alan Gilbert }, 931bf1ae1f4SDr. David Alan Gilbert 932bf1ae1f4SDr. David Alan GilbertSTEXI 933bf1ae1f4SDr. David Alan Gilbert@item migrate_incoming @var{uri} 934bf1ae1f4SDr. David Alan Gilbert@findex migrate_incoming 935bf1ae1f4SDr. David Alan GilbertContinue an incoming migration using the @var{uri} (that has the same syntax 936bf1ae1f4SDr. David Alan Gilbertas the -incoming option). 937bf1ae1f4SDr. David Alan Gilbert 938bf1ae1f4SDr. David Alan GilbertETEXI 939bf1ae1f4SDr. David Alan Gilbert 940bf1ae1f4SDr. David Alan Gilbert { 9419e1ba4ccSOrit Wasserman .name = "migrate_set_cache_size", 9429e1ba4ccSOrit Wasserman .args_type = "value:o", 9439e1ba4ccSOrit Wasserman .params = "value", 9449e1ba4ccSOrit Wasserman .help = "set cache size (in bytes) for XBZRLE migrations," 9459e1ba4ccSOrit Wasserman "the cache size will be rounded down to the nearest " 9469e1ba4ccSOrit Wasserman "power of 2.\n" 9479e1ba4ccSOrit Wasserman "The cache size affects the number of cache misses." 9489e1ba4ccSOrit Wasserman "In case of a high cache miss ratio you need to increase" 9499e1ba4ccSOrit Wasserman " the cache size", 9509e1ba4ccSOrit Wasserman .mhandler.cmd = hmp_migrate_set_cache_size, 9519e1ba4ccSOrit Wasserman }, 9529e1ba4ccSOrit Wasserman 9539e1ba4ccSOrit WassermanSTEXI 9549e1ba4ccSOrit Wasserman@item migrate_set_cache_size @var{value} 9559e1ba4ccSOrit Wasserman@findex migrate_set_cache_size 9569e1ba4ccSOrit WassermanSet cache size to @var{value} (in bytes) for xbzrle migrations. 9572313086aSBlue SwirlETEXI 9582313086aSBlue Swirl 959d7f9b689SLuiz Capitulino { 960d7f9b689SLuiz Capitulino .name = "migrate_set_speed", 961ed3d4a80SJes Sorensen .args_type = "value:o", 962d7f9b689SLuiz Capitulino .params = "value", 963ed3d4a80SJes Sorensen .help = "set maximum speed (in bytes) for migrations. " 964ed3d4a80SJes Sorensen "Defaults to MB if no size suffix is specified, ie. B/K/M/G/T", 9653dc85383SLuiz Capitulino .mhandler.cmd = hmp_migrate_set_speed, 966d7f9b689SLuiz Capitulino }, 967d7f9b689SLuiz Capitulino 9682313086aSBlue SwirlSTEXI 9692313086aSBlue Swirl@item migrate_set_speed @var{value} 97070fcbbe7SStefan Weil@findex migrate_set_speed 9712313086aSBlue SwirlSet maximum speed to @var{value} (in bytes) for migrations. 9722313086aSBlue SwirlETEXI 9732313086aSBlue Swirl 974d7f9b689SLuiz Capitulino { 975d7f9b689SLuiz Capitulino .name = "migrate_set_downtime", 976b0fbf7d3SMarkus Armbruster .args_type = "value:T", 977d7f9b689SLuiz Capitulino .params = "value", 978d7f9b689SLuiz Capitulino .help = "set maximum tolerated downtime (in seconds) for migrations", 9794f0a993bSLuiz Capitulino .mhandler.cmd = hmp_migrate_set_downtime, 980d7f9b689SLuiz Capitulino }, 9812ea42952SGlauber Costa 9822ea42952SGlauber CostaSTEXI 9832ea42952SGlauber Costa@item migrate_set_downtime @var{second} 98470fcbbe7SStefan Weil@findex migrate_set_downtime 9852ea42952SGlauber CostaSet maximum tolerated downtime (in seconds) for migration. 9862ea42952SGlauber CostaETEXI 9872ea42952SGlauber Costa 988f8882568SJes Sorensen { 98900458433SOrit Wasserman .name = "migrate_set_capability", 99000458433SOrit Wasserman .args_type = "capability:s,state:b", 99100458433SOrit Wasserman .params = "capability state", 99200458433SOrit Wasserman .help = "Enable/Disable the usage of a capability for migration", 99300458433SOrit Wasserman .mhandler.cmd = hmp_migrate_set_capability, 994c68a0409SHani Benhabiles .command_completion = migrate_set_capability_completion, 99500458433SOrit Wasserman }, 99600458433SOrit Wasserman 99700458433SOrit WassermanSTEXI 99800458433SOrit Wasserman@item migrate_set_capability @var{capability} @var{state} 99900458433SOrit Wasserman@findex migrate_set_capability 100000458433SOrit WassermanEnable/Disable the usage of a capability @var{capability} for migration. 100100458433SOrit WassermanETEXI 100200458433SOrit Wasserman 100300458433SOrit Wasserman { 10042ea720dbSJes Sorensen .name = "client_migrate_info", 10052ea720dbSJes Sorensen .args_type = "protocol:s,hostname:s,port:i?,tls-port:i?,cert-subject:s?", 10062ea720dbSJes Sorensen .params = "protocol hostname port tls-port cert-subject", 10072ea720dbSJes Sorensen .help = "send migration info to spice/vnc client", 10082ea720dbSJes Sorensen .user_print = monitor_user_noop, 1009edc5cb1aSYonit Halperin .mhandler.cmd_async = client_migrate_info, 1010edc5cb1aSYonit Halperin .flags = MONITOR_CMD_ASYNC, 1011f8882568SJes Sorensen }, 1012f8882568SJes Sorensen 1013f8882568SJes SorensenSTEXI 1014e866e239SGerd Hoffmann@item client_migrate_info @var{protocol} @var{hostname} @var{port} @var{tls-port} @var{cert-subject} 1015e866e239SGerd Hoffmann@findex client_migrate_info 1016e866e239SGerd HoffmannSet the spice/vnc connection info for the migration target. The spice/vnc 1017e866e239SGerd Hoffmannserver will ask the spice/vnc client to automatically reconnect using the 1018e866e239SGerd Hoffmannnew parameters (if specified) once the vm migration finished successfully. 1019e866e239SGerd HoffmannETEXI 1020e866e239SGerd Hoffmann 1021783e9b48SWen Congyang { 1022783e9b48SWen Congyang .name = "dump-guest-memory", 10231b7a0f75SQiao Nuohan .args_type = "paging:-p,zlib:-z,lzo:-l,snappy:-s,filename:F,begin:i?,length:i?", 10241b7a0f75SQiao Nuohan .params = "[-p] [-z|-l|-s] filename [begin length]", 1025c20499d9SQiao Nuohan .help = "dump guest memory into file 'filename'.\n\t\t\t" 1026c20499d9SQiao Nuohan "-p: do paging to get guest's memory mapping.\n\t\t\t" 10271b7a0f75SQiao Nuohan "-z: dump in kdump-compressed format, with zlib compression.\n\t\t\t" 10281b7a0f75SQiao Nuohan "-l: dump in kdump-compressed format, with lzo compression.\n\t\t\t" 10291b7a0f75SQiao Nuohan "-s: dump in kdump-compressed format, with snappy compression.\n\t\t\t" 1030c20499d9SQiao Nuohan "begin: the starting physical address.\n\t\t\t" 1031c20499d9SQiao Nuohan "length: the memory size, in bytes.", 1032783e9b48SWen Congyang .mhandler.cmd = hmp_dump_guest_memory, 1033783e9b48SWen Congyang }, 1034783e9b48SWen Congyang 1035783e9b48SWen Congyang 1036783e9b48SWen CongyangSTEXI 1037c20499d9SQiao Nuohan@item dump-guest-memory [-p] @var{filename} @var{begin} @var{length} 10381b7a0f75SQiao Nuohan@item dump-guest-memory [-z|-l|-s] @var{filename} 1039783e9b48SWen Congyang@findex dump-guest-memory 1040783e9b48SWen CongyangDump guest memory to @var{protocol}. The file can be processed with crash or 10411b7a0f75SQiao Nuohangdb. Without -z|-l|-s, the dump format is ELF. 1042c20499d9SQiao Nuohan -p: do paging to get guest's memory mapping. 10431b7a0f75SQiao Nuohan -z: dump in kdump-compressed format, with zlib compression. 10441b7a0f75SQiao Nuohan -l: dump in kdump-compressed format, with lzo compression. 10451b7a0f75SQiao Nuohan -s: dump in kdump-compressed format, with snappy compression. 1046c20499d9SQiao Nuohan filename: dump file name. 1047783e9b48SWen Congyang begin: the starting physical address. It's optional, and should be 1048c20499d9SQiao Nuohan specified together with length. 1049783e9b48SWen Congyang length: the memory size, in bytes. It's optional, and should be specified 1050c20499d9SQiao Nuohan together with begin. 1051783e9b48SWen CongyangETEXI 1052783e9b48SWen Congyang 1053e866e239SGerd Hoffmann { 10542ea720dbSJes Sorensen .name = "snapshot_blkdev", 10556cc2a415SPaolo Bonzini .args_type = "reuse:-n,device:B,snapshot-file:s?,format:s?", 10566cc2a415SPaolo Bonzini .params = "[-n] device [new-image-file] [format]", 10572ea720dbSJes Sorensen .help = "initiates a live snapshot\n\t\t\t" 10582ea720dbSJes Sorensen "of device. If a new image file is specified, the\n\t\t\t" 10592ea720dbSJes Sorensen "new image file will become the new root image.\n\t\t\t" 10602ea720dbSJes Sorensen "If format is specified, the snapshot file will\n\t\t\t" 1061775ca88eSWenchao Xia "be created in that format.\n\t\t\t" 10626cc2a415SPaolo Bonzini "The default format is qcow2. The -n flag requests QEMU\n\t\t\t" 10636cc2a415SPaolo Bonzini "to reuse the image found in new-image-file, instead of\n\t\t\t" 10646cc2a415SPaolo Bonzini "recreating it from scratch.", 10656106e249SLuiz Capitulino .mhandler.cmd = hmp_snapshot_blkdev, 1066e866e239SGerd Hoffmann }, 1067e866e239SGerd Hoffmann 1068e866e239SGerd HoffmannSTEXI 1069f8882568SJes Sorensen@item snapshot_blkdev 1070f8882568SJes Sorensen@findex snapshot_blkdev 1071f8882568SJes SorensenSnapshot device, using snapshot file as target if provided 1072f8882568SJes SorensenETEXI 1073f8882568SJes Sorensen 1074d7f9b689SLuiz Capitulino { 1075775ca88eSWenchao Xia .name = "snapshot_blkdev_internal", 1076775ca88eSWenchao Xia .args_type = "device:B,name:s", 1077775ca88eSWenchao Xia .params = "device name", 1078775ca88eSWenchao Xia .help = "take an internal snapshot of device.\n\t\t\t" 1079775ca88eSWenchao Xia "The format of the image used by device must\n\t\t\t" 1080775ca88eSWenchao Xia "support it, such as qcow2.\n\t\t\t", 1081775ca88eSWenchao Xia .mhandler.cmd = hmp_snapshot_blkdev_internal, 1082775ca88eSWenchao Xia }, 1083775ca88eSWenchao Xia 1084775ca88eSWenchao XiaSTEXI 1085775ca88eSWenchao Xia@item snapshot_blkdev_internal 1086775ca88eSWenchao Xia@findex snapshot_blkdev_internal 1087775ca88eSWenchao XiaTake an internal snapshot on device if it support 1088775ca88eSWenchao XiaETEXI 1089775ca88eSWenchao Xia 1090775ca88eSWenchao Xia { 10917a4ed2eeSWenchao Xia .name = "snapshot_delete_blkdev_internal", 10927a4ed2eeSWenchao Xia .args_type = "device:B,name:s,id:s?", 10937a4ed2eeSWenchao Xia .params = "device name [id]", 10947a4ed2eeSWenchao Xia .help = "delete an internal snapshot of device.\n\t\t\t" 10957a4ed2eeSWenchao Xia "If id is specified, qemu will try delete\n\t\t\t" 10967a4ed2eeSWenchao Xia "the snapshot matching both id and name.\n\t\t\t" 10977a4ed2eeSWenchao Xia "The format of the image used by device must\n\t\t\t" 10987a4ed2eeSWenchao Xia "support it, such as qcow2.\n\t\t\t", 10997a4ed2eeSWenchao Xia .mhandler.cmd = hmp_snapshot_delete_blkdev_internal, 11007a4ed2eeSWenchao Xia }, 11017a4ed2eeSWenchao Xia 11027a4ed2eeSWenchao XiaSTEXI 11037a4ed2eeSWenchao Xia@item snapshot_delete_blkdev_internal 11047a4ed2eeSWenchao Xia@findex snapshot_delete_blkdev_internal 11057a4ed2eeSWenchao XiaDelete an internal snapshot on device if it support 11067a4ed2eeSWenchao XiaETEXI 11077a4ed2eeSWenchao Xia 11087a4ed2eeSWenchao Xia { 1109d9b902dbSPaolo Bonzini .name = "drive_mirror", 1110d9b902dbSPaolo Bonzini .args_type = "reuse:-n,full:-f,device:B,target:s,format:s?", 1111d9b902dbSPaolo Bonzini .params = "[-n] [-f] device target [format]", 1112d9b902dbSPaolo Bonzini .help = "initiates live storage\n\t\t\t" 1113d9b902dbSPaolo Bonzini "migration for a device. The device's contents are\n\t\t\t" 1114d9b902dbSPaolo Bonzini "copied to the new image file, including data that\n\t\t\t" 1115d9b902dbSPaolo Bonzini "is written after the command is started.\n\t\t\t" 1116d9b902dbSPaolo Bonzini "The -n flag requests QEMU to reuse the image found\n\t\t\t" 1117d9b902dbSPaolo Bonzini "in new-image-file, instead of recreating it from scratch.\n\t\t\t" 1118d9b902dbSPaolo Bonzini "The -f flag requests QEMU to copy the whole disk,\n\t\t\t" 1119d9b902dbSPaolo Bonzini "so that the result does not need a backing file.\n\t\t\t", 1120d9b902dbSPaolo Bonzini .mhandler.cmd = hmp_drive_mirror, 1121d9b902dbSPaolo Bonzini }, 1122d9b902dbSPaolo BonziniSTEXI 1123d9b902dbSPaolo Bonzini@item drive_mirror 1124d9b902dbSPaolo Bonzini@findex drive_mirror 1125d9b902dbSPaolo BonziniStart mirroring a block device's writes to a new destination, 1126d9b902dbSPaolo Bonziniusing the specified target. 1127d9b902dbSPaolo BonziniETEXI 1128d9b902dbSPaolo Bonzini 1129d9b902dbSPaolo Bonzini { 1130de90930aSStefan Hajnoczi .name = "drive_backup", 1131de90930aSStefan Hajnoczi .args_type = "reuse:-n,full:-f,device:B,target:s,format:s?", 1132de90930aSStefan Hajnoczi .params = "[-n] [-f] device target [format]", 1133de90930aSStefan Hajnoczi .help = "initiates a point-in-time\n\t\t\t" 1134de90930aSStefan Hajnoczi "copy for a device. The device's contents are\n\t\t\t" 1135de90930aSStefan Hajnoczi "copied to the new image file, excluding data that\n\t\t\t" 1136de90930aSStefan Hajnoczi "is written after the command is started.\n\t\t\t" 1137de90930aSStefan Hajnoczi "The -n flag requests QEMU to reuse the image found\n\t\t\t" 1138de90930aSStefan Hajnoczi "in new-image-file, instead of recreating it from scratch.\n\t\t\t" 1139de90930aSStefan Hajnoczi "The -f flag requests QEMU to copy the whole disk,\n\t\t\t" 1140de90930aSStefan Hajnoczi "so that the result does not need a backing file.\n\t\t\t", 1141de90930aSStefan Hajnoczi .mhandler.cmd = hmp_drive_backup, 1142de90930aSStefan Hajnoczi }, 1143de90930aSStefan HajnocziSTEXI 1144de90930aSStefan Hajnoczi@item drive_backup 1145de90930aSStefan Hajnoczi@findex drive_backup 1146de90930aSStefan HajnocziStart a point-in-time copy of a block device to a specificed target. 1147de90930aSStefan HajnocziETEXI 1148de90930aSStefan Hajnoczi 1149de90930aSStefan Hajnoczi { 1150d7f9b689SLuiz Capitulino .name = "drive_add", 1151d7f9b689SLuiz Capitulino .args_type = "pci_addr:s,opts:s", 1152d7f9b689SLuiz Capitulino .params = "[[<domain>:]<bus>:]<slot>\n" 11532313086aSBlue Swirl "[file=file][,if=type][,bus=n]\n" 1154fb0490f6SStefan Hajnoczi "[,unit=m][,media=d][,index=i]\n" 11552313086aSBlue Swirl "[,cyls=c,heads=h,secs=s[,trans=t]]\n" 1156fb0490f6SStefan Hajnoczi "[,snapshot=on|off][,cache=on|off]\n" 1157fb0490f6SStefan Hajnoczi "[,readonly=on|off][,copy-on-read=on|off]", 1158d7f9b689SLuiz Capitulino .help = "add drive to PCI storage controller", 11593e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_drive_add, 1160d7f9b689SLuiz Capitulino }, 1161d7f9b689SLuiz Capitulino 11622313086aSBlue SwirlSTEXI 11632313086aSBlue Swirl@item drive_add 116470fcbbe7SStefan Weil@findex drive_add 11652313086aSBlue SwirlAdd drive to PCI storage controller. 11662313086aSBlue SwirlETEXI 11672313086aSBlue Swirl 1168d7f9b689SLuiz Capitulino { 11692ae63bdaSIsaku Yamahata .name = "pcie_aer_inject_error", 11702ae63bdaSIsaku Yamahata .args_type = "advisory_non_fatal:-a,correctable:-c," 11712ae63bdaSIsaku Yamahata "id:s,error_status:s," 11722ae63bdaSIsaku Yamahata "header0:i?,header1:i?,header2:i?,header3:i?," 11732ae63bdaSIsaku Yamahata "prefix0:i?,prefix1:i?,prefix2:i?,prefix3:i?", 11742ae63bdaSIsaku Yamahata .params = "[-a] [-c] id " 11752ae63bdaSIsaku Yamahata "<error_status> [<tlp header> [<tlp header prefix>]]", 11762ae63bdaSIsaku Yamahata .help = "inject pcie aer error\n\t\t\t" 11772ae63bdaSIsaku Yamahata " -a for advisory non fatal error\n\t\t\t" 11782ae63bdaSIsaku Yamahata " -c for correctable error\n\t\t\t" 11792ae63bdaSIsaku Yamahata "<id> = qdev device id\n\t\t\t" 11802ae63bdaSIsaku Yamahata "<error_status> = error string or 32bit\n\t\t\t" 11812ae63bdaSIsaku Yamahata "<tlb header> = 32bit x 4\n\t\t\t" 11822ae63bdaSIsaku Yamahata "<tlb header prefix> = 32bit x 4", 11832ae63bdaSIsaku Yamahata .user_print = pcie_aer_inject_error_print, 11843e5a50d6SMarkus Armbruster .mhandler.cmd_new = hmp_pcie_aer_inject_error, 11852ae63bdaSIsaku Yamahata }, 11862ae63bdaSIsaku Yamahata 11872ae63bdaSIsaku YamahataSTEXI 11882ae63bdaSIsaku Yamahata@item pcie_aer_inject_error 11892ae63bdaSIsaku Yamahata@findex pcie_aer_inject_error 11902ae63bdaSIsaku YamahataInject PCIe AER error 11912ae63bdaSIsaku YamahataETEXI 11922ae63bdaSIsaku Yamahata 11932ae63bdaSIsaku Yamahata { 1194d7f9b689SLuiz Capitulino .name = "host_net_add", 1195d7f9b689SLuiz Capitulino .args_type = "device:s,opts:s?", 119603ce5744SNikolay Nikolaev .params = "tap|user|socket|vde|netmap|bridge|vhost-user|dump [options]", 1197d7f9b689SLuiz Capitulino .help = "add host VLAN client", 11983e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_host_net_add, 1199e3bb532cSHani Benhabiles .command_completion = host_net_add_completion, 1200d7f9b689SLuiz Capitulino }, 1201d7f9b689SLuiz Capitulino 12022313086aSBlue SwirlSTEXI 12032313086aSBlue Swirl@item host_net_add 120470fcbbe7SStefan Weil@findex host_net_add 12052313086aSBlue SwirlAdd host VLAN client. 12062313086aSBlue SwirlETEXI 12072313086aSBlue Swirl 1208d7f9b689SLuiz Capitulino { 1209d7f9b689SLuiz Capitulino .name = "host_net_remove", 1210d7f9b689SLuiz Capitulino .args_type = "vlan_id:i,device:s", 1211d7f9b689SLuiz Capitulino .params = "vlan_id name", 1212d7f9b689SLuiz Capitulino .help = "remove host VLAN client", 12133e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_host_net_remove, 1214ddd6b45cSHani Benhabiles .command_completion = host_net_remove_completion, 1215d7f9b689SLuiz Capitulino }, 1216d7f9b689SLuiz Capitulino 12172313086aSBlue SwirlSTEXI 12182313086aSBlue Swirl@item host_net_remove 121970fcbbe7SStefan Weil@findex host_net_remove 12202313086aSBlue SwirlRemove host VLAN client. 12212313086aSBlue SwirlETEXI 12222313086aSBlue Swirl 1223ae82d324SMarkus Armbruster { 1224ae82d324SMarkus Armbruster .name = "netdev_add", 1225ae82d324SMarkus Armbruster .args_type = "netdev:O", 122603ce5744SNikolay Nikolaev .params = "[user|tap|socket|vde|bridge|hubport|netmap|vhost-user],id=str[,prop=value][,...]", 1227ae82d324SMarkus Armbruster .help = "add host network device", 1228928059a3SLuiz Capitulino .mhandler.cmd = hmp_netdev_add, 1229b162b49aSHani Benhabiles .command_completion = netdev_add_completion, 1230ae82d324SMarkus Armbruster }, 1231ae82d324SMarkus Armbruster 1232ae82d324SMarkus ArmbrusterSTEXI 1233ae82d324SMarkus Armbruster@item netdev_add 1234ae82d324SMarkus Armbruster@findex netdev_add 1235ae82d324SMarkus ArmbrusterAdd host network device. 1236ae82d324SMarkus ArmbrusterETEXI 1237ae82d324SMarkus Armbruster 1238ae82d324SMarkus Armbruster { 1239ae82d324SMarkus Armbruster .name = "netdev_del", 1240ae82d324SMarkus Armbruster .args_type = "id:s", 1241ae82d324SMarkus Armbruster .params = "id", 1242ae82d324SMarkus Armbruster .help = "remove host network device", 12435f964155SLuiz Capitulino .mhandler.cmd = hmp_netdev_del, 124411b389f2SHani Benhabiles .command_completion = netdev_del_completion, 1245ae82d324SMarkus Armbruster }, 1246ae82d324SMarkus Armbruster 1247ae82d324SMarkus ArmbrusterSTEXI 1248ae82d324SMarkus Armbruster@item netdev_del 1249ae82d324SMarkus Armbruster@findex netdev_del 1250ae82d324SMarkus ArmbrusterRemove host network device. 1251ae82d324SMarkus ArmbrusterETEXI 1252ae82d324SMarkus Armbruster 1253ab2d0531SPaolo Bonzini { 1254cff8b2c6SPaolo Bonzini .name = "object_add", 1255cff8b2c6SPaolo Bonzini .args_type = "object:O", 1256cff8b2c6SPaolo Bonzini .params = "[qom-type=]type,id=str[,prop=value][,...]", 1257cff8b2c6SPaolo Bonzini .help = "create QOM object", 1258cff8b2c6SPaolo Bonzini .mhandler.cmd = hmp_object_add, 1259bfa40f77SHani Benhabiles .command_completion = object_add_completion, 1260cff8b2c6SPaolo Bonzini }, 1261cff8b2c6SPaolo Bonzini 1262cff8b2c6SPaolo BonziniSTEXI 1263cff8b2c6SPaolo Bonzini@item object_add 1264cff8b2c6SPaolo Bonzini@findex object_add 1265cff8b2c6SPaolo BonziniCreate QOM object. 1266cff8b2c6SPaolo BonziniETEXI 1267cff8b2c6SPaolo Bonzini 1268cff8b2c6SPaolo Bonzini { 1269ab2d0531SPaolo Bonzini .name = "object_del", 1270ab2d0531SPaolo Bonzini .args_type = "id:s", 1271ab2d0531SPaolo Bonzini .params = "id", 1272ab2d0531SPaolo Bonzini .help = "destroy QOM object", 1273ab2d0531SPaolo Bonzini .mhandler.cmd = hmp_object_del, 1274bfa40f77SHani Benhabiles .command_completion = object_del_completion, 1275ab2d0531SPaolo Bonzini }, 1276ab2d0531SPaolo Bonzini 1277ab2d0531SPaolo BonziniSTEXI 1278ab2d0531SPaolo Bonzini@item object_del 1279ab2d0531SPaolo Bonzini@findex object_del 1280ab2d0531SPaolo BonziniDestroy QOM object. 1281ab2d0531SPaolo BonziniETEXI 1282ab2d0531SPaolo Bonzini 12832313086aSBlue Swirl#ifdef CONFIG_SLIRP 1284d7f9b689SLuiz Capitulino { 1285d7f9b689SLuiz Capitulino .name = "hostfwd_add", 1286d7f9b689SLuiz Capitulino .args_type = "arg1:s,arg2:s?,arg3:s?", 1287d7f9b689SLuiz Capitulino .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport-[guestaddr]:guestport", 1288d7f9b689SLuiz Capitulino .help = "redirect TCP or UDP connections from host to guest (requires -net user)", 12893e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_hostfwd_add, 1290d7f9b689SLuiz Capitulino }, 129121413d68SMarkus Armbruster#endif 129221413d68SMarkus ArmbrusterSTEXI 129321413d68SMarkus Armbruster@item hostfwd_add 129421413d68SMarkus Armbruster@findex hostfwd_add 129521413d68SMarkus ArmbrusterRedirect TCP or UDP connections from host to guest (requires -net user). 129621413d68SMarkus ArmbrusterETEXI 1297d7f9b689SLuiz Capitulino 129821413d68SMarkus Armbruster#ifdef CONFIG_SLIRP 1299d7f9b689SLuiz Capitulino { 1300d7f9b689SLuiz Capitulino .name = "hostfwd_remove", 1301d7f9b689SLuiz Capitulino .args_type = "arg1:s,arg2:s?,arg3:s?", 1302d7f9b689SLuiz Capitulino .params = "[vlan_id name] [tcp|udp]:[hostaddr]:hostport", 1303d7f9b689SLuiz Capitulino .help = "remove host-to-guest TCP or UDP redirection", 13043e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_hostfwd_remove, 1305d7f9b689SLuiz Capitulino }, 1306d7f9b689SLuiz Capitulino 13072313086aSBlue Swirl#endif 13082313086aSBlue SwirlSTEXI 130921413d68SMarkus Armbruster@item hostfwd_remove 131021413d68SMarkus Armbruster@findex hostfwd_remove 131121413d68SMarkus ArmbrusterRemove host-to-guest TCP or UDP redirection. 13122313086aSBlue SwirlETEXI 13132313086aSBlue Swirl 1314d7f9b689SLuiz Capitulino { 1315d7f9b689SLuiz Capitulino .name = "balloon", 13163b0bd6ecSLuiz Capitulino .args_type = "value:M", 1317d7f9b689SLuiz Capitulino .params = "target", 13183c05613aSRiccardo Magliocchetti .help = "request VM to change its memory allocation (in MB)", 1319d72f3264SLuiz Capitulino .mhandler.cmd = hmp_balloon, 1320d7f9b689SLuiz Capitulino }, 1321d7f9b689SLuiz Capitulino 13222313086aSBlue SwirlSTEXI 13232313086aSBlue Swirl@item balloon @var{value} 132470fcbbe7SStefan Weil@findex balloon 13252313086aSBlue SwirlRequest VM to change its memory allocation to @var{value} (in MB). 13262313086aSBlue SwirlETEXI 13272313086aSBlue Swirl 1328d7f9b689SLuiz Capitulino { 1329d7f9b689SLuiz Capitulino .name = "set_link", 1330c9b26a4cSMarkus Armbruster .args_type = "name:s,up:b", 1331c9b26a4cSMarkus Armbruster .params = "name on|off", 1332d7f9b689SLuiz Capitulino .help = "change the link status of a network adapter", 13334b37156cSLuiz Capitulino .mhandler.cmd = hmp_set_link, 133440d19394SHani Benhabiles .command_completion = set_link_completion, 1335d7f9b689SLuiz Capitulino }, 1336d7f9b689SLuiz Capitulino 13372313086aSBlue SwirlSTEXI 1338c9b26a4cSMarkus Armbruster@item set_link @var{name} [on|off] 133970fcbbe7SStefan Weil@findex set_link 1340c9b26a4cSMarkus ArmbrusterSwitch link @var{name} on (i.e. up) or off (i.e. down). 13412313086aSBlue SwirlETEXI 13422313086aSBlue Swirl 1343d7f9b689SLuiz Capitulino { 1344d7f9b689SLuiz Capitulino .name = "watchdog_action", 1345d7f9b689SLuiz Capitulino .args_type = "action:s", 1346d7f9b689SLuiz Capitulino .params = "[reset|shutdown|poweroff|pause|debug|none]", 1347d7f9b689SLuiz Capitulino .help = "change watchdog action", 13483e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_watchdog_action, 1349d0ece345SHani Benhabiles .command_completion = watchdog_action_completion, 1350d7f9b689SLuiz Capitulino }, 1351d7f9b689SLuiz Capitulino 13522313086aSBlue SwirlSTEXI 13532313086aSBlue Swirl@item watchdog_action 135470fcbbe7SStefan Weil@findex watchdog_action 13552313086aSBlue SwirlChange watchdog action. 13562313086aSBlue SwirlETEXI 13572313086aSBlue Swirl 1358d7f9b689SLuiz Capitulino { 1359d7f9b689SLuiz Capitulino .name = "acl_show", 1360d7f9b689SLuiz Capitulino .args_type = "aclname:s", 1361d7f9b689SLuiz Capitulino .params = "aclname", 1362d7f9b689SLuiz Capitulino .help = "list rules in the access control list", 13633e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_acl_show, 1364d7f9b689SLuiz Capitulino }, 1365d7f9b689SLuiz Capitulino 13662313086aSBlue SwirlSTEXI 136715dfcd45SJan Kiszka@item acl_show @var{aclname} 136870fcbbe7SStefan Weil@findex acl_show 136915dfcd45SJan KiszkaList all the matching rules in the access control list, and the default 137015dfcd45SJan Kiszkapolicy. There are currently two named access control lists, 137115dfcd45SJan Kiszka@var{vnc.x509dname} and @var{vnc.username} matching on the x509 client 137215dfcd45SJan Kiszkacertificate distinguished name, and SASL username respectively. 137315dfcd45SJan KiszkaETEXI 13742313086aSBlue Swirl 1375d7f9b689SLuiz Capitulino { 1376d7f9b689SLuiz Capitulino .name = "acl_policy", 1377d7f9b689SLuiz Capitulino .args_type = "aclname:s,policy:s", 1378d7f9b689SLuiz Capitulino .params = "aclname allow|deny", 1379d7f9b689SLuiz Capitulino .help = "set default access control list policy", 13803e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_acl_policy, 1381d7f9b689SLuiz Capitulino }, 1382d7f9b689SLuiz Capitulino 138315dfcd45SJan KiszkaSTEXI 1384cbbfacc6SJan Kiszka@item acl_policy @var{aclname} @code{allow|deny} 138570fcbbe7SStefan Weil@findex acl_policy 138615dfcd45SJan KiszkaSet the default access control list policy, used in the event that 13872313086aSBlue Swirlnone of the explicit rules match. The default policy at startup is 138815dfcd45SJan Kiszkaalways @code{deny}. 138915dfcd45SJan KiszkaETEXI 139015dfcd45SJan Kiszka 1391d7f9b689SLuiz Capitulino { 1392d7f9b689SLuiz Capitulino .name = "acl_add", 1393d7f9b689SLuiz Capitulino .args_type = "aclname:s,match:s,policy:s,index:i?", 1394d7f9b689SLuiz Capitulino .params = "aclname match allow|deny [index]", 1395d7f9b689SLuiz Capitulino .help = "add a match rule to the access control list", 13963e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_acl_add, 1397d7f9b689SLuiz Capitulino }, 1398d7f9b689SLuiz Capitulino 139915dfcd45SJan KiszkaSTEXI 14000e4aec98SMarkus Armbruster@item acl_add @var{aclname} @var{match} @code{allow|deny} [@var{index}] 14010e4aec98SMarkus Armbruster@findex acl_add 140215dfcd45SJan KiszkaAdd a match rule to the access control list, allowing or denying access. 140315dfcd45SJan KiszkaThe match will normally be an exact username or x509 distinguished name, 140415dfcd45SJan Kiszkabut can optionally include wildcard globs. eg @code{*@@EXAMPLE.COM} to 140515dfcd45SJan Kiszkaallow all users in the @code{EXAMPLE.COM} kerberos realm. The match will 14062313086aSBlue Swirlnormally be appended to the end of the ACL, but can be inserted 140715dfcd45SJan Kiszkaearlier in the list if the optional @var{index} parameter is supplied. 140815dfcd45SJan KiszkaETEXI 140915dfcd45SJan Kiszka 1410d7f9b689SLuiz Capitulino { 1411d7f9b689SLuiz Capitulino .name = "acl_remove", 1412d7f9b689SLuiz Capitulino .args_type = "aclname:s,match:s", 1413d7f9b689SLuiz Capitulino .params = "aclname match", 1414d7f9b689SLuiz Capitulino .help = "remove a match rule from the access control list", 14153e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_acl_remove, 1416d7f9b689SLuiz Capitulino }, 1417d7f9b689SLuiz Capitulino 141815dfcd45SJan KiszkaSTEXI 141915dfcd45SJan Kiszka@item acl_remove @var{aclname} @var{match} 142070fcbbe7SStefan Weil@findex acl_remove 142115dfcd45SJan KiszkaRemove the specified match rule from the access control list. 142215dfcd45SJan KiszkaETEXI 142315dfcd45SJan Kiszka 1424d7f9b689SLuiz Capitulino { 1425d7f9b689SLuiz Capitulino .name = "acl_reset", 1426d7f9b689SLuiz Capitulino .args_type = "aclname:s", 1427d7f9b689SLuiz Capitulino .params = "aclname", 1428d7f9b689SLuiz Capitulino .help = "reset the access control list", 14293e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_acl_reset, 1430d7f9b689SLuiz Capitulino }, 1431d7f9b689SLuiz Capitulino 143215dfcd45SJan KiszkaSTEXI 14330e4aec98SMarkus Armbruster@item acl_reset @var{aclname} 14340e4aec98SMarkus Armbruster@findex acl_reset 143515dfcd45SJan KiszkaRemove all matches from the access control list, and set the default 14362313086aSBlue Swirlpolicy back to @code{deny}. 14372313086aSBlue SwirlETEXI 14382313086aSBlue Swirl 14394057725fSPaolo Bonzini { 14404057725fSPaolo Bonzini .name = "nbd_server_start", 14414057725fSPaolo Bonzini .args_type = "all:-a,writable:-w,uri:s", 14424057725fSPaolo Bonzini .params = "nbd_server_start [-a] [-w] host:port", 14434057725fSPaolo Bonzini .help = "serve block devices on the given host and port", 14444057725fSPaolo Bonzini .mhandler.cmd = hmp_nbd_server_start, 14454057725fSPaolo Bonzini }, 14464057725fSPaolo BonziniSTEXI 14474057725fSPaolo Bonzini@item nbd_server_start @var{host}:@var{port} 14484057725fSPaolo Bonzini@findex nbd_server_start 14494057725fSPaolo BonziniStart an NBD server on the given host and/or port. If the @option{-a} 14504057725fSPaolo Bonzinioption is included, all of the virtual machine's block devices that 14514057725fSPaolo Bonzinihave an inserted media on them are automatically exported; in this case, 14524057725fSPaolo Bonzinithe @option{-w} option makes the devices writable too. 14534057725fSPaolo BonziniETEXI 14544057725fSPaolo Bonzini 14554057725fSPaolo Bonzini { 14564057725fSPaolo Bonzini .name = "nbd_server_add", 14574057725fSPaolo Bonzini .args_type = "writable:-w,device:B", 14584057725fSPaolo Bonzini .params = "nbd_server_add [-w] device", 14594057725fSPaolo Bonzini .help = "export a block device via NBD", 14604057725fSPaolo Bonzini .mhandler.cmd = hmp_nbd_server_add, 14614057725fSPaolo Bonzini }, 14624057725fSPaolo BonziniSTEXI 14634057725fSPaolo Bonzini@item nbd_server_add @var{device} 14644057725fSPaolo Bonzini@findex nbd_server_add 14654057725fSPaolo BonziniExport a block device through QEMU's NBD server, which must be started 14664057725fSPaolo Bonzinibeforehand with @command{nbd_server_start}. The @option{-w} option makes the 14674057725fSPaolo Bonziniexported device writable too. 14684057725fSPaolo BonziniETEXI 14694057725fSPaolo Bonzini 14704057725fSPaolo Bonzini { 14714057725fSPaolo Bonzini .name = "nbd_server_stop", 14724057725fSPaolo Bonzini .args_type = "", 14734057725fSPaolo Bonzini .params = "nbd_server_stop", 14744057725fSPaolo Bonzini .help = "stop serving block devices using the NBD protocol", 14754057725fSPaolo Bonzini .mhandler.cmd = hmp_nbd_server_stop, 14764057725fSPaolo Bonzini }, 14774057725fSPaolo BonziniSTEXI 14784057725fSPaolo Bonzini@item nbd_server_stop 14794057725fSPaolo Bonzini@findex nbd_server_stop 14804057725fSPaolo BonziniStop the QEMU embedded NBD server. 14814057725fSPaolo BonziniETEXI 14824057725fSPaolo Bonzini 14834057725fSPaolo Bonzini 148479c4f6b0SHuang Ying#if defined(TARGET_I386) 1485d7f9b689SLuiz Capitulino 1486d7f9b689SLuiz Capitulino { 1487d7f9b689SLuiz Capitulino .name = "mce", 148831ce5e0cSJin Dongming .args_type = "broadcast:-b,cpu_index:i,bank:i,status:l,mcg_status:l,addr:l,misc:l", 148931ce5e0cSJin Dongming .params = "[-b] cpu bank status mcgstatus addr misc", 149031ce5e0cSJin Dongming .help = "inject a MCE on the given CPU [and broadcast to other CPUs with -b option]", 14913e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_mce, 1492d7f9b689SLuiz Capitulino }, 1493d7f9b689SLuiz Capitulino 149479c4f6b0SHuang Ying#endif 149579c4f6b0SHuang YingSTEXI 149679c4f6b0SHuang Ying@item mce @var{cpu} @var{bank} @var{status} @var{mcgstatus} @var{addr} @var{misc} 149770fcbbe7SStefan Weil@findex mce (x86) 149879c4f6b0SHuang YingInject an MCE on the given CPU (x86 only). 149979c4f6b0SHuang YingETEXI 150079c4f6b0SHuang Ying 1501d7f9b689SLuiz Capitulino { 1502d7f9b689SLuiz Capitulino .name = "getfd", 1503d7f9b689SLuiz Capitulino .args_type = "fdname:s", 1504d7f9b689SLuiz Capitulino .params = "getfd name", 1505d7f9b689SLuiz Capitulino .help = "receive a file descriptor via SCM rights and assign it a name", 1506208c9d1bSCorey Bryant .mhandler.cmd = hmp_getfd, 1507d7f9b689SLuiz Capitulino }, 1508d7f9b689SLuiz Capitulino 1509f07918fdSMark McLoughlinSTEXI 1510f07918fdSMark McLoughlin@item getfd @var{fdname} 151170fcbbe7SStefan Weil@findex getfd 1512f07918fdSMark McLoughlinIf a file descriptor is passed alongside this command using the SCM_RIGHTS 1513f07918fdSMark McLoughlinmechanism on unix sockets, it is stored using the name @var{fdname} for 1514f07918fdSMark McLoughlinlater use by other monitor commands. 1515f07918fdSMark McLoughlinETEXI 1516f07918fdSMark McLoughlin 1517d7f9b689SLuiz Capitulino { 1518d7f9b689SLuiz Capitulino .name = "closefd", 1519d7f9b689SLuiz Capitulino .args_type = "fdname:s", 1520d7f9b689SLuiz Capitulino .params = "closefd name", 1521d7f9b689SLuiz Capitulino .help = "close a file descriptor previously passed via SCM rights", 1522208c9d1bSCorey Bryant .mhandler.cmd = hmp_closefd, 1523d7f9b689SLuiz Capitulino }, 1524d7f9b689SLuiz Capitulino 1525f07918fdSMark McLoughlinSTEXI 1526f07918fdSMark McLoughlin@item closefd @var{fdname} 152770fcbbe7SStefan Weil@findex closefd 1528f07918fdSMark McLoughlinClose the file descriptor previously assigned to @var{fdname} using the 1529f07918fdSMark McLoughlin@code{getfd} command. This is only needed if the file descriptor was never 1530f07918fdSMark McLoughlinused by another monitor command. 1531f07918fdSMark McLoughlinETEXI 1532f07918fdSMark McLoughlin 1533a3a55a2eSLuiz Capitulino { 1534a3a55a2eSLuiz Capitulino .name = "block_passwd", 1535a3a55a2eSLuiz Capitulino .args_type = "device:B,password:s", 1536a3a55a2eSLuiz Capitulino .params = "block_passwd device password", 1537a3a55a2eSLuiz Capitulino .help = "set the password of encrypted block devices", 1538a4dea8a9SLuiz Capitulino .mhandler.cmd = hmp_block_passwd, 1539a3a55a2eSLuiz Capitulino }, 1540a3a55a2eSLuiz Capitulino 1541a3a55a2eSLuiz CapitulinoSTEXI 1542727f005eSZhi Yong Wu@item block_set_io_throttle @var{device} @var{bps} @var{bps_rd} @var{bps_wr} @var{iops} @var{iops_rd} @var{iops_wr} 1543727f005eSZhi Yong Wu@findex block_set_io_throttle 1544727f005eSZhi Yong WuChange 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} 1545727f005eSZhi Yong WuETEXI 1546727f005eSZhi Yong Wu 1547727f005eSZhi Yong Wu { 1548727f005eSZhi Yong Wu .name = "block_set_io_throttle", 1549727f005eSZhi Yong Wu .args_type = "device:B,bps:l,bps_rd:l,bps_wr:l,iops:l,iops_rd:l,iops_wr:l", 1550727f005eSZhi Yong Wu .params = "device bps bps_rd bps_wr iops iops_rd iops_wr", 1551727f005eSZhi Yong Wu .help = "change I/O throttle limits for a block drive", 155280047da5SLuiz Capitulino .mhandler.cmd = hmp_block_set_io_throttle, 1553727f005eSZhi Yong Wu }, 1554727f005eSZhi Yong Wu 1555727f005eSZhi Yong WuSTEXI 1556a3a55a2eSLuiz Capitulino@item block_passwd @var{device} @var{password} 155770fcbbe7SStefan Weil@findex block_passwd 1558a3a55a2eSLuiz CapitulinoSet the encrypted device @var{device} password to @var{password} 1559a3a55a2eSLuiz CapitulinoETEXI 1560b40292e7SJan Kiszka 156133572eceSJan Kiszka { 15627572150cSGerd Hoffmann .name = "set_password", 15637572150cSGerd Hoffmann .args_type = "protocol:s,password:s,connected:s?", 15647572150cSGerd Hoffmann .params = "protocol password action-if-connected", 15657572150cSGerd Hoffmann .help = "set spice/vnc password", 1566fbf796fdSLuiz Capitulino .mhandler.cmd = hmp_set_password, 15677572150cSGerd Hoffmann }, 15687572150cSGerd Hoffmann 15697572150cSGerd HoffmannSTEXI 15707572150cSGerd Hoffmann@item set_password [ vnc | spice ] password [ action-if-connected ] 15717572150cSGerd Hoffmann@findex set_password 15727572150cSGerd Hoffmann 15737572150cSGerd HoffmannChange spice/vnc password. Use zero to make the password stay valid 15747572150cSGerd Hoffmannforever. @var{action-if-connected} specifies what should happen in 15757572150cSGerd Hoffmanncase a connection is established: @var{fail} makes the password change 15767572150cSGerd Hoffmannfail. @var{disconnect} changes the password and disconnects the 15777572150cSGerd Hoffmannclient. @var{keep} changes the password and keeps the connection up. 15787572150cSGerd Hoffmann@var{keep} is the default. 15797572150cSGerd HoffmannETEXI 15807572150cSGerd Hoffmann 15817572150cSGerd Hoffmann { 15827572150cSGerd Hoffmann .name = "expire_password", 15837572150cSGerd Hoffmann .args_type = "protocol:s,time:s", 15847572150cSGerd Hoffmann .params = "protocol time", 15857572150cSGerd Hoffmann .help = "set spice/vnc password expire-time", 15869ad5372dSLuiz Capitulino .mhandler.cmd = hmp_expire_password, 15877572150cSGerd Hoffmann }, 15887572150cSGerd Hoffmann 15897572150cSGerd HoffmannSTEXI 15907572150cSGerd Hoffmann@item expire_password [ vnc | spice ] expire-time 15917572150cSGerd Hoffmann@findex expire_password 15927572150cSGerd Hoffmann 15937572150cSGerd HoffmannSpecify when a password for spice/vnc becomes 15947572150cSGerd Hoffmanninvalid. @var{expire-time} accepts: 15957572150cSGerd Hoffmann 15967572150cSGerd Hoffmann@table @var 15977572150cSGerd Hoffmann@item now 15987572150cSGerd HoffmannInvalidate password instantly. 15997572150cSGerd Hoffmann 16007572150cSGerd Hoffmann@item never 16017572150cSGerd HoffmannPassword stays valid forever. 16027572150cSGerd Hoffmann 16037572150cSGerd Hoffmann@item +nsec 16047572150cSGerd HoffmannPassword stays valid for @var{nsec} seconds starting now. 16057572150cSGerd Hoffmann 16067572150cSGerd Hoffmann@item nsec 16077572150cSGerd HoffmannPassword is invalidated at the given time. @var{nsec} are the seconds 16087572150cSGerd Hoffmannpassed since 1970, i.e. unix epoch. 16097572150cSGerd Hoffmann 16107572150cSGerd Hoffmann@end table 16117572150cSGerd HoffmannETEXI 16127572150cSGerd Hoffmann 161346920825SGerd Hoffmann { 161446920825SGerd Hoffmann .name = "chardev-add", 161546920825SGerd Hoffmann .args_type = "args:s", 161646920825SGerd Hoffmann .params = "args", 161746920825SGerd Hoffmann .help = "add chardev", 161846920825SGerd Hoffmann .mhandler.cmd = hmp_chardev_add, 161913e315daSHani Benhabiles .command_completion = chardev_add_completion, 162046920825SGerd Hoffmann }, 162146920825SGerd Hoffmann 162246920825SGerd HoffmannSTEXI 162346920825SGerd Hoffmann@item chardev_add args 162446920825SGerd Hoffmann@findex chardev_add 162546920825SGerd Hoffmann 162646920825SGerd Hoffmannchardev_add accepts the same parameters as the -chardev command line switch. 162746920825SGerd Hoffmann 162846920825SGerd HoffmannETEXI 162946920825SGerd Hoffmann 163046920825SGerd Hoffmann { 163146920825SGerd Hoffmann .name = "chardev-remove", 163246920825SGerd Hoffmann .args_type = "id:s", 163346920825SGerd Hoffmann .params = "id", 163446920825SGerd Hoffmann .help = "remove chardev", 163546920825SGerd Hoffmann .mhandler.cmd = hmp_chardev_remove, 16366297d9a2SHani Benhabiles .command_completion = chardev_remove_completion, 163746920825SGerd Hoffmann }, 163846920825SGerd Hoffmann 163946920825SGerd HoffmannSTEXI 164046920825SGerd Hoffmann@item chardev_remove id 164146920825SGerd Hoffmann@findex chardev_remove 164246920825SGerd Hoffmann 164346920825SGerd HoffmannRemoves the chardev @var{id}. 164446920825SGerd Hoffmann 164546920825SGerd HoffmannETEXI 1646f1088908SGerd Hoffmann 1647f1088908SGerd Hoffmann { 1648587da2c3SKevin Wolf .name = "qemu-io", 1649587da2c3SKevin Wolf .args_type = "device:B,command:s", 1650587da2c3SKevin Wolf .params = "[device] \"[command]\"", 1651587da2c3SKevin Wolf .help = "run a qemu-io command on a block device", 1652587da2c3SKevin Wolf .mhandler.cmd = hmp_qemu_io, 1653587da2c3SKevin Wolf }, 1654587da2c3SKevin Wolf 1655587da2c3SKevin WolfSTEXI 1656587da2c3SKevin Wolf@item qemu-io @var{device} @var{command} 1657587da2c3SKevin Wolf@findex qemu-io 1658587da2c3SKevin Wolf 1659587da2c3SKevin WolfExecutes a qemu-io command on the given block device. 1660587da2c3SKevin Wolf 1661587da2c3SKevin WolfETEXI 1662587da2c3SKevin Wolf 1663587da2c3SKevin Wolf { 1664abf23329SJason J. Herne .name = "cpu-add", 1665abf23329SJason J. Herne .args_type = "id:i", 1666abf23329SJason J. Herne .params = "id", 1667abf23329SJason J. Herne .help = "add cpu", 1668abf23329SJason J. Herne .mhandler.cmd = hmp_cpu_add, 1669abf23329SJason J. Herne }, 1670abf23329SJason J. Herne 1671abf23329SJason J. HerneSTEXI 1672abf23329SJason J. Herne@item cpu-add @var{id} 1673abf23329SJason J. HerneAdd CPU with id @var{id} 1674abf23329SJason J. HerneETEXI 1675abf23329SJason J. Herne 1676abf23329SJason J. Herne { 167789d7fa9eSAndreas Färber .name = "qom-list", 167889d7fa9eSAndreas Färber .args_type = "path:s?", 167989d7fa9eSAndreas Färber .params = "path", 168089d7fa9eSAndreas Färber .help = "list QOM properties", 168189d7fa9eSAndreas Färber .mhandler.cmd = hmp_qom_list, 168289d7fa9eSAndreas Färber }, 168389d7fa9eSAndreas Färber 168489d7fa9eSAndreas FärberSTEXI 168589d7fa9eSAndreas Färber@item qom-list [@var{path}] 168689d7fa9eSAndreas FärberPrint QOM properties of object at location @var{path} 168789d7fa9eSAndreas FärberETEXI 168889d7fa9eSAndreas Färber 168989d7fa9eSAndreas Färber { 1690*c0e6ee9eSAndreas Färber .name = "qom-set", 1691*c0e6ee9eSAndreas Färber .args_type = "path:s,property:s,value:s", 1692*c0e6ee9eSAndreas Färber .params = "path property value", 1693*c0e6ee9eSAndreas Färber .help = "set QOM property", 1694*c0e6ee9eSAndreas Färber .mhandler.cmd = hmp_qom_set, 1695*c0e6ee9eSAndreas Färber }, 1696*c0e6ee9eSAndreas Färber 1697*c0e6ee9eSAndreas FärberSTEXI 1698*c0e6ee9eSAndreas Färber@item qom-set @var{path} @var{property} @var{value} 1699*c0e6ee9eSAndreas FärberSet QOM property @var{property} of object at location @var{path} to value @var{value} 1700*c0e6ee9eSAndreas FärberETEXI 1701*c0e6ee9eSAndreas Färber 1702*c0e6ee9eSAndreas Färber { 170333572eceSJan Kiszka .name = "info", 170433572eceSJan Kiszka .args_type = "item:s?", 170533572eceSJan Kiszka .params = "[subcommand]", 170633572eceSJan Kiszka .help = "show various information about the system state", 17073e5a50d6SMarkus Armbruster .mhandler.cmd = hmp_info_help, 170884c44613SWenchao Xia .sub_table = info_cmds, 170933572eceSJan Kiszka }, 171033572eceSJan Kiszka 171133572eceSJan KiszkaSTEXI 171233572eceSJan Kiszka@item info @var{subcommand} 171333572eceSJan Kiszka@findex info 171433572eceSJan KiszkaShow various information about the system state. 171533572eceSJan Kiszka 171633572eceSJan Kiszka@table @option 171733572eceSJan Kiszka@item info version 171833572eceSJan Kiszkashow the version of QEMU 171933572eceSJan Kiszka@item info network 172033572eceSJan Kiszkashow the various VLANs and the associated devices 172133572eceSJan Kiszka@item info chardev 172233572eceSJan Kiszkashow the character devices 172333572eceSJan Kiszka@item info block 172433572eceSJan Kiszkashow the block devices 172533572eceSJan Kiszka@item info blockstats 172633572eceSJan Kiszkashow block device statistics 172733572eceSJan Kiszka@item info registers 172833572eceSJan Kiszkashow the cpu registers 172933572eceSJan Kiszka@item info cpus 173033572eceSJan Kiszkashow infos for each CPU 173133572eceSJan Kiszka@item info history 173233572eceSJan Kiszkashow the command line history 173333572eceSJan Kiszka@item info irq 173433572eceSJan Kiszkashow the interrupts statistics (if available) 173533572eceSJan Kiszka@item info pic 173633572eceSJan Kiszkashow i8259 (PIC) state 173733572eceSJan Kiszka@item info pci 173833572eceSJan Kiszkashow emulated PCI device info 173933572eceSJan Kiszka@item info tlb 1740692f737cSMax Filippovshow virtual to physical memory mappings (i386, SH4, SPARC, PPC, and Xtensa only) 174133572eceSJan Kiszka@item info mem 174233572eceSJan Kiszkashow the active virtual memory mappings (i386 only) 174333572eceSJan Kiszka@item info jit 174433572eceSJan Kiszkashow dynamic compiler info 174533572eceSJan Kiszka@item info numa 174633572eceSJan Kiszkashow NUMA information 1747b40292e7SJan Kiszka@item info kvm 1748b40292e7SJan Kiszkashow KVM information 174933572eceSJan Kiszka@item info usb 175033572eceSJan Kiszkashow USB devices plugged on the virtual USB hub 175133572eceSJan Kiszka@item info usbhost 175233572eceSJan Kiszkashow all USB host devices 175333572eceSJan Kiszka@item info profile 175433572eceSJan Kiszkashow profiling information 175533572eceSJan Kiszka@item info capture 175633572eceSJan Kiszkashow information about active capturing 175733572eceSJan Kiszka@item info snapshots 175833572eceSJan Kiszkashow list of VM snapshots 175933572eceSJan Kiszka@item info status 176033572eceSJan Kiszkashow the current VM status (running|paused) 176133572eceSJan Kiszka@item info mice 176233572eceSJan Kiszkashow which guest mouse is receiving events 176333572eceSJan Kiszka@item info vnc 176433572eceSJan Kiszkashow the vnc server status 176533572eceSJan Kiszka@item info name 176633572eceSJan Kiszkashow the current VM name 176733572eceSJan Kiszka@item info uuid 176833572eceSJan Kiszkashow the current VM UUID 176933572eceSJan Kiszka@item info cpustats 177033572eceSJan Kiszkashow CPU statistics 177133572eceSJan Kiszka@item info usernet 177233572eceSJan Kiszkashow user network stack connection states 177333572eceSJan Kiszka@item info migrate 177433572eceSJan Kiszkashow migration status 1775bbf6da32SOrit Wasserman@item info migrate_capabilities 1776bbf6da32SOrit Wassermanshow current migration capabilities 17779e1ba4ccSOrit Wasserman@item info migrate_cache_size 17789e1ba4ccSOrit Wassermanshow current migration XBZRLE cache size 177933572eceSJan Kiszka@item info balloon 178033572eceSJan Kiszkashow balloon information 178133572eceSJan Kiszka@item info qtree 178233572eceSJan Kiszkashow device tree 178333572eceSJan Kiszka@item info qdm 178433572eceSJan Kiszkashow qdev device model list 178533572eceSJan Kiszka@item info roms 178633572eceSJan Kiszkashow roms 1787d1a0cf73SStefan Berger@item info tpm 1788d1a0cf73SStefan Bergershow the TPM device 1789a631892fSZhu Guihua@item info memory-devices 1790a631892fSZhu Guihuashow the memory devices 179133572eceSJan Kiszka@end table 179233572eceSJan KiszkaETEXI 179333572eceSJan Kiszka 179431965ae2SLluÃsSTEXI 179522890ab5SPrerna Saxena@item info trace-events 179622890ab5SPrerna Saxenashow available trace events and their state 179722890ab5SPrerna SaxenaETEXI 179822890ab5SPrerna Saxena 17992313086aSBlue SwirlSTEXI 18002313086aSBlue Swirl@end table 18012313086aSBlue SwirlETEXI 1802