qemu-options.hx 114 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147
  1. HXCOMM Use DEFHEADING() to define headings in both help text and texi
  2. HXCOMM Text between STEXI and ETEXI are copied to texi version and
  3. HXCOMM discarded from C version
  4. HXCOMM DEF(option, HAS_ARG/0, opt_enum, opt_help, arch_mask) is used to
  5. HXCOMM construct option structures, enums and help message for specified
  6. HXCOMM architectures.
  7. HXCOMM HXCOMM can be used for comments, discarded from both texi and C
  8. DEFHEADING(Standard options:)
  9. STEXI
  10. @table @option
  11. ETEXI
  12. DEF("help", 0, QEMU_OPTION_h,
  13. "-h or -help display this help and exit\n", QEMU_ARCH_ALL)
  14. STEXI
  15. @item -h
  16. @findex -h
  17. Display help and exit
  18. ETEXI
  19. DEF("version", 0, QEMU_OPTION_version,
  20. "-version display version information and exit\n", QEMU_ARCH_ALL)
  21. STEXI
  22. @item -version
  23. @findex -version
  24. Display version information and exit
  25. ETEXI
  26. DEF("machine", HAS_ARG, QEMU_OPTION_machine, \
  27. "-machine [type=]name[,prop[=value][,...]]\n"
  28. " selects emulated machine ('-machine help' for list)\n"
  29. " property accel=accel1[:accel2[:...]] selects accelerator\n"
  30. " supported accelerators are kvm, xen, tcg (default: tcg)\n"
  31. " kernel_irqchip=on|off controls accelerated irqchip support\n"
  32. " kvm_shadow_mem=size of KVM shadow MMU\n"
  33. " dump-guest-core=on|off include guest memory in a core dump (default=on)\n"
  34. " mem-merge=on|off controls memory merge support (default: on)\n",
  35. QEMU_ARCH_ALL)
  36. STEXI
  37. @item -machine [type=]@var{name}[,prop=@var{value}[,...]]
  38. @findex -machine
  39. Select the emulated machine by @var{name}. Use @code{-machine help} to list
  40. available machines. Supported machine properties are:
  41. @table @option
  42. @item accel=@var{accels1}[:@var{accels2}[:...]]
  43. This is used to enable an accelerator. Depending on the target architecture,
  44. kvm, xen, or tcg can be available. By default, tcg is used. If there is more
  45. than one accelerator specified, the next one is used if the previous one fails
  46. to initialize.
  47. @item kernel_irqchip=on|off
  48. Enables in-kernel irqchip support for the chosen accelerator when available.
  49. @item kvm_shadow_mem=size
  50. Defines the size of the KVM shadow MMU.
  51. @item dump-guest-core=on|off
  52. Include guest memory in a core dump. The default is on.
  53. @item mem-merge=on|off
  54. Enables or disables memory merge support. This feature, when supported by
  55. the host, de-duplicates identical memory pages among VMs instances
  56. (enabled by default).
  57. @end table
  58. ETEXI
  59. HXCOMM Deprecated by -machine
  60. DEF("M", HAS_ARG, QEMU_OPTION_M, "", QEMU_ARCH_ALL)
  61. DEF("cpu", HAS_ARG, QEMU_OPTION_cpu,
  62. "-cpu cpu select CPU ('-cpu help' for list)\n", QEMU_ARCH_ALL)
  63. STEXI
  64. @item -cpu @var{model}
  65. @findex -cpu
  66. Select CPU model (@code{-cpu help} for list and additional feature selection)
  67. ETEXI
  68. DEF("smp", HAS_ARG, QEMU_OPTION_smp,
  69. "-smp [cpus=]n[,maxcpus=cpus][,cores=cores][,threads=threads][,sockets=sockets]\n"
  70. " set the number of CPUs to 'n' [default=1]\n"
  71. " maxcpus= maximum number of total cpus, including\n"
  72. " offline CPUs for hotplug, etc\n"
  73. " cores= number of CPU cores on one socket\n"
  74. " threads= number of threads on one CPU core\n"
  75. " sockets= number of discrete sockets in the system\n",
  76. QEMU_ARCH_ALL)
  77. STEXI
  78. @item -smp [cpus=]@var{n}[,cores=@var{cores}][,threads=@var{threads}][,sockets=@var{sockets}][,maxcpus=@var{maxcpus}]
  79. @findex -smp
  80. Simulate an SMP system with @var{n} CPUs. On the PC target, up to 255
  81. CPUs are supported. On Sparc32 target, Linux limits the number of usable CPUs
  82. to 4.
  83. For the PC target, the number of @var{cores} per socket, the number
  84. of @var{threads} per cores and the total number of @var{sockets} can be
  85. specified. Missing values will be computed. If any on the three values is
  86. given, the total number of CPUs @var{n} can be omitted. @var{maxcpus}
  87. specifies the maximum number of hotpluggable CPUs.
  88. ETEXI
  89. DEF("numa", HAS_ARG, QEMU_OPTION_numa,
  90. "-numa node[,mem=size][,cpus=cpu[-cpu]][,nodeid=node]\n", QEMU_ARCH_ALL)
  91. STEXI
  92. @item -numa @var{opts}
  93. @findex -numa
  94. Simulate a multi node NUMA system. If mem and cpus are omitted, resources
  95. are split equally.
  96. ETEXI
  97. DEF("add-fd", HAS_ARG, QEMU_OPTION_add_fd,
  98. "-add-fd fd=fd,set=set[,opaque=opaque]\n"
  99. " Add 'fd' to fd 'set'\n", QEMU_ARCH_ALL)
  100. STEXI
  101. @item -add-fd fd=@var{fd},set=@var{set}[,opaque=@var{opaque}]
  102. @findex -add-fd
  103. Add a file descriptor to an fd set. Valid options are:
  104. @table @option
  105. @item fd=@var{fd}
  106. This option defines the file descriptor of which a duplicate is added to fd set.
  107. The file descriptor cannot be stdin, stdout, or stderr.
  108. @item set=@var{set}
  109. This option defines the ID of the fd set to add the file descriptor to.
  110. @item opaque=@var{opaque}
  111. This option defines a free-form string that can be used to describe @var{fd}.
  112. @end table
  113. You can open an image using pre-opened file descriptors from an fd set:
  114. @example
  115. qemu-system-i386
  116. -add-fd fd=3,set=2,opaque="rdwr:/path/to/file"
  117. -add-fd fd=4,set=2,opaque="rdonly:/path/to/file"
  118. -drive file=/dev/fdset/2,index=0,media=disk
  119. @end example
  120. ETEXI
  121. DEF("set", HAS_ARG, QEMU_OPTION_set,
  122. "-set group.id.arg=value\n"
  123. " set <arg> parameter for item <id> of type <group>\n"
  124. " i.e. -set drive.$id.file=/path/to/image\n", QEMU_ARCH_ALL)
  125. STEXI
  126. @item -set @var{group}.@var{id}.@var{arg}=@var{value}
  127. @findex -set
  128. Set parameter @var{arg} for item @var{id} of type @var{group}\n"
  129. ETEXI
  130. DEF("global", HAS_ARG, QEMU_OPTION_global,
  131. "-global driver.prop=value\n"
  132. " set a global default for a driver property\n",
  133. QEMU_ARCH_ALL)
  134. STEXI
  135. @item -global @var{driver}.@var{prop}=@var{value}
  136. @findex -global
  137. Set default value of @var{driver}'s property @var{prop} to @var{value}, e.g.:
  138. @example
  139. qemu-system-i386 -global ide-drive.physical_block_size=4096 -drive file=file,if=ide,index=0,media=disk
  140. @end example
  141. In particular, you can use this to set driver properties for devices which are
  142. created automatically by the machine model. To create a device which is not
  143. created automatically and set properties on it, use -@option{device}.
  144. ETEXI
  145. DEF("boot", HAS_ARG, QEMU_OPTION_boot,
  146. "-boot [order=drives][,once=drives][,menu=on|off]\n"
  147. " [,splash=sp_name][,splash-time=sp_time][,reboot-timeout=rb_time][,strict=on|off]\n"
  148. " 'drives': floppy (a), hard disk (c), CD-ROM (d), network (n)\n"
  149. " 'sp_name': the file's name that would be passed to bios as logo picture, if menu=on\n"
  150. " 'sp_time': the period that splash picture last if menu=on, unit is ms\n"
  151. " 'rb_timeout': the timeout before guest reboot when boot failed, unit is ms\n",
  152. QEMU_ARCH_ALL)
  153. STEXI
  154. @item -boot [order=@var{drives}][,once=@var{drives}][,menu=on|off][,splash=@var{sp_name}][,splash-time=@var{sp_time}][,reboot-timeout=@var{rb_timeout}][,strict=on|off]
  155. @findex -boot
  156. Specify boot order @var{drives} as a string of drive letters. Valid
  157. drive letters depend on the target achitecture. The x86 PC uses: a, b
  158. (floppy 1 and 2), c (first hard disk), d (first CD-ROM), n-p (Etherboot
  159. from network adapter 1-4), hard disk boot is the default. To apply a
  160. particular boot order only on the first startup, specify it via
  161. @option{once}.
  162. Interactive boot menus/prompts can be enabled via @option{menu=on} as far
  163. as firmware/BIOS supports them. The default is non-interactive boot.
  164. A splash picture could be passed to bios, enabling user to show it as logo,
  165. when option splash=@var{sp_name} is given and menu=on, If firmware/BIOS
  166. supports them. Currently Seabios for X86 system support it.
  167. limitation: The splash file could be a jpeg file or a BMP file in 24 BPP
  168. format(true color). The resolution should be supported by the SVGA mode, so
  169. the recommended is 320x240, 640x480, 800x640.
  170. A timeout could be passed to bios, guest will pause for @var{rb_timeout} ms
  171. when boot failed, then reboot. If @var{rb_timeout} is '-1', guest will not
  172. reboot, qemu passes '-1' to bios by default. Currently Seabios for X86
  173. system support it.
  174. Do strict boot via @option{strict=on} as far as firmware/BIOS
  175. supports it. This only effects when boot priority is changed by
  176. bootindex options. The default is non-strict boot.
  177. @example
  178. # try to boot from network first, then from hard disk
  179. qemu-system-i386 -boot order=nc
  180. # boot from CD-ROM first, switch back to default order after reboot
  181. qemu-system-i386 -boot once=d
  182. # boot with a splash picture for 5 seconds.
  183. qemu-system-i386 -boot menu=on,splash=/root/boot.bmp,splash-time=5000
  184. @end example
  185. Note: The legacy format '-boot @var{drives}' is still supported but its
  186. use is discouraged as it may be removed from future versions.
  187. ETEXI
  188. DEF("m", HAS_ARG, QEMU_OPTION_m,
  189. "-m megs set virtual RAM size to megs MB [default="
  190. stringify(DEFAULT_RAM_SIZE) "]\n", QEMU_ARCH_ALL)
  191. STEXI
  192. @item -m @var{megs}
  193. @findex -m
  194. Set virtual RAM size to @var{megs} megabytes. Default is 128 MiB. Optionally,
  195. a suffix of ``M'' or ``G'' can be used to signify a value in megabytes or
  196. gigabytes respectively.
  197. ETEXI
  198. DEF("mem-path", HAS_ARG, QEMU_OPTION_mempath,
  199. "-mem-path FILE provide backing storage for guest RAM\n", QEMU_ARCH_ALL)
  200. STEXI
  201. @item -mem-path @var{path}
  202. @findex -mem-path
  203. Allocate guest RAM from a temporarily created file in @var{path}.
  204. ETEXI
  205. DEF("mem-prealloc", 0, QEMU_OPTION_mem_prealloc,
  206. "-mem-prealloc preallocate guest memory (use with -mem-path)\n",
  207. QEMU_ARCH_ALL)
  208. STEXI
  209. @item -mem-prealloc
  210. @findex -mem-prealloc
  211. Preallocate memory when using -mem-path.
  212. ETEXI
  213. DEF("k", HAS_ARG, QEMU_OPTION_k,
  214. "-k language use keyboard layout (for example 'fr' for French)\n",
  215. QEMU_ARCH_ALL)
  216. STEXI
  217. @item -k @var{language}
  218. @findex -k
  219. Use keyboard layout @var{language} (for example @code{fr} for
  220. French). This option is only needed where it is not easy to get raw PC
  221. keycodes (e.g. on Macs, with some X11 servers or with a VNC
  222. display). You don't normally need to use it on PC/Linux or PC/Windows
  223. hosts.
  224. The available layouts are:
  225. @example
  226. ar de-ch es fo fr-ca hu ja mk no pt-br sv
  227. da en-gb et fr fr-ch is lt nl pl ru th
  228. de en-us fi fr-be hr it lv nl-be pt sl tr
  229. @end example
  230. The default is @code{en-us}.
  231. ETEXI
  232. DEF("audio-help", 0, QEMU_OPTION_audio_help,
  233. "-audio-help print list of audio drivers and their options\n",
  234. QEMU_ARCH_ALL)
  235. STEXI
  236. @item -audio-help
  237. @findex -audio-help
  238. Will show the audio subsystem help: list of drivers, tunable
  239. parameters.
  240. ETEXI
  241. DEF("soundhw", HAS_ARG, QEMU_OPTION_soundhw,
  242. "-soundhw c1,... enable audio support\n"
  243. " and only specified sound cards (comma separated list)\n"
  244. " use '-soundhw help' to get the list of supported cards\n"
  245. " use '-soundhw all' to enable all of them\n", QEMU_ARCH_ALL)
  246. STEXI
  247. @item -soundhw @var{card1}[,@var{card2},...] or -soundhw all
  248. @findex -soundhw
  249. Enable audio and selected sound hardware. Use 'help' to print all
  250. available sound hardware.
  251. @example
  252. qemu-system-i386 -soundhw sb16,adlib disk.img
  253. qemu-system-i386 -soundhw es1370 disk.img
  254. qemu-system-i386 -soundhw ac97 disk.img
  255. qemu-system-i386 -soundhw hda disk.img
  256. qemu-system-i386 -soundhw all disk.img
  257. qemu-system-i386 -soundhw help
  258. @end example
  259. Note that Linux's i810_audio OSS kernel (for AC97) module might
  260. require manually specifying clocking.
  261. @example
  262. modprobe i810_audio clocking=48000
  263. @end example
  264. ETEXI
  265. DEF("balloon", HAS_ARG, QEMU_OPTION_balloon,
  266. "-balloon none disable balloon device\n"
  267. "-balloon virtio[,addr=str]\n"
  268. " enable virtio balloon device (default)\n", QEMU_ARCH_ALL)
  269. STEXI
  270. @item -balloon none
  271. @findex -balloon
  272. Disable balloon device.
  273. @item -balloon virtio[,addr=@var{addr}]
  274. Enable virtio balloon device (default), optionally with PCI address
  275. @var{addr}.
  276. ETEXI
  277. DEF("device", HAS_ARG, QEMU_OPTION_device,
  278. "-device driver[,prop[=value][,...]]\n"
  279. " add device (based on driver)\n"
  280. " prop=value,... sets driver properties\n"
  281. " use '-device help' to print all possible drivers\n"
  282. " use '-device driver,help' to print all possible properties\n",
  283. QEMU_ARCH_ALL)
  284. STEXI
  285. @item -device @var{driver}[,@var{prop}[=@var{value}][,...]]
  286. @findex -device
  287. Add device @var{driver}. @var{prop}=@var{value} sets driver
  288. properties. Valid properties depend on the driver. To get help on
  289. possible drivers and properties, use @code{-device help} and
  290. @code{-device @var{driver},help}.
  291. ETEXI
  292. DEF("name", HAS_ARG, QEMU_OPTION_name,
  293. "-name string1[,process=string2][,debug-threads=on|off]\n"
  294. " set the name of the guest\n"
  295. " string1 sets the window title and string2 the process name (on Linux)\n"
  296. " When debug-threads is enabled, individual threads are given a separate name (on Linux)\n"
  297. " NOTE: The thread names are for debugging and not a stable API.\n",
  298. QEMU_ARCH_ALL)
  299. STEXI
  300. @item -name @var{name}
  301. @findex -name
  302. Sets the @var{name} of the guest.
  303. This name will be displayed in the SDL window caption.
  304. The @var{name} will also be used for the VNC server.
  305. Also optionally set the top visible process name in Linux.
  306. Naming of individual threads can also be enabled on Linux to aid debugging.
  307. ETEXI
  308. DEF("uuid", HAS_ARG, QEMU_OPTION_uuid,
  309. "-uuid %08x-%04x-%04x-%04x-%012x\n"
  310. " specify machine UUID\n", QEMU_ARCH_ALL)
  311. STEXI
  312. @item -uuid @var{uuid}
  313. @findex -uuid
  314. Set system UUID.
  315. ETEXI
  316. STEXI
  317. @end table
  318. ETEXI
  319. DEFHEADING()
  320. DEFHEADING(Block device options:)
  321. STEXI
  322. @table @option
  323. ETEXI
  324. DEF("fda", HAS_ARG, QEMU_OPTION_fda,
  325. "-fda/-fdb file use 'file' as floppy disk 0/1 image\n", QEMU_ARCH_ALL)
  326. DEF("fdb", HAS_ARG, QEMU_OPTION_fdb, "", QEMU_ARCH_ALL)
  327. STEXI
  328. @item -fda @var{file}
  329. @item -fdb @var{file}
  330. @findex -fda
  331. @findex -fdb
  332. Use @var{file} as floppy disk 0/1 image (@pxref{disk_images}). You can
  333. use the host floppy by using @file{/dev/fd0} as filename (@pxref{host_drives}).
  334. ETEXI
  335. DEF("hda", HAS_ARG, QEMU_OPTION_hda,
  336. "-hda/-hdb file use 'file' as IDE hard disk 0/1 image\n", QEMU_ARCH_ALL)
  337. DEF("hdb", HAS_ARG, QEMU_OPTION_hdb, "", QEMU_ARCH_ALL)
  338. DEF("hdc", HAS_ARG, QEMU_OPTION_hdc,
  339. "-hdc/-hdd file use 'file' as IDE hard disk 2/3 image\n", QEMU_ARCH_ALL)
  340. DEF("hdd", HAS_ARG, QEMU_OPTION_hdd, "", QEMU_ARCH_ALL)
  341. STEXI
  342. @item -hda @var{file}
  343. @item -hdb @var{file}
  344. @item -hdc @var{file}
  345. @item -hdd @var{file}
  346. @findex -hda
  347. @findex -hdb
  348. @findex -hdc
  349. @findex -hdd
  350. Use @var{file} as hard disk 0, 1, 2 or 3 image (@pxref{disk_images}).
  351. ETEXI
  352. DEF("cdrom", HAS_ARG, QEMU_OPTION_cdrom,
  353. "-cdrom file use 'file' as IDE cdrom image (cdrom is ide1 master)\n",
  354. QEMU_ARCH_ALL)
  355. STEXI
  356. @item -cdrom @var{file}
  357. @findex -cdrom
  358. Use @var{file} as CD-ROM image (you cannot use @option{-hdc} and
  359. @option{-cdrom} at the same time). You can use the host CD-ROM by
  360. using @file{/dev/cdrom} as filename (@pxref{host_drives}).
  361. ETEXI
  362. DEF("drive", HAS_ARG, QEMU_OPTION_drive,
  363. "-drive [file=file][,if=type][,bus=n][,unit=m][,media=d][,index=i]\n"
  364. " [,cyls=c,heads=h,secs=s[,trans=t]][,snapshot=on|off]\n"
  365. " [,cache=writethrough|writeback|none|directsync|unsafe][,format=f]\n"
  366. " [,serial=s][,addr=A][,id=name][,aio=threads|native]\n"
  367. " [,readonly=on|off][,copy-on-read=on|off]\n"
  368. " [[,bps=b]|[[,bps_rd=r][,bps_wr=w]]]\n"
  369. " [[,iops=i]|[[,iops_rd=r][,iops_wr=w]]]\n"
  370. " [[,bps_max=bm]|[[,bps_rd_max=rm][,bps_wr_max=wm]]]\n"
  371. " [[,iops_max=im]|[[,iops_rd_max=irm][,iops_wr_max=iwm]]]\n"
  372. " [[,iops_size=is]]\n"
  373. " use 'file' as a drive image\n", QEMU_ARCH_ALL)
  374. STEXI
  375. @item -drive @var{option}[,@var{option}[,@var{option}[,...]]]
  376. @findex -drive
  377. Define a new drive. Valid options are:
  378. @table @option
  379. @item file=@var{file}
  380. This option defines which disk image (@pxref{disk_images}) to use with
  381. this drive. If the filename contains comma, you must double it
  382. (for instance, "file=my,,file" to use file "my,file").
  383. Special files such as iSCSI devices can be specified using protocol
  384. specific URLs. See the section for "Device URL Syntax" for more information.
  385. @item if=@var{interface}
  386. This option defines on which type on interface the drive is connected.
  387. Available types are: ide, scsi, sd, mtd, floppy, pflash, virtio.
  388. @item bus=@var{bus},unit=@var{unit}
  389. These options define where is connected the drive by defining the bus number and
  390. the unit id.
  391. @item index=@var{index}
  392. This option defines where is connected the drive by using an index in the list
  393. of available connectors of a given interface type.
  394. @item media=@var{media}
  395. This option defines the type of the media: disk or cdrom.
  396. @item cyls=@var{c},heads=@var{h},secs=@var{s}[,trans=@var{t}]
  397. These options have the same definition as they have in @option{-hdachs}.
  398. @item snapshot=@var{snapshot}
  399. @var{snapshot} is "on" or "off" and allows to enable snapshot for given drive (see @option{-snapshot}).
  400. @item cache=@var{cache}
  401. @var{cache} is "none", "writeback", "unsafe", "directsync" or "writethrough" and controls how the host cache is used to access block data.
  402. @item aio=@var{aio}
  403. @var{aio} is "threads", or "native" and selects between pthread based disk I/O and native Linux AIO.
  404. @item discard=@var{discard}
  405. @var{discard} is one of "ignore" (or "off") or "unmap" (or "on") and controls whether @dfn{discard} (also known as @dfn{trim} or @dfn{unmap}) requests are ignored or passed to the filesystem. Some machine types may not support discard requests.
  406. @item format=@var{format}
  407. Specify which disk @var{format} will be used rather than detecting
  408. the format. Can be used to specifiy format=raw to avoid interpreting
  409. an untrusted format header.
  410. @item serial=@var{serial}
  411. This option specifies the serial number to assign to the device.
  412. @item addr=@var{addr}
  413. Specify the controller's PCI address (if=virtio only).
  414. @item werror=@var{action},rerror=@var{action}
  415. Specify which @var{action} to take on write and read errors. Valid actions are:
  416. "ignore" (ignore the error and try to continue), "stop" (pause QEMU),
  417. "report" (report the error to the guest), "enospc" (pause QEMU only if the
  418. host disk is full; report the error to the guest otherwise).
  419. The default setting is @option{werror=enospc} and @option{rerror=report}.
  420. @item readonly
  421. Open drive @option{file} as read-only. Guest write attempts will fail.
  422. @item copy-on-read=@var{copy-on-read}
  423. @var{copy-on-read} is "on" or "off" and enables whether to copy read backing
  424. file sectors into the image file.
  425. @end table
  426. By default, the @option{cache=writeback} mode is used. It will report data
  427. writes as completed as soon as the data is present in the host page cache.
  428. This is safe as long as your guest OS makes sure to correctly flush disk caches
  429. where needed. If your guest OS does not handle volatile disk write caches
  430. correctly and your host crashes or loses power, then the guest may experience
  431. data corruption.
  432. For such guests, you should consider using @option{cache=writethrough}. This
  433. means that the host page cache will be used to read and write data, but write
  434. notification will be sent to the guest only after QEMU has made sure to flush
  435. each write to the disk. Be aware that this has a major impact on performance.
  436. The host page cache can be avoided entirely with @option{cache=none}. This will
  437. attempt to do disk IO directly to the guest's memory. QEMU may still perform
  438. an internal copy of the data. Note that this is considered a writeback mode and
  439. the guest OS must handle the disk write cache correctly in order to avoid data
  440. corruption on host crashes.
  441. The host page cache can be avoided while only sending write notifications to
  442. the guest when the data has been flushed to the disk using
  443. @option{cache=directsync}.
  444. In case you don't care about data integrity over host failures, use
  445. @option{cache=unsafe}. This option tells QEMU that it never needs to write any
  446. data to the disk but can instead keep things in cache. If anything goes wrong,
  447. like your host losing power, the disk storage getting disconnected accidentally,
  448. etc. your image will most probably be rendered unusable. When using
  449. the @option{-snapshot} option, unsafe caching is always used.
  450. Copy-on-read avoids accessing the same backing file sectors repeatedly and is
  451. useful when the backing file is over a slow network. By default copy-on-read
  452. is off.
  453. Instead of @option{-cdrom} you can use:
  454. @example
  455. qemu-system-i386 -drive file=file,index=2,media=cdrom
  456. @end example
  457. Instead of @option{-hda}, @option{-hdb}, @option{-hdc}, @option{-hdd}, you can
  458. use:
  459. @example
  460. qemu-system-i386 -drive file=file,index=0,media=disk
  461. qemu-system-i386 -drive file=file,index=1,media=disk
  462. qemu-system-i386 -drive file=file,index=2,media=disk
  463. qemu-system-i386 -drive file=file,index=3,media=disk
  464. @end example
  465. You can open an image using pre-opened file descriptors from an fd set:
  466. @example
  467. qemu-system-i386
  468. -add-fd fd=3,set=2,opaque="rdwr:/path/to/file"
  469. -add-fd fd=4,set=2,opaque="rdonly:/path/to/file"
  470. -drive file=/dev/fdset/2,index=0,media=disk
  471. @end example
  472. You can connect a CDROM to the slave of ide0:
  473. @example
  474. qemu-system-i386 -drive file=file,if=ide,index=1,media=cdrom
  475. @end example
  476. If you don't specify the "file=" argument, you define an empty drive:
  477. @example
  478. qemu-system-i386 -drive if=ide,index=1,media=cdrom
  479. @end example
  480. You can connect a SCSI disk with unit ID 6 on the bus #0:
  481. @example
  482. qemu-system-i386 -drive file=file,if=scsi,bus=0,unit=6
  483. @end example
  484. Instead of @option{-fda}, @option{-fdb}, you can use:
  485. @example
  486. qemu-system-i386 -drive file=file,index=0,if=floppy
  487. qemu-system-i386 -drive file=file,index=1,if=floppy
  488. @end example
  489. By default, @var{interface} is "ide" and @var{index} is automatically
  490. incremented:
  491. @example
  492. qemu-system-i386 -drive file=a -drive file=b"
  493. @end example
  494. is interpreted like:
  495. @example
  496. qemu-system-i386 -hda a -hdb b
  497. @end example
  498. ETEXI
  499. DEF("mtdblock", HAS_ARG, QEMU_OPTION_mtdblock,
  500. "-mtdblock file use 'file' as on-board Flash memory image\n",
  501. QEMU_ARCH_ALL)
  502. STEXI
  503. @item -mtdblock @var{file}
  504. @findex -mtdblock
  505. Use @var{file} as on-board Flash memory image.
  506. ETEXI
  507. DEF("sd", HAS_ARG, QEMU_OPTION_sd,
  508. "-sd file use 'file' as SecureDigital card image\n", QEMU_ARCH_ALL)
  509. STEXI
  510. @item -sd @var{file}
  511. @findex -sd
  512. Use @var{file} as SecureDigital card image.
  513. ETEXI
  514. DEF("pflash", HAS_ARG, QEMU_OPTION_pflash,
  515. "-pflash file use 'file' as a parallel flash image\n", QEMU_ARCH_ALL)
  516. STEXI
  517. @item -pflash @var{file}
  518. @findex -pflash
  519. Use @var{file} as a parallel flash image.
  520. ETEXI
  521. DEF("snapshot", 0, QEMU_OPTION_snapshot,
  522. "-snapshot write to temporary files instead of disk image files\n",
  523. QEMU_ARCH_ALL)
  524. STEXI
  525. @item -snapshot
  526. @findex -snapshot
  527. Write to temporary files instead of disk image files. In this case,
  528. the raw disk image you use is not written back. You can however force
  529. the write back by pressing @key{C-a s} (@pxref{disk_images}).
  530. ETEXI
  531. DEF("hdachs", HAS_ARG, QEMU_OPTION_hdachs, \
  532. "-hdachs c,h,s[,t]\n" \
  533. " force hard disk 0 physical geometry and the optional BIOS\n" \
  534. " translation (t=none or lba) (usually QEMU can guess them)\n",
  535. QEMU_ARCH_ALL)
  536. STEXI
  537. @item -hdachs @var{c},@var{h},@var{s},[,@var{t}]
  538. @findex -hdachs
  539. Force hard disk 0 physical geometry (1 <= @var{c} <= 16383, 1 <=
  540. @var{h} <= 16, 1 <= @var{s} <= 63) and optionally force the BIOS
  541. translation mode (@var{t}=none, lba or auto). Usually QEMU can guess
  542. all those parameters. This option is useful for old MS-DOS disk
  543. images.
  544. ETEXI
  545. DEF("fsdev", HAS_ARG, QEMU_OPTION_fsdev,
  546. "-fsdev fsdriver,id=id[,path=path,][security_model={mapped-xattr|mapped-file|passthrough|none}]\n"
  547. " [,writeout=immediate][,readonly][,socket=socket|sock_fd=sock_fd]\n",
  548. QEMU_ARCH_ALL)
  549. STEXI
  550. @item -fsdev @var{fsdriver},id=@var{id},path=@var{path},[security_model=@var{security_model}][,writeout=@var{writeout}][,readonly][,socket=@var{socket}|sock_fd=@var{sock_fd}]
  551. @findex -fsdev
  552. Define a new file system device. Valid options are:
  553. @table @option
  554. @item @var{fsdriver}
  555. This option specifies the fs driver backend to use.
  556. Currently "local", "handle" and "proxy" file system drivers are supported.
  557. @item id=@var{id}
  558. Specifies identifier for this device
  559. @item path=@var{path}
  560. Specifies the export path for the file system device. Files under
  561. this path will be available to the 9p client on the guest.
  562. @item security_model=@var{security_model}
  563. Specifies the security model to be used for this export path.
  564. Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
  565. In "passthrough" security model, files are stored using the same
  566. credentials as they are created on the guest. This requires QEMU
  567. to run as root. In "mapped-xattr" security model, some of the file
  568. attributes like uid, gid, mode bits and link target are stored as
  569. file attributes. For "mapped-file" these attributes are stored in the
  570. hidden .virtfs_metadata directory. Directories exported by this security model cannot
  571. interact with other unix tools. "none" security model is same as
  572. passthrough except the sever won't report failures if it fails to
  573. set file attributes like ownership. Security model is mandatory
  574. only for local fsdriver. Other fsdrivers (like handle, proxy) don't take
  575. security model as a parameter.
  576. @item writeout=@var{writeout}
  577. This is an optional argument. The only supported value is "immediate".
  578. This means that host page cache will be used to read and write data but
  579. write notification will be sent to the guest only when the data has been
  580. reported as written by the storage subsystem.
  581. @item readonly
  582. Enables exporting 9p share as a readonly mount for guests. By default
  583. read-write access is given.
  584. @item socket=@var{socket}
  585. Enables proxy filesystem driver to use passed socket file for communicating
  586. with virtfs-proxy-helper
  587. @item sock_fd=@var{sock_fd}
  588. Enables proxy filesystem driver to use passed socket descriptor for
  589. communicating with virtfs-proxy-helper. Usually a helper like libvirt
  590. will create socketpair and pass one of the fds as sock_fd
  591. @end table
  592. -fsdev option is used along with -device driver "virtio-9p-pci".
  593. @item -device virtio-9p-pci,fsdev=@var{id},mount_tag=@var{mount_tag}
  594. Options for virtio-9p-pci driver are:
  595. @table @option
  596. @item fsdev=@var{id}
  597. Specifies the id value specified along with -fsdev option
  598. @item mount_tag=@var{mount_tag}
  599. Specifies the tag name to be used by the guest to mount this export point
  600. @end table
  601. ETEXI
  602. DEF("virtfs", HAS_ARG, QEMU_OPTION_virtfs,
  603. "-virtfs local,path=path,mount_tag=tag,security_model=[mapped-xattr|mapped-file|passthrough|none]\n"
  604. " [,writeout=immediate][,readonly][,socket=socket|sock_fd=sock_fd]\n",
  605. QEMU_ARCH_ALL)
  606. STEXI
  607. @item -virtfs @var{fsdriver}[,path=@var{path}],mount_tag=@var{mount_tag}[,security_model=@var{security_model}][,writeout=@var{writeout}][,readonly][,socket=@var{socket}|sock_fd=@var{sock_fd}]
  608. @findex -virtfs
  609. The general form of a Virtual File system pass-through options are:
  610. @table @option
  611. @item @var{fsdriver}
  612. This option specifies the fs driver backend to use.
  613. Currently "local", "handle" and "proxy" file system drivers are supported.
  614. @item id=@var{id}
  615. Specifies identifier for this device
  616. @item path=@var{path}
  617. Specifies the export path for the file system device. Files under
  618. this path will be available to the 9p client on the guest.
  619. @item security_model=@var{security_model}
  620. Specifies the security model to be used for this export path.
  621. Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
  622. In "passthrough" security model, files are stored using the same
  623. credentials as they are created on the guest. This requires QEMU
  624. to run as root. In "mapped-xattr" security model, some of the file
  625. attributes like uid, gid, mode bits and link target are stored as
  626. file attributes. For "mapped-file" these attributes are stored in the
  627. hidden .virtfs_metadata directory. Directories exported by this security model cannot
  628. interact with other unix tools. "none" security model is same as
  629. passthrough except the sever won't report failures if it fails to
  630. set file attributes like ownership. Security model is mandatory only
  631. for local fsdriver. Other fsdrivers (like handle, proxy) don't take security
  632. model as a parameter.
  633. @item writeout=@var{writeout}
  634. This is an optional argument. The only supported value is "immediate".
  635. This means that host page cache will be used to read and write data but
  636. write notification will be sent to the guest only when the data has been
  637. reported as written by the storage subsystem.
  638. @item readonly
  639. Enables exporting 9p share as a readonly mount for guests. By default
  640. read-write access is given.
  641. @item socket=@var{socket}
  642. Enables proxy filesystem driver to use passed socket file for
  643. communicating with virtfs-proxy-helper. Usually a helper like libvirt
  644. will create socketpair and pass one of the fds as sock_fd
  645. @item sock_fd
  646. Enables proxy filesystem driver to use passed 'sock_fd' as the socket
  647. descriptor for interfacing with virtfs-proxy-helper
  648. @end table
  649. ETEXI
  650. DEF("virtfs_synth", 0, QEMU_OPTION_virtfs_synth,
  651. "-virtfs_synth Create synthetic file system image\n",
  652. QEMU_ARCH_ALL)
  653. STEXI
  654. @item -virtfs_synth
  655. @findex -virtfs_synth
  656. Create synthetic file system image
  657. ETEXI
  658. STEXI
  659. @end table
  660. ETEXI
  661. DEFHEADING()
  662. DEFHEADING(USB options:)
  663. STEXI
  664. @table @option
  665. ETEXI
  666. DEF("usb", 0, QEMU_OPTION_usb,
  667. "-usb enable the USB driver (will be the default soon)\n",
  668. QEMU_ARCH_ALL)
  669. STEXI
  670. @item -usb
  671. @findex -usb
  672. Enable the USB driver (will be the default soon)
  673. ETEXI
  674. DEF("usbdevice", HAS_ARG, QEMU_OPTION_usbdevice,
  675. "-usbdevice name add the host or guest USB device 'name'\n",
  676. QEMU_ARCH_ALL)
  677. STEXI
  678. @item -usbdevice @var{devname}
  679. @findex -usbdevice
  680. Add the USB device @var{devname}. @xref{usb_devices}.
  681. @table @option
  682. @item mouse
  683. Virtual Mouse. This will override the PS/2 mouse emulation when activated.
  684. @item tablet
  685. Pointer device that uses absolute coordinates (like a touchscreen). This
  686. means QEMU is able to report the mouse position without having to grab the
  687. mouse. Also overrides the PS/2 mouse emulation when activated.
  688. @item disk:[format=@var{format}]:@var{file}
  689. Mass storage device based on file. The optional @var{format} argument
  690. will be used rather than detecting the format. Can be used to specifiy
  691. @code{format=raw} to avoid interpreting an untrusted format header.
  692. @item host:@var{bus}.@var{addr}
  693. Pass through the host device identified by @var{bus}.@var{addr} (Linux only).
  694. @item host:@var{vendor_id}:@var{product_id}
  695. Pass through the host device identified by @var{vendor_id}:@var{product_id}
  696. (Linux only).
  697. @item serial:[vendorid=@var{vendor_id}][,productid=@var{product_id}]:@var{dev}
  698. Serial converter to host character device @var{dev}, see @code{-serial} for the
  699. available devices.
  700. @item braille
  701. Braille device. This will use BrlAPI to display the braille output on a real
  702. or fake device.
  703. @item net:@var{options}
  704. Network adapter that supports CDC ethernet and RNDIS protocols.
  705. @end table
  706. ETEXI
  707. STEXI
  708. @end table
  709. ETEXI
  710. DEFHEADING()
  711. DEFHEADING(Display options:)
  712. STEXI
  713. @table @option
  714. ETEXI
  715. DEF("display", HAS_ARG, QEMU_OPTION_display,
  716. "-display sdl[,frame=on|off][,alt_grab=on|off][,ctrl_grab=on|off]\n"
  717. " [,window_close=on|off]|curses|none|\n"
  718. " gtk[,grab_on_hover=on|off]|\n"
  719. " vnc=<display>[,<optargs>]\n"
  720. " select display type\n", QEMU_ARCH_ALL)
  721. STEXI
  722. @item -display @var{type}
  723. @findex -display
  724. Select type of display to use. This option is a replacement for the
  725. old style -sdl/-curses/... options. Valid values for @var{type} are
  726. @table @option
  727. @item sdl
  728. Display video output via SDL (usually in a separate graphics
  729. window; see the SDL documentation for other possibilities).
  730. @item curses
  731. Display video output via curses. For graphics device models which
  732. support a text mode, QEMU can display this output using a
  733. curses/ncurses interface. Nothing is displayed when the graphics
  734. device is in graphical mode or if the graphics device does not support
  735. a text mode. Generally only the VGA device models support text mode.
  736. @item none
  737. Do not display video output. The guest will still see an emulated
  738. graphics card, but its output will not be displayed to the QEMU
  739. user. This option differs from the -nographic option in that it
  740. only affects what is done with video output; -nographic also changes
  741. the destination of the serial and parallel port data.
  742. @item gtk
  743. Display video output in a GTK window. This interface provides drop-down
  744. menus and other UI elements to configure and control the VM during
  745. runtime.
  746. @item vnc
  747. Start a VNC server on display <arg>
  748. @end table
  749. ETEXI
  750. DEF("nographic", 0, QEMU_OPTION_nographic,
  751. "-nographic disable graphical output and redirect serial I/Os to console\n",
  752. QEMU_ARCH_ALL)
  753. STEXI
  754. @item -nographic
  755. @findex -nographic
  756. Normally, QEMU uses SDL to display the VGA output. With this option,
  757. you can totally disable graphical output so that QEMU is a simple
  758. command line application. The emulated serial port is redirected on
  759. the console and muxed with the monitor (unless redirected elsewhere
  760. explicitly). Therefore, you can still use QEMU to debug a Linux kernel
  761. with a serial console. Use @key{C-a h} for help on switching between
  762. the console and monitor.
  763. ETEXI
  764. DEF("curses", 0, QEMU_OPTION_curses,
  765. "-curses use a curses/ncurses interface instead of SDL\n",
  766. QEMU_ARCH_ALL)
  767. STEXI
  768. @item -curses
  769. @findex -curses
  770. Normally, QEMU uses SDL to display the VGA output. With this option,
  771. QEMU can display the VGA output when in text mode using a
  772. curses/ncurses interface. Nothing is displayed in graphical mode.
  773. ETEXI
  774. DEF("no-frame", 0, QEMU_OPTION_no_frame,
  775. "-no-frame open SDL window without a frame and window decorations\n",
  776. QEMU_ARCH_ALL)
  777. STEXI
  778. @item -no-frame
  779. @findex -no-frame
  780. Do not use decorations for SDL windows and start them using the whole
  781. available screen space. This makes the using QEMU in a dedicated desktop
  782. workspace more convenient.
  783. ETEXI
  784. DEF("alt-grab", 0, QEMU_OPTION_alt_grab,
  785. "-alt-grab use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt)\n",
  786. QEMU_ARCH_ALL)
  787. STEXI
  788. @item -alt-grab
  789. @findex -alt-grab
  790. Use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt). Note that this also
  791. affects the special keys (for fullscreen, monitor-mode switching, etc).
  792. ETEXI
  793. DEF("ctrl-grab", 0, QEMU_OPTION_ctrl_grab,
  794. "-ctrl-grab use Right-Ctrl to grab mouse (instead of Ctrl-Alt)\n",
  795. QEMU_ARCH_ALL)
  796. STEXI
  797. @item -ctrl-grab
  798. @findex -ctrl-grab
  799. Use Right-Ctrl to grab mouse (instead of Ctrl-Alt). Note that this also
  800. affects the special keys (for fullscreen, monitor-mode switching, etc).
  801. ETEXI
  802. DEF("no-quit", 0, QEMU_OPTION_no_quit,
  803. "-no-quit disable SDL window close capability\n", QEMU_ARCH_ALL)
  804. STEXI
  805. @item -no-quit
  806. @findex -no-quit
  807. Disable SDL window close capability.
  808. ETEXI
  809. DEF("sdl", 0, QEMU_OPTION_sdl,
  810. "-sdl enable SDL\n", QEMU_ARCH_ALL)
  811. STEXI
  812. @item -sdl
  813. @findex -sdl
  814. Enable SDL.
  815. ETEXI
  816. DEF("spice", HAS_ARG, QEMU_OPTION_spice,
  817. "-spice [port=port][,tls-port=secured-port][,x509-dir=<dir>]\n"
  818. " [,x509-key-file=<file>][,x509-key-password=<file>]\n"
  819. " [,x509-cert-file=<file>][,x509-cacert-file=<file>]\n"
  820. " [,x509-dh-key-file=<file>][,addr=addr][,ipv4|ipv6]\n"
  821. " [,tls-ciphers=<list>]\n"
  822. " [,tls-channel=[main|display|cursor|inputs|record|playback]]\n"
  823. " [,plaintext-channel=[main|display|cursor|inputs|record|playback]]\n"
  824. " [,sasl][,password=<secret>][,disable-ticketing]\n"
  825. " [,image-compression=[auto_glz|auto_lz|quic|glz|lz|off]]\n"
  826. " [,jpeg-wan-compression=[auto|never|always]]\n"
  827. " [,zlib-glz-wan-compression=[auto|never|always]]\n"
  828. " [,streaming-video=[off|all|filter]][,disable-copy-paste]\n"
  829. " [,disable-agent-file-xfer][,agent-mouse=[on|off]]\n"
  830. " [,playback-compression=[on|off]][,seamless-migration=[on|off]]\n"
  831. " enable spice\n"
  832. " at least one of {port, tls-port} is mandatory\n",
  833. QEMU_ARCH_ALL)
  834. STEXI
  835. @item -spice @var{option}[,@var{option}[,...]]
  836. @findex -spice
  837. Enable the spice remote desktop protocol. Valid options are
  838. @table @option
  839. @item port=<nr>
  840. Set the TCP port spice is listening on for plaintext channels.
  841. @item addr=<addr>
  842. Set the IP address spice is listening on. Default is any address.
  843. @item ipv4
  844. @item ipv6
  845. Force using the specified IP version.
  846. @item password=<secret>
  847. Set the password you need to authenticate.
  848. @item sasl
  849. Require that the client use SASL to authenticate with the spice.
  850. The exact choice of authentication method used is controlled from the
  851. system / user's SASL configuration file for the 'qemu' service. This
  852. is typically found in /etc/sasl2/qemu.conf. If running QEMU as an
  853. unprivileged user, an environment variable SASL_CONF_PATH can be used
  854. to make it search alternate locations for the service config.
  855. While some SASL auth methods can also provide data encryption (eg GSSAPI),
  856. it is recommended that SASL always be combined with the 'tls' and
  857. 'x509' settings to enable use of SSL and server certificates. This
  858. ensures a data encryption preventing compromise of authentication
  859. credentials.
  860. @item disable-ticketing
  861. Allow client connects without authentication.
  862. @item disable-copy-paste
  863. Disable copy paste between the client and the guest.
  864. @item disable-agent-file-xfer
  865. Disable spice-vdagent based file-xfer between the client and the guest.
  866. @item tls-port=<nr>
  867. Set the TCP port spice is listening on for encrypted channels.
  868. @item x509-dir=<dir>
  869. Set the x509 file directory. Expects same filenames as -vnc $display,x509=$dir
  870. @item x509-key-file=<file>
  871. @item x509-key-password=<file>
  872. @item x509-cert-file=<file>
  873. @item x509-cacert-file=<file>
  874. @item x509-dh-key-file=<file>
  875. The x509 file names can also be configured individually.
  876. @item tls-ciphers=<list>
  877. Specify which ciphers to use.
  878. @item tls-channel=[main|display|cursor|inputs|record|playback]
  879. @item plaintext-channel=[main|display|cursor|inputs|record|playback]
  880. Force specific channel to be used with or without TLS encryption. The
  881. options can be specified multiple times to configure multiple
  882. channels. The special name "default" can be used to set the default
  883. mode. For channels which are not explicitly forced into one mode the
  884. spice client is allowed to pick tls/plaintext as he pleases.
  885. @item image-compression=[auto_glz|auto_lz|quic|glz|lz|off]
  886. Configure image compression (lossless).
  887. Default is auto_glz.
  888. @item jpeg-wan-compression=[auto|never|always]
  889. @item zlib-glz-wan-compression=[auto|never|always]
  890. Configure wan image compression (lossy for slow links).
  891. Default is auto.
  892. @item streaming-video=[off|all|filter]
  893. Configure video stream detection. Default is filter.
  894. @item agent-mouse=[on|off]
  895. Enable/disable passing mouse events via vdagent. Default is on.
  896. @item playback-compression=[on|off]
  897. Enable/disable audio stream compression (using celt 0.5.1). Default is on.
  898. @item seamless-migration=[on|off]
  899. Enable/disable spice seamless migration. Default is off.
  900. @end table
  901. ETEXI
  902. DEF("portrait", 0, QEMU_OPTION_portrait,
  903. "-portrait rotate graphical output 90 deg left (only PXA LCD)\n",
  904. QEMU_ARCH_ALL)
  905. STEXI
  906. @item -portrait
  907. @findex -portrait
  908. Rotate graphical output 90 deg left (only PXA LCD).
  909. ETEXI
  910. DEF("rotate", HAS_ARG, QEMU_OPTION_rotate,
  911. "-rotate <deg> rotate graphical output some deg left (only PXA LCD)\n",
  912. QEMU_ARCH_ALL)
  913. STEXI
  914. @item -rotate @var{deg}
  915. @findex -rotate
  916. Rotate graphical output some deg left (only PXA LCD).
  917. ETEXI
  918. DEF("vga", HAS_ARG, QEMU_OPTION_vga,
  919. "-vga [std|cirrus|vmware|qxl|xenfb|tcx|cg3|none]\n"
  920. " select video card type\n", QEMU_ARCH_ALL)
  921. STEXI
  922. @item -vga @var{type}
  923. @findex -vga
  924. Select type of VGA card to emulate. Valid values for @var{type} are
  925. @table @option
  926. @item cirrus
  927. Cirrus Logic GD5446 Video card. All Windows versions starting from
  928. Windows 95 should recognize and use this graphic card. For optimal
  929. performances, use 16 bit color depth in the guest and the host OS.
  930. (This one is the default)
  931. @item std
  932. Standard VGA card with Bochs VBE extensions. If your guest OS
  933. supports the VESA 2.0 VBE extensions (e.g. Windows XP) and if you want
  934. to use high resolution modes (>= 1280x1024x16) then you should use
  935. this option.
  936. @item vmware
  937. VMWare SVGA-II compatible adapter. Use it if you have sufficiently
  938. recent XFree86/XOrg server or Windows guest with a driver for this
  939. card.
  940. @item qxl
  941. QXL paravirtual graphic card. It is VGA compatible (including VESA
  942. 2.0 VBE support). Works best with qxl guest drivers installed though.
  943. Recommended choice when using the spice protocol.
  944. @item tcx
  945. (sun4m only) Sun TCX framebuffer. This is the default framebuffer for
  946. sun4m machines and offers both 8-bit and 24-bit colour depths at a
  947. fixed resolution of 1024x768.
  948. @item cg3
  949. (sun4m only) Sun cgthree framebuffer. This is a simple 8-bit framebuffer
  950. for sun4m machines available in both 1024x768 (OpenBIOS) and 1152x900 (OBP)
  951. resolutions aimed at people wishing to run older Solaris versions.
  952. @item none
  953. Disable VGA card.
  954. @end table
  955. ETEXI
  956. DEF("full-screen", 0, QEMU_OPTION_full_screen,
  957. "-full-screen start in full screen\n", QEMU_ARCH_ALL)
  958. STEXI
  959. @item -full-screen
  960. @findex -full-screen
  961. Start in full screen.
  962. ETEXI
  963. DEF("g", 1, QEMU_OPTION_g ,
  964. "-g WxH[xDEPTH] Set the initial graphical resolution and depth\n",
  965. QEMU_ARCH_PPC | QEMU_ARCH_SPARC)
  966. STEXI
  967. @item -g @var{width}x@var{height}[x@var{depth}]
  968. @findex -g
  969. Set the initial graphical resolution and depth (PPC, SPARC only).
  970. ETEXI
  971. DEF("vnc", HAS_ARG, QEMU_OPTION_vnc ,
  972. "-vnc display start a VNC server on display\n", QEMU_ARCH_ALL)
  973. STEXI
  974. @item -vnc @var{display}[,@var{option}[,@var{option}[,...]]]
  975. @findex -vnc
  976. Normally, QEMU uses SDL to display the VGA output. With this option,
  977. you can have QEMU listen on VNC display @var{display} and redirect the VGA
  978. display over the VNC session. It is very useful to enable the usb
  979. tablet device when using this option (option @option{-usbdevice
  980. tablet}). When using the VNC display, you must use the @option{-k}
  981. parameter to set the keyboard layout if you are not using en-us. Valid
  982. syntax for the @var{display} is
  983. @table @option
  984. @item @var{host}:@var{d}
  985. TCP connections will only be allowed from @var{host} on display @var{d}.
  986. By convention the TCP port is 5900+@var{d}. Optionally, @var{host} can
  987. be omitted in which case the server will accept connections from any host.
  988. @item unix:@var{path}
  989. Connections will be allowed over UNIX domain sockets where @var{path} is the
  990. location of a unix socket to listen for connections on.
  991. @item none
  992. VNC is initialized but not started. The monitor @code{change} command
  993. can be used to later start the VNC server.
  994. @end table
  995. Following the @var{display} value there may be one or more @var{option} flags
  996. separated by commas. Valid options are
  997. @table @option
  998. @item reverse
  999. Connect to a listening VNC client via a ``reverse'' connection. The
  1000. client is specified by the @var{display}. For reverse network
  1001. connections (@var{host}:@var{d},@code{reverse}), the @var{d} argument
  1002. is a TCP port number, not a display number.
  1003. @item websocket
  1004. Opens an additional TCP listening port dedicated to VNC Websocket connections.
  1005. By definition the Websocket port is 5700+@var{display}. If @var{host} is
  1006. specified connections will only be allowed from this host.
  1007. As an alternative the Websocket port could be specified by using
  1008. @code{websocket}=@var{port}.
  1009. TLS encryption for the Websocket connection is supported if the required
  1010. certificates are specified with the VNC option @option{x509}.
  1011. @item password
  1012. Require that password based authentication is used for client connections.
  1013. The password must be set separately using the @code{set_password} command in
  1014. the @ref{pcsys_monitor}. The syntax to change your password is:
  1015. @code{set_password <protocol> <password>} where <protocol> could be either
  1016. "vnc" or "spice".
  1017. If you would like to change <protocol> password expiration, you should use
  1018. @code{expire_password <protocol> <expiration-time>} where expiration time could
  1019. be one of the following options: now, never, +seconds or UNIX time of
  1020. expiration, e.g. +60 to make password expire in 60 seconds, or 1335196800
  1021. to make password expire on "Mon Apr 23 12:00:00 EDT 2012" (UNIX time for this
  1022. date and time).
  1023. You can also use keywords "now" or "never" for the expiration time to
  1024. allow <protocol> password to expire immediately or never expire.
  1025. @item tls
  1026. Require that client use TLS when communicating with the VNC server. This
  1027. uses anonymous TLS credentials so is susceptible to a man-in-the-middle
  1028. attack. It is recommended that this option be combined with either the
  1029. @option{x509} or @option{x509verify} options.
  1030. @item x509=@var{/path/to/certificate/dir}
  1031. Valid if @option{tls} is specified. Require that x509 credentials are used
  1032. for negotiating the TLS session. The server will send its x509 certificate
  1033. to the client. It is recommended that a password be set on the VNC server
  1034. to provide authentication of the client when this is used. The path following
  1035. this option specifies where the x509 certificates are to be loaded from.
  1036. See the @ref{vnc_security} section for details on generating certificates.
  1037. @item x509verify=@var{/path/to/certificate/dir}
  1038. Valid if @option{tls} is specified. Require that x509 credentials are used
  1039. for negotiating the TLS session. The server will send its x509 certificate
  1040. to the client, and request that the client send its own x509 certificate.
  1041. The server will validate the client's certificate against the CA certificate,
  1042. and reject clients when validation fails. If the certificate authority is
  1043. trusted, this is a sufficient authentication mechanism. You may still wish
  1044. to set a password on the VNC server as a second authentication layer. The
  1045. path following this option specifies where the x509 certificates are to
  1046. be loaded from. See the @ref{vnc_security} section for details on generating
  1047. certificates.
  1048. @item sasl
  1049. Require that the client use SASL to authenticate with the VNC server.
  1050. The exact choice of authentication method used is controlled from the
  1051. system / user's SASL configuration file for the 'qemu' service. This
  1052. is typically found in /etc/sasl2/qemu.conf. If running QEMU as an
  1053. unprivileged user, an environment variable SASL_CONF_PATH can be used
  1054. to make it search alternate locations for the service config.
  1055. While some SASL auth methods can also provide data encryption (eg GSSAPI),
  1056. it is recommended that SASL always be combined with the 'tls' and
  1057. 'x509' settings to enable use of SSL and server certificates. This
  1058. ensures a data encryption preventing compromise of authentication
  1059. credentials. See the @ref{vnc_security} section for details on using
  1060. SASL authentication.
  1061. @item acl
  1062. Turn on access control lists for checking of the x509 client certificate
  1063. and SASL party. For x509 certs, the ACL check is made against the
  1064. certificate's distinguished name. This is something that looks like
  1065. @code{C=GB,O=ACME,L=Boston,CN=bob}. For SASL party, the ACL check is
  1066. made against the username, which depending on the SASL plugin, may
  1067. include a realm component, eg @code{bob} or @code{bob@@EXAMPLE.COM}.
  1068. When the @option{acl} flag is set, the initial access list will be
  1069. empty, with a @code{deny} policy. Thus no one will be allowed to
  1070. use the VNC server until the ACLs have been loaded. This can be
  1071. achieved using the @code{acl} monitor command.
  1072. @item lossy
  1073. Enable lossy compression methods (gradient, JPEG, ...). If this
  1074. option is set, VNC client may receive lossy framebuffer updates
  1075. depending on its encoding settings. Enabling this option can save
  1076. a lot of bandwidth at the expense of quality.
  1077. @item non-adaptive
  1078. Disable adaptive encodings. Adaptive encodings are enabled by default.
  1079. An adaptive encoding will try to detect frequently updated screen regions,
  1080. and send updates in these regions using a lossy encoding (like JPEG).
  1081. This can be really helpful to save bandwidth when playing videos. Disabling
  1082. adaptive encodings allows to restore the original static behavior of encodings
  1083. like Tight.
  1084. @item share=[allow-exclusive|force-shared|ignore]
  1085. Set display sharing policy. 'allow-exclusive' allows clients to ask
  1086. for exclusive access. As suggested by the rfb spec this is
  1087. implemented by dropping other connections. Connecting multiple
  1088. clients in parallel requires all clients asking for a shared session
  1089. (vncviewer: -shared switch). This is the default. 'force-shared'
  1090. disables exclusive client access. Useful for shared desktop sessions,
  1091. where you don't want someone forgetting specify -shared disconnect
  1092. everybody else. 'ignore' completely ignores the shared flag and
  1093. allows everybody connect unconditionally. Doesn't conform to the rfb
  1094. spec but is traditional QEMU behavior.
  1095. @end table
  1096. ETEXI
  1097. STEXI
  1098. @end table
  1099. ETEXI
  1100. ARCHHEADING(, QEMU_ARCH_I386)
  1101. ARCHHEADING(i386 target only:, QEMU_ARCH_I386)
  1102. STEXI
  1103. @table @option
  1104. ETEXI
  1105. DEF("win2k-hack", 0, QEMU_OPTION_win2k_hack,
  1106. "-win2k-hack use it when installing Windows 2000 to avoid a disk full bug\n",
  1107. QEMU_ARCH_I386)
  1108. STEXI
  1109. @item -win2k-hack
  1110. @findex -win2k-hack
  1111. Use it when installing Windows 2000 to avoid a disk full bug. After
  1112. Windows 2000 is installed, you no longer need this option (this option
  1113. slows down the IDE transfers).
  1114. ETEXI
  1115. HXCOMM Deprecated by -rtc
  1116. DEF("rtc-td-hack", 0, QEMU_OPTION_rtc_td_hack, "", QEMU_ARCH_I386)
  1117. DEF("no-fd-bootchk", 0, QEMU_OPTION_no_fd_bootchk,
  1118. "-no-fd-bootchk disable boot signature checking for floppy disks\n",
  1119. QEMU_ARCH_I386)
  1120. STEXI
  1121. @item -no-fd-bootchk
  1122. @findex -no-fd-bootchk
  1123. Disable boot signature checking for floppy disks in BIOS. May
  1124. be needed to boot from old floppy disks.
  1125. ETEXI
  1126. DEF("no-acpi", 0, QEMU_OPTION_no_acpi,
  1127. "-no-acpi disable ACPI\n", QEMU_ARCH_I386)
  1128. STEXI
  1129. @item -no-acpi
  1130. @findex -no-acpi
  1131. Disable ACPI (Advanced Configuration and Power Interface) support. Use
  1132. it if your guest OS complains about ACPI problems (PC target machine
  1133. only).
  1134. ETEXI
  1135. DEF("no-hpet", 0, QEMU_OPTION_no_hpet,
  1136. "-no-hpet disable HPET\n", QEMU_ARCH_I386)
  1137. STEXI
  1138. @item -no-hpet
  1139. @findex -no-hpet
  1140. Disable HPET support.
  1141. ETEXI
  1142. DEF("acpitable", HAS_ARG, QEMU_OPTION_acpitable,
  1143. "-acpitable [sig=str][,rev=n][,oem_id=str][,oem_table_id=str][,oem_rev=n][,asl_compiler_id=str][,asl_compiler_rev=n][,{data|file}=file1[:file2]...]\n"
  1144. " ACPI table description\n", QEMU_ARCH_I386)
  1145. STEXI
  1146. @item -acpitable [sig=@var{str}][,rev=@var{n}][,oem_id=@var{str}][,oem_table_id=@var{str}][,oem_rev=@var{n}] [,asl_compiler_id=@var{str}][,asl_compiler_rev=@var{n}][,data=@var{file1}[:@var{file2}]...]
  1147. @findex -acpitable
  1148. Add ACPI table with specified header fields and context from specified files.
  1149. For file=, take whole ACPI table from the specified files, including all
  1150. ACPI headers (possible overridden by other options).
  1151. For data=, only data
  1152. portion of the table is used, all header information is specified in the
  1153. command line.
  1154. ETEXI
  1155. DEF("smbios", HAS_ARG, QEMU_OPTION_smbios,
  1156. "-smbios file=binary\n"
  1157. " load SMBIOS entry from binary file\n"
  1158. "-smbios type=0[,vendor=str][,version=str][,date=str][,release=%d.%d]\n"
  1159. " specify SMBIOS type 0 fields\n"
  1160. "-smbios type=1[,manufacturer=str][,product=str][,version=str][,serial=str]\n"
  1161. " [,uuid=uuid][,sku=str][,family=str]\n"
  1162. " specify SMBIOS type 1 fields\n", QEMU_ARCH_I386)
  1163. STEXI
  1164. @item -smbios file=@var{binary}
  1165. @findex -smbios
  1166. Load SMBIOS entry from binary file.
  1167. @item -smbios type=0[,vendor=@var{str}][,version=@var{str}][,date=@var{str}][,release=@var{%d.%d}]
  1168. Specify SMBIOS type 0 fields
  1169. @item -smbios type=1[,manufacturer=@var{str}][,product=@var{str}] [,version=@var{str}][,serial=@var{str}][,uuid=@var{uuid}][,sku=@var{str}] [,family=@var{str}]
  1170. Specify SMBIOS type 1 fields
  1171. ETEXI
  1172. STEXI
  1173. @end table
  1174. ETEXI
  1175. DEFHEADING()
  1176. DEFHEADING(Network options:)
  1177. STEXI
  1178. @table @option
  1179. ETEXI
  1180. HXCOMM Legacy slirp options (now moved to -net user):
  1181. #ifdef CONFIG_SLIRP
  1182. DEF("tftp", HAS_ARG, QEMU_OPTION_tftp, "", QEMU_ARCH_ALL)
  1183. DEF("bootp", HAS_ARG, QEMU_OPTION_bootp, "", QEMU_ARCH_ALL)
  1184. DEF("redir", HAS_ARG, QEMU_OPTION_redir, "", QEMU_ARCH_ALL)
  1185. #ifndef _WIN32
  1186. DEF("smb", HAS_ARG, QEMU_OPTION_smb, "", QEMU_ARCH_ALL)
  1187. #endif
  1188. #endif
  1189. DEF("net", HAS_ARG, QEMU_OPTION_net,
  1190. "-net nic[,vlan=n][,macaddr=mac][,model=type][,name=str][,addr=str][,vectors=v]\n"
  1191. " create a new Network Interface Card and connect it to VLAN 'n'\n"
  1192. #ifdef CONFIG_SLIRP
  1193. "-net user[,vlan=n][,name=str][,net=addr[/mask]][,host=addr][,restrict=on|off]\n"
  1194. " [,hostname=host][,dhcpstart=addr][,dns=addr][,dnssearch=domain][,tftp=dir]\n"
  1195. " [,bootfile=f][,hostfwd=rule][,guestfwd=rule]"
  1196. #ifndef _WIN32
  1197. "[,smb=dir[,smbserver=addr]]\n"
  1198. #endif
  1199. " connect the user mode network stack to VLAN 'n', configure its\n"
  1200. " DHCP server and enabled optional services\n"
  1201. #endif
  1202. #ifdef _WIN32
  1203. "-net tap[,vlan=n][,name=str],ifname=name\n"
  1204. " connect the host TAP network interface to VLAN 'n'\n"
  1205. #else
  1206. "-net tap[,vlan=n][,name=str][,fd=h][,fds=x:y:...:z][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostfds=x:y:...:z][,vhostforce=on|off][,queues=n]\n"
  1207. " connect the host TAP network interface to VLAN 'n'\n"
  1208. " use network scripts 'file' (default=" DEFAULT_NETWORK_SCRIPT ")\n"
  1209. " to configure it and 'dfile' (default=" DEFAULT_NETWORK_DOWN_SCRIPT ")\n"
  1210. " to deconfigure it\n"
  1211. " use '[down]script=no' to disable script execution\n"
  1212. " use network helper 'helper' (default=" DEFAULT_BRIDGE_HELPER ") to\n"
  1213. " configure it\n"
  1214. " use 'fd=h' to connect to an already opened TAP interface\n"
  1215. " use 'fds=x:y:...:z' to connect to already opened multiqueue capable TAP interfaces\n"
  1216. " use 'sndbuf=nbytes' to limit the size of the send buffer (the\n"
  1217. " default is disabled 'sndbuf=0' to enable flow control set 'sndbuf=1048576')\n"
  1218. " use vnet_hdr=off to avoid enabling the IFF_VNET_HDR tap flag\n"
  1219. " use vnet_hdr=on to make the lack of IFF_VNET_HDR support an error condition\n"
  1220. " use vhost=on to enable experimental in kernel accelerator\n"
  1221. " (only has effect for virtio guests which use MSIX)\n"
  1222. " use vhostforce=on to force vhost on for non-MSIX virtio guests\n"
  1223. " use 'vhostfd=h' to connect to an already opened vhost net device\n"
  1224. " use 'vhostfds=x:y:...:z to connect to multiple already opened vhost net devices\n"
  1225. " use 'queues=n' to specify the number of queues to be created for multiqueue TAP\n"
  1226. "-net bridge[,vlan=n][,name=str][,br=bridge][,helper=helper]\n"
  1227. " connects a host TAP network interface to a host bridge device 'br'\n"
  1228. " (default=" DEFAULT_BRIDGE_INTERFACE ") using the program 'helper'\n"
  1229. " (default=" DEFAULT_BRIDGE_HELPER ")\n"
  1230. #endif
  1231. "-net socket[,vlan=n][,name=str][,fd=h][,listen=[host]:port][,connect=host:port]\n"
  1232. " connect the vlan 'n' to another VLAN using a socket connection\n"
  1233. "-net socket[,vlan=n][,name=str][,fd=h][,mcast=maddr:port[,localaddr=addr]]\n"
  1234. " connect the vlan 'n' to multicast maddr and port\n"
  1235. " use 'localaddr=addr' to specify the host address to send packets from\n"
  1236. "-net socket[,vlan=n][,name=str][,fd=h][,udp=host:port][,localaddr=host:port]\n"
  1237. " connect the vlan 'n' to another VLAN using an UDP tunnel\n"
  1238. #ifdef CONFIG_VDE
  1239. "-net vde[,vlan=n][,name=str][,sock=socketpath][,port=n][,group=groupname][,mode=octalmode]\n"
  1240. " connect the vlan 'n' to port 'n' of a vde switch running\n"
  1241. " on host and listening for incoming connections on 'socketpath'.\n"
  1242. " Use group 'groupname' and mode 'octalmode' to change default\n"
  1243. " ownership and permissions for communication port.\n"
  1244. #endif
  1245. #ifdef CONFIG_NETMAP
  1246. "-net netmap,ifname=name[,devname=nmname]\n"
  1247. " attach to the existing netmap-enabled network interface 'name', or to a\n"
  1248. " VALE port (created on the fly) called 'name' ('nmname' is name of the \n"
  1249. " netmap device, defaults to '/dev/netmap')\n"
  1250. #endif
  1251. "-net dump[,vlan=n][,file=f][,len=n]\n"
  1252. " dump traffic on vlan 'n' to file 'f' (max n bytes per packet)\n"
  1253. "-net none use it alone to have zero network devices. If no -net option\n"
  1254. " is provided, the default is '-net nic -net user'\n", QEMU_ARCH_ALL)
  1255. DEF("netdev", HAS_ARG, QEMU_OPTION_netdev,
  1256. "-netdev ["
  1257. #ifdef CONFIG_SLIRP
  1258. "user|"
  1259. #endif
  1260. "tap|"
  1261. "bridge|"
  1262. #ifdef CONFIG_VDE
  1263. "vde|"
  1264. #endif
  1265. #ifdef CONFIG_NETMAP
  1266. "netmap|"
  1267. #endif
  1268. "socket|"
  1269. "hubport],id=str[,option][,option][,...]\n", QEMU_ARCH_ALL)
  1270. STEXI
  1271. @item -net nic[,vlan=@var{n}][,macaddr=@var{mac}][,model=@var{type}] [,name=@var{name}][,addr=@var{addr}][,vectors=@var{v}]
  1272. @findex -net
  1273. Create a new Network Interface Card and connect it to VLAN @var{n} (@var{n}
  1274. = 0 is the default). The NIC is an e1000 by default on the PC
  1275. target. Optionally, the MAC address can be changed to @var{mac}, the
  1276. device address set to @var{addr} (PCI cards only),
  1277. and a @var{name} can be assigned for use in monitor commands.
  1278. Optionally, for PCI cards, you can specify the number @var{v} of MSI-X vectors
  1279. that the card should have; this option currently only affects virtio cards; set
  1280. @var{v} = 0 to disable MSI-X. If no @option{-net} option is specified, a single
  1281. NIC is created. QEMU can emulate several different models of network card.
  1282. Valid values for @var{type} are
  1283. @code{virtio}, @code{i82551}, @code{i82557b}, @code{i82559er},
  1284. @code{ne2k_pci}, @code{ne2k_isa}, @code{pcnet}, @code{rtl8139},
  1285. @code{e1000}, @code{smc91c111}, @code{lance} and @code{mcf_fec}.
  1286. Not all devices are supported on all targets. Use @code{-net nic,model=help}
  1287. for a list of available devices for your target.
  1288. @item -netdev user,id=@var{id}[,@var{option}][,@var{option}][,...]
  1289. @findex -netdev
  1290. @item -net user[,@var{option}][,@var{option}][,...]
  1291. Use the user mode network stack which requires no administrator
  1292. privilege to run. Valid options are:
  1293. @table @option
  1294. @item vlan=@var{n}
  1295. Connect user mode stack to VLAN @var{n} (@var{n} = 0 is the default).
  1296. @item id=@var{id}
  1297. @item name=@var{name}
  1298. Assign symbolic name for use in monitor commands.
  1299. @item net=@var{addr}[/@var{mask}]
  1300. Set IP network address the guest will see. Optionally specify the netmask,
  1301. either in the form a.b.c.d or as number of valid top-most bits. Default is
  1302. 10.0.2.0/24.
  1303. @item host=@var{addr}
  1304. Specify the guest-visible address of the host. Default is the 2nd IP in the
  1305. guest network, i.e. x.x.x.2.
  1306. @item restrict=on|off
  1307. If this option is enabled, the guest will be isolated, i.e. it will not be
  1308. able to contact the host and no guest IP packets will be routed over the host
  1309. to the outside. This option does not affect any explicitly set forwarding rules.
  1310. @item hostname=@var{name}
  1311. Specifies the client hostname reported by the built-in DHCP server.
  1312. @item dhcpstart=@var{addr}
  1313. Specify the first of the 16 IPs the built-in DHCP server can assign. Default
  1314. is the 15th to 31st IP in the guest network, i.e. x.x.x.15 to x.x.x.31.
  1315. @item dns=@var{addr}
  1316. Specify the guest-visible address of the virtual nameserver. The address must
  1317. be different from the host address. Default is the 3rd IP in the guest network,
  1318. i.e. x.x.x.3.
  1319. @item dnssearch=@var{domain}
  1320. Provides an entry for the domain-search list sent by the built-in
  1321. DHCP server. More than one domain suffix can be transmitted by specifying
  1322. this option multiple times. If supported, this will cause the guest to
  1323. automatically try to append the given domain suffix(es) in case a domain name
  1324. can not be resolved.
  1325. Example:
  1326. @example
  1327. qemu -net user,dnssearch=mgmt.example.org,dnssearch=example.org [...]
  1328. @end example
  1329. @item tftp=@var{dir}
  1330. When using the user mode network stack, activate a built-in TFTP
  1331. server. The files in @var{dir} will be exposed as the root of a TFTP server.
  1332. The TFTP client on the guest must be configured in binary mode (use the command
  1333. @code{bin} of the Unix TFTP client).
  1334. @item bootfile=@var{file}
  1335. When using the user mode network stack, broadcast @var{file} as the BOOTP
  1336. filename. In conjunction with @option{tftp}, this can be used to network boot
  1337. a guest from a local directory.
  1338. Example (using pxelinux):
  1339. @example
  1340. qemu-system-i386 -hda linux.img -boot n -net user,tftp=/path/to/tftp/files,bootfile=/pxelinux.0
  1341. @end example
  1342. @item smb=@var{dir}[,smbserver=@var{addr}]
  1343. When using the user mode network stack, activate a built-in SMB
  1344. server so that Windows OSes can access to the host files in @file{@var{dir}}
  1345. transparently. The IP address of the SMB server can be set to @var{addr}. By
  1346. default the 4th IP in the guest network is used, i.e. x.x.x.4.
  1347. In the guest Windows OS, the line:
  1348. @example
  1349. 10.0.2.4 smbserver
  1350. @end example
  1351. must be added in the file @file{C:\WINDOWS\LMHOSTS} (for windows 9x/Me)
  1352. or @file{C:\WINNT\SYSTEM32\DRIVERS\ETC\LMHOSTS} (Windows NT/2000).
  1353. Then @file{@var{dir}} can be accessed in @file{\\smbserver\qemu}.
  1354. Note that a SAMBA server must be installed on the host OS.
  1355. QEMU was tested successfully with smbd versions from Red Hat 9,
  1356. Fedora Core 3 and OpenSUSE 11.x.
  1357. @item hostfwd=[tcp|udp]:[@var{hostaddr}]:@var{hostport}-[@var{guestaddr}]:@var{guestport}
  1358. Redirect incoming TCP or UDP connections to the host port @var{hostport} to
  1359. the guest IP address @var{guestaddr} on guest port @var{guestport}. If
  1360. @var{guestaddr} is not specified, its value is x.x.x.15 (default first address
  1361. given by the built-in DHCP server). By specifying @var{hostaddr}, the rule can
  1362. be bound to a specific host interface. If no connection type is set, TCP is
  1363. used. This option can be given multiple times.
  1364. For example, to redirect host X11 connection from screen 1 to guest
  1365. screen 0, use the following:
  1366. @example
  1367. # on the host
  1368. qemu-system-i386 -net user,hostfwd=tcp:127.0.0.1:6001-:6000 [...]
  1369. # this host xterm should open in the guest X11 server
  1370. xterm -display :1
  1371. @end example
  1372. To redirect telnet connections from host port 5555 to telnet port on
  1373. the guest, use the following:
  1374. @example
  1375. # on the host
  1376. qemu-system-i386 -net user,hostfwd=tcp::5555-:23 [...]
  1377. telnet localhost 5555
  1378. @end example
  1379. Then when you use on the host @code{telnet localhost 5555}, you
  1380. connect to the guest telnet server.
  1381. @item guestfwd=[tcp]:@var{server}:@var{port}-@var{dev}
  1382. @item guestfwd=[tcp]:@var{server}:@var{port}-@var{cmd:command}
  1383. Forward guest TCP connections to the IP address @var{server} on port @var{port}
  1384. to the character device @var{dev} or to a program executed by @var{cmd:command}
  1385. which gets spawned for each connection. This option can be given multiple times.
  1386. You can either use a chardev directly and have that one used throughout QEMU's
  1387. lifetime, like in the following example:
  1388. @example
  1389. # open 10.10.1.1:4321 on bootup, connect 10.0.2.100:1234 to it whenever
  1390. # the guest accesses it
  1391. qemu -net user,guestfwd=tcp:10.0.2.100:1234-tcp:10.10.1.1:4321 [...]
  1392. @end example
  1393. Or you can execute a command on every TCP connection established by the guest,
  1394. so that QEMU behaves similar to an inetd process for that virtual server:
  1395. @example
  1396. # call "netcat 10.10.1.1 4321" on every TCP connection to 10.0.2.100:1234
  1397. # and connect the TCP stream to its stdin/stdout
  1398. qemu -net 'user,guestfwd=tcp:10.0.2.100:1234-cmd:netcat 10.10.1.1 4321'
  1399. @end example
  1400. @end table
  1401. Note: Legacy stand-alone options -tftp, -bootp, -smb and -redir are still
  1402. processed and applied to -net user. Mixing them with the new configuration
  1403. syntax gives undefined results. Their use for new applications is discouraged
  1404. as they will be removed from future versions.
  1405. @item -netdev tap,id=@var{id}[,fd=@var{h}][,ifname=@var{name}][,script=@var{file}][,downscript=@var{dfile}][,helper=@var{helper}]
  1406. @item -net tap[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}][,ifname=@var{name}][,script=@var{file}][,downscript=@var{dfile}][,helper=@var{helper}]
  1407. Connect the host TAP network interface @var{name} to VLAN @var{n}.
  1408. Use the network script @var{file} to configure it and the network script
  1409. @var{dfile} to deconfigure it. If @var{name} is not provided, the OS
  1410. automatically provides one. The default network configure script is
  1411. @file{/etc/qemu-ifup} and the default network deconfigure script is
  1412. @file{/etc/qemu-ifdown}. Use @option{script=no} or @option{downscript=no}
  1413. to disable script execution.
  1414. If running QEMU as an unprivileged user, use the network helper
  1415. @var{helper} to configure the TAP interface. The default network
  1416. helper executable is @file{/path/to/qemu-bridge-helper}.
  1417. @option{fd}=@var{h} can be used to specify the handle of an already
  1418. opened host TAP interface.
  1419. Examples:
  1420. @example
  1421. #launch a QEMU instance with the default network script
  1422. qemu-system-i386 linux.img -net nic -net tap
  1423. @end example
  1424. @example
  1425. #launch a QEMU instance with two NICs, each one connected
  1426. #to a TAP device
  1427. qemu-system-i386 linux.img \
  1428. -net nic,vlan=0 -net tap,vlan=0,ifname=tap0 \
  1429. -net nic,vlan=1 -net tap,vlan=1,ifname=tap1
  1430. @end example
  1431. @example
  1432. #launch a QEMU instance with the default network helper to
  1433. #connect a TAP device to bridge br0
  1434. qemu-system-i386 linux.img \
  1435. -net nic -net tap,"helper=/path/to/qemu-bridge-helper"
  1436. @end example
  1437. @item -netdev bridge,id=@var{id}[,br=@var{bridge}][,helper=@var{helper}]
  1438. @item -net bridge[,vlan=@var{n}][,name=@var{name}][,br=@var{bridge}][,helper=@var{helper}]
  1439. Connect a host TAP network interface to a host bridge device.
  1440. Use the network helper @var{helper} to configure the TAP interface and
  1441. attach it to the bridge. The default network helper executable is
  1442. @file{/path/to/qemu-bridge-helper} and the default bridge
  1443. device is @file{br0}.
  1444. Examples:
  1445. @example
  1446. #launch a QEMU instance with the default network helper to
  1447. #connect a TAP device to bridge br0
  1448. qemu-system-i386 linux.img -net bridge -net nic,model=virtio
  1449. @end example
  1450. @example
  1451. #launch a QEMU instance with the default network helper to
  1452. #connect a TAP device to bridge qemubr0
  1453. qemu-system-i386 linux.img -net bridge,br=qemubr0 -net nic,model=virtio
  1454. @end example
  1455. @item -netdev socket,id=@var{id}[,fd=@var{h}][,listen=[@var{host}]:@var{port}][,connect=@var{host}:@var{port}]
  1456. @item -net socket[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}] [,listen=[@var{host}]:@var{port}][,connect=@var{host}:@var{port}]
  1457. Connect the VLAN @var{n} to a remote VLAN in another QEMU virtual
  1458. machine using a TCP socket connection. If @option{listen} is
  1459. specified, QEMU waits for incoming connections on @var{port}
  1460. (@var{host} is optional). @option{connect} is used to connect to
  1461. another QEMU instance using the @option{listen} option. @option{fd}=@var{h}
  1462. specifies an already opened TCP socket.
  1463. Example:
  1464. @example
  1465. # launch a first QEMU instance
  1466. qemu-system-i386 linux.img \
  1467. -net nic,macaddr=52:54:00:12:34:56 \
  1468. -net socket,listen=:1234
  1469. # connect the VLAN 0 of this instance to the VLAN 0
  1470. # of the first instance
  1471. qemu-system-i386 linux.img \
  1472. -net nic,macaddr=52:54:00:12:34:57 \
  1473. -net socket,connect=127.0.0.1:1234
  1474. @end example
  1475. @item -netdev socket,id=@var{id}[,fd=@var{h}][,mcast=@var{maddr}:@var{port}[,localaddr=@var{addr}]]
  1476. @item -net socket[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}][,mcast=@var{maddr}:@var{port}[,localaddr=@var{addr}]]
  1477. Create a VLAN @var{n} shared with another QEMU virtual
  1478. machines using a UDP multicast socket, effectively making a bus for
  1479. every QEMU with same multicast address @var{maddr} and @var{port}.
  1480. NOTES:
  1481. @enumerate
  1482. @item
  1483. Several QEMU can be running on different hosts and share same bus (assuming
  1484. correct multicast setup for these hosts).
  1485. @item
  1486. mcast support is compatible with User Mode Linux (argument @option{eth@var{N}=mcast}), see
  1487. @url{http://user-mode-linux.sf.net}.
  1488. @item
  1489. Use @option{fd=h} to specify an already opened UDP multicast socket.
  1490. @end enumerate
  1491. Example:
  1492. @example
  1493. # launch one QEMU instance
  1494. qemu-system-i386 linux.img \
  1495. -net nic,macaddr=52:54:00:12:34:56 \
  1496. -net socket,mcast=230.0.0.1:1234
  1497. # launch another QEMU instance on same "bus"
  1498. qemu-system-i386 linux.img \
  1499. -net nic,macaddr=52:54:00:12:34:57 \
  1500. -net socket,mcast=230.0.0.1:1234
  1501. # launch yet another QEMU instance on same "bus"
  1502. qemu-system-i386 linux.img \
  1503. -net nic,macaddr=52:54:00:12:34:58 \
  1504. -net socket,mcast=230.0.0.1:1234
  1505. @end example
  1506. Example (User Mode Linux compat.):
  1507. @example
  1508. # launch QEMU instance (note mcast address selected
  1509. # is UML's default)
  1510. qemu-system-i386 linux.img \
  1511. -net nic,macaddr=52:54:00:12:34:56 \
  1512. -net socket,mcast=239.192.168.1:1102
  1513. # launch UML
  1514. /path/to/linux ubd0=/path/to/root_fs eth0=mcast
  1515. @end example
  1516. Example (send packets from host's 1.2.3.4):
  1517. @example
  1518. qemu-system-i386 linux.img \
  1519. -net nic,macaddr=52:54:00:12:34:56 \
  1520. -net socket,mcast=239.192.168.1:1102,localaddr=1.2.3.4
  1521. @end example
  1522. @item -netdev vde,id=@var{id}[,sock=@var{socketpath}][,port=@var{n}][,group=@var{groupname}][,mode=@var{octalmode}]
  1523. @item -net vde[,vlan=@var{n}][,name=@var{name}][,sock=@var{socketpath}] [,port=@var{n}][,group=@var{groupname}][,mode=@var{octalmode}]
  1524. Connect VLAN @var{n} to PORT @var{n} of a vde switch running on host and
  1525. listening for incoming connections on @var{socketpath}. Use GROUP @var{groupname}
  1526. and MODE @var{octalmode} to change default ownership and permissions for
  1527. communication port. This option is only available if QEMU has been compiled
  1528. with vde support enabled.
  1529. Example:
  1530. @example
  1531. # launch vde switch
  1532. vde_switch -F -sock /tmp/myswitch
  1533. # launch QEMU instance
  1534. qemu-system-i386 linux.img -net nic -net vde,sock=/tmp/myswitch
  1535. @end example
  1536. @item -netdev hubport,id=@var{id},hubid=@var{hubid}
  1537. Create a hub port on QEMU "vlan" @var{hubid}.
  1538. The hubport netdev lets you connect a NIC to a QEMU "vlan" instead of a single
  1539. netdev. @code{-net} and @code{-device} with parameter @option{vlan} create the
  1540. required hub automatically.
  1541. @item -net dump[,vlan=@var{n}][,file=@var{file}][,len=@var{len}]
  1542. Dump network traffic on VLAN @var{n} to file @var{file} (@file{qemu-vlan0.pcap} by default).
  1543. At most @var{len} bytes (64k by default) per packet are stored. The file format is
  1544. libpcap, so it can be analyzed with tools such as tcpdump or Wireshark.
  1545. @item -net none
  1546. Indicate that no network devices should be configured. It is used to
  1547. override the default configuration (@option{-net nic -net user}) which
  1548. is activated if no @option{-net} options are provided.
  1549. ETEXI
  1550. STEXI
  1551. @end table
  1552. ETEXI
  1553. DEFHEADING()
  1554. DEFHEADING(Character device options:)
  1555. STEXI
  1556. The general form of a character device option is:
  1557. @table @option
  1558. ETEXI
  1559. DEF("chardev", HAS_ARG, QEMU_OPTION_chardev,
  1560. "-chardev null,id=id[,mux=on|off]\n"
  1561. "-chardev socket,id=id[,host=host],port=host[,to=to][,ipv4][,ipv6][,nodelay]\n"
  1562. " [,server][,nowait][,telnet][,mux=on|off] (tcp)\n"
  1563. "-chardev socket,id=id,path=path[,server][,nowait][,telnet],[mux=on|off] (unix)\n"
  1564. "-chardev udp,id=id[,host=host],port=port[,localaddr=localaddr]\n"
  1565. " [,localport=localport][,ipv4][,ipv6][,mux=on|off]\n"
  1566. "-chardev msmouse,id=id[,mux=on|off]\n"
  1567. "-chardev vc,id=id[[,width=width][,height=height]][[,cols=cols][,rows=rows]]\n"
  1568. " [,mux=on|off]\n"
  1569. "-chardev ringbuf,id=id[,size=size]\n"
  1570. "-chardev file,id=id,path=path[,mux=on|off]\n"
  1571. "-chardev pipe,id=id,path=path[,mux=on|off]\n"
  1572. #ifdef _WIN32
  1573. "-chardev console,id=id[,mux=on|off]\n"
  1574. "-chardev serial,id=id,path=path[,mux=on|off]\n"
  1575. #else
  1576. "-chardev pty,id=id[,mux=on|off]\n"
  1577. "-chardev stdio,id=id[,mux=on|off][,signal=on|off]\n"
  1578. #endif
  1579. #ifdef CONFIG_BRLAPI
  1580. "-chardev braille,id=id[,mux=on|off]\n"
  1581. #endif
  1582. #if defined(__linux__) || defined(__sun__) || defined(__FreeBSD__) \
  1583. || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
  1584. "-chardev serial,id=id,path=path[,mux=on|off]\n"
  1585. "-chardev tty,id=id,path=path[,mux=on|off]\n"
  1586. #endif
  1587. #if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
  1588. "-chardev parallel,id=id,path=path[,mux=on|off]\n"
  1589. "-chardev parport,id=id,path=path[,mux=on|off]\n"
  1590. #endif
  1591. #if defined(CONFIG_SPICE)
  1592. "-chardev spicevmc,id=id,name=name[,debug=debug]\n"
  1593. "-chardev spiceport,id=id,name=name[,debug=debug]\n"
  1594. #endif
  1595. , QEMU_ARCH_ALL
  1596. )
  1597. STEXI
  1598. @item -chardev @var{backend} ,id=@var{id} [,mux=on|off] [,@var{options}]
  1599. @findex -chardev
  1600. Backend is one of:
  1601. @option{null},
  1602. @option{socket},
  1603. @option{udp},
  1604. @option{msmouse},
  1605. @option{vc},
  1606. @option{ringbuf},
  1607. @option{file},
  1608. @option{pipe},
  1609. @option{console},
  1610. @option{serial},
  1611. @option{pty},
  1612. @option{stdio},
  1613. @option{braille},
  1614. @option{tty},
  1615. @option{parallel},
  1616. @option{parport},
  1617. @option{spicevmc}.
  1618. @option{spiceport}.
  1619. The specific backend will determine the applicable options.
  1620. All devices must have an id, which can be any string up to 127 characters long.
  1621. It is used to uniquely identify this device in other command line directives.
  1622. A character device may be used in multiplexing mode by multiple front-ends.
  1623. The key sequence of @key{Control-a} and @key{c} will rotate the input focus
  1624. between attached front-ends. Specify @option{mux=on} to enable this mode.
  1625. Options to each backend are described below.
  1626. @item -chardev null ,id=@var{id}
  1627. A void device. This device will not emit any data, and will drop any data it
  1628. receives. The null backend does not take any options.
  1629. @item -chardev socket ,id=@var{id} [@var{TCP options} or @var{unix options}] [,server] [,nowait] [,telnet]
  1630. Create a two-way stream socket, which can be either a TCP or a unix socket. A
  1631. unix socket will be created if @option{path} is specified. Behaviour is
  1632. undefined if TCP options are specified for a unix socket.
  1633. @option{server} specifies that the socket shall be a listening socket.
  1634. @option{nowait} specifies that QEMU should not block waiting for a client to
  1635. connect to a listening socket.
  1636. @option{telnet} specifies that traffic on the socket should interpret telnet
  1637. escape sequences.
  1638. TCP and unix socket options are given below:
  1639. @table @option
  1640. @item TCP options: port=@var{port} [,host=@var{host}] [,to=@var{to}] [,ipv4] [,ipv6] [,nodelay]
  1641. @option{host} for a listening socket specifies the local address to be bound.
  1642. For a connecting socket species the remote host to connect to. @option{host} is
  1643. optional for listening sockets. If not specified it defaults to @code{0.0.0.0}.
  1644. @option{port} for a listening socket specifies the local port to be bound. For a
  1645. connecting socket specifies the port on the remote host to connect to.
  1646. @option{port} can be given as either a port number or a service name.
  1647. @option{port} is required.
  1648. @option{to} is only relevant to listening sockets. If it is specified, and
  1649. @option{port} cannot be bound, QEMU will attempt to bind to subsequent ports up
  1650. to and including @option{to} until it succeeds. @option{to} must be specified
  1651. as a port number.
  1652. @option{ipv4} and @option{ipv6} specify that either IPv4 or IPv6 must be used.
  1653. If neither is specified the socket may use either protocol.
  1654. @option{nodelay} disables the Nagle algorithm.
  1655. @item unix options: path=@var{path}
  1656. @option{path} specifies the local path of the unix socket. @option{path} is
  1657. required.
  1658. @end table
  1659. @item -chardev udp ,id=@var{id} [,host=@var{host}] ,port=@var{port} [,localaddr=@var{localaddr}] [,localport=@var{localport}] [,ipv4] [,ipv6]
  1660. Sends all traffic from the guest to a remote host over UDP.
  1661. @option{host} specifies the remote host to connect to. If not specified it
  1662. defaults to @code{localhost}.
  1663. @option{port} specifies the port on the remote host to connect to. @option{port}
  1664. is required.
  1665. @option{localaddr} specifies the local address to bind to. If not specified it
  1666. defaults to @code{0.0.0.0}.
  1667. @option{localport} specifies the local port to bind to. If not specified any
  1668. available local port will be used.
  1669. @option{ipv4} and @option{ipv6} specify that either IPv4 or IPv6 must be used.
  1670. If neither is specified the device may use either protocol.
  1671. @item -chardev msmouse ,id=@var{id}
  1672. Forward QEMU's emulated msmouse events to the guest. @option{msmouse} does not
  1673. take any options.
  1674. @item -chardev vc ,id=@var{id} [[,width=@var{width}] [,height=@var{height}]] [[,cols=@var{cols}] [,rows=@var{rows}]]
  1675. Connect to a QEMU text console. @option{vc} may optionally be given a specific
  1676. size.
  1677. @option{width} and @option{height} specify the width and height respectively of
  1678. the console, in pixels.
  1679. @option{cols} and @option{rows} specify that the console be sized to fit a text
  1680. console with the given dimensions.
  1681. @item -chardev ringbuf ,id=@var{id} [,size=@var{size}]
  1682. Create a ring buffer with fixed size @option{size}.
  1683. @var{size} must be a power of two, and defaults to @code{64K}).
  1684. @item -chardev file ,id=@var{id} ,path=@var{path}
  1685. Log all traffic received from the guest to a file.
  1686. @option{path} specifies the path of the file to be opened. This file will be
  1687. created if it does not already exist, and overwritten if it does. @option{path}
  1688. is required.
  1689. @item -chardev pipe ,id=@var{id} ,path=@var{path}
  1690. Create a two-way connection to the guest. The behaviour differs slightly between
  1691. Windows hosts and other hosts:
  1692. On Windows, a single duplex pipe will be created at
  1693. @file{\\.pipe\@option{path}}.
  1694. On other hosts, 2 pipes will be created called @file{@option{path}.in} and
  1695. @file{@option{path}.out}. Data written to @file{@option{path}.in} will be
  1696. received by the guest. Data written by the guest can be read from
  1697. @file{@option{path}.out}. QEMU will not create these fifos, and requires them to
  1698. be present.
  1699. @option{path} forms part of the pipe path as described above. @option{path} is
  1700. required.
  1701. @item -chardev console ,id=@var{id}
  1702. Send traffic from the guest to QEMU's standard output. @option{console} does not
  1703. take any options.
  1704. @option{console} is only available on Windows hosts.
  1705. @item -chardev serial ,id=@var{id} ,path=@option{path}
  1706. Send traffic from the guest to a serial device on the host.
  1707. On Unix hosts serial will actually accept any tty device,
  1708. not only serial lines.
  1709. @option{path} specifies the name of the serial device to open.
  1710. @item -chardev pty ,id=@var{id}
  1711. Create a new pseudo-terminal on the host and connect to it. @option{pty} does
  1712. not take any options.
  1713. @option{pty} is not available on Windows hosts.
  1714. @item -chardev stdio ,id=@var{id} [,signal=on|off]
  1715. Connect to standard input and standard output of the QEMU process.
  1716. @option{signal} controls if signals are enabled on the terminal, that includes
  1717. exiting QEMU with the key sequence @key{Control-c}. This option is enabled by
  1718. default, use @option{signal=off} to disable it.
  1719. @option{stdio} is not available on Windows hosts.
  1720. @item -chardev braille ,id=@var{id}
  1721. Connect to a local BrlAPI server. @option{braille} does not take any options.
  1722. @item -chardev tty ,id=@var{id} ,path=@var{path}
  1723. @option{tty} is only available on Linux, Sun, FreeBSD, NetBSD, OpenBSD and
  1724. DragonFlyBSD hosts. It is an alias for @option{serial}.
  1725. @option{path} specifies the path to the tty. @option{path} is required.
  1726. @item -chardev parallel ,id=@var{id} ,path=@var{path}
  1727. @item -chardev parport ,id=@var{id} ,path=@var{path}
  1728. @option{parallel} is only available on Linux, FreeBSD and DragonFlyBSD hosts.
  1729. Connect to a local parallel port.
  1730. @option{path} specifies the path to the parallel port device. @option{path} is
  1731. required.
  1732. @item -chardev spicevmc ,id=@var{id} ,debug=@var{debug}, name=@var{name}
  1733. @option{spicevmc} is only available when spice support is built in.
  1734. @option{debug} debug level for spicevmc
  1735. @option{name} name of spice channel to connect to
  1736. Connect to a spice virtual machine channel, such as vdiport.
  1737. @item -chardev spiceport ,id=@var{id} ,debug=@var{debug}, name=@var{name}
  1738. @option{spiceport} is only available when spice support is built in.
  1739. @option{debug} debug level for spicevmc
  1740. @option{name} name of spice port to connect to
  1741. Connect to a spice port, allowing a Spice client to handle the traffic
  1742. identified by a name (preferably a fqdn).
  1743. ETEXI
  1744. STEXI
  1745. @end table
  1746. ETEXI
  1747. DEFHEADING()
  1748. DEFHEADING(Device URL Syntax:)
  1749. STEXI
  1750. In addition to using normal file images for the emulated storage devices,
  1751. QEMU can also use networked resources such as iSCSI devices. These are
  1752. specified using a special URL syntax.
  1753. @table @option
  1754. @item iSCSI
  1755. iSCSI support allows QEMU to access iSCSI resources directly and use as
  1756. images for the guest storage. Both disk and cdrom images are supported.
  1757. Syntax for specifying iSCSI LUNs is
  1758. ``iscsi://<target-ip>[:<port>]/<target-iqn>/<lun>''
  1759. By default qemu will use the iSCSI initiator-name
  1760. 'iqn.2008-11.org.linux-kvm[:<name>]' but this can also be set from the command
  1761. line or a configuration file.
  1762. Example (without authentication):
  1763. @example
  1764. qemu-system-i386 -iscsi initiator-name=iqn.2001-04.com.example:my-initiator \
  1765. -cdrom iscsi://192.0.2.1/iqn.2001-04.com.example/2 \
  1766. -drive file=iscsi://192.0.2.1/iqn.2001-04.com.example/1
  1767. @end example
  1768. Example (CHAP username/password via URL):
  1769. @example
  1770. qemu-system-i386 -drive file=iscsi://user%password@@192.0.2.1/iqn.2001-04.com.example/1
  1771. @end example
  1772. Example (CHAP username/password via environment variables):
  1773. @example
  1774. LIBISCSI_CHAP_USERNAME="user" \
  1775. LIBISCSI_CHAP_PASSWORD="password" \
  1776. qemu-system-i386 -drive file=iscsi://192.0.2.1/iqn.2001-04.com.example/1
  1777. @end example
  1778. iSCSI support is an optional feature of QEMU and only available when
  1779. compiled and linked against libiscsi.
  1780. ETEXI
  1781. DEF("iscsi", HAS_ARG, QEMU_OPTION_iscsi,
  1782. "-iscsi [user=user][,password=password]\n"
  1783. " [,header-digest=CRC32C|CR32C-NONE|NONE-CRC32C|NONE\n"
  1784. " [,initiator-name=initiator-iqn][,id=target-iqn]\n"
  1785. " iSCSI session parameters\n", QEMU_ARCH_ALL)
  1786. STEXI
  1787. iSCSI parameters such as username and password can also be specified via
  1788. a configuration file. See qemu-doc for more information and examples.
  1789. @item NBD
  1790. QEMU supports NBD (Network Block Devices) both using TCP protocol as well
  1791. as Unix Domain Sockets.
  1792. Syntax for specifying a NBD device using TCP
  1793. ``nbd:<server-ip>:<port>[:exportname=<export>]''
  1794. Syntax for specifying a NBD device using Unix Domain Sockets
  1795. ``nbd:unix:<domain-socket>[:exportname=<export>]''
  1796. Example for TCP
  1797. @example
  1798. qemu-system-i386 --drive file=nbd:192.0.2.1:30000
  1799. @end example
  1800. Example for Unix Domain Sockets
  1801. @example
  1802. qemu-system-i386 --drive file=nbd:unix:/tmp/nbd-socket
  1803. @end example
  1804. @item SSH
  1805. QEMU supports SSH (Secure Shell) access to remote disks.
  1806. Examples:
  1807. @example
  1808. qemu-system-i386 -drive file=ssh://user@@host/path/to/disk.img
  1809. qemu-system-i386 -drive file.driver=ssh,file.user=user,file.host=host,file.port=22,file.path=/path/to/disk.img
  1810. @end example
  1811. Currently authentication must be done using ssh-agent. Other
  1812. authentication methods may be supported in future.
  1813. @item Sheepdog
  1814. Sheepdog is a distributed storage system for QEMU.
  1815. QEMU supports using either local sheepdog devices or remote networked
  1816. devices.
  1817. Syntax for specifying a sheepdog device
  1818. @example
  1819. sheepdog[+tcp|+unix]://[host:port]/vdiname[?socket=path][#snapid|#tag]
  1820. @end example
  1821. Example
  1822. @example
  1823. qemu-system-i386 --drive file=sheepdog://192.0.2.1:30000/MyVirtualMachine
  1824. @end example
  1825. See also @url{http://http://www.osrg.net/sheepdog/}.
  1826. @item GlusterFS
  1827. GlusterFS is an user space distributed file system.
  1828. QEMU supports the use of GlusterFS volumes for hosting VM disk images using
  1829. TCP, Unix Domain Sockets and RDMA transport protocols.
  1830. Syntax for specifying a VM disk image on GlusterFS volume is
  1831. @example
  1832. gluster[+transport]://[server[:port]]/volname/image[?socket=...]
  1833. @end example
  1834. Example
  1835. @example
  1836. qemu-system-x86_64 --drive file=gluster://192.0.2.1/testvol/a.img
  1837. @end example
  1838. See also @url{http://www.gluster.org}.
  1839. ETEXI
  1840. STEXI
  1841. @end table
  1842. ETEXI
  1843. DEFHEADING(Bluetooth(R) options:)
  1844. STEXI
  1845. @table @option
  1846. ETEXI
  1847. DEF("bt", HAS_ARG, QEMU_OPTION_bt, \
  1848. "-bt hci,null dumb bluetooth HCI - doesn't respond to commands\n" \
  1849. "-bt hci,host[:id]\n" \
  1850. " use host's HCI with the given name\n" \
  1851. "-bt hci[,vlan=n]\n" \
  1852. " emulate a standard HCI in virtual scatternet 'n'\n" \
  1853. "-bt vhci[,vlan=n]\n" \
  1854. " add host computer to virtual scatternet 'n' using VHCI\n" \
  1855. "-bt device:dev[,vlan=n]\n" \
  1856. " emulate a bluetooth device 'dev' in scatternet 'n'\n",
  1857. QEMU_ARCH_ALL)
  1858. STEXI
  1859. @item -bt hci[...]
  1860. @findex -bt
  1861. Defines the function of the corresponding Bluetooth HCI. -bt options
  1862. are matched with the HCIs present in the chosen machine type. For
  1863. example when emulating a machine with only one HCI built into it, only
  1864. the first @code{-bt hci[...]} option is valid and defines the HCI's
  1865. logic. The Transport Layer is decided by the machine type. Currently
  1866. the machines @code{n800} and @code{n810} have one HCI and all other
  1867. machines have none.
  1868. @anchor{bt-hcis}
  1869. The following three types are recognized:
  1870. @table @option
  1871. @item -bt hci,null
  1872. (default) The corresponding Bluetooth HCI assumes no internal logic
  1873. and will not respond to any HCI commands or emit events.
  1874. @item -bt hci,host[:@var{id}]
  1875. (@code{bluez} only) The corresponding HCI passes commands / events
  1876. to / from the physical HCI identified by the name @var{id} (default:
  1877. @code{hci0}) on the computer running QEMU. Only available on @code{bluez}
  1878. capable systems like Linux.
  1879. @item -bt hci[,vlan=@var{n}]
  1880. Add a virtual, standard HCI that will participate in the Bluetooth
  1881. scatternet @var{n} (default @code{0}). Similarly to @option{-net}
  1882. VLANs, devices inside a bluetooth network @var{n} can only communicate
  1883. with other devices in the same network (scatternet).
  1884. @end table
  1885. @item -bt vhci[,vlan=@var{n}]
  1886. (Linux-host only) Create a HCI in scatternet @var{n} (default 0) attached
  1887. to the host bluetooth stack instead of to the emulated target. This
  1888. allows the host and target machines to participate in a common scatternet
  1889. and communicate. Requires the Linux @code{vhci} driver installed. Can
  1890. be used as following:
  1891. @example
  1892. qemu-system-i386 [...OPTIONS...] -bt hci,vlan=5 -bt vhci,vlan=5
  1893. @end example
  1894. @item -bt device:@var{dev}[,vlan=@var{n}]
  1895. Emulate a bluetooth device @var{dev} and place it in network @var{n}
  1896. (default @code{0}). QEMU can only emulate one type of bluetooth devices
  1897. currently:
  1898. @table @option
  1899. @item keyboard
  1900. Virtual wireless keyboard implementing the HIDP bluetooth profile.
  1901. @end table
  1902. ETEXI
  1903. STEXI
  1904. @end table
  1905. ETEXI
  1906. DEFHEADING()
  1907. #ifdef CONFIG_TPM
  1908. DEFHEADING(TPM device options:)
  1909. DEF("tpmdev", HAS_ARG, QEMU_OPTION_tpmdev, \
  1910. "-tpmdev passthrough,id=id[,path=path][,cancel-path=path]\n"
  1911. " use path to provide path to a character device; default is /dev/tpm0\n"
  1912. " use cancel-path to provide path to TPM's cancel sysfs entry; if\n"
  1913. " not provided it will be searched for in /sys/class/misc/tpm?/device\n",
  1914. QEMU_ARCH_ALL)
  1915. STEXI
  1916. The general form of a TPM device option is:
  1917. @table @option
  1918. @item -tpmdev @var{backend} ,id=@var{id} [,@var{options}]
  1919. @findex -tpmdev
  1920. Backend type must be:
  1921. @option{passthrough}.
  1922. The specific backend type will determine the applicable options.
  1923. The @code{-tpmdev} option creates the TPM backend and requires a
  1924. @code{-device} option that specifies the TPM frontend interface model.
  1925. Options to each backend are described below.
  1926. Use 'help' to print all available TPM backend types.
  1927. @example
  1928. qemu -tpmdev help
  1929. @end example
  1930. @item -tpmdev passthrough, id=@var{id}, path=@var{path}, cancel-path=@var{cancel-path}
  1931. (Linux-host only) Enable access to the host's TPM using the passthrough
  1932. driver.
  1933. @option{path} specifies the path to the host's TPM device, i.e., on
  1934. a Linux host this would be @code{/dev/tpm0}.
  1935. @option{path} is optional and by default @code{/dev/tpm0} is used.
  1936. @option{cancel-path} specifies the path to the host TPM device's sysfs
  1937. entry allowing for cancellation of an ongoing TPM command.
  1938. @option{cancel-path} is optional and by default QEMU will search for the
  1939. sysfs entry to use.
  1940. Some notes about using the host's TPM with the passthrough driver:
  1941. The TPM device accessed by the passthrough driver must not be
  1942. used by any other application on the host.
  1943. Since the host's firmware (BIOS/UEFI) has already initialized the TPM,
  1944. the VM's firmware (BIOS/UEFI) will not be able to initialize the
  1945. TPM again and may therefore not show a TPM-specific menu that would
  1946. otherwise allow the user to configure the TPM, e.g., allow the user to
  1947. enable/disable or activate/deactivate the TPM.
  1948. Further, if TPM ownership is released from within a VM then the host's TPM
  1949. will get disabled and deactivated. To enable and activate the
  1950. TPM again afterwards, the host has to be rebooted and the user is
  1951. required to enter the firmware's menu to enable and activate the TPM.
  1952. If the TPM is left disabled and/or deactivated most TPM commands will fail.
  1953. To create a passthrough TPM use the following two options:
  1954. @example
  1955. -tpmdev passthrough,id=tpm0 -device tpm-tis,tpmdev=tpm0
  1956. @end example
  1957. Note that the @code{-tpmdev} id is @code{tpm0} and is referenced by
  1958. @code{tpmdev=tpm0} in the device option.
  1959. @end table
  1960. ETEXI
  1961. DEFHEADING()
  1962. #endif
  1963. DEFHEADING(Linux/Multiboot boot specific:)
  1964. STEXI
  1965. When using these options, you can use a given Linux or Multiboot
  1966. kernel without installing it in the disk image. It can be useful
  1967. for easier testing of various kernels.
  1968. @table @option
  1969. ETEXI
  1970. DEF("kernel", HAS_ARG, QEMU_OPTION_kernel, \
  1971. "-kernel bzImage use 'bzImage' as kernel image\n", QEMU_ARCH_ALL)
  1972. STEXI
  1973. @item -kernel @var{bzImage}
  1974. @findex -kernel
  1975. Use @var{bzImage} as kernel image. The kernel can be either a Linux kernel
  1976. or in multiboot format.
  1977. ETEXI
  1978. DEF("append", HAS_ARG, QEMU_OPTION_append, \
  1979. "-append cmdline use 'cmdline' as kernel command line\n", QEMU_ARCH_ALL)
  1980. STEXI
  1981. @item -append @var{cmdline}
  1982. @findex -append
  1983. Use @var{cmdline} as kernel command line
  1984. ETEXI
  1985. DEF("initrd", HAS_ARG, QEMU_OPTION_initrd, \
  1986. "-initrd file use 'file' as initial ram disk\n", QEMU_ARCH_ALL)
  1987. STEXI
  1988. @item -initrd @var{file}
  1989. @findex -initrd
  1990. Use @var{file} as initial ram disk.
  1991. @item -initrd "@var{file1} arg=foo,@var{file2}"
  1992. This syntax is only available with multiboot.
  1993. Use @var{file1} and @var{file2} as modules and pass arg=foo as parameter to the
  1994. first module.
  1995. ETEXI
  1996. DEF("dtb", HAS_ARG, QEMU_OPTION_dtb, \
  1997. "-dtb file use 'file' as device tree image\n", QEMU_ARCH_ALL)
  1998. STEXI
  1999. @item -dtb @var{file}
  2000. @findex -dtb
  2001. Use @var{file} as a device tree binary (dtb) image and pass it to the kernel
  2002. on boot.
  2003. ETEXI
  2004. STEXI
  2005. @end table
  2006. ETEXI
  2007. DEFHEADING()
  2008. DEFHEADING(Debug/Expert options:)
  2009. STEXI
  2010. @table @option
  2011. ETEXI
  2012. DEF("serial", HAS_ARG, QEMU_OPTION_serial, \
  2013. "-serial dev redirect the serial port to char device 'dev'\n",
  2014. QEMU_ARCH_ALL)
  2015. STEXI
  2016. @item -serial @var{dev}
  2017. @findex -serial
  2018. Redirect the virtual serial port to host character device
  2019. @var{dev}. The default device is @code{vc} in graphical mode and
  2020. @code{stdio} in non graphical mode.
  2021. This option can be used several times to simulate up to 4 serial
  2022. ports.
  2023. Use @code{-serial none} to disable all serial ports.
  2024. Available character devices are:
  2025. @table @option
  2026. @item vc[:@var{W}x@var{H}]
  2027. Virtual console. Optionally, a width and height can be given in pixel with
  2028. @example
  2029. vc:800x600
  2030. @end example
  2031. It is also possible to specify width or height in characters:
  2032. @example
  2033. vc:80Cx24C
  2034. @end example
  2035. @item pty
  2036. [Linux only] Pseudo TTY (a new PTY is automatically allocated)
  2037. @item none
  2038. No device is allocated.
  2039. @item null
  2040. void device
  2041. @item chardev:@var{id}
  2042. Use a named character device defined with the @code{-chardev} option.
  2043. @item /dev/XXX
  2044. [Linux only] Use host tty, e.g. @file{/dev/ttyS0}. The host serial port
  2045. parameters are set according to the emulated ones.
  2046. @item /dev/parport@var{N}
  2047. [Linux only, parallel port only] Use host parallel port
  2048. @var{N}. Currently SPP and EPP parallel port features can be used.
  2049. @item file:@var{filename}
  2050. Write output to @var{filename}. No character can be read.
  2051. @item stdio
  2052. [Unix only] standard input/output
  2053. @item pipe:@var{filename}
  2054. name pipe @var{filename}
  2055. @item COM@var{n}
  2056. [Windows only] Use host serial port @var{n}
  2057. @item udp:[@var{remote_host}]:@var{remote_port}[@@[@var{src_ip}]:@var{src_port}]
  2058. This implements UDP Net Console.
  2059. When @var{remote_host} or @var{src_ip} are not specified
  2060. they default to @code{0.0.0.0}.
  2061. When not using a specified @var{src_port} a random port is automatically chosen.
  2062. If you just want a simple readonly console you can use @code{netcat} or
  2063. @code{nc}, by starting QEMU with: @code{-serial udp::4555} and nc as:
  2064. @code{nc -u -l -p 4555}. Any time QEMU writes something to that port it
  2065. will appear in the netconsole session.
  2066. If you plan to send characters back via netconsole or you want to stop
  2067. and start QEMU a lot of times, you should have QEMU use the same
  2068. source port each time by using something like @code{-serial
  2069. udp::4555@@:4556} to QEMU. Another approach is to use a patched
  2070. version of netcat which can listen to a TCP port and send and receive
  2071. characters via udp. If you have a patched version of netcat which
  2072. activates telnet remote echo and single char transfer, then you can
  2073. use the following options to step up a netcat redirector to allow
  2074. telnet on port 5555 to access the QEMU port.
  2075. @table @code
  2076. @item QEMU Options:
  2077. -serial udp::4555@@:4556
  2078. @item netcat options:
  2079. -u -P 4555 -L 0.0.0.0:4556 -t -p 5555 -I -T
  2080. @item telnet options:
  2081. localhost 5555
  2082. @end table
  2083. @item tcp:[@var{host}]:@var{port}[,@var{server}][,nowait][,nodelay]
  2084. The TCP Net Console has two modes of operation. It can send the serial
  2085. I/O to a location or wait for a connection from a location. By default
  2086. the TCP Net Console is sent to @var{host} at the @var{port}. If you use
  2087. the @var{server} option QEMU will wait for a client socket application
  2088. to connect to the port before continuing, unless the @code{nowait}
  2089. option was specified. The @code{nodelay} option disables the Nagle buffering
  2090. algorithm. If @var{host} is omitted, 0.0.0.0 is assumed. Only
  2091. one TCP connection at a time is accepted. You can use @code{telnet} to
  2092. connect to the corresponding character device.
  2093. @table @code
  2094. @item Example to send tcp console to 192.168.0.2 port 4444
  2095. -serial tcp:192.168.0.2:4444
  2096. @item Example to listen and wait on port 4444 for connection
  2097. -serial tcp::4444,server
  2098. @item Example to not wait and listen on ip 192.168.0.100 port 4444
  2099. -serial tcp:192.168.0.100:4444,server,nowait
  2100. @end table
  2101. @item telnet:@var{host}:@var{port}[,server][,nowait][,nodelay]
  2102. The telnet protocol is used instead of raw tcp sockets. The options
  2103. work the same as if you had specified @code{-serial tcp}. The
  2104. difference is that the port acts like a telnet server or client using
  2105. telnet option negotiation. This will also allow you to send the
  2106. MAGIC_SYSRQ sequence if you use a telnet that supports sending the break
  2107. sequence. Typically in unix telnet you do it with Control-] and then
  2108. type "send break" followed by pressing the enter key.
  2109. @item unix:@var{path}[,server][,nowait]
  2110. A unix domain socket is used instead of a tcp socket. The option works the
  2111. same as if you had specified @code{-serial tcp} except the unix domain socket
  2112. @var{path} is used for connections.
  2113. @item mon:@var{dev_string}
  2114. This is a special option to allow the monitor to be multiplexed onto
  2115. another serial port. The monitor is accessed with key sequence of
  2116. @key{Control-a} and then pressing @key{c}.
  2117. @var{dev_string} should be any one of the serial devices specified
  2118. above. An example to multiplex the monitor onto a telnet server
  2119. listening on port 4444 would be:
  2120. @table @code
  2121. @item -serial mon:telnet::4444,server,nowait
  2122. @end table
  2123. When the monitor is multiplexed to stdio in this way, Ctrl+C will not terminate
  2124. QEMU any more but will be passed to the guest instead.
  2125. @item braille
  2126. Braille device. This will use BrlAPI to display the braille output on a real
  2127. or fake device.
  2128. @item msmouse
  2129. Three button serial mouse. Configure the guest to use Microsoft protocol.
  2130. @end table
  2131. ETEXI
  2132. DEF("parallel", HAS_ARG, QEMU_OPTION_parallel, \
  2133. "-parallel dev redirect the parallel port to char device 'dev'\n",
  2134. QEMU_ARCH_ALL)
  2135. STEXI
  2136. @item -parallel @var{dev}
  2137. @findex -parallel
  2138. Redirect the virtual parallel port to host device @var{dev} (same
  2139. devices as the serial port). On Linux hosts, @file{/dev/parportN} can
  2140. be used to use hardware devices connected on the corresponding host
  2141. parallel port.
  2142. This option can be used several times to simulate up to 3 parallel
  2143. ports.
  2144. Use @code{-parallel none} to disable all parallel ports.
  2145. ETEXI
  2146. DEF("monitor", HAS_ARG, QEMU_OPTION_monitor, \
  2147. "-monitor dev redirect the monitor to char device 'dev'\n",
  2148. QEMU_ARCH_ALL)
  2149. STEXI
  2150. @item -monitor @var{dev}
  2151. @findex -monitor
  2152. Redirect the monitor to host device @var{dev} (same devices as the
  2153. serial port).
  2154. The default device is @code{vc} in graphical mode and @code{stdio} in
  2155. non graphical mode.
  2156. Use @code{-monitor none} to disable the default monitor.
  2157. ETEXI
  2158. DEF("qmp", HAS_ARG, QEMU_OPTION_qmp, \
  2159. "-qmp dev like -monitor but opens in 'control' mode\n",
  2160. QEMU_ARCH_ALL)
  2161. STEXI
  2162. @item -qmp @var{dev}
  2163. @findex -qmp
  2164. Like -monitor but opens in 'control' mode.
  2165. ETEXI
  2166. DEF("mon", HAS_ARG, QEMU_OPTION_mon, \
  2167. "-mon [chardev=]name[,mode=readline|control][,default]\n", QEMU_ARCH_ALL)
  2168. STEXI
  2169. @item -mon [chardev=]name[,mode=readline|control][,default]
  2170. @findex -mon
  2171. Setup monitor on chardev @var{name}.
  2172. ETEXI
  2173. DEF("debugcon", HAS_ARG, QEMU_OPTION_debugcon, \
  2174. "-debugcon dev redirect the debug console to char device 'dev'\n",
  2175. QEMU_ARCH_ALL)
  2176. STEXI
  2177. @item -debugcon @var{dev}
  2178. @findex -debugcon
  2179. Redirect the debug console to host device @var{dev} (same devices as the
  2180. serial port). The debug console is an I/O port which is typically port
  2181. 0xe9; writing to that I/O port sends output to this device.
  2182. The default device is @code{vc} in graphical mode and @code{stdio} in
  2183. non graphical mode.
  2184. ETEXI
  2185. DEF("pidfile", HAS_ARG, QEMU_OPTION_pidfile, \
  2186. "-pidfile file write PID to 'file'\n", QEMU_ARCH_ALL)
  2187. STEXI
  2188. @item -pidfile @var{file}
  2189. @findex -pidfile
  2190. Store the QEMU process PID in @var{file}. It is useful if you launch QEMU
  2191. from a script.
  2192. ETEXI
  2193. DEF("singlestep", 0, QEMU_OPTION_singlestep, \
  2194. "-singlestep always run in singlestep mode\n", QEMU_ARCH_ALL)
  2195. STEXI
  2196. @item -singlestep
  2197. @findex -singlestep
  2198. Run the emulation in single step mode.
  2199. ETEXI
  2200. DEF("S", 0, QEMU_OPTION_S, \
  2201. "-S freeze CPU at startup (use 'c' to start execution)\n",
  2202. QEMU_ARCH_ALL)
  2203. STEXI
  2204. @item -S
  2205. @findex -S
  2206. Do not start CPU at startup (you must type 'c' in the monitor).
  2207. ETEXI
  2208. DEF("realtime", HAS_ARG, QEMU_OPTION_realtime,
  2209. "-realtime [mlock=on|off]\n"
  2210. " run qemu with realtime features\n"
  2211. " mlock=on|off controls mlock support (default: on)\n",
  2212. QEMU_ARCH_ALL)
  2213. STEXI
  2214. @item -realtime mlock=on|off
  2215. @findex -realtime
  2216. Run qemu with realtime features.
  2217. mlocking qemu and guest memory can be enabled via @option{mlock=on}
  2218. (enabled by default).
  2219. ETEXI
  2220. DEF("gdb", HAS_ARG, QEMU_OPTION_gdb, \
  2221. "-gdb dev wait for gdb connection on 'dev'\n", QEMU_ARCH_ALL)
  2222. STEXI
  2223. @item -gdb @var{dev}
  2224. @findex -gdb
  2225. Wait for gdb connection on device @var{dev} (@pxref{gdb_usage}). Typical
  2226. connections will likely be TCP-based, but also UDP, pseudo TTY, or even
  2227. stdio are reasonable use case. The latter is allowing to start QEMU from
  2228. within gdb and establish the connection via a pipe:
  2229. @example
  2230. (gdb) target remote | exec qemu-system-i386 -gdb stdio ...
  2231. @end example
  2232. ETEXI
  2233. DEF("s", 0, QEMU_OPTION_s, \
  2234. "-s shorthand for -gdb tcp::" DEFAULT_GDBSTUB_PORT "\n",
  2235. QEMU_ARCH_ALL)
  2236. STEXI
  2237. @item -s
  2238. @findex -s
  2239. Shorthand for -gdb tcp::1234, i.e. open a gdbserver on TCP port 1234
  2240. (@pxref{gdb_usage}).
  2241. ETEXI
  2242. DEF("d", HAS_ARG, QEMU_OPTION_d, \
  2243. "-d item1,... enable logging of specified items (use '-d help' for a list of log items)\n",
  2244. QEMU_ARCH_ALL)
  2245. STEXI
  2246. @item -d @var{item1}[,...]
  2247. @findex -d
  2248. Enable logging of specified items. Use '-d help' for a list of log items.
  2249. ETEXI
  2250. DEF("D", HAS_ARG, QEMU_OPTION_D, \
  2251. "-D logfile output log to logfile (default stderr)\n",
  2252. QEMU_ARCH_ALL)
  2253. STEXI
  2254. @item -D @var{logfile}
  2255. @findex -D
  2256. Output log in @var{logfile} instead of to stderr
  2257. ETEXI
  2258. DEF("L", HAS_ARG, QEMU_OPTION_L, \
  2259. "-L path set the directory for the BIOS, VGA BIOS and keymaps\n",
  2260. QEMU_ARCH_ALL)
  2261. STEXI
  2262. @item -L @var{path}
  2263. @findex -L
  2264. Set the directory for the BIOS, VGA BIOS and keymaps.
  2265. ETEXI
  2266. DEF("bios", HAS_ARG, QEMU_OPTION_bios, \
  2267. "-bios file set the filename for the BIOS\n", QEMU_ARCH_ALL)
  2268. STEXI
  2269. @item -bios @var{file}
  2270. @findex -bios
  2271. Set the filename for the BIOS.
  2272. ETEXI
  2273. DEF("enable-kvm", 0, QEMU_OPTION_enable_kvm, \
  2274. "-enable-kvm enable KVM full virtualization support\n", QEMU_ARCH_ALL)
  2275. STEXI
  2276. @item -enable-kvm
  2277. @findex -enable-kvm
  2278. Enable KVM full virtualization support. This option is only available
  2279. if KVM support is enabled when compiling.
  2280. ETEXI
  2281. DEF("xen-domid", HAS_ARG, QEMU_OPTION_xen_domid,
  2282. "-xen-domid id specify xen guest domain id\n", QEMU_ARCH_ALL)
  2283. DEF("xen-create", 0, QEMU_OPTION_xen_create,
  2284. "-xen-create create domain using xen hypercalls, bypassing xend\n"
  2285. " warning: should not be used when xend is in use\n",
  2286. QEMU_ARCH_ALL)
  2287. DEF("xen-attach", 0, QEMU_OPTION_xen_attach,
  2288. "-xen-attach attach to existing xen domain\n"
  2289. " xend will use this when starting QEMU\n",
  2290. QEMU_ARCH_ALL)
  2291. STEXI
  2292. @item -xen-domid @var{id}
  2293. @findex -xen-domid
  2294. Specify xen guest domain @var{id} (XEN only).
  2295. @item -xen-create
  2296. @findex -xen-create
  2297. Create domain using xen hypercalls, bypassing xend.
  2298. Warning: should not be used when xend is in use (XEN only).
  2299. @item -xen-attach
  2300. @findex -xen-attach
  2301. Attach to existing xen domain.
  2302. xend will use this when starting QEMU (XEN only).
  2303. ETEXI
  2304. DEF("no-reboot", 0, QEMU_OPTION_no_reboot, \
  2305. "-no-reboot exit instead of rebooting\n", QEMU_ARCH_ALL)
  2306. STEXI
  2307. @item -no-reboot
  2308. @findex -no-reboot
  2309. Exit instead of rebooting.
  2310. ETEXI
  2311. DEF("no-shutdown", 0, QEMU_OPTION_no_shutdown, \
  2312. "-no-shutdown stop before shutdown\n", QEMU_ARCH_ALL)
  2313. STEXI
  2314. @item -no-shutdown
  2315. @findex -no-shutdown
  2316. Don't exit QEMU on guest shutdown, but instead only stop the emulation.
  2317. This allows for instance switching to monitor to commit changes to the
  2318. disk image.
  2319. ETEXI
  2320. DEF("loadvm", HAS_ARG, QEMU_OPTION_loadvm, \
  2321. "-loadvm [tag|id]\n" \
  2322. " start right away with a saved state (loadvm in monitor)\n",
  2323. QEMU_ARCH_ALL)
  2324. STEXI
  2325. @item -loadvm @var{file}
  2326. @findex -loadvm
  2327. Start right away with a saved state (@code{loadvm} in monitor)
  2328. ETEXI
  2329. #ifndef _WIN32
  2330. DEF("daemonize", 0, QEMU_OPTION_daemonize, \
  2331. "-daemonize daemonize QEMU after initializing\n", QEMU_ARCH_ALL)
  2332. #endif
  2333. STEXI
  2334. @item -daemonize
  2335. @findex -daemonize
  2336. Daemonize the QEMU process after initialization. QEMU will not detach from
  2337. standard IO until it is ready to receive connections on any of its devices.
  2338. This option is a useful way for external programs to launch QEMU without having
  2339. to cope with initialization race conditions.
  2340. ETEXI
  2341. DEF("option-rom", HAS_ARG, QEMU_OPTION_option_rom, \
  2342. "-option-rom rom load a file, rom, into the option ROM space\n",
  2343. QEMU_ARCH_ALL)
  2344. STEXI
  2345. @item -option-rom @var{file}
  2346. @findex -option-rom
  2347. Load the contents of @var{file} as an option ROM.
  2348. This option is useful to load things like EtherBoot.
  2349. ETEXI
  2350. DEF("clock", HAS_ARG, QEMU_OPTION_clock, \
  2351. "-clock force the use of the given methods for timer alarm.\n" \
  2352. " To see what timers are available use '-clock help'\n",
  2353. QEMU_ARCH_ALL)
  2354. STEXI
  2355. @item -clock @var{method}
  2356. @findex -clock
  2357. Force the use of the given methods for timer alarm. To see what timers
  2358. are available use @code{-clock help}.
  2359. ETEXI
  2360. HXCOMM Options deprecated by -rtc
  2361. DEF("localtime", 0, QEMU_OPTION_localtime, "", QEMU_ARCH_ALL)
  2362. DEF("startdate", HAS_ARG, QEMU_OPTION_startdate, "", QEMU_ARCH_ALL)
  2363. DEF("rtc", HAS_ARG, QEMU_OPTION_rtc, \
  2364. "-rtc [base=utc|localtime|date][,clock=host|rt|vm][,driftfix=none|slew]\n" \
  2365. " set the RTC base and clock, enable drift fix for clock ticks (x86 only)\n",
  2366. QEMU_ARCH_ALL)
  2367. STEXI
  2368. @item -rtc [base=utc|localtime|@var{date}][,clock=host|vm][,driftfix=none|slew]
  2369. @findex -rtc
  2370. Specify @option{base} as @code{utc} or @code{localtime} to let the RTC start at the current
  2371. UTC or local time, respectively. @code{localtime} is required for correct date in
  2372. MS-DOS or Windows. To start at a specific point in time, provide @var{date} in the
  2373. format @code{2006-06-17T16:01:21} or @code{2006-06-17}. The default base is UTC.
  2374. By default the RTC is driven by the host system time. This allows to use the
  2375. RTC as accurate reference clock inside the guest, specifically if the host
  2376. time is smoothly following an accurate external reference clock, e.g. via NTP.
  2377. If you want to isolate the guest time from the host, you can set @option{clock}
  2378. to @code{rt} instead. To even prevent it from progressing during suspension,
  2379. you can set it to @code{vm}.
  2380. Enable @option{driftfix} (i386 targets only) if you experience time drift problems,
  2381. specifically with Windows' ACPI HAL. This option will try to figure out how
  2382. many timer interrupts were not processed by the Windows guest and will
  2383. re-inject them.
  2384. ETEXI
  2385. DEF("icount", HAS_ARG, QEMU_OPTION_icount, \
  2386. "-icount [N|auto]\n" \
  2387. " enable virtual instruction counter with 2^N clock ticks per\n" \
  2388. " instruction\n", QEMU_ARCH_ALL)
  2389. STEXI
  2390. @item -icount [@var{N}|auto]
  2391. @findex -icount
  2392. Enable virtual instruction counter. The virtual cpu will execute one
  2393. instruction every 2^@var{N} ns of virtual time. If @code{auto} is specified
  2394. then the virtual cpu speed will be automatically adjusted to keep virtual
  2395. time within a few seconds of real time.
  2396. Note that while this option can give deterministic behavior, it does not
  2397. provide cycle accurate emulation. Modern CPUs contain superscalar out of
  2398. order cores with complex cache hierarchies. The number of instructions
  2399. executed often has little or no correlation with actual performance.
  2400. ETEXI
  2401. DEF("watchdog", HAS_ARG, QEMU_OPTION_watchdog, \
  2402. "-watchdog i6300esb|ib700\n" \
  2403. " enable virtual hardware watchdog [default=none]\n",
  2404. QEMU_ARCH_ALL)
  2405. STEXI
  2406. @item -watchdog @var{model}
  2407. @findex -watchdog
  2408. Create a virtual hardware watchdog device. Once enabled (by a guest
  2409. action), the watchdog must be periodically polled by an agent inside
  2410. the guest or else the guest will be restarted.
  2411. The @var{model} is the model of hardware watchdog to emulate. Choices
  2412. for model are: @code{ib700} (iBASE 700) which is a very simple ISA
  2413. watchdog with a single timer, or @code{i6300esb} (Intel 6300ESB I/O
  2414. controller hub) which is a much more featureful PCI-based dual-timer
  2415. watchdog. Choose a model for which your guest has drivers.
  2416. Use @code{-watchdog help} to list available hardware models. Only one
  2417. watchdog can be enabled for a guest.
  2418. ETEXI
  2419. DEF("watchdog-action", HAS_ARG, QEMU_OPTION_watchdog_action, \
  2420. "-watchdog-action reset|shutdown|poweroff|pause|debug|none\n" \
  2421. " action when watchdog fires [default=reset]\n",
  2422. QEMU_ARCH_ALL)
  2423. STEXI
  2424. @item -watchdog-action @var{action}
  2425. @findex -watchdog-action
  2426. The @var{action} controls what QEMU will do when the watchdog timer
  2427. expires.
  2428. The default is
  2429. @code{reset} (forcefully reset the guest).
  2430. Other possible actions are:
  2431. @code{shutdown} (attempt to gracefully shutdown the guest),
  2432. @code{poweroff} (forcefully poweroff the guest),
  2433. @code{pause} (pause the guest),
  2434. @code{debug} (print a debug message and continue), or
  2435. @code{none} (do nothing).
  2436. Note that the @code{shutdown} action requires that the guest responds
  2437. to ACPI signals, which it may not be able to do in the sort of
  2438. situations where the watchdog would have expired, and thus
  2439. @code{-watchdog-action shutdown} is not recommended for production use.
  2440. Examples:
  2441. @table @code
  2442. @item -watchdog i6300esb -watchdog-action pause
  2443. @item -watchdog ib700
  2444. @end table
  2445. ETEXI
  2446. DEF("echr", HAS_ARG, QEMU_OPTION_echr, \
  2447. "-echr chr set terminal escape character instead of ctrl-a\n",
  2448. QEMU_ARCH_ALL)
  2449. STEXI
  2450. @item -echr @var{numeric_ascii_value}
  2451. @findex -echr
  2452. Change the escape character used for switching to the monitor when using
  2453. monitor and serial sharing. The default is @code{0x01} when using the
  2454. @code{-nographic} option. @code{0x01} is equal to pressing
  2455. @code{Control-a}. You can select a different character from the ascii
  2456. control keys where 1 through 26 map to Control-a through Control-z. For
  2457. instance you could use the either of the following to change the escape
  2458. character to Control-t.
  2459. @table @code
  2460. @item -echr 0x14
  2461. @item -echr 20
  2462. @end table
  2463. ETEXI
  2464. DEF("virtioconsole", HAS_ARG, QEMU_OPTION_virtiocon, \
  2465. "-virtioconsole c\n" \
  2466. " set virtio console\n", QEMU_ARCH_ALL)
  2467. STEXI
  2468. @item -virtioconsole @var{c}
  2469. @findex -virtioconsole
  2470. Set virtio console.
  2471. This option is maintained for backward compatibility.
  2472. Please use @code{-device virtconsole} for the new way of invocation.
  2473. ETEXI
  2474. DEF("show-cursor", 0, QEMU_OPTION_show_cursor, \
  2475. "-show-cursor show cursor\n", QEMU_ARCH_ALL)
  2476. STEXI
  2477. @item -show-cursor
  2478. @findex -show-cursor
  2479. Show cursor.
  2480. ETEXI
  2481. DEF("tb-size", HAS_ARG, QEMU_OPTION_tb_size, \
  2482. "-tb-size n set TB size\n", QEMU_ARCH_ALL)
  2483. STEXI
  2484. @item -tb-size @var{n}
  2485. @findex -tb-size
  2486. Set TB size.
  2487. ETEXI
  2488. DEF("incoming", HAS_ARG, QEMU_OPTION_incoming, \
  2489. "-incoming p prepare for incoming migration, listen on port p\n",
  2490. QEMU_ARCH_ALL)
  2491. STEXI
  2492. @item -incoming @var{port}
  2493. @findex -incoming
  2494. Prepare for incoming migration, listen on @var{port}.
  2495. ETEXI
  2496. DEF("nodefaults", 0, QEMU_OPTION_nodefaults, \
  2497. "-nodefaults don't create default devices\n", QEMU_ARCH_ALL)
  2498. STEXI
  2499. @item -nodefaults
  2500. @findex -nodefaults
  2501. Don't create default devices. Normally, QEMU sets the default devices like serial
  2502. port, parallel port, virtual console, monitor device, VGA adapter, floppy and
  2503. CD-ROM drive and others. The @code{-nodefaults} option will disable all those
  2504. default devices.
  2505. ETEXI
  2506. #ifndef _WIN32
  2507. DEF("chroot", HAS_ARG, QEMU_OPTION_chroot, \
  2508. "-chroot dir chroot to dir just before starting the VM\n",
  2509. QEMU_ARCH_ALL)
  2510. #endif
  2511. STEXI
  2512. @item -chroot @var{dir}
  2513. @findex -chroot
  2514. Immediately before starting guest execution, chroot to the specified
  2515. directory. Especially useful in combination with -runas.
  2516. ETEXI
  2517. #ifndef _WIN32
  2518. DEF("runas", HAS_ARG, QEMU_OPTION_runas, \
  2519. "-runas user change to user id user just before starting the VM\n",
  2520. QEMU_ARCH_ALL)
  2521. #endif
  2522. STEXI
  2523. @item -runas @var{user}
  2524. @findex -runas
  2525. Immediately before starting guest execution, drop root privileges, switching
  2526. to the specified user.
  2527. ETEXI
  2528. DEF("prom-env", HAS_ARG, QEMU_OPTION_prom_env,
  2529. "-prom-env variable=value\n"
  2530. " set OpenBIOS nvram variables\n",
  2531. QEMU_ARCH_PPC | QEMU_ARCH_SPARC)
  2532. STEXI
  2533. @item -prom-env @var{variable}=@var{value}
  2534. @findex -prom-env
  2535. Set OpenBIOS nvram @var{variable} to given @var{value} (PPC, SPARC only).
  2536. ETEXI
  2537. DEF("semihosting", 0, QEMU_OPTION_semihosting,
  2538. "-semihosting semihosting mode\n", QEMU_ARCH_ARM | QEMU_ARCH_M68K | QEMU_ARCH_XTENSA)
  2539. STEXI
  2540. @item -semihosting
  2541. @findex -semihosting
  2542. Semihosting mode (ARM, M68K, Xtensa only).
  2543. ETEXI
  2544. DEF("old-param", 0, QEMU_OPTION_old_param,
  2545. "-old-param old param mode\n", QEMU_ARCH_ARM)
  2546. STEXI
  2547. @item -old-param
  2548. @findex -old-param (ARM)
  2549. Old param mode (ARM only).
  2550. ETEXI
  2551. DEF("sandbox", HAS_ARG, QEMU_OPTION_sandbox, \
  2552. "-sandbox <arg> Enable seccomp mode 2 system call filter (default 'off').\n",
  2553. QEMU_ARCH_ALL)
  2554. STEXI
  2555. @item -sandbox @var{arg}
  2556. @findex -sandbox
  2557. Enable Seccomp mode 2 system call filter. 'on' will enable syscall filtering and 'off' will
  2558. disable it. The default is 'off'.
  2559. ETEXI
  2560. DEF("readconfig", HAS_ARG, QEMU_OPTION_readconfig,
  2561. "-readconfig <file>\n", QEMU_ARCH_ALL)
  2562. STEXI
  2563. @item -readconfig @var{file}
  2564. @findex -readconfig
  2565. Read device configuration from @var{file}. This approach is useful when you want to spawn
  2566. QEMU process with many command line options but you don't want to exceed the command line
  2567. character limit.
  2568. ETEXI
  2569. DEF("writeconfig", HAS_ARG, QEMU_OPTION_writeconfig,
  2570. "-writeconfig <file>\n"
  2571. " read/write config file\n", QEMU_ARCH_ALL)
  2572. STEXI
  2573. @item -writeconfig @var{file}
  2574. @findex -writeconfig
  2575. Write device configuration to @var{file}. The @var{file} can be either filename to save
  2576. command line and device configuration into file or dash @code{-}) character to print the
  2577. output to stdout. This can be later used as input file for @code{-readconfig} option.
  2578. ETEXI
  2579. DEF("nodefconfig", 0, QEMU_OPTION_nodefconfig,
  2580. "-nodefconfig\n"
  2581. " do not load default config files at startup\n",
  2582. QEMU_ARCH_ALL)
  2583. STEXI
  2584. @item -nodefconfig
  2585. @findex -nodefconfig
  2586. Normally QEMU loads configuration files from @var{sysconfdir} and @var{datadir} at startup.
  2587. The @code{-nodefconfig} option will prevent QEMU from loading any of those config files.
  2588. ETEXI
  2589. DEF("no-user-config", 0, QEMU_OPTION_nouserconfig,
  2590. "-no-user-config\n"
  2591. " do not load user-provided config files at startup\n",
  2592. QEMU_ARCH_ALL)
  2593. STEXI
  2594. @item -no-user-config
  2595. @findex -no-user-config
  2596. The @code{-no-user-config} option makes QEMU not load any of the user-provided
  2597. config files on @var{sysconfdir}, but won't make it skip the QEMU-provided config
  2598. files from @var{datadir}.
  2599. ETEXI
  2600. DEF("trace", HAS_ARG, QEMU_OPTION_trace,
  2601. "-trace [events=<file>][,file=<file>]\n"
  2602. " specify tracing options\n",
  2603. QEMU_ARCH_ALL)
  2604. STEXI
  2605. HXCOMM This line is not accurate, as some sub-options are backend-specific but
  2606. HXCOMM HX does not support conditional compilation of text.
  2607. @item -trace [events=@var{file}][,file=@var{file}]
  2608. @findex -trace
  2609. Specify tracing options.
  2610. @table @option
  2611. @item events=@var{file}
  2612. Immediately enable events listed in @var{file}.
  2613. The file must contain one event name (as listed in the @var{trace-events} file)
  2614. per line.
  2615. This option is only available if QEMU has been compiled with
  2616. either @var{simple} or @var{stderr} tracing backend.
  2617. @item file=@var{file}
  2618. Log output traces to @var{file}.
  2619. This option is only available if QEMU has been compiled with
  2620. the @var{simple} tracing backend.
  2621. @end table
  2622. ETEXI
  2623. HXCOMM Internal use
  2624. DEF("qtest", HAS_ARG, QEMU_OPTION_qtest, "", QEMU_ARCH_ALL)
  2625. DEF("qtest-log", HAS_ARG, QEMU_OPTION_qtest_log, "", QEMU_ARCH_ALL)
  2626. #ifdef __linux__
  2627. DEF("enable-fips", 0, QEMU_OPTION_enablefips,
  2628. "-enable-fips enable FIPS 140-2 compliance\n",
  2629. QEMU_ARCH_ALL)
  2630. #endif
  2631. STEXI
  2632. @item -enable-fips
  2633. @findex -enable-fips
  2634. Enable FIPS 140-2 compliance mode.
  2635. ETEXI
  2636. HXCOMM Deprecated by -machine accel=tcg property
  2637. DEF("no-kvm", 0, QEMU_OPTION_no_kvm, "", QEMU_ARCH_I386)
  2638. HXCOMM Deprecated by kvm-pit driver properties
  2639. DEF("no-kvm-pit-reinjection", 0, QEMU_OPTION_no_kvm_pit_reinjection,
  2640. "", QEMU_ARCH_I386)
  2641. HXCOMM Deprecated (ignored)
  2642. DEF("no-kvm-pit", 0, QEMU_OPTION_no_kvm_pit, "", QEMU_ARCH_I386)
  2643. HXCOMM Deprecated by -machine kernel_irqchip=on|off property
  2644. DEF("no-kvm-irqchip", 0, QEMU_OPTION_no_kvm_irqchip, "", QEMU_ARCH_I386)
  2645. HXCOMM Deprecated (ignored)
  2646. DEF("tdf", 0, QEMU_OPTION_tdf,"", QEMU_ARCH_ALL)
  2647. DEF("object", HAS_ARG, QEMU_OPTION_object,
  2648. "-object TYPENAME[,PROP1=VALUE1,...]\n"
  2649. " create an new object of type TYPENAME setting properties\n"
  2650. " in the order they are specified. Note that the 'id'\n"
  2651. " property must be set. These objects are placed in the\n"
  2652. " '/objects' path.\n",
  2653. QEMU_ARCH_ALL)
  2654. STEXI
  2655. @item -object @var{typename}[,@var{prop1}=@var{value1},...]
  2656. @findex -object
  2657. Create an new object of type @var{typename} setting properties
  2658. in the order they are specified. Note that the 'id'
  2659. property must be set. These objects are placed in the
  2660. '/objects' path.
  2661. ETEXI
  2662. DEF("msg", HAS_ARG, QEMU_OPTION_msg,
  2663. "-msg timestamp[=on|off]\n"
  2664. " change the format of messages\n"
  2665. " on|off controls leading timestamps (default:on)\n",
  2666. QEMU_ARCH_ALL)
  2667. STEXI
  2668. @item -msg timestamp[=on|off]
  2669. @findex -msg
  2670. prepend a timestamp to each log message.(default:on)
  2671. ETEXI
  2672. HXCOMM This is the last statement. Insert new options before this line!
  2673. STEXI
  2674. @end table
  2675. ETEXI