scripts: Remove scripts/qtest
[qemu/cris-port.git] / qemu-options.hx
blobecd0e342693e8c13729ce29c634c040b5b756731
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
9 DEFHEADING(Standard options:)
10 STEXI
11 @table @option
12 ETEXI
14 DEF("help", 0, QEMU_OPTION_h,
15 "-h or -help display this help and exit\n", QEMU_ARCH_ALL)
16 STEXI
17 @item -h
18 @findex -h
19 Display help and exit
20 ETEXI
22 DEF("version", 0, QEMU_OPTION_version,
23 "-version display version information and exit\n", QEMU_ARCH_ALL)
24 STEXI
25 @item -version
26 @findex -version
27 Display version information and exit
28 ETEXI
30 DEF("machine", HAS_ARG, QEMU_OPTION_machine, \
31 "-machine [type=]name[,prop[=value][,...]]\n"
32 " selects emulated machine ('-machine help' for list)\n"
33 " property accel=accel1[:accel2[:...]] selects accelerator\n"
34 " supported accelerators are kvm, xen, tcg (default: tcg)\n"
35 " kernel_irqchip=on|off controls accelerated irqchip support\n"
36 " kvm_shadow_mem=size of KVM shadow MMU\n"
37 " dump-guest-core=on|off include guest memory in a core dump (default=on)\n"
38 " mem-merge=on|off controls memory merge support (default: on)\n",
39 QEMU_ARCH_ALL)
40 STEXI
41 @item -machine [type=]@var{name}[,prop=@var{value}[,...]]
42 @findex -machine
43 Select the emulated machine by @var{name}. Use @code{-machine help} to list
44 available machines. Supported machine properties are:
45 @table @option
46 @item accel=@var{accels1}[:@var{accels2}[:...]]
47 This is used to enable an accelerator. Depending on the target architecture,
48 kvm, xen, or tcg can be available. By default, tcg is used. If there is more
49 than one accelerator specified, the next one is used if the previous one fails
50 to initialize.
51 @item kernel_irqchip=on|off
52 Enables in-kernel irqchip support for the chosen accelerator when available.
53 @item kvm_shadow_mem=size
54 Defines the size of the KVM shadow MMU.
55 @item dump-guest-core=on|off
56 Include guest memory in a core dump. The default is on.
57 @item mem-merge=on|off
58 Enables or disables memory merge support. This feature, when supported by
59 the host, de-duplicates identical memory pages among VMs instances
60 (enabled by default).
61 @end table
62 ETEXI
64 HXCOMM Deprecated by -machine
65 DEF("M", HAS_ARG, QEMU_OPTION_M, "", QEMU_ARCH_ALL)
67 DEF("cpu", HAS_ARG, QEMU_OPTION_cpu,
68 "-cpu cpu select CPU ('-cpu help' for list)\n", QEMU_ARCH_ALL)
69 STEXI
70 @item -cpu @var{model}
71 @findex -cpu
72 Select CPU model (@code{-cpu help} for list and additional feature selection)
73 ETEXI
75 DEF("smp", HAS_ARG, QEMU_OPTION_smp,
76 "-smp [cpus=]n[,maxcpus=cpus][,cores=cores][,threads=threads][,sockets=sockets]\n"
77 " set the number of CPUs to 'n' [default=1]\n"
78 " maxcpus= maximum number of total cpus, including\n"
79 " offline CPUs for hotplug, etc\n"
80 " cores= number of CPU cores on one socket\n"
81 " threads= number of threads on one CPU core\n"
82 " sockets= number of discrete sockets in the system\n",
83 QEMU_ARCH_ALL)
84 STEXI
85 @item -smp [cpus=]@var{n}[,cores=@var{cores}][,threads=@var{threads}][,sockets=@var{sockets}][,maxcpus=@var{maxcpus}]
86 @findex -smp
87 Simulate an SMP system with @var{n} CPUs. On the PC target, up to 255
88 CPUs are supported. On Sparc32 target, Linux limits the number of usable CPUs
89 to 4.
90 For the PC target, the number of @var{cores} per socket, the number
91 of @var{threads} per cores and the total number of @var{sockets} can be
92 specified. Missing values will be computed. If any on the three values is
93 given, the total number of CPUs @var{n} can be omitted. @var{maxcpus}
94 specifies the maximum number of hotpluggable CPUs.
95 ETEXI
97 DEF("numa", HAS_ARG, QEMU_OPTION_numa,
98 "-numa node[,mem=size][,cpus=cpu[-cpu]][,nodeid=node]\n"
99 "-numa node[,memdev=id][,cpus=cpu[-cpu]][,nodeid=node]\n", QEMU_ARCH_ALL)
100 STEXI
101 @item -numa node[,mem=@var{size}][,cpus=@var{cpu[-cpu]}][,nodeid=@var{node}]
102 @item -numa node[,memdev=@var{id}][,cpus=@var{cpu[-cpu]}][,nodeid=@var{node}]
103 @findex -numa
104 Simulate a multi node NUMA system. If @samp{mem}, @samp{memdev}
105 and @samp{cpus} are omitted, resources are split equally. Also, note
106 that the -@option{numa} option doesn't allocate any of the specified
107 resources. That is, it just assigns existing resources to NUMA nodes. This
108 means that one still has to use the @option{-m}, @option{-smp} options
109 to allocate RAM and VCPUs respectively, and possibly @option{-object}
110 to specify the memory backend for the @samp{memdev} suboption.
112 @samp{mem} and @samp{memdev} are mutually exclusive. Furthermore, if one
113 node uses @samp{memdev}, all of them have to use it.
114 ETEXI
116 DEF("add-fd", HAS_ARG, QEMU_OPTION_add_fd,
117 "-add-fd fd=fd,set=set[,opaque=opaque]\n"
118 " Add 'fd' to fd 'set'\n", QEMU_ARCH_ALL)
119 STEXI
120 @item -add-fd fd=@var{fd},set=@var{set}[,opaque=@var{opaque}]
121 @findex -add-fd
123 Add a file descriptor to an fd set. Valid options are:
125 @table @option
126 @item fd=@var{fd}
127 This option defines the file descriptor of which a duplicate is added to fd set.
128 The file descriptor cannot be stdin, stdout, or stderr.
129 @item set=@var{set}
130 This option defines the ID of the fd set to add the file descriptor to.
131 @item opaque=@var{opaque}
132 This option defines a free-form string that can be used to describe @var{fd}.
133 @end table
135 You can open an image using pre-opened file descriptors from an fd set:
136 @example
137 qemu-system-i386
138 -add-fd fd=3,set=2,opaque="rdwr:/path/to/file"
139 -add-fd fd=4,set=2,opaque="rdonly:/path/to/file"
140 -drive file=/dev/fdset/2,index=0,media=disk
141 @end example
142 ETEXI
144 DEF("set", HAS_ARG, QEMU_OPTION_set,
145 "-set group.id.arg=value\n"
146 " set <arg> parameter for item <id> of type <group>\n"
147 " i.e. -set drive.$id.file=/path/to/image\n", QEMU_ARCH_ALL)
148 STEXI
149 @item -set @var{group}.@var{id}.@var{arg}=@var{value}
150 @findex -set
151 Set parameter @var{arg} for item @var{id} of type @var{group}\n"
152 ETEXI
154 DEF("global", HAS_ARG, QEMU_OPTION_global,
155 "-global driver.prop=value\n"
156 " set a global default for a driver property\n",
157 QEMU_ARCH_ALL)
158 STEXI
159 @item -global @var{driver}.@var{prop}=@var{value}
160 @findex -global
161 Set default value of @var{driver}'s property @var{prop} to @var{value}, e.g.:
163 @example
164 qemu-system-i386 -global ide-drive.physical_block_size=4096 -drive file=file,if=ide,index=0,media=disk
165 @end example
167 In particular, you can use this to set driver properties for devices which are
168 created automatically by the machine model. To create a device which is not
169 created automatically and set properties on it, use -@option{device}.
170 ETEXI
172 DEF("boot", HAS_ARG, QEMU_OPTION_boot,
173 "-boot [order=drives][,once=drives][,menu=on|off]\n"
174 " [,splash=sp_name][,splash-time=sp_time][,reboot-timeout=rb_time][,strict=on|off]\n"
175 " 'drives': floppy (a), hard disk (c), CD-ROM (d), network (n)\n"
176 " 'sp_name': the file's name that would be passed to bios as logo picture, if menu=on\n"
177 " 'sp_time': the period that splash picture last if menu=on, unit is ms\n"
178 " 'rb_timeout': the timeout before guest reboot when boot failed, unit is ms\n",
179 QEMU_ARCH_ALL)
180 STEXI
181 @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]
182 @findex -boot
183 Specify boot order @var{drives} as a string of drive letters. Valid
184 drive letters depend on the target achitecture. The x86 PC uses: a, b
185 (floppy 1 and 2), c (first hard disk), d (first CD-ROM), n-p (Etherboot
186 from network adapter 1-4), hard disk boot is the default. To apply a
187 particular boot order only on the first startup, specify it via
188 @option{once}.
190 Interactive boot menus/prompts can be enabled via @option{menu=on} as far
191 as firmware/BIOS supports them. The default is non-interactive boot.
193 A splash picture could be passed to bios, enabling user to show it as logo,
194 when option splash=@var{sp_name} is given and menu=on, If firmware/BIOS
195 supports them. Currently Seabios for X86 system support it.
196 limitation: The splash file could be a jpeg file or a BMP file in 24 BPP
197 format(true color). The resolution should be supported by the SVGA mode, so
198 the recommended is 320x240, 640x480, 800x640.
200 A timeout could be passed to bios, guest will pause for @var{rb_timeout} ms
201 when boot failed, then reboot. If @var{rb_timeout} is '-1', guest will not
202 reboot, qemu passes '-1' to bios by default. Currently Seabios for X86
203 system support it.
205 Do strict boot via @option{strict=on} as far as firmware/BIOS
206 supports it. This only effects when boot priority is changed by
207 bootindex options. The default is non-strict boot.
209 @example
210 # try to boot from network first, then from hard disk
211 qemu-system-i386 -boot order=nc
212 # boot from CD-ROM first, switch back to default order after reboot
213 qemu-system-i386 -boot once=d
214 # boot with a splash picture for 5 seconds.
215 qemu-system-i386 -boot menu=on,splash=/root/boot.bmp,splash-time=5000
216 @end example
218 Note: The legacy format '-boot @var{drives}' is still supported but its
219 use is discouraged as it may be removed from future versions.
220 ETEXI
222 DEF("m", HAS_ARG, QEMU_OPTION_m,
223 "-m[emory] [size=]megs[,slots=n,maxmem=size]\n"
224 " configure guest RAM\n"
225 " size: initial amount of guest memory (default: "
226 stringify(DEFAULT_RAM_SIZE) "MiB)\n"
227 " slots: number of hotplug slots (default: none)\n"
228 " maxmem: maximum amount of guest memory (default: none)\n"
229 "NOTE: Some architectures might enforce a specific granularity\n",
230 QEMU_ARCH_ALL)
231 STEXI
232 @item -m [size=]@var{megs}
233 @findex -m
234 Set virtual RAM size to @var{megs} megabytes. Default is 128 MiB. Optionally,
235 a suffix of ``M'' or ``G'' can be used to signify a value in megabytes or
236 gigabytes respectively. Optional pair @var{slots}, @var{maxmem} could be used
237 to set amount of hotluggable memory slots and possible maximum amount of memory.
238 ETEXI
240 DEF("mem-path", HAS_ARG, QEMU_OPTION_mempath,
241 "-mem-path FILE provide backing storage for guest RAM\n", QEMU_ARCH_ALL)
242 STEXI
243 @item -mem-path @var{path}
244 @findex -mem-path
245 Allocate guest RAM from a temporarily created file in @var{path}.
246 ETEXI
248 DEF("mem-prealloc", 0, QEMU_OPTION_mem_prealloc,
249 "-mem-prealloc preallocate guest memory (use with -mem-path)\n",
250 QEMU_ARCH_ALL)
251 STEXI
252 @item -mem-prealloc
253 @findex -mem-prealloc
254 Preallocate memory when using -mem-path.
255 ETEXI
257 DEF("k", HAS_ARG, QEMU_OPTION_k,
258 "-k language use keyboard layout (for example 'fr' for French)\n",
259 QEMU_ARCH_ALL)
260 STEXI
261 @item -k @var{language}
262 @findex -k
263 Use keyboard layout @var{language} (for example @code{fr} for
264 French). This option is only needed where it is not easy to get raw PC
265 keycodes (e.g. on Macs, with some X11 servers or with a VNC
266 display). You don't normally need to use it on PC/Linux or PC/Windows
267 hosts.
269 The available layouts are:
270 @example
271 ar de-ch es fo fr-ca hu ja mk no pt-br sv
272 da en-gb et fr fr-ch is lt nl pl ru th
273 de en-us fi fr-be hr it lv nl-be pt sl tr
274 @end example
276 The default is @code{en-us}.
277 ETEXI
280 DEF("audio-help", 0, QEMU_OPTION_audio_help,
281 "-audio-help print list of audio drivers and their options\n",
282 QEMU_ARCH_ALL)
283 STEXI
284 @item -audio-help
285 @findex -audio-help
286 Will show the audio subsystem help: list of drivers, tunable
287 parameters.
288 ETEXI
290 DEF("soundhw", HAS_ARG, QEMU_OPTION_soundhw,
291 "-soundhw c1,... enable audio support\n"
292 " and only specified sound cards (comma separated list)\n"
293 " use '-soundhw help' to get the list of supported cards\n"
294 " use '-soundhw all' to enable all of them\n", QEMU_ARCH_ALL)
295 STEXI
296 @item -soundhw @var{card1}[,@var{card2},...] or -soundhw all
297 @findex -soundhw
298 Enable audio and selected sound hardware. Use 'help' to print all
299 available sound hardware.
301 @example
302 qemu-system-i386 -soundhw sb16,adlib disk.img
303 qemu-system-i386 -soundhw es1370 disk.img
304 qemu-system-i386 -soundhw ac97 disk.img
305 qemu-system-i386 -soundhw hda disk.img
306 qemu-system-i386 -soundhw all disk.img
307 qemu-system-i386 -soundhw help
308 @end example
310 Note that Linux's i810_audio OSS kernel (for AC97) module might
311 require manually specifying clocking.
313 @example
314 modprobe i810_audio clocking=48000
315 @end example
316 ETEXI
318 DEF("balloon", HAS_ARG, QEMU_OPTION_balloon,
319 "-balloon none disable balloon device\n"
320 "-balloon virtio[,addr=str]\n"
321 " enable virtio balloon device (default)\n", QEMU_ARCH_ALL)
322 STEXI
323 @item -balloon none
324 @findex -balloon
325 Disable balloon device.
326 @item -balloon virtio[,addr=@var{addr}]
327 Enable virtio balloon device (default), optionally with PCI address
328 @var{addr}.
329 ETEXI
331 DEF("device", HAS_ARG, QEMU_OPTION_device,
332 "-device driver[,prop[=value][,...]]\n"
333 " add device (based on driver)\n"
334 " prop=value,... sets driver properties\n"
335 " use '-device help' to print all possible drivers\n"
336 " use '-device driver,help' to print all possible properties\n",
337 QEMU_ARCH_ALL)
338 STEXI
339 @item -device @var{driver}[,@var{prop}[=@var{value}][,...]]
340 @findex -device
341 Add device @var{driver}. @var{prop}=@var{value} sets driver
342 properties. Valid properties depend on the driver. To get help on
343 possible drivers and properties, use @code{-device help} and
344 @code{-device @var{driver},help}.
345 ETEXI
347 DEF("name", HAS_ARG, QEMU_OPTION_name,
348 "-name string1[,process=string2][,debug-threads=on|off]\n"
349 " set the name of the guest\n"
350 " string1 sets the window title and string2 the process name (on Linux)\n"
351 " When debug-threads is enabled, individual threads are given a separate name (on Linux)\n"
352 " NOTE: The thread names are for debugging and not a stable API.\n",
353 QEMU_ARCH_ALL)
354 STEXI
355 @item -name @var{name}
356 @findex -name
357 Sets the @var{name} of the guest.
358 This name will be displayed in the SDL window caption.
359 The @var{name} will also be used for the VNC server.
360 Also optionally set the top visible process name in Linux.
361 Naming of individual threads can also be enabled on Linux to aid debugging.
362 ETEXI
364 DEF("uuid", HAS_ARG, QEMU_OPTION_uuid,
365 "-uuid %08x-%04x-%04x-%04x-%012x\n"
366 " specify machine UUID\n", QEMU_ARCH_ALL)
367 STEXI
368 @item -uuid @var{uuid}
369 @findex -uuid
370 Set system UUID.
371 ETEXI
373 STEXI
374 @end table
375 ETEXI
376 DEFHEADING()
378 DEFHEADING(Block device options:)
379 STEXI
380 @table @option
381 ETEXI
383 DEF("fda", HAS_ARG, QEMU_OPTION_fda,
384 "-fda/-fdb file use 'file' as floppy disk 0/1 image\n", QEMU_ARCH_ALL)
385 DEF("fdb", HAS_ARG, QEMU_OPTION_fdb, "", QEMU_ARCH_ALL)
386 STEXI
387 @item -fda @var{file}
388 @item -fdb @var{file}
389 @findex -fda
390 @findex -fdb
391 Use @var{file} as floppy disk 0/1 image (@pxref{disk_images}). You can
392 use the host floppy by using @file{/dev/fd0} as filename (@pxref{host_drives}).
393 ETEXI
395 DEF("hda", HAS_ARG, QEMU_OPTION_hda,
396 "-hda/-hdb file use 'file' as IDE hard disk 0/1 image\n", QEMU_ARCH_ALL)
397 DEF("hdb", HAS_ARG, QEMU_OPTION_hdb, "", QEMU_ARCH_ALL)
398 DEF("hdc", HAS_ARG, QEMU_OPTION_hdc,
399 "-hdc/-hdd file use 'file' as IDE hard disk 2/3 image\n", QEMU_ARCH_ALL)
400 DEF("hdd", HAS_ARG, QEMU_OPTION_hdd, "", QEMU_ARCH_ALL)
401 STEXI
402 @item -hda @var{file}
403 @item -hdb @var{file}
404 @item -hdc @var{file}
405 @item -hdd @var{file}
406 @findex -hda
407 @findex -hdb
408 @findex -hdc
409 @findex -hdd
410 Use @var{file} as hard disk 0, 1, 2 or 3 image (@pxref{disk_images}).
411 ETEXI
413 DEF("cdrom", HAS_ARG, QEMU_OPTION_cdrom,
414 "-cdrom file use 'file' as IDE cdrom image (cdrom is ide1 master)\n",
415 QEMU_ARCH_ALL)
416 STEXI
417 @item -cdrom @var{file}
418 @findex -cdrom
419 Use @var{file} as CD-ROM image (you cannot use @option{-hdc} and
420 @option{-cdrom} at the same time). You can use the host CD-ROM by
421 using @file{/dev/cdrom} as filename (@pxref{host_drives}).
422 ETEXI
424 DEF("drive", HAS_ARG, QEMU_OPTION_drive,
425 "-drive [file=file][,if=type][,bus=n][,unit=m][,media=d][,index=i]\n"
426 " [,cyls=c,heads=h,secs=s[,trans=t]][,snapshot=on|off]\n"
427 " [,cache=writethrough|writeback|none|directsync|unsafe][,format=f]\n"
428 " [,serial=s][,addr=A][,rerror=ignore|stop|report]\n"
429 " [,werror=ignore|stop|report|enospc][,id=name][,aio=threads|native]\n"
430 " [,readonly=on|off][,copy-on-read=on|off]\n"
431 " [,discard=ignore|unmap][,detect-zeroes=on|off|unmap]\n"
432 " [[,bps=b]|[[,bps_rd=r][,bps_wr=w]]]\n"
433 " [[,iops=i]|[[,iops_rd=r][,iops_wr=w]]]\n"
434 " [[,bps_max=bm]|[[,bps_rd_max=rm][,bps_wr_max=wm]]]\n"
435 " [[,iops_max=im]|[[,iops_rd_max=irm][,iops_wr_max=iwm]]]\n"
436 " [[,iops_size=is]]\n"
437 " use 'file' as a drive image\n", QEMU_ARCH_ALL)
438 STEXI
439 @item -drive @var{option}[,@var{option}[,@var{option}[,...]]]
440 @findex -drive
442 Define a new drive. Valid options are:
444 @table @option
445 @item file=@var{file}
446 This option defines which disk image (@pxref{disk_images}) to use with
447 this drive. If the filename contains comma, you must double it
448 (for instance, "file=my,,file" to use file "my,file").
450 Special files such as iSCSI devices can be specified using protocol
451 specific URLs. See the section for "Device URL Syntax" for more information.
452 @item if=@var{interface}
453 This option defines on which type on interface the drive is connected.
454 Available types are: ide, scsi, sd, mtd, floppy, pflash, virtio.
455 @item bus=@var{bus},unit=@var{unit}
456 These options define where is connected the drive by defining the bus number and
457 the unit id.
458 @item index=@var{index}
459 This option defines where is connected the drive by using an index in the list
460 of available connectors of a given interface type.
461 @item media=@var{media}
462 This option defines the type of the media: disk or cdrom.
463 @item cyls=@var{c},heads=@var{h},secs=@var{s}[,trans=@var{t}]
464 These options have the same definition as they have in @option{-hdachs}.
465 @item snapshot=@var{snapshot}
466 @var{snapshot} is "on" or "off" and controls snapshot mode for the given drive
467 (see @option{-snapshot}).
468 @item cache=@var{cache}
469 @var{cache} is "none", "writeback", "unsafe", "directsync" or "writethrough" and controls how the host cache is used to access block data.
470 @item aio=@var{aio}
471 @var{aio} is "threads", or "native" and selects between pthread based disk I/O and native Linux AIO.
472 @item discard=@var{discard}
473 @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.
474 @item format=@var{format}
475 Specify which disk @var{format} will be used rather than detecting
476 the format. Can be used to specifiy format=raw to avoid interpreting
477 an untrusted format header.
478 @item serial=@var{serial}
479 This option specifies the serial number to assign to the device.
480 @item addr=@var{addr}
481 Specify the controller's PCI address (if=virtio only).
482 @item werror=@var{action},rerror=@var{action}
483 Specify which @var{action} to take on write and read errors. Valid actions are:
484 "ignore" (ignore the error and try to continue), "stop" (pause QEMU),
485 "report" (report the error to the guest), "enospc" (pause QEMU only if the
486 host disk is full; report the error to the guest otherwise).
487 The default setting is @option{werror=enospc} and @option{rerror=report}.
488 @item readonly
489 Open drive @option{file} as read-only. Guest write attempts will fail.
490 @item copy-on-read=@var{copy-on-read}
491 @var{copy-on-read} is "on" or "off" and enables whether to copy read backing
492 file sectors into the image file.
493 @item detect-zeroes=@var{detect-zeroes}
494 @var{detect-zeroes} is "off", "on" or "unmap" and enables the automatic
495 conversion of plain zero writes by the OS to driver specific optimized
496 zero write commands. You may even choose "unmap" if @var{discard} is set
497 to "unmap" to allow a zero write to be converted to an UNMAP operation.
498 @end table
500 By default, the @option{cache=writeback} mode is used. It will report data
501 writes as completed as soon as the data is present in the host page cache.
502 This is safe as long as your guest OS makes sure to correctly flush disk caches
503 where needed. If your guest OS does not handle volatile disk write caches
504 correctly and your host crashes or loses power, then the guest may experience
505 data corruption.
507 For such guests, you should consider using @option{cache=writethrough}. This
508 means that the host page cache will be used to read and write data, but write
509 notification will be sent to the guest only after QEMU has made sure to flush
510 each write to the disk. Be aware that this has a major impact on performance.
512 The host page cache can be avoided entirely with @option{cache=none}. This will
513 attempt to do disk IO directly to the guest's memory. QEMU may still perform
514 an internal copy of the data. Note that this is considered a writeback mode and
515 the guest OS must handle the disk write cache correctly in order to avoid data
516 corruption on host crashes.
518 The host page cache can be avoided while only sending write notifications to
519 the guest when the data has been flushed to the disk using
520 @option{cache=directsync}.
522 In case you don't care about data integrity over host failures, use
523 @option{cache=unsafe}. This option tells QEMU that it never needs to write any
524 data to the disk but can instead keep things in cache. If anything goes wrong,
525 like your host losing power, the disk storage getting disconnected accidentally,
526 etc. your image will most probably be rendered unusable. When using
527 the @option{-snapshot} option, unsafe caching is always used.
529 Copy-on-read avoids accessing the same backing file sectors repeatedly and is
530 useful when the backing file is over a slow network. By default copy-on-read
531 is off.
533 Instead of @option{-cdrom} you can use:
534 @example
535 qemu-system-i386 -drive file=file,index=2,media=cdrom
536 @end example
538 Instead of @option{-hda}, @option{-hdb}, @option{-hdc}, @option{-hdd}, you can
539 use:
540 @example
541 qemu-system-i386 -drive file=file,index=0,media=disk
542 qemu-system-i386 -drive file=file,index=1,media=disk
543 qemu-system-i386 -drive file=file,index=2,media=disk
544 qemu-system-i386 -drive file=file,index=3,media=disk
545 @end example
547 You can open an image using pre-opened file descriptors from an fd set:
548 @example
549 qemu-system-i386
550 -add-fd fd=3,set=2,opaque="rdwr:/path/to/file"
551 -add-fd fd=4,set=2,opaque="rdonly:/path/to/file"
552 -drive file=/dev/fdset/2,index=0,media=disk
553 @end example
555 You can connect a CDROM to the slave of ide0:
556 @example
557 qemu-system-i386 -drive file=file,if=ide,index=1,media=cdrom
558 @end example
560 If you don't specify the "file=" argument, you define an empty drive:
561 @example
562 qemu-system-i386 -drive if=ide,index=1,media=cdrom
563 @end example
565 You can connect a SCSI disk with unit ID 6 on the bus #0:
566 @example
567 qemu-system-i386 -drive file=file,if=scsi,bus=0,unit=6
568 @end example
570 Instead of @option{-fda}, @option{-fdb}, you can use:
571 @example
572 qemu-system-i386 -drive file=file,index=0,if=floppy
573 qemu-system-i386 -drive file=file,index=1,if=floppy
574 @end example
576 By default, @var{interface} is "ide" and @var{index} is automatically
577 incremented:
578 @example
579 qemu-system-i386 -drive file=a -drive file=b"
580 @end example
581 is interpreted like:
582 @example
583 qemu-system-i386 -hda a -hdb b
584 @end example
585 ETEXI
587 DEF("mtdblock", HAS_ARG, QEMU_OPTION_mtdblock,
588 "-mtdblock file use 'file' as on-board Flash memory image\n",
589 QEMU_ARCH_ALL)
590 STEXI
591 @item -mtdblock @var{file}
592 @findex -mtdblock
593 Use @var{file} as on-board Flash memory image.
594 ETEXI
596 DEF("sd", HAS_ARG, QEMU_OPTION_sd,
597 "-sd file use 'file' as SecureDigital card image\n", QEMU_ARCH_ALL)
598 STEXI
599 @item -sd @var{file}
600 @findex -sd
601 Use @var{file} as SecureDigital card image.
602 ETEXI
604 DEF("pflash", HAS_ARG, QEMU_OPTION_pflash,
605 "-pflash file use 'file' as a parallel flash image\n", QEMU_ARCH_ALL)
606 STEXI
607 @item -pflash @var{file}
608 @findex -pflash
609 Use @var{file} as a parallel flash image.
610 ETEXI
612 DEF("snapshot", 0, QEMU_OPTION_snapshot,
613 "-snapshot write to temporary files instead of disk image files\n",
614 QEMU_ARCH_ALL)
615 STEXI
616 @item -snapshot
617 @findex -snapshot
618 Write to temporary files instead of disk image files. In this case,
619 the raw disk image you use is not written back. You can however force
620 the write back by pressing @key{C-a s} (@pxref{disk_images}).
621 ETEXI
623 DEF("hdachs", HAS_ARG, QEMU_OPTION_hdachs, \
624 "-hdachs c,h,s[,t]\n" \
625 " force hard disk 0 physical geometry and the optional BIOS\n" \
626 " translation (t=none or lba) (usually QEMU can guess them)\n",
627 QEMU_ARCH_ALL)
628 STEXI
629 @item -hdachs @var{c},@var{h},@var{s},[,@var{t}]
630 @findex -hdachs
631 Force hard disk 0 physical geometry (1 <= @var{c} <= 16383, 1 <=
632 @var{h} <= 16, 1 <= @var{s} <= 63) and optionally force the BIOS
633 translation mode (@var{t}=none, lba or auto). Usually QEMU can guess
634 all those parameters. This option is useful for old MS-DOS disk
635 images.
636 ETEXI
638 DEF("fsdev", HAS_ARG, QEMU_OPTION_fsdev,
639 "-fsdev fsdriver,id=id[,path=path,][security_model={mapped-xattr|mapped-file|passthrough|none}]\n"
640 " [,writeout=immediate][,readonly][,socket=socket|sock_fd=sock_fd]\n",
641 QEMU_ARCH_ALL)
643 STEXI
645 @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}]
646 @findex -fsdev
647 Define a new file system device. Valid options are:
648 @table @option
649 @item @var{fsdriver}
650 This option specifies the fs driver backend to use.
651 Currently "local", "handle" and "proxy" file system drivers are supported.
652 @item id=@var{id}
653 Specifies identifier for this device
654 @item path=@var{path}
655 Specifies the export path for the file system device. Files under
656 this path will be available to the 9p client on the guest.
657 @item security_model=@var{security_model}
658 Specifies the security model to be used for this export path.
659 Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
660 In "passthrough" security model, files are stored using the same
661 credentials as they are created on the guest. This requires QEMU
662 to run as root. In "mapped-xattr" security model, some of the file
663 attributes like uid, gid, mode bits and link target are stored as
664 file attributes. For "mapped-file" these attributes are stored in the
665 hidden .virtfs_metadata directory. Directories exported by this security model cannot
666 interact with other unix tools. "none" security model is same as
667 passthrough except the sever won't report failures if it fails to
668 set file attributes like ownership. Security model is mandatory
669 only for local fsdriver. Other fsdrivers (like handle, proxy) don't take
670 security model as a parameter.
671 @item writeout=@var{writeout}
672 This is an optional argument. The only supported value is "immediate".
673 This means that host page cache will be used to read and write data but
674 write notification will be sent to the guest only when the data has been
675 reported as written by the storage subsystem.
676 @item readonly
677 Enables exporting 9p share as a readonly mount for guests. By default
678 read-write access is given.
679 @item socket=@var{socket}
680 Enables proxy filesystem driver to use passed socket file for communicating
681 with virtfs-proxy-helper
682 @item sock_fd=@var{sock_fd}
683 Enables proxy filesystem driver to use passed socket descriptor for
684 communicating with virtfs-proxy-helper. Usually a helper like libvirt
685 will create socketpair and pass one of the fds as sock_fd
686 @end table
688 -fsdev option is used along with -device driver "virtio-9p-pci".
689 @item -device virtio-9p-pci,fsdev=@var{id},mount_tag=@var{mount_tag}
690 Options for virtio-9p-pci driver are:
691 @table @option
692 @item fsdev=@var{id}
693 Specifies the id value specified along with -fsdev option
694 @item mount_tag=@var{mount_tag}
695 Specifies the tag name to be used by the guest to mount this export point
696 @end table
698 ETEXI
700 DEF("virtfs", HAS_ARG, QEMU_OPTION_virtfs,
701 "-virtfs local,path=path,mount_tag=tag,security_model=[mapped-xattr|mapped-file|passthrough|none]\n"
702 " [,writeout=immediate][,readonly][,socket=socket|sock_fd=sock_fd]\n",
703 QEMU_ARCH_ALL)
705 STEXI
707 @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}]
708 @findex -virtfs
710 The general form of a Virtual File system pass-through options are:
711 @table @option
712 @item @var{fsdriver}
713 This option specifies the fs driver backend to use.
714 Currently "local", "handle" and "proxy" file system drivers are supported.
715 @item id=@var{id}
716 Specifies identifier for this device
717 @item path=@var{path}
718 Specifies the export path for the file system device. Files under
719 this path will be available to the 9p client on the guest.
720 @item security_model=@var{security_model}
721 Specifies the security model to be used for this export path.
722 Supported security models are "passthrough", "mapped-xattr", "mapped-file" and "none".
723 In "passthrough" security model, files are stored using the same
724 credentials as they are created on the guest. This requires QEMU
725 to run as root. In "mapped-xattr" security model, some of the file
726 attributes like uid, gid, mode bits and link target are stored as
727 file attributes. For "mapped-file" these attributes are stored in the
728 hidden .virtfs_metadata directory. Directories exported by this security model cannot
729 interact with other unix tools. "none" security model is same as
730 passthrough except the sever won't report failures if it fails to
731 set file attributes like ownership. Security model is mandatory only
732 for local fsdriver. Other fsdrivers (like handle, proxy) don't take security
733 model as a parameter.
734 @item writeout=@var{writeout}
735 This is an optional argument. The only supported value is "immediate".
736 This means that host page cache will be used to read and write data but
737 write notification will be sent to the guest only when the data has been
738 reported as written by the storage subsystem.
739 @item readonly
740 Enables exporting 9p share as a readonly mount for guests. By default
741 read-write access is given.
742 @item socket=@var{socket}
743 Enables proxy filesystem driver to use passed socket file for
744 communicating with virtfs-proxy-helper. Usually a helper like libvirt
745 will create socketpair and pass one of the fds as sock_fd
746 @item sock_fd
747 Enables proxy filesystem driver to use passed 'sock_fd' as the socket
748 descriptor for interfacing with virtfs-proxy-helper
749 @end table
750 ETEXI
752 DEF("virtfs_synth", 0, QEMU_OPTION_virtfs_synth,
753 "-virtfs_synth Create synthetic file system image\n",
754 QEMU_ARCH_ALL)
755 STEXI
756 @item -virtfs_synth
757 @findex -virtfs_synth
758 Create synthetic file system image
759 ETEXI
761 STEXI
762 @end table
763 ETEXI
764 DEFHEADING()
766 DEFHEADING(USB options:)
767 STEXI
768 @table @option
769 ETEXI
771 DEF("usb", 0, QEMU_OPTION_usb,
772 "-usb enable the USB driver (will be the default soon)\n",
773 QEMU_ARCH_ALL)
774 STEXI
775 @item -usb
776 @findex -usb
777 Enable the USB driver (will be the default soon)
778 ETEXI
780 DEF("usbdevice", HAS_ARG, QEMU_OPTION_usbdevice,
781 "-usbdevice name add the host or guest USB device 'name'\n",
782 QEMU_ARCH_ALL)
783 STEXI
785 @item -usbdevice @var{devname}
786 @findex -usbdevice
787 Add the USB device @var{devname}. @xref{usb_devices}.
789 @table @option
791 @item mouse
792 Virtual Mouse. This will override the PS/2 mouse emulation when activated.
794 @item tablet
795 Pointer device that uses absolute coordinates (like a touchscreen). This
796 means QEMU is able to report the mouse position without having to grab the
797 mouse. Also overrides the PS/2 mouse emulation when activated.
799 @item disk:[format=@var{format}]:@var{file}
800 Mass storage device based on file. The optional @var{format} argument
801 will be used rather than detecting the format. Can be used to specifiy
802 @code{format=raw} to avoid interpreting an untrusted format header.
804 @item host:@var{bus}.@var{addr}
805 Pass through the host device identified by @var{bus}.@var{addr} (Linux only).
807 @item host:@var{vendor_id}:@var{product_id}
808 Pass through the host device identified by @var{vendor_id}:@var{product_id}
809 (Linux only).
811 @item serial:[vendorid=@var{vendor_id}][,productid=@var{product_id}]:@var{dev}
812 Serial converter to host character device @var{dev}, see @code{-serial} for the
813 available devices.
815 @item braille
816 Braille device. This will use BrlAPI to display the braille output on a real
817 or fake device.
819 @item net:@var{options}
820 Network adapter that supports CDC ethernet and RNDIS protocols.
822 @end table
823 ETEXI
825 STEXI
826 @end table
827 ETEXI
828 DEFHEADING()
830 DEFHEADING(Display options:)
831 STEXI
832 @table @option
833 ETEXI
835 DEF("display", HAS_ARG, QEMU_OPTION_display,
836 "-display sdl[,frame=on|off][,alt_grab=on|off][,ctrl_grab=on|off]\n"
837 " [,window_close=on|off]|curses|none|\n"
838 " gtk[,grab_on_hover=on|off]|\n"
839 " vnc=<display>[,<optargs>]\n"
840 " select display type\n", QEMU_ARCH_ALL)
841 STEXI
842 @item -display @var{type}
843 @findex -display
844 Select type of display to use. This option is a replacement for the
845 old style -sdl/-curses/... options. Valid values for @var{type} are
846 @table @option
847 @item sdl
848 Display video output via SDL (usually in a separate graphics
849 window; see the SDL documentation for other possibilities).
850 @item curses
851 Display video output via curses. For graphics device models which
852 support a text mode, QEMU can display this output using a
853 curses/ncurses interface. Nothing is displayed when the graphics
854 device is in graphical mode or if the graphics device does not support
855 a text mode. Generally only the VGA device models support text mode.
856 @item none
857 Do not display video output. The guest will still see an emulated
858 graphics card, but its output will not be displayed to the QEMU
859 user. This option differs from the -nographic option in that it
860 only affects what is done with video output; -nographic also changes
861 the destination of the serial and parallel port data.
862 @item gtk
863 Display video output in a GTK window. This interface provides drop-down
864 menus and other UI elements to configure and control the VM during
865 runtime.
866 @item vnc
867 Start a VNC server on display <arg>
868 @end table
869 ETEXI
871 DEF("nographic", 0, QEMU_OPTION_nographic,
872 "-nographic disable graphical output and redirect serial I/Os to console\n",
873 QEMU_ARCH_ALL)
874 STEXI
875 @item -nographic
876 @findex -nographic
877 Normally, QEMU uses SDL to display the VGA output. With this option,
878 you can totally disable graphical output so that QEMU is a simple
879 command line application. The emulated serial port is redirected on
880 the console and muxed with the monitor (unless redirected elsewhere
881 explicitly). Therefore, you can still use QEMU to debug a Linux kernel
882 with a serial console. Use @key{C-a h} for help on switching between
883 the console and monitor.
884 ETEXI
886 DEF("curses", 0, QEMU_OPTION_curses,
887 "-curses use a curses/ncurses interface instead of SDL\n",
888 QEMU_ARCH_ALL)
889 STEXI
890 @item -curses
891 @findex -curses
892 Normally, QEMU uses SDL to display the VGA output. With this option,
893 QEMU can display the VGA output when in text mode using a
894 curses/ncurses interface. Nothing is displayed in graphical mode.
895 ETEXI
897 DEF("no-frame", 0, QEMU_OPTION_no_frame,
898 "-no-frame open SDL window without a frame and window decorations\n",
899 QEMU_ARCH_ALL)
900 STEXI
901 @item -no-frame
902 @findex -no-frame
903 Do not use decorations for SDL windows and start them using the whole
904 available screen space. This makes the using QEMU in a dedicated desktop
905 workspace more convenient.
906 ETEXI
908 DEF("alt-grab", 0, QEMU_OPTION_alt_grab,
909 "-alt-grab use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt)\n",
910 QEMU_ARCH_ALL)
911 STEXI
912 @item -alt-grab
913 @findex -alt-grab
914 Use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt). Note that this also
915 affects the special keys (for fullscreen, monitor-mode switching, etc).
916 ETEXI
918 DEF("ctrl-grab", 0, QEMU_OPTION_ctrl_grab,
919 "-ctrl-grab use Right-Ctrl to grab mouse (instead of Ctrl-Alt)\n",
920 QEMU_ARCH_ALL)
921 STEXI
922 @item -ctrl-grab
923 @findex -ctrl-grab
924 Use Right-Ctrl to grab mouse (instead of Ctrl-Alt). Note that this also
925 affects the special keys (for fullscreen, monitor-mode switching, etc).
926 ETEXI
928 DEF("no-quit", 0, QEMU_OPTION_no_quit,
929 "-no-quit disable SDL window close capability\n", QEMU_ARCH_ALL)
930 STEXI
931 @item -no-quit
932 @findex -no-quit
933 Disable SDL window close capability.
934 ETEXI
936 DEF("sdl", 0, QEMU_OPTION_sdl,
937 "-sdl enable SDL\n", QEMU_ARCH_ALL)
938 STEXI
939 @item -sdl
940 @findex -sdl
941 Enable SDL.
942 ETEXI
944 DEF("spice", HAS_ARG, QEMU_OPTION_spice,
945 "-spice [port=port][,tls-port=secured-port][,x509-dir=<dir>]\n"
946 " [,x509-key-file=<file>][,x509-key-password=<file>]\n"
947 " [,x509-cert-file=<file>][,x509-cacert-file=<file>]\n"
948 " [,x509-dh-key-file=<file>][,addr=addr][,ipv4|ipv6]\n"
949 " [,tls-ciphers=<list>]\n"
950 " [,tls-channel=[main|display|cursor|inputs|record|playback]]\n"
951 " [,plaintext-channel=[main|display|cursor|inputs|record|playback]]\n"
952 " [,sasl][,password=<secret>][,disable-ticketing]\n"
953 " [,image-compression=[auto_glz|auto_lz|quic|glz|lz|off]]\n"
954 " [,jpeg-wan-compression=[auto|never|always]]\n"
955 " [,zlib-glz-wan-compression=[auto|never|always]]\n"
956 " [,streaming-video=[off|all|filter]][,disable-copy-paste]\n"
957 " [,disable-agent-file-xfer][,agent-mouse=[on|off]]\n"
958 " [,playback-compression=[on|off]][,seamless-migration=[on|off]]\n"
959 " enable spice\n"
960 " at least one of {port, tls-port} is mandatory\n",
961 QEMU_ARCH_ALL)
962 STEXI
963 @item -spice @var{option}[,@var{option}[,...]]
964 @findex -spice
965 Enable the spice remote desktop protocol. Valid options are
967 @table @option
969 @item port=<nr>
970 Set the TCP port spice is listening on for plaintext channels.
972 @item addr=<addr>
973 Set the IP address spice is listening on. Default is any address.
975 @item ipv4
976 @item ipv6
977 Force using the specified IP version.
979 @item password=<secret>
980 Set the password you need to authenticate.
982 @item sasl
983 Require that the client use SASL to authenticate with the spice.
984 The exact choice of authentication method used is controlled from the
985 system / user's SASL configuration file for the 'qemu' service. This
986 is typically found in /etc/sasl2/qemu.conf. If running QEMU as an
987 unprivileged user, an environment variable SASL_CONF_PATH can be used
988 to make it search alternate locations for the service config.
989 While some SASL auth methods can also provide data encryption (eg GSSAPI),
990 it is recommended that SASL always be combined with the 'tls' and
991 'x509' settings to enable use of SSL and server certificates. This
992 ensures a data encryption preventing compromise of authentication
993 credentials.
995 @item disable-ticketing
996 Allow client connects without authentication.
998 @item disable-copy-paste
999 Disable copy paste between the client and the guest.
1001 @item disable-agent-file-xfer
1002 Disable spice-vdagent based file-xfer between the client and the guest.
1004 @item tls-port=<nr>
1005 Set the TCP port spice is listening on for encrypted channels.
1007 @item x509-dir=<dir>
1008 Set the x509 file directory. Expects same filenames as -vnc $display,x509=$dir
1010 @item x509-key-file=<file>
1011 @item x509-key-password=<file>
1012 @item x509-cert-file=<file>
1013 @item x509-cacert-file=<file>
1014 @item x509-dh-key-file=<file>
1015 The x509 file names can also be configured individually.
1017 @item tls-ciphers=<list>
1018 Specify which ciphers to use.
1020 @item tls-channel=[main|display|cursor|inputs|record|playback]
1021 @item plaintext-channel=[main|display|cursor|inputs|record|playback]
1022 Force specific channel to be used with or without TLS encryption. The
1023 options can be specified multiple times to configure multiple
1024 channels. The special name "default" can be used to set the default
1025 mode. For channels which are not explicitly forced into one mode the
1026 spice client is allowed to pick tls/plaintext as he pleases.
1028 @item image-compression=[auto_glz|auto_lz|quic|glz|lz|off]
1029 Configure image compression (lossless).
1030 Default is auto_glz.
1032 @item jpeg-wan-compression=[auto|never|always]
1033 @item zlib-glz-wan-compression=[auto|never|always]
1034 Configure wan image compression (lossy for slow links).
1035 Default is auto.
1037 @item streaming-video=[off|all|filter]
1038 Configure video stream detection. Default is filter.
1040 @item agent-mouse=[on|off]
1041 Enable/disable passing mouse events via vdagent. Default is on.
1043 @item playback-compression=[on|off]
1044 Enable/disable audio stream compression (using celt 0.5.1). Default is on.
1046 @item seamless-migration=[on|off]
1047 Enable/disable spice seamless migration. Default is off.
1049 @end table
1050 ETEXI
1052 DEF("portrait", 0, QEMU_OPTION_portrait,
1053 "-portrait rotate graphical output 90 deg left (only PXA LCD)\n",
1054 QEMU_ARCH_ALL)
1055 STEXI
1056 @item -portrait
1057 @findex -portrait
1058 Rotate graphical output 90 deg left (only PXA LCD).
1059 ETEXI
1061 DEF("rotate", HAS_ARG, QEMU_OPTION_rotate,
1062 "-rotate <deg> rotate graphical output some deg left (only PXA LCD)\n",
1063 QEMU_ARCH_ALL)
1064 STEXI
1065 @item -rotate @var{deg}
1066 @findex -rotate
1067 Rotate graphical output some deg left (only PXA LCD).
1068 ETEXI
1070 DEF("vga", HAS_ARG, QEMU_OPTION_vga,
1071 "-vga [std|cirrus|vmware|qxl|xenfb|tcx|cg3|none]\n"
1072 " select video card type\n", QEMU_ARCH_ALL)
1073 STEXI
1074 @item -vga @var{type}
1075 @findex -vga
1076 Select type of VGA card to emulate. Valid values for @var{type} are
1077 @table @option
1078 @item cirrus
1079 Cirrus Logic GD5446 Video card. All Windows versions starting from
1080 Windows 95 should recognize and use this graphic card. For optimal
1081 performances, use 16 bit color depth in the guest and the host OS.
1082 (This one is the default)
1083 @item std
1084 Standard VGA card with Bochs VBE extensions. If your guest OS
1085 supports the VESA 2.0 VBE extensions (e.g. Windows XP) and if you want
1086 to use high resolution modes (>= 1280x1024x16) then you should use
1087 this option.
1088 @item vmware
1089 VMWare SVGA-II compatible adapter. Use it if you have sufficiently
1090 recent XFree86/XOrg server or Windows guest with a driver for this
1091 card.
1092 @item qxl
1093 QXL paravirtual graphic card. It is VGA compatible (including VESA
1094 2.0 VBE support). Works best with qxl guest drivers installed though.
1095 Recommended choice when using the spice protocol.
1096 @item tcx
1097 (sun4m only) Sun TCX framebuffer. This is the default framebuffer for
1098 sun4m machines and offers both 8-bit and 24-bit colour depths at a
1099 fixed resolution of 1024x768.
1100 @item cg3
1101 (sun4m only) Sun cgthree framebuffer. This is a simple 8-bit framebuffer
1102 for sun4m machines available in both 1024x768 (OpenBIOS) and 1152x900 (OBP)
1103 resolutions aimed at people wishing to run older Solaris versions.
1104 @item none
1105 Disable VGA card.
1106 @end table
1107 ETEXI
1109 DEF("full-screen", 0, QEMU_OPTION_full_screen,
1110 "-full-screen start in full screen\n", QEMU_ARCH_ALL)
1111 STEXI
1112 @item -full-screen
1113 @findex -full-screen
1114 Start in full screen.
1115 ETEXI
1117 DEF("g", 1, QEMU_OPTION_g ,
1118 "-g WxH[xDEPTH] Set the initial graphical resolution and depth\n",
1119 QEMU_ARCH_PPC | QEMU_ARCH_SPARC)
1120 STEXI
1121 @item -g @var{width}x@var{height}[x@var{depth}]
1122 @findex -g
1123 Set the initial graphical resolution and depth (PPC, SPARC only).
1124 ETEXI
1126 DEF("vnc", HAS_ARG, QEMU_OPTION_vnc ,
1127 "-vnc display start a VNC server on display\n", QEMU_ARCH_ALL)
1128 STEXI
1129 @item -vnc @var{display}[,@var{option}[,@var{option}[,...]]]
1130 @findex -vnc
1131 Normally, QEMU uses SDL to display the VGA output. With this option,
1132 you can have QEMU listen on VNC display @var{display} and redirect the VGA
1133 display over the VNC session. It is very useful to enable the usb
1134 tablet device when using this option (option @option{-usbdevice
1135 tablet}). When using the VNC display, you must use the @option{-k}
1136 parameter to set the keyboard layout if you are not using en-us. Valid
1137 syntax for the @var{display} is
1139 @table @option
1141 @item @var{host}:@var{d}
1143 TCP connections will only be allowed from @var{host} on display @var{d}.
1144 By convention the TCP port is 5900+@var{d}. Optionally, @var{host} can
1145 be omitted in which case the server will accept connections from any host.
1147 @item unix:@var{path}
1149 Connections will be allowed over UNIX domain sockets where @var{path} is the
1150 location of a unix socket to listen for connections on.
1152 @item none
1154 VNC is initialized but not started. The monitor @code{change} command
1155 can be used to later start the VNC server.
1157 @end table
1159 Following the @var{display} value there may be one or more @var{option} flags
1160 separated by commas. Valid options are
1162 @table @option
1164 @item reverse
1166 Connect to a listening VNC client via a ``reverse'' connection. The
1167 client is specified by the @var{display}. For reverse network
1168 connections (@var{host}:@var{d},@code{reverse}), the @var{d} argument
1169 is a TCP port number, not a display number.
1171 @item websocket
1173 Opens an additional TCP listening port dedicated to VNC Websocket connections.
1174 By definition the Websocket port is 5700+@var{display}. If @var{host} is
1175 specified connections will only be allowed from this host.
1176 As an alternative the Websocket port could be specified by using
1177 @code{websocket}=@var{port}.
1178 TLS encryption for the Websocket connection is supported if the required
1179 certificates are specified with the VNC option @option{x509}.
1181 @item password
1183 Require that password based authentication is used for client connections.
1185 The password must be set separately using the @code{set_password} command in
1186 the @ref{pcsys_monitor}. The syntax to change your password is:
1187 @code{set_password <protocol> <password>} where <protocol> could be either
1188 "vnc" or "spice".
1190 If you would like to change <protocol> password expiration, you should use
1191 @code{expire_password <protocol> <expiration-time>} where expiration time could
1192 be one of the following options: now, never, +seconds or UNIX time of
1193 expiration, e.g. +60 to make password expire in 60 seconds, or 1335196800
1194 to make password expire on "Mon Apr 23 12:00:00 EDT 2012" (UNIX time for this
1195 date and time).
1197 You can also use keywords "now" or "never" for the expiration time to
1198 allow <protocol> password to expire immediately or never expire.
1200 @item tls
1202 Require that client use TLS when communicating with the VNC server. This
1203 uses anonymous TLS credentials so is susceptible to a man-in-the-middle
1204 attack. It is recommended that this option be combined with either the
1205 @option{x509} or @option{x509verify} options.
1207 @item x509=@var{/path/to/certificate/dir}
1209 Valid if @option{tls} is specified. Require that x509 credentials are used
1210 for negotiating the TLS session. The server will send its x509 certificate
1211 to the client. It is recommended that a password be set on the VNC server
1212 to provide authentication of the client when this is used. The path following
1213 this option specifies where the x509 certificates are to be loaded from.
1214 See the @ref{vnc_security} section for details on generating certificates.
1216 @item x509verify=@var{/path/to/certificate/dir}
1218 Valid if @option{tls} is specified. Require that x509 credentials are used
1219 for negotiating the TLS session. The server will send its x509 certificate
1220 to the client, and request that the client send its own x509 certificate.
1221 The server will validate the client's certificate against the CA certificate,
1222 and reject clients when validation fails. If the certificate authority is
1223 trusted, this is a sufficient authentication mechanism. You may still wish
1224 to set a password on the VNC server as a second authentication layer. The
1225 path following this option specifies where the x509 certificates are to
1226 be loaded from. See the @ref{vnc_security} section for details on generating
1227 certificates.
1229 @item sasl
1231 Require that the client use SASL to authenticate with the VNC server.
1232 The exact choice of authentication method used is controlled from the
1233 system / user's SASL configuration file for the 'qemu' service. This
1234 is typically found in /etc/sasl2/qemu.conf. If running QEMU as an
1235 unprivileged user, an environment variable SASL_CONF_PATH can be used
1236 to make it search alternate locations for the service config.
1237 While some SASL auth methods can also provide data encryption (eg GSSAPI),
1238 it is recommended that SASL always be combined with the 'tls' and
1239 'x509' settings to enable use of SSL and server certificates. This
1240 ensures a data encryption preventing compromise of authentication
1241 credentials. See the @ref{vnc_security} section for details on using
1242 SASL authentication.
1244 @item acl
1246 Turn on access control lists for checking of the x509 client certificate
1247 and SASL party. For x509 certs, the ACL check is made against the
1248 certificate's distinguished name. This is something that looks like
1249 @code{C=GB,O=ACME,L=Boston,CN=bob}. For SASL party, the ACL check is
1250 made against the username, which depending on the SASL plugin, may
1251 include a realm component, eg @code{bob} or @code{bob@@EXAMPLE.COM}.
1252 When the @option{acl} flag is set, the initial access list will be
1253 empty, with a @code{deny} policy. Thus no one will be allowed to
1254 use the VNC server until the ACLs have been loaded. This can be
1255 achieved using the @code{acl} monitor command.
1257 @item lossy
1259 Enable lossy compression methods (gradient, JPEG, ...). If this
1260 option is set, VNC client may receive lossy framebuffer updates
1261 depending on its encoding settings. Enabling this option can save
1262 a lot of bandwidth at the expense of quality.
1264 @item non-adaptive
1266 Disable adaptive encodings. Adaptive encodings are enabled by default.
1267 An adaptive encoding will try to detect frequently updated screen regions,
1268 and send updates in these regions using a lossy encoding (like JPEG).
1269 This can be really helpful to save bandwidth when playing videos. Disabling
1270 adaptive encodings restores the original static behavior of encodings
1271 like Tight.
1273 @item share=[allow-exclusive|force-shared|ignore]
1275 Set display sharing policy. 'allow-exclusive' allows clients to ask
1276 for exclusive access. As suggested by the rfb spec this is
1277 implemented by dropping other connections. Connecting multiple
1278 clients in parallel requires all clients asking for a shared session
1279 (vncviewer: -shared switch). This is the default. 'force-shared'
1280 disables exclusive client access. Useful for shared desktop sessions,
1281 where you don't want someone forgetting specify -shared disconnect
1282 everybody else. 'ignore' completely ignores the shared flag and
1283 allows everybody connect unconditionally. Doesn't conform to the rfb
1284 spec but is traditional QEMU behavior.
1286 @end table
1287 ETEXI
1289 STEXI
1290 @end table
1291 ETEXI
1292 ARCHHEADING(, QEMU_ARCH_I386)
1294 ARCHHEADING(i386 target only:, QEMU_ARCH_I386)
1295 STEXI
1296 @table @option
1297 ETEXI
1299 DEF("win2k-hack", 0, QEMU_OPTION_win2k_hack,
1300 "-win2k-hack use it when installing Windows 2000 to avoid a disk full bug\n",
1301 QEMU_ARCH_I386)
1302 STEXI
1303 @item -win2k-hack
1304 @findex -win2k-hack
1305 Use it when installing Windows 2000 to avoid a disk full bug. After
1306 Windows 2000 is installed, you no longer need this option (this option
1307 slows down the IDE transfers).
1308 ETEXI
1310 HXCOMM Deprecated by -rtc
1311 DEF("rtc-td-hack", 0, QEMU_OPTION_rtc_td_hack, "", QEMU_ARCH_I386)
1313 DEF("no-fd-bootchk", 0, QEMU_OPTION_no_fd_bootchk,
1314 "-no-fd-bootchk disable boot signature checking for floppy disks\n",
1315 QEMU_ARCH_I386)
1316 STEXI
1317 @item -no-fd-bootchk
1318 @findex -no-fd-bootchk
1319 Disable boot signature checking for floppy disks in BIOS. May
1320 be needed to boot from old floppy disks.
1321 ETEXI
1323 DEF("no-acpi", 0, QEMU_OPTION_no_acpi,
1324 "-no-acpi disable ACPI\n", QEMU_ARCH_I386)
1325 STEXI
1326 @item -no-acpi
1327 @findex -no-acpi
1328 Disable ACPI (Advanced Configuration and Power Interface) support. Use
1329 it if your guest OS complains about ACPI problems (PC target machine
1330 only).
1331 ETEXI
1333 DEF("no-hpet", 0, QEMU_OPTION_no_hpet,
1334 "-no-hpet disable HPET\n", QEMU_ARCH_I386)
1335 STEXI
1336 @item -no-hpet
1337 @findex -no-hpet
1338 Disable HPET support.
1339 ETEXI
1341 DEF("acpitable", HAS_ARG, QEMU_OPTION_acpitable,
1342 "-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"
1343 " ACPI table description\n", QEMU_ARCH_I386)
1344 STEXI
1345 @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}]...]
1346 @findex -acpitable
1347 Add ACPI table with specified header fields and context from specified files.
1348 For file=, take whole ACPI table from the specified files, including all
1349 ACPI headers (possible overridden by other options).
1350 For data=, only data
1351 portion of the table is used, all header information is specified in the
1352 command line.
1353 ETEXI
1355 DEF("smbios", HAS_ARG, QEMU_OPTION_smbios,
1356 "-smbios file=binary\n"
1357 " load SMBIOS entry from binary file\n"
1358 "-smbios type=0[,vendor=str][,version=str][,date=str][,release=%d.%d][,uefi=on|off]\n"
1359 " specify SMBIOS type 0 fields\n"
1360 "-smbios type=1[,manufacturer=str][,product=str][,version=str][,serial=str]\n"
1361 " [,uuid=uuid][,sku=str][,family=str]\n"
1362 " specify SMBIOS type 1 fields\n", QEMU_ARCH_I386)
1363 STEXI
1364 @item -smbios file=@var{binary}
1365 @findex -smbios
1366 Load SMBIOS entry from binary file.
1368 @item -smbios type=0[,vendor=@var{str}][,version=@var{str}][,date=@var{str}][,release=@var{%d.%d}][,uefi=on|off]
1369 Specify SMBIOS type 0 fields
1371 @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}]
1372 Specify SMBIOS type 1 fields
1373 ETEXI
1375 STEXI
1376 @end table
1377 ETEXI
1378 DEFHEADING()
1380 DEFHEADING(Network options:)
1381 STEXI
1382 @table @option
1383 ETEXI
1385 HXCOMM Legacy slirp options (now moved to -net user):
1386 #ifdef CONFIG_SLIRP
1387 DEF("tftp", HAS_ARG, QEMU_OPTION_tftp, "", QEMU_ARCH_ALL)
1388 DEF("bootp", HAS_ARG, QEMU_OPTION_bootp, "", QEMU_ARCH_ALL)
1389 DEF("redir", HAS_ARG, QEMU_OPTION_redir, "", QEMU_ARCH_ALL)
1390 #ifndef _WIN32
1391 DEF("smb", HAS_ARG, QEMU_OPTION_smb, "", QEMU_ARCH_ALL)
1392 #endif
1393 #endif
1395 DEF("net", HAS_ARG, QEMU_OPTION_net,
1396 "-net nic[,vlan=n][,macaddr=mac][,model=type][,name=str][,addr=str][,vectors=v]\n"
1397 " create a new Network Interface Card and connect it to VLAN 'n'\n"
1398 #ifdef CONFIG_SLIRP
1399 "-net user[,vlan=n][,name=str][,net=addr[/mask]][,host=addr][,restrict=on|off]\n"
1400 " [,hostname=host][,dhcpstart=addr][,dns=addr][,dnssearch=domain][,tftp=dir]\n"
1401 " [,bootfile=f][,hostfwd=rule][,guestfwd=rule]"
1402 #ifndef _WIN32
1403 "[,smb=dir[,smbserver=addr]]\n"
1404 #endif
1405 " connect the user mode network stack to VLAN 'n', configure its\n"
1406 " DHCP server and enabled optional services\n"
1407 #endif
1408 #ifdef _WIN32
1409 "-net tap[,vlan=n][,name=str],ifname=name\n"
1410 " connect the host TAP network interface to VLAN 'n'\n"
1411 #else
1412 "-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"
1413 " connect the host TAP network interface to VLAN 'n'\n"
1414 " use network scripts 'file' (default=" DEFAULT_NETWORK_SCRIPT ")\n"
1415 " to configure it and 'dfile' (default=" DEFAULT_NETWORK_DOWN_SCRIPT ")\n"
1416 " to deconfigure it\n"
1417 " use '[down]script=no' to disable script execution\n"
1418 " use network helper 'helper' (default=" DEFAULT_BRIDGE_HELPER ") to\n"
1419 " configure it\n"
1420 " use 'fd=h' to connect to an already opened TAP interface\n"
1421 " use 'fds=x:y:...:z' to connect to already opened multiqueue capable TAP interfaces\n"
1422 " use 'sndbuf=nbytes' to limit the size of the send buffer (the\n"
1423 " default is disabled 'sndbuf=0' to enable flow control set 'sndbuf=1048576')\n"
1424 " use vnet_hdr=off to avoid enabling the IFF_VNET_HDR tap flag\n"
1425 " use vnet_hdr=on to make the lack of IFF_VNET_HDR support an error condition\n"
1426 " use vhost=on to enable experimental in kernel accelerator\n"
1427 " (only has effect for virtio guests which use MSIX)\n"
1428 " use vhostforce=on to force vhost on for non-MSIX virtio guests\n"
1429 " use 'vhostfd=h' to connect to an already opened vhost net device\n"
1430 " use 'vhostfds=x:y:...:z to connect to multiple already opened vhost net devices\n"
1431 " use 'queues=n' to specify the number of queues to be created for multiqueue TAP\n"
1432 "-net bridge[,vlan=n][,name=str][,br=bridge][,helper=helper]\n"
1433 " connects a host TAP network interface to a host bridge device 'br'\n"
1434 " (default=" DEFAULT_BRIDGE_INTERFACE ") using the program 'helper'\n"
1435 " (default=" DEFAULT_BRIDGE_HELPER ")\n"
1436 #endif
1437 #ifdef __linux__
1438 "-net l2tpv3[,vlan=n][,name=str],src=srcaddr,dst=dstaddr[,srcport=srcport][,dstport=dstport],txsession=txsession[,rxsession=rxsession][,ipv6=on/off][,udp=on/off][,cookie64=on/off][,counter][,pincounter][,txcookie=txcookie][,rxcookie=rxcookie][,offset=offset]\n"
1439 " connect the VLAN to an Ethernet over L2TPv3 pseudowire\n"
1440 " Linux kernel 3.3+ as well as most routers can talk\n"
1441 " L2TPv3. This transport allows connecting a VM to a VM,\n"
1442 " VM to a router and even VM to Host. It is a nearly-universal\n"
1443 " standard (RFC3391). Note - this implementation uses static\n"
1444 " pre-configured tunnels (same as the Linux kernel).\n"
1445 " use 'src=' to specify source address\n"
1446 " use 'dst=' to specify destination address\n"
1447 " use 'udp=on' to specify udp encapsulation\n"
1448 " use 'srcport=' to specify source udp port\n"
1449 " use 'dstport=' to specify destination udp port\n"
1450 " use 'ipv6=on' to force v6\n"
1451 " L2TPv3 uses cookies to prevent misconfiguration as\n"
1452 " well as a weak security measure\n"
1453 " use 'rxcookie=0x012345678' to specify a rxcookie\n"
1454 " use 'txcookie=0x012345678' to specify a txcookie\n"
1455 " use 'cookie64=on' to set cookie size to 64 bit, otherwise 32\n"
1456 " use 'counter=off' to force a 'cut-down' L2TPv3 with no counter\n"
1457 " use 'pincounter=on' to work around broken counter handling in peer\n"
1458 " use 'offset=X' to add an extra offset between header and data\n"
1459 #endif
1460 "-net socket[,vlan=n][,name=str][,fd=h][,listen=[host]:port][,connect=host:port]\n"
1461 " connect the vlan 'n' to another VLAN using a socket connection\n"
1462 "-net socket[,vlan=n][,name=str][,fd=h][,mcast=maddr:port[,localaddr=addr]]\n"
1463 " connect the vlan 'n' to multicast maddr and port\n"
1464 " use 'localaddr=addr' to specify the host address to send packets from\n"
1465 "-net socket[,vlan=n][,name=str][,fd=h][,udp=host:port][,localaddr=host:port]\n"
1466 " connect the vlan 'n' to another VLAN using an UDP tunnel\n"
1467 #ifdef CONFIG_VDE
1468 "-net vde[,vlan=n][,name=str][,sock=socketpath][,port=n][,group=groupname][,mode=octalmode]\n"
1469 " connect the vlan 'n' to port 'n' of a vde switch running\n"
1470 " on host and listening for incoming connections on 'socketpath'.\n"
1471 " Use group 'groupname' and mode 'octalmode' to change default\n"
1472 " ownership and permissions for communication port.\n"
1473 #endif
1474 #ifdef CONFIG_NETMAP
1475 "-net netmap,ifname=name[,devname=nmname]\n"
1476 " attach to the existing netmap-enabled network interface 'name', or to a\n"
1477 " VALE port (created on the fly) called 'name' ('nmname' is name of the \n"
1478 " netmap device, defaults to '/dev/netmap')\n"
1479 #endif
1480 "-net dump[,vlan=n][,file=f][,len=n]\n"
1481 " dump traffic on vlan 'n' to file 'f' (max n bytes per packet)\n"
1482 "-net none use it alone to have zero network devices. If no -net option\n"
1483 " is provided, the default is '-net nic -net user'\n", QEMU_ARCH_ALL)
1484 DEF("netdev", HAS_ARG, QEMU_OPTION_netdev,
1485 "-netdev ["
1486 #ifdef CONFIG_SLIRP
1487 "user|"
1488 #endif
1489 "tap|"
1490 "bridge|"
1491 #ifdef CONFIG_VDE
1492 "vde|"
1493 #endif
1494 #ifdef CONFIG_NETMAP
1495 "netmap|"
1496 #endif
1497 "vhost-user|"
1498 "socket|"
1499 "hubport],id=str[,option][,option][,...]\n", QEMU_ARCH_ALL)
1500 STEXI
1501 @item -net nic[,vlan=@var{n}][,macaddr=@var{mac}][,model=@var{type}] [,name=@var{name}][,addr=@var{addr}][,vectors=@var{v}]
1502 @findex -net
1503 Create a new Network Interface Card and connect it to VLAN @var{n} (@var{n}
1504 = 0 is the default). The NIC is an e1000 by default on the PC
1505 target. Optionally, the MAC address can be changed to @var{mac}, the
1506 device address set to @var{addr} (PCI cards only),
1507 and a @var{name} can be assigned for use in monitor commands.
1508 Optionally, for PCI cards, you can specify the number @var{v} of MSI-X vectors
1509 that the card should have; this option currently only affects virtio cards; set
1510 @var{v} = 0 to disable MSI-X. If no @option{-net} option is specified, a single
1511 NIC is created. QEMU can emulate several different models of network card.
1512 Valid values for @var{type} are
1513 @code{virtio}, @code{i82551}, @code{i82557b}, @code{i82559er},
1514 @code{ne2k_pci}, @code{ne2k_isa}, @code{pcnet}, @code{rtl8139},
1515 @code{e1000}, @code{smc91c111}, @code{lance} and @code{mcf_fec}.
1516 Not all devices are supported on all targets. Use @code{-net nic,model=help}
1517 for a list of available devices for your target.
1519 @item -netdev user,id=@var{id}[,@var{option}][,@var{option}][,...]
1520 @findex -netdev
1521 @item -net user[,@var{option}][,@var{option}][,...]
1522 Use the user mode network stack which requires no administrator
1523 privilege to run. Valid options are:
1525 @table @option
1526 @item vlan=@var{n}
1527 Connect user mode stack to VLAN @var{n} (@var{n} = 0 is the default).
1529 @item id=@var{id}
1530 @item name=@var{name}
1531 Assign symbolic name for use in monitor commands.
1533 @item net=@var{addr}[/@var{mask}]
1534 Set IP network address the guest will see. Optionally specify the netmask,
1535 either in the form a.b.c.d or as number of valid top-most bits. Default is
1536 10.0.2.0/24.
1538 @item host=@var{addr}
1539 Specify the guest-visible address of the host. Default is the 2nd IP in the
1540 guest network, i.e. x.x.x.2.
1542 @item restrict=on|off
1543 If this option is enabled, the guest will be isolated, i.e. it will not be
1544 able to contact the host and no guest IP packets will be routed over the host
1545 to the outside. This option does not affect any explicitly set forwarding rules.
1547 @item hostname=@var{name}
1548 Specifies the client hostname reported by the built-in DHCP server.
1550 @item dhcpstart=@var{addr}
1551 Specify the first of the 16 IPs the built-in DHCP server can assign. Default
1552 is the 15th to 31st IP in the guest network, i.e. x.x.x.15 to x.x.x.31.
1554 @item dns=@var{addr}
1555 Specify the guest-visible address of the virtual nameserver. The address must
1556 be different from the host address. Default is the 3rd IP in the guest network,
1557 i.e. x.x.x.3.
1559 @item dnssearch=@var{domain}
1560 Provides an entry for the domain-search list sent by the built-in
1561 DHCP server. More than one domain suffix can be transmitted by specifying
1562 this option multiple times. If supported, this will cause the guest to
1563 automatically try to append the given domain suffix(es) in case a domain name
1564 can not be resolved.
1566 Example:
1567 @example
1568 qemu -net user,dnssearch=mgmt.example.org,dnssearch=example.org [...]
1569 @end example
1571 @item tftp=@var{dir}
1572 When using the user mode network stack, activate a built-in TFTP
1573 server. The files in @var{dir} will be exposed as the root of a TFTP server.
1574 The TFTP client on the guest must be configured in binary mode (use the command
1575 @code{bin} of the Unix TFTP client).
1577 @item bootfile=@var{file}
1578 When using the user mode network stack, broadcast @var{file} as the BOOTP
1579 filename. In conjunction with @option{tftp}, this can be used to network boot
1580 a guest from a local directory.
1582 Example (using pxelinux):
1583 @example
1584 qemu-system-i386 -hda linux.img -boot n -net user,tftp=/path/to/tftp/files,bootfile=/pxelinux.0
1585 @end example
1587 @item smb=@var{dir}[,smbserver=@var{addr}]
1588 When using the user mode network stack, activate a built-in SMB
1589 server so that Windows OSes can access to the host files in @file{@var{dir}}
1590 transparently. The IP address of the SMB server can be set to @var{addr}. By
1591 default the 4th IP in the guest network is used, i.e. x.x.x.4.
1593 In the guest Windows OS, the line:
1594 @example
1595 10.0.2.4 smbserver
1596 @end example
1597 must be added in the file @file{C:\WINDOWS\LMHOSTS} (for windows 9x/Me)
1598 or @file{C:\WINNT\SYSTEM32\DRIVERS\ETC\LMHOSTS} (Windows NT/2000).
1600 Then @file{@var{dir}} can be accessed in @file{\\smbserver\qemu}.
1602 Note that a SAMBA server must be installed on the host OS.
1603 QEMU was tested successfully with smbd versions from Red Hat 9,
1604 Fedora Core 3 and OpenSUSE 11.x.
1606 @item hostfwd=[tcp|udp]:[@var{hostaddr}]:@var{hostport}-[@var{guestaddr}]:@var{guestport}
1607 Redirect incoming TCP or UDP connections to the host port @var{hostport} to
1608 the guest IP address @var{guestaddr} on guest port @var{guestport}. If
1609 @var{guestaddr} is not specified, its value is x.x.x.15 (default first address
1610 given by the built-in DHCP server). By specifying @var{hostaddr}, the rule can
1611 be bound to a specific host interface. If no connection type is set, TCP is
1612 used. This option can be given multiple times.
1614 For example, to redirect host X11 connection from screen 1 to guest
1615 screen 0, use the following:
1617 @example
1618 # on the host
1619 qemu-system-i386 -net user,hostfwd=tcp:127.0.0.1:6001-:6000 [...]
1620 # this host xterm should open in the guest X11 server
1621 xterm -display :1
1622 @end example
1624 To redirect telnet connections from host port 5555 to telnet port on
1625 the guest, use the following:
1627 @example
1628 # on the host
1629 qemu-system-i386 -net user,hostfwd=tcp::5555-:23 [...]
1630 telnet localhost 5555
1631 @end example
1633 Then when you use on the host @code{telnet localhost 5555}, you
1634 connect to the guest telnet server.
1636 @item guestfwd=[tcp]:@var{server}:@var{port}-@var{dev}
1637 @item guestfwd=[tcp]:@var{server}:@var{port}-@var{cmd:command}
1638 Forward guest TCP connections to the IP address @var{server} on port @var{port}
1639 to the character device @var{dev} or to a program executed by @var{cmd:command}
1640 which gets spawned for each connection. This option can be given multiple times.
1642 You can either use a chardev directly and have that one used throughout QEMU's
1643 lifetime, like in the following example:
1645 @example
1646 # open 10.10.1.1:4321 on bootup, connect 10.0.2.100:1234 to it whenever
1647 # the guest accesses it
1648 qemu -net user,guestfwd=tcp:10.0.2.100:1234-tcp:10.10.1.1:4321 [...]
1649 @end example
1651 Or you can execute a command on every TCP connection established by the guest,
1652 so that QEMU behaves similar to an inetd process for that virtual server:
1654 @example
1655 # call "netcat 10.10.1.1 4321" on every TCP connection to 10.0.2.100:1234
1656 # and connect the TCP stream to its stdin/stdout
1657 qemu -net 'user,guestfwd=tcp:10.0.2.100:1234-cmd:netcat 10.10.1.1 4321'
1658 @end example
1660 @end table
1662 Note: Legacy stand-alone options -tftp, -bootp, -smb and -redir are still
1663 processed and applied to -net user. Mixing them with the new configuration
1664 syntax gives undefined results. Their use for new applications is discouraged
1665 as they will be removed from future versions.
1667 @item -netdev tap,id=@var{id}[,fd=@var{h}][,ifname=@var{name}][,script=@var{file}][,downscript=@var{dfile}][,helper=@var{helper}]
1668 @item -net tap[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}][,ifname=@var{name}][,script=@var{file}][,downscript=@var{dfile}][,helper=@var{helper}]
1669 Connect the host TAP network interface @var{name} to VLAN @var{n}.
1671 Use the network script @var{file} to configure it and the network script
1672 @var{dfile} to deconfigure it. If @var{name} is not provided, the OS
1673 automatically provides one. The default network configure script is
1674 @file{/etc/qemu-ifup} and the default network deconfigure script is
1675 @file{/etc/qemu-ifdown}. Use @option{script=no} or @option{downscript=no}
1676 to disable script execution.
1678 If running QEMU as an unprivileged user, use the network helper
1679 @var{helper} to configure the TAP interface. The default network
1680 helper executable is @file{/path/to/qemu-bridge-helper}.
1682 @option{fd}=@var{h} can be used to specify the handle of an already
1683 opened host TAP interface.
1685 Examples:
1687 @example
1688 #launch a QEMU instance with the default network script
1689 qemu-system-i386 linux.img -net nic -net tap
1690 @end example
1692 @example
1693 #launch a QEMU instance with two NICs, each one connected
1694 #to a TAP device
1695 qemu-system-i386 linux.img \
1696 -net nic,vlan=0 -net tap,vlan=0,ifname=tap0 \
1697 -net nic,vlan=1 -net tap,vlan=1,ifname=tap1
1698 @end example
1700 @example
1701 #launch a QEMU instance with the default network helper to
1702 #connect a TAP device to bridge br0
1703 qemu-system-i386 linux.img \
1704 -net nic -net tap,"helper=/path/to/qemu-bridge-helper"
1705 @end example
1707 @item -netdev bridge,id=@var{id}[,br=@var{bridge}][,helper=@var{helper}]
1708 @item -net bridge[,vlan=@var{n}][,name=@var{name}][,br=@var{bridge}][,helper=@var{helper}]
1709 Connect a host TAP network interface to a host bridge device.
1711 Use the network helper @var{helper} to configure the TAP interface and
1712 attach it to the bridge. The default network helper executable is
1713 @file{/path/to/qemu-bridge-helper} and the default bridge
1714 device is @file{br0}.
1716 Examples:
1718 @example
1719 #launch a QEMU instance with the default network helper to
1720 #connect a TAP device to bridge br0
1721 qemu-system-i386 linux.img -net bridge -net nic,model=virtio
1722 @end example
1724 @example
1725 #launch a QEMU instance with the default network helper to
1726 #connect a TAP device to bridge qemubr0
1727 qemu-system-i386 linux.img -net bridge,br=qemubr0 -net nic,model=virtio
1728 @end example
1730 @item -netdev socket,id=@var{id}[,fd=@var{h}][,listen=[@var{host}]:@var{port}][,connect=@var{host}:@var{port}]
1731 @item -net socket[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}] [,listen=[@var{host}]:@var{port}][,connect=@var{host}:@var{port}]
1733 Connect the VLAN @var{n} to a remote VLAN in another QEMU virtual
1734 machine using a TCP socket connection. If @option{listen} is
1735 specified, QEMU waits for incoming connections on @var{port}
1736 (@var{host} is optional). @option{connect} is used to connect to
1737 another QEMU instance using the @option{listen} option. @option{fd}=@var{h}
1738 specifies an already opened TCP socket.
1740 Example:
1741 @example
1742 # launch a first QEMU instance
1743 qemu-system-i386 linux.img \
1744 -net nic,macaddr=52:54:00:12:34:56 \
1745 -net socket,listen=:1234
1746 # connect the VLAN 0 of this instance to the VLAN 0
1747 # of the first instance
1748 qemu-system-i386 linux.img \
1749 -net nic,macaddr=52:54:00:12:34:57 \
1750 -net socket,connect=127.0.0.1:1234
1751 @end example
1753 @item -netdev socket,id=@var{id}[,fd=@var{h}][,mcast=@var{maddr}:@var{port}[,localaddr=@var{addr}]]
1754 @item -net socket[,vlan=@var{n}][,name=@var{name}][,fd=@var{h}][,mcast=@var{maddr}:@var{port}[,localaddr=@var{addr}]]
1756 Create a VLAN @var{n} shared with another QEMU virtual
1757 machines using a UDP multicast socket, effectively making a bus for
1758 every QEMU with same multicast address @var{maddr} and @var{port}.
1759 NOTES:
1760 @enumerate
1761 @item
1762 Several QEMU can be running on different hosts and share same bus (assuming
1763 correct multicast setup for these hosts).
1764 @item
1765 mcast support is compatible with User Mode Linux (argument @option{eth@var{N}=mcast}), see
1766 @url{http://user-mode-linux.sf.net}.
1767 @item
1768 Use @option{fd=h} to specify an already opened UDP multicast socket.
1769 @end enumerate
1771 Example:
1772 @example
1773 # launch one QEMU instance
1774 qemu-system-i386 linux.img \
1775 -net nic,macaddr=52:54:00:12:34:56 \
1776 -net socket,mcast=230.0.0.1:1234
1777 # launch another QEMU instance on same "bus"
1778 qemu-system-i386 linux.img \
1779 -net nic,macaddr=52:54:00:12:34:57 \
1780 -net socket,mcast=230.0.0.1:1234
1781 # launch yet another QEMU instance on same "bus"
1782 qemu-system-i386 linux.img \
1783 -net nic,macaddr=52:54:00:12:34:58 \
1784 -net socket,mcast=230.0.0.1:1234
1785 @end example
1787 Example (User Mode Linux compat.):
1788 @example
1789 # launch QEMU instance (note mcast address selected
1790 # is UML's default)
1791 qemu-system-i386 linux.img \
1792 -net nic,macaddr=52:54:00:12:34:56 \
1793 -net socket,mcast=239.192.168.1:1102
1794 # launch UML
1795 /path/to/linux ubd0=/path/to/root_fs eth0=mcast
1796 @end example
1798 Example (send packets from host's 1.2.3.4):
1799 @example
1800 qemu-system-i386 linux.img \
1801 -net nic,macaddr=52:54:00:12:34:56 \
1802 -net socket,mcast=239.192.168.1:1102,localaddr=1.2.3.4
1803 @end example
1805 @item -netdev l2tpv3,id=@var{id},src=@var{srcaddr},dst=@var{dstaddr}[,srcport=@var{srcport}][,dstport=@var{dstport}],txsession=@var{txsession}[,rxsession=@var{rxsession}][,ipv6][,udp][,cookie64][,counter][,pincounter][,txcookie=@var{txcookie}][,rxcookie=@var{rxcookie}][,offset=@var{offset}]
1806 @item -net l2tpv3[,vlan=@var{n}][,name=@var{name}],src=@var{srcaddr},dst=@var{dstaddr}[,srcport=@var{srcport}][,dstport=@var{dstport}],txsession=@var{txsession}[,rxsession=@var{rxsession}][,ipv6][,udp][,cookie64][,counter][,pincounter][,txcookie=@var{txcookie}][,rxcookie=@var{rxcookie}][,offset=@var{offset}]
1807 Connect VLAN @var{n} to L2TPv3 pseudowire. L2TPv3 (RFC3391) is a popular
1808 protocol to transport Ethernet (and other Layer 2) data frames between
1809 two systems. It is present in routers, firewalls and the Linux kernel
1810 (from version 3.3 onwards).
1812 This transport allows a VM to communicate to another VM, router or firewall directly.
1814 @item src=@var{srcaddr}
1815 source address (mandatory)
1816 @item dst=@var{dstaddr}
1817 destination address (mandatory)
1818 @item udp
1819 select udp encapsulation (default is ip).
1820 @item srcport=@var{srcport}
1821 source udp port.
1822 @item dstport=@var{dstport}
1823 destination udp port.
1824 @item ipv6
1825 force v6, otherwise defaults to v4.
1826 @item rxcookie=@var{rxcookie}
1827 @item txcookie=@var{txcookie}
1828 Cookies are a weak form of security in the l2tpv3 specification.
1829 Their function is mostly to prevent misconfiguration. By default they are 32
1830 bit.
1831 @item cookie64
1832 Set cookie size to 64 bit instead of the default 32
1833 @item counter=off
1834 Force a 'cut-down' L2TPv3 with no counter as in
1835 draft-mkonstan-l2tpext-keyed-ipv6-tunnel-00
1836 @item pincounter=on
1837 Work around broken counter handling in peer. This may also help on
1838 networks which have packet reorder.
1839 @item offset=@var{offset}
1840 Add an extra offset between header and data
1842 For example, to attach a VM running on host 4.3.2.1 via L2TPv3 to the bridge br-lan
1843 on the remote Linux host 1.2.3.4:
1844 @example
1845 # Setup tunnel on linux host using raw ip as encapsulation
1846 # on 1.2.3.4
1847 ip l2tp add tunnel remote 4.3.2.1 local 1.2.3.4 tunnel_id 1 peer_tunnel_id 1 \
1848 encap udp udp_sport 16384 udp_dport 16384
1849 ip l2tp add session tunnel_id 1 name vmtunnel0 session_id \
1850 0xFFFFFFFF peer_session_id 0xFFFFFFFF
1851 ifconfig vmtunnel0 mtu 1500
1852 ifconfig vmtunnel0 up
1853 brctl addif br-lan vmtunnel0
1856 # on 4.3.2.1
1857 # launch QEMU instance - if your network has reorder or is very lossy add ,pincounter
1859 qemu-system-i386 linux.img -net nic -net l2tpv3,src=4.2.3.1,dst=1.2.3.4,udp,srcport=16384,dstport=16384,rxsession=0xffffffff,txsession=0xffffffff,counter
1862 @end example
1864 @item -netdev vde,id=@var{id}[,sock=@var{socketpath}][,port=@var{n}][,group=@var{groupname}][,mode=@var{octalmode}]
1865 @item -net vde[,vlan=@var{n}][,name=@var{name}][,sock=@var{socketpath}] [,port=@var{n}][,group=@var{groupname}][,mode=@var{octalmode}]
1866 Connect VLAN @var{n} to PORT @var{n} of a vde switch running on host and
1867 listening for incoming connections on @var{socketpath}. Use GROUP @var{groupname}
1868 and MODE @var{octalmode} to change default ownership and permissions for
1869 communication port. This option is only available if QEMU has been compiled
1870 with vde support enabled.
1872 Example:
1873 @example
1874 # launch vde switch
1875 vde_switch -F -sock /tmp/myswitch
1876 # launch QEMU instance
1877 qemu-system-i386 linux.img -net nic -net vde,sock=/tmp/myswitch
1878 @end example
1880 @item -netdev hubport,id=@var{id},hubid=@var{hubid}
1882 Create a hub port on QEMU "vlan" @var{hubid}.
1884 The hubport netdev lets you connect a NIC to a QEMU "vlan" instead of a single
1885 netdev. @code{-net} and @code{-device} with parameter @option{vlan} create the
1886 required hub automatically.
1888 @item -netdev vhost-user,chardev=@var{id}[,vhostforce=on|off]
1890 Establish a vhost-user netdev, backed by a chardev @var{id}. The chardev should
1891 be a unix domain socket backed one. The vhost-user uses a specifically defined
1892 protocol to pass vhost ioctl replacement messages to an application on the other
1893 end of the socket. On non-MSIX guests, the feature can be forced with
1894 @var{vhostforce}.
1896 Example:
1897 @example
1898 qemu -m 512 -object memory-backend-file,id=mem,size=512M,mem-path=/hugetlbfs,share=on \
1899 -numa node,memdev=mem \
1900 -chardev socket,path=/path/to/socket \
1901 -netdev type=vhost-user,id=net0,chardev=chr0 \
1902 -device virtio-net-pci,netdev=net0
1903 @end example
1905 @item -net dump[,vlan=@var{n}][,file=@var{file}][,len=@var{len}]
1906 Dump network traffic on VLAN @var{n} to file @var{file} (@file{qemu-vlan0.pcap} by default).
1907 At most @var{len} bytes (64k by default) per packet are stored. The file format is
1908 libpcap, so it can be analyzed with tools such as tcpdump or Wireshark.
1910 @item -net none
1911 Indicate that no network devices should be configured. It is used to
1912 override the default configuration (@option{-net nic -net user}) which
1913 is activated if no @option{-net} options are provided.
1914 ETEXI
1916 STEXI
1917 @end table
1918 ETEXI
1919 DEFHEADING()
1921 DEFHEADING(Character device options:)
1922 STEXI
1924 The general form of a character device option is:
1925 @table @option
1926 ETEXI
1928 DEF("chardev", HAS_ARG, QEMU_OPTION_chardev,
1929 "-chardev null,id=id[,mux=on|off]\n"
1930 "-chardev socket,id=id[,host=host],port=port[,to=to][,ipv4][,ipv6][,nodelay]\n"
1931 " [,server][,nowait][,telnet][,mux=on|off] (tcp)\n"
1932 "-chardev socket,id=id,path=path[,server][,nowait][,telnet],[mux=on|off] (unix)\n"
1933 "-chardev udp,id=id[,host=host],port=port[,localaddr=localaddr]\n"
1934 " [,localport=localport][,ipv4][,ipv6][,mux=on|off]\n"
1935 "-chardev msmouse,id=id[,mux=on|off]\n"
1936 "-chardev vc,id=id[[,width=width][,height=height]][[,cols=cols][,rows=rows]]\n"
1937 " [,mux=on|off]\n"
1938 "-chardev ringbuf,id=id[,size=size]\n"
1939 "-chardev file,id=id,path=path[,mux=on|off]\n"
1940 "-chardev pipe,id=id,path=path[,mux=on|off]\n"
1941 #ifdef _WIN32
1942 "-chardev console,id=id[,mux=on|off]\n"
1943 "-chardev serial,id=id,path=path[,mux=on|off]\n"
1944 #else
1945 "-chardev pty,id=id[,mux=on|off]\n"
1946 "-chardev stdio,id=id[,mux=on|off][,signal=on|off]\n"
1947 #endif
1948 #ifdef CONFIG_BRLAPI
1949 "-chardev braille,id=id[,mux=on|off]\n"
1950 #endif
1951 #if defined(__linux__) || defined(__sun__) || defined(__FreeBSD__) \
1952 || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
1953 "-chardev serial,id=id,path=path[,mux=on|off]\n"
1954 "-chardev tty,id=id,path=path[,mux=on|off]\n"
1955 #endif
1956 #if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
1957 "-chardev parallel,id=id,path=path[,mux=on|off]\n"
1958 "-chardev parport,id=id,path=path[,mux=on|off]\n"
1959 #endif
1960 #if defined(CONFIG_SPICE)
1961 "-chardev spicevmc,id=id,name=name[,debug=debug]\n"
1962 "-chardev spiceport,id=id,name=name[,debug=debug]\n"
1963 #endif
1964 , QEMU_ARCH_ALL
1967 STEXI
1968 @item -chardev @var{backend} ,id=@var{id} [,mux=on|off] [,@var{options}]
1969 @findex -chardev
1970 Backend is one of:
1971 @option{null},
1972 @option{socket},
1973 @option{udp},
1974 @option{msmouse},
1975 @option{vc},
1976 @option{ringbuf},
1977 @option{file},
1978 @option{pipe},
1979 @option{console},
1980 @option{serial},
1981 @option{pty},
1982 @option{stdio},
1983 @option{braille},
1984 @option{tty},
1985 @option{parallel},
1986 @option{parport},
1987 @option{spicevmc}.
1988 @option{spiceport}.
1989 The specific backend will determine the applicable options.
1991 All devices must have an id, which can be any string up to 127 characters long.
1992 It is used to uniquely identify this device in other command line directives.
1994 A character device may be used in multiplexing mode by multiple front-ends.
1995 The key sequence of @key{Control-a} and @key{c} will rotate the input focus
1996 between attached front-ends. Specify @option{mux=on} to enable this mode.
1998 Options to each backend are described below.
2000 @item -chardev null ,id=@var{id}
2001 A void device. This device will not emit any data, and will drop any data it
2002 receives. The null backend does not take any options.
2004 @item -chardev socket ,id=@var{id} [@var{TCP options} or @var{unix options}] [,server] [,nowait] [,telnet]
2006 Create a two-way stream socket, which can be either a TCP or a unix socket. A
2007 unix socket will be created if @option{path} is specified. Behaviour is
2008 undefined if TCP options are specified for a unix socket.
2010 @option{server} specifies that the socket shall be a listening socket.
2012 @option{nowait} specifies that QEMU should not block waiting for a client to
2013 connect to a listening socket.
2015 @option{telnet} specifies that traffic on the socket should interpret telnet
2016 escape sequences.
2018 TCP and unix socket options are given below:
2020 @table @option
2022 @item TCP options: port=@var{port} [,host=@var{host}] [,to=@var{to}] [,ipv4] [,ipv6] [,nodelay]
2024 @option{host} for a listening socket specifies the local address to be bound.
2025 For a connecting socket species the remote host to connect to. @option{host} is
2026 optional for listening sockets. If not specified it defaults to @code{0.0.0.0}.
2028 @option{port} for a listening socket specifies the local port to be bound. For a
2029 connecting socket specifies the port on the remote host to connect to.
2030 @option{port} can be given as either a port number or a service name.
2031 @option{port} is required.
2033 @option{to} is only relevant to listening sockets. If it is specified, and
2034 @option{port} cannot be bound, QEMU will attempt to bind to subsequent ports up
2035 to and including @option{to} until it succeeds. @option{to} must be specified
2036 as a port number.
2038 @option{ipv4} and @option{ipv6} specify that either IPv4 or IPv6 must be used.
2039 If neither is specified the socket may use either protocol.
2041 @option{nodelay} disables the Nagle algorithm.
2043 @item unix options: path=@var{path}
2045 @option{path} specifies the local path of the unix socket. @option{path} is
2046 required.
2048 @end table
2050 @item -chardev udp ,id=@var{id} [,host=@var{host}] ,port=@var{port} [,localaddr=@var{localaddr}] [,localport=@var{localport}] [,ipv4] [,ipv6]
2052 Sends all traffic from the guest to a remote host over UDP.
2054 @option{host} specifies the remote host to connect to. If not specified it
2055 defaults to @code{localhost}.
2057 @option{port} specifies the port on the remote host to connect to. @option{port}
2058 is required.
2060 @option{localaddr} specifies the local address to bind to. If not specified it
2061 defaults to @code{0.0.0.0}.
2063 @option{localport} specifies the local port to bind to. If not specified any
2064 available local port will be used.
2066 @option{ipv4} and @option{ipv6} specify that either IPv4 or IPv6 must be used.
2067 If neither is specified the device may use either protocol.
2069 @item -chardev msmouse ,id=@var{id}
2071 Forward QEMU's emulated msmouse events to the guest. @option{msmouse} does not
2072 take any options.
2074 @item -chardev vc ,id=@var{id} [[,width=@var{width}] [,height=@var{height}]] [[,cols=@var{cols}] [,rows=@var{rows}]]
2076 Connect to a QEMU text console. @option{vc} may optionally be given a specific
2077 size.
2079 @option{width} and @option{height} specify the width and height respectively of
2080 the console, in pixels.
2082 @option{cols} and @option{rows} specify that the console be sized to fit a text
2083 console with the given dimensions.
2085 @item -chardev ringbuf ,id=@var{id} [,size=@var{size}]
2087 Create a ring buffer with fixed size @option{size}.
2088 @var{size} must be a power of two, and defaults to @code{64K}).
2090 @item -chardev file ,id=@var{id} ,path=@var{path}
2092 Log all traffic received from the guest to a file.
2094 @option{path} specifies the path of the file to be opened. This file will be
2095 created if it does not already exist, and overwritten if it does. @option{path}
2096 is required.
2098 @item -chardev pipe ,id=@var{id} ,path=@var{path}
2100 Create a two-way connection to the guest. The behaviour differs slightly between
2101 Windows hosts and other hosts:
2103 On Windows, a single duplex pipe will be created at
2104 @file{\\.pipe\@option{path}}.
2106 On other hosts, 2 pipes will be created called @file{@option{path}.in} and
2107 @file{@option{path}.out}. Data written to @file{@option{path}.in} will be
2108 received by the guest. Data written by the guest can be read from
2109 @file{@option{path}.out}. QEMU will not create these fifos, and requires them to
2110 be present.
2112 @option{path} forms part of the pipe path as described above. @option{path} is
2113 required.
2115 @item -chardev console ,id=@var{id}
2117 Send traffic from the guest to QEMU's standard output. @option{console} does not
2118 take any options.
2120 @option{console} is only available on Windows hosts.
2122 @item -chardev serial ,id=@var{id} ,path=@option{path}
2124 Send traffic from the guest to a serial device on the host.
2126 On Unix hosts serial will actually accept any tty device,
2127 not only serial lines.
2129 @option{path} specifies the name of the serial device to open.
2131 @item -chardev pty ,id=@var{id}
2133 Create a new pseudo-terminal on the host and connect to it. @option{pty} does
2134 not take any options.
2136 @option{pty} is not available on Windows hosts.
2138 @item -chardev stdio ,id=@var{id} [,signal=on|off]
2139 Connect to standard input and standard output of the QEMU process.
2141 @option{signal} controls if signals are enabled on the terminal, that includes
2142 exiting QEMU with the key sequence @key{Control-c}. This option is enabled by
2143 default, use @option{signal=off} to disable it.
2145 @option{stdio} is not available on Windows hosts.
2147 @item -chardev braille ,id=@var{id}
2149 Connect to a local BrlAPI server. @option{braille} does not take any options.
2151 @item -chardev tty ,id=@var{id} ,path=@var{path}
2153 @option{tty} is only available on Linux, Sun, FreeBSD, NetBSD, OpenBSD and
2154 DragonFlyBSD hosts. It is an alias for @option{serial}.
2156 @option{path} specifies the path to the tty. @option{path} is required.
2158 @item -chardev parallel ,id=@var{id} ,path=@var{path}
2159 @item -chardev parport ,id=@var{id} ,path=@var{path}
2161 @option{parallel} is only available on Linux, FreeBSD and DragonFlyBSD hosts.
2163 Connect to a local parallel port.
2165 @option{path} specifies the path to the parallel port device. @option{path} is
2166 required.
2168 @item -chardev spicevmc ,id=@var{id} ,debug=@var{debug}, name=@var{name}
2170 @option{spicevmc} is only available when spice support is built in.
2172 @option{debug} debug level for spicevmc
2174 @option{name} name of spice channel to connect to
2176 Connect to a spice virtual machine channel, such as vdiport.
2178 @item -chardev spiceport ,id=@var{id} ,debug=@var{debug}, name=@var{name}
2180 @option{spiceport} is only available when spice support is built in.
2182 @option{debug} debug level for spicevmc
2184 @option{name} name of spice port to connect to
2186 Connect to a spice port, allowing a Spice client to handle the traffic
2187 identified by a name (preferably a fqdn).
2188 ETEXI
2190 STEXI
2191 @end table
2192 ETEXI
2193 DEFHEADING()
2195 DEFHEADING(Device URL Syntax:)
2196 STEXI
2198 In addition to using normal file images for the emulated storage devices,
2199 QEMU can also use networked resources such as iSCSI devices. These are
2200 specified using a special URL syntax.
2202 @table @option
2203 @item iSCSI
2204 iSCSI support allows QEMU to access iSCSI resources directly and use as
2205 images for the guest storage. Both disk and cdrom images are supported.
2207 Syntax for specifying iSCSI LUNs is
2208 ``iscsi://<target-ip>[:<port>]/<target-iqn>/<lun>''
2210 By default qemu will use the iSCSI initiator-name
2211 'iqn.2008-11.org.linux-kvm[:<name>]' but this can also be set from the command
2212 line or a configuration file.
2215 Example (without authentication):
2216 @example
2217 qemu-system-i386 -iscsi initiator-name=iqn.2001-04.com.example:my-initiator \
2218 -cdrom iscsi://192.0.2.1/iqn.2001-04.com.example/2 \
2219 -drive file=iscsi://192.0.2.1/iqn.2001-04.com.example/1
2220 @end example
2222 Example (CHAP username/password via URL):
2223 @example
2224 qemu-system-i386 -drive file=iscsi://user%password@@192.0.2.1/iqn.2001-04.com.example/1
2225 @end example
2227 Example (CHAP username/password via environment variables):
2228 @example
2229 LIBISCSI_CHAP_USERNAME="user" \
2230 LIBISCSI_CHAP_PASSWORD="password" \
2231 qemu-system-i386 -drive file=iscsi://192.0.2.1/iqn.2001-04.com.example/1
2232 @end example
2234 iSCSI support is an optional feature of QEMU and only available when
2235 compiled and linked against libiscsi.
2236 ETEXI
2237 DEF("iscsi", HAS_ARG, QEMU_OPTION_iscsi,
2238 "-iscsi [user=user][,password=password]\n"
2239 " [,header-digest=CRC32C|CR32C-NONE|NONE-CRC32C|NONE\n"
2240 " [,initiator-name=initiator-iqn][,id=target-iqn]\n"
2241 " iSCSI session parameters\n", QEMU_ARCH_ALL)
2242 STEXI
2244 iSCSI parameters such as username and password can also be specified via
2245 a configuration file. See qemu-doc for more information and examples.
2247 @item NBD
2248 QEMU supports NBD (Network Block Devices) both using TCP protocol as well
2249 as Unix Domain Sockets.
2251 Syntax for specifying a NBD device using TCP
2252 ``nbd:<server-ip>:<port>[:exportname=<export>]''
2254 Syntax for specifying a NBD device using Unix Domain Sockets
2255 ``nbd:unix:<domain-socket>[:exportname=<export>]''
2258 Example for TCP
2259 @example
2260 qemu-system-i386 --drive file=nbd:192.0.2.1:30000
2261 @end example
2263 Example for Unix Domain Sockets
2264 @example
2265 qemu-system-i386 --drive file=nbd:unix:/tmp/nbd-socket
2266 @end example
2268 @item SSH
2269 QEMU supports SSH (Secure Shell) access to remote disks.
2271 Examples:
2272 @example
2273 qemu-system-i386 -drive file=ssh://user@@host/path/to/disk.img
2274 qemu-system-i386 -drive file.driver=ssh,file.user=user,file.host=host,file.port=22,file.path=/path/to/disk.img
2275 @end example
2277 Currently authentication must be done using ssh-agent. Other
2278 authentication methods may be supported in future.
2280 @item Sheepdog
2281 Sheepdog is a distributed storage system for QEMU.
2282 QEMU supports using either local sheepdog devices or remote networked
2283 devices.
2285 Syntax for specifying a sheepdog device
2286 @example
2287 sheepdog[+tcp|+unix]://[host:port]/vdiname[?socket=path][#snapid|#tag]
2288 @end example
2290 Example
2291 @example
2292 qemu-system-i386 --drive file=sheepdog://192.0.2.1:30000/MyVirtualMachine
2293 @end example
2295 See also @url{http://http://www.osrg.net/sheepdog/}.
2297 @item GlusterFS
2298 GlusterFS is an user space distributed file system.
2299 QEMU supports the use of GlusterFS volumes for hosting VM disk images using
2300 TCP, Unix Domain Sockets and RDMA transport protocols.
2302 Syntax for specifying a VM disk image on GlusterFS volume is
2303 @example
2304 gluster[+transport]://[server[:port]]/volname/image[?socket=...]
2305 @end example
2308 Example
2309 @example
2310 qemu-system-x86_64 --drive file=gluster://192.0.2.1/testvol/a.img
2311 @end example
2313 See also @url{http://www.gluster.org}.
2315 @item HTTP/HTTPS/FTP/FTPS/TFTP
2316 QEMU supports read-only access to files accessed over http(s), ftp(s) and tftp.
2318 Syntax using a single filename:
2319 @example
2320 <protocol>://[<username>[:<password>]@@]<host>/<path>
2321 @end example
2323 where:
2324 @table @option
2325 @item protocol
2326 'http', 'https', 'ftp', 'ftps', or 'tftp'.
2328 @item username
2329 Optional username for authentication to the remote server.
2331 @item password
2332 Optional password for authentication to the remote server.
2334 @item host
2335 Address of the remote server.
2337 @item path
2338 Path on the remote server, including any query string.
2339 @end table
2341 The following options are also supported:
2342 @table @option
2343 @item url
2344 The full URL when passing options to the driver explicitly.
2346 @item readahead
2347 The amount of data to read ahead with each range request to the remote server.
2348 This value may optionally have the suffix 'T', 'G', 'M', 'K', 'k' or 'b'. If it
2349 does not have a suffix, it will be assumed to be in bytes. The value must be a
2350 multiple of 512 bytes. It defaults to 256k.
2352 @item sslverify
2353 Whether to verify the remote server's certificate when connecting over SSL. It
2354 can have the value 'on' or 'off'. It defaults to 'on'.
2356 @item cookie
2357 Send this cookie (it can also be a list of cookies separated by ';') with
2358 each outgoing request. Only supported when using protocols such as HTTP
2359 which support cookies, otherwise ignored.
2361 @item timeout
2362 Set the timeout in seconds of the CURL connection. This timeout is the time
2363 that CURL waits for a response from the remote server to get the size of the
2364 image to be downloaded. If not set, the default timeout of 5 seconds is used.
2365 @end table
2367 Note that when passing options to qemu explicitly, @option{driver} is the value
2368 of <protocol>.
2370 Example: boot from a remote Fedora 20 live ISO image
2371 @example
2372 qemu-system-x86_64 --drive media=cdrom,file=http://dl.fedoraproject.org/pub/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
2374 qemu-system-x86_64 --drive media=cdrom,file.driver=http,file.url=http://dl.fedoraproject.org/pub/fedora/linux/releases/20/Live/x86_64/Fedora-Live-Desktop-x86_64-20-1.iso,readonly
2375 @end example
2377 Example: boot from a remote Fedora 20 cloud image using a local overlay for
2378 writes, copy-on-read, and a readahead of 64k
2379 @example
2380 qemu-img create -f qcow2 -o backing_file='json:@{"file.driver":"http",, "file.url":"https://dl.fedoraproject.org/pub/fedora/linux/releases/20/Images/x86_64/Fedora-x86_64-20-20131211.1-sda.qcow2",, "file.readahead":"64k"@}' /tmp/Fedora-x86_64-20-20131211.1-sda.qcow2
2382 qemu-system-x86_64 -drive file=/tmp/Fedora-x86_64-20-20131211.1-sda.qcow2,copy-on-read=on
2383 @end example
2385 Example: boot from an image stored on a VMware vSphere server with a self-signed
2386 certificate using a local overlay for writes, a readahead of 64k and a timeout
2387 of 10 seconds.
2388 @example
2389 qemu-img create -f qcow2 -o backing_file='json:@{"file.driver":"https",, "file.url":"https://user:password@@vsphere.example.com/folder/test/test-flat.vmdk?dcPath=Datacenter&dsName=datastore1",, "file.sslverify":"off",, "file.readahead":"64k",, "file.timeout":10@}' /tmp/test.qcow2
2391 qemu-system-x86_64 -drive file=/tmp/test.qcow2
2392 @end example
2393 ETEXI
2395 STEXI
2396 @end table
2397 ETEXI
2399 DEFHEADING(Bluetooth(R) options:)
2400 STEXI
2401 @table @option
2402 ETEXI
2404 DEF("bt", HAS_ARG, QEMU_OPTION_bt, \
2405 "-bt hci,null dumb bluetooth HCI - doesn't respond to commands\n" \
2406 "-bt hci,host[:id]\n" \
2407 " use host's HCI with the given name\n" \
2408 "-bt hci[,vlan=n]\n" \
2409 " emulate a standard HCI in virtual scatternet 'n'\n" \
2410 "-bt vhci[,vlan=n]\n" \
2411 " add host computer to virtual scatternet 'n' using VHCI\n" \
2412 "-bt device:dev[,vlan=n]\n" \
2413 " emulate a bluetooth device 'dev' in scatternet 'n'\n",
2414 QEMU_ARCH_ALL)
2415 STEXI
2416 @item -bt hci[...]
2417 @findex -bt
2418 Defines the function of the corresponding Bluetooth HCI. -bt options
2419 are matched with the HCIs present in the chosen machine type. For
2420 example when emulating a machine with only one HCI built into it, only
2421 the first @code{-bt hci[...]} option is valid and defines the HCI's
2422 logic. The Transport Layer is decided by the machine type. Currently
2423 the machines @code{n800} and @code{n810} have one HCI and all other
2424 machines have none.
2426 @anchor{bt-hcis}
2427 The following three types are recognized:
2429 @table @option
2430 @item -bt hci,null
2431 (default) The corresponding Bluetooth HCI assumes no internal logic
2432 and will not respond to any HCI commands or emit events.
2434 @item -bt hci,host[:@var{id}]
2435 (@code{bluez} only) The corresponding HCI passes commands / events
2436 to / from the physical HCI identified by the name @var{id} (default:
2437 @code{hci0}) on the computer running QEMU. Only available on @code{bluez}
2438 capable systems like Linux.
2440 @item -bt hci[,vlan=@var{n}]
2441 Add a virtual, standard HCI that will participate in the Bluetooth
2442 scatternet @var{n} (default @code{0}). Similarly to @option{-net}
2443 VLANs, devices inside a bluetooth network @var{n} can only communicate
2444 with other devices in the same network (scatternet).
2445 @end table
2447 @item -bt vhci[,vlan=@var{n}]
2448 (Linux-host only) Create a HCI in scatternet @var{n} (default 0) attached
2449 to the host bluetooth stack instead of to the emulated target. This
2450 allows the host and target machines to participate in a common scatternet
2451 and communicate. Requires the Linux @code{vhci} driver installed. Can
2452 be used as following:
2454 @example
2455 qemu-system-i386 [...OPTIONS...] -bt hci,vlan=5 -bt vhci,vlan=5
2456 @end example
2458 @item -bt device:@var{dev}[,vlan=@var{n}]
2459 Emulate a bluetooth device @var{dev} and place it in network @var{n}
2460 (default @code{0}). QEMU can only emulate one type of bluetooth devices
2461 currently:
2463 @table @option
2464 @item keyboard
2465 Virtual wireless keyboard implementing the HIDP bluetooth profile.
2466 @end table
2467 ETEXI
2469 STEXI
2470 @end table
2471 ETEXI
2472 DEFHEADING()
2474 #ifdef CONFIG_TPM
2475 DEFHEADING(TPM device options:)
2477 DEF("tpmdev", HAS_ARG, QEMU_OPTION_tpmdev, \
2478 "-tpmdev passthrough,id=id[,path=path][,cancel-path=path]\n"
2479 " use path to provide path to a character device; default is /dev/tpm0\n"
2480 " use cancel-path to provide path to TPM's cancel sysfs entry; if\n"
2481 " not provided it will be searched for in /sys/class/misc/tpm?/device\n",
2482 QEMU_ARCH_ALL)
2483 STEXI
2485 The general form of a TPM device option is:
2486 @table @option
2488 @item -tpmdev @var{backend} ,id=@var{id} [,@var{options}]
2489 @findex -tpmdev
2490 Backend type must be:
2491 @option{passthrough}.
2493 The specific backend type will determine the applicable options.
2494 The @code{-tpmdev} option creates the TPM backend and requires a
2495 @code{-device} option that specifies the TPM frontend interface model.
2497 Options to each backend are described below.
2499 Use 'help' to print all available TPM backend types.
2500 @example
2501 qemu -tpmdev help
2502 @end example
2504 @item -tpmdev passthrough, id=@var{id}, path=@var{path}, cancel-path=@var{cancel-path}
2506 (Linux-host only) Enable access to the host's TPM using the passthrough
2507 driver.
2509 @option{path} specifies the path to the host's TPM device, i.e., on
2510 a Linux host this would be @code{/dev/tpm0}.
2511 @option{path} is optional and by default @code{/dev/tpm0} is used.
2513 @option{cancel-path} specifies the path to the host TPM device's sysfs
2514 entry allowing for cancellation of an ongoing TPM command.
2515 @option{cancel-path} is optional and by default QEMU will search for the
2516 sysfs entry to use.
2518 Some notes about using the host's TPM with the passthrough driver:
2520 The TPM device accessed by the passthrough driver must not be
2521 used by any other application on the host.
2523 Since the host's firmware (BIOS/UEFI) has already initialized the TPM,
2524 the VM's firmware (BIOS/UEFI) will not be able to initialize the
2525 TPM again and may therefore not show a TPM-specific menu that would
2526 otherwise allow the user to configure the TPM, e.g., allow the user to
2527 enable/disable or activate/deactivate the TPM.
2528 Further, if TPM ownership is released from within a VM then the host's TPM
2529 will get disabled and deactivated. To enable and activate the
2530 TPM again afterwards, the host has to be rebooted and the user is
2531 required to enter the firmware's menu to enable and activate the TPM.
2532 If the TPM is left disabled and/or deactivated most TPM commands will fail.
2534 To create a passthrough TPM use the following two options:
2535 @example
2536 -tpmdev passthrough,id=tpm0 -device tpm-tis,tpmdev=tpm0
2537 @end example
2538 Note that the @code{-tpmdev} id is @code{tpm0} and is referenced by
2539 @code{tpmdev=tpm0} in the device option.
2541 @end table
2543 ETEXI
2545 DEFHEADING()
2547 #endif
2549 DEFHEADING(Linux/Multiboot boot specific:)
2550 STEXI
2552 When using these options, you can use a given Linux or Multiboot
2553 kernel without installing it in the disk image. It can be useful
2554 for easier testing of various kernels.
2556 @table @option
2557 ETEXI
2559 DEF("kernel", HAS_ARG, QEMU_OPTION_kernel, \
2560 "-kernel bzImage use 'bzImage' as kernel image\n", QEMU_ARCH_ALL)
2561 STEXI
2562 @item -kernel @var{bzImage}
2563 @findex -kernel
2564 Use @var{bzImage} as kernel image. The kernel can be either a Linux kernel
2565 or in multiboot format.
2566 ETEXI
2568 DEF("append", HAS_ARG, QEMU_OPTION_append, \
2569 "-append cmdline use 'cmdline' as kernel command line\n", QEMU_ARCH_ALL)
2570 STEXI
2571 @item -append @var{cmdline}
2572 @findex -append
2573 Use @var{cmdline} as kernel command line
2574 ETEXI
2576 DEF("initrd", HAS_ARG, QEMU_OPTION_initrd, \
2577 "-initrd file use 'file' as initial ram disk\n", QEMU_ARCH_ALL)
2578 STEXI
2579 @item -initrd @var{file}
2580 @findex -initrd
2581 Use @var{file} as initial ram disk.
2583 @item -initrd "@var{file1} arg=foo,@var{file2}"
2585 This syntax is only available with multiboot.
2587 Use @var{file1} and @var{file2} as modules and pass arg=foo as parameter to the
2588 first module.
2589 ETEXI
2591 DEF("dtb", HAS_ARG, QEMU_OPTION_dtb, \
2592 "-dtb file use 'file' as device tree image\n", QEMU_ARCH_ALL)
2593 STEXI
2594 @item -dtb @var{file}
2595 @findex -dtb
2596 Use @var{file} as a device tree binary (dtb) image and pass it to the kernel
2597 on boot.
2598 ETEXI
2600 STEXI
2601 @end table
2602 ETEXI
2603 DEFHEADING()
2605 DEFHEADING(Debug/Expert options:)
2606 STEXI
2607 @table @option
2608 ETEXI
2610 DEF("serial", HAS_ARG, QEMU_OPTION_serial, \
2611 "-serial dev redirect the serial port to char device 'dev'\n",
2612 QEMU_ARCH_ALL)
2613 STEXI
2614 @item -serial @var{dev}
2615 @findex -serial
2616 Redirect the virtual serial port to host character device
2617 @var{dev}. The default device is @code{vc} in graphical mode and
2618 @code{stdio} in non graphical mode.
2620 This option can be used several times to simulate up to 4 serial
2621 ports.
2623 Use @code{-serial none} to disable all serial ports.
2625 Available character devices are:
2626 @table @option
2627 @item vc[:@var{W}x@var{H}]
2628 Virtual console. Optionally, a width and height can be given in pixel with
2629 @example
2630 vc:800x600
2631 @end example
2632 It is also possible to specify width or height in characters:
2633 @example
2634 vc:80Cx24C
2635 @end example
2636 @item pty
2637 [Linux only] Pseudo TTY (a new PTY is automatically allocated)
2638 @item none
2639 No device is allocated.
2640 @item null
2641 void device
2642 @item chardev:@var{id}
2643 Use a named character device defined with the @code{-chardev} option.
2644 @item /dev/XXX
2645 [Linux only] Use host tty, e.g. @file{/dev/ttyS0}. The host serial port
2646 parameters are set according to the emulated ones.
2647 @item /dev/parport@var{N}
2648 [Linux only, parallel port only] Use host parallel port
2649 @var{N}. Currently SPP and EPP parallel port features can be used.
2650 @item file:@var{filename}
2651 Write output to @var{filename}. No character can be read.
2652 @item stdio
2653 [Unix only] standard input/output
2654 @item pipe:@var{filename}
2655 name pipe @var{filename}
2656 @item COM@var{n}
2657 [Windows only] Use host serial port @var{n}
2658 @item udp:[@var{remote_host}]:@var{remote_port}[@@[@var{src_ip}]:@var{src_port}]
2659 This implements UDP Net Console.
2660 When @var{remote_host} or @var{src_ip} are not specified
2661 they default to @code{0.0.0.0}.
2662 When not using a specified @var{src_port} a random port is automatically chosen.
2664 If you just want a simple readonly console you can use @code{netcat} or
2665 @code{nc}, by starting QEMU with: @code{-serial udp::4555} and nc as:
2666 @code{nc -u -l -p 4555}. Any time QEMU writes something to that port it
2667 will appear in the netconsole session.
2669 If you plan to send characters back via netconsole or you want to stop
2670 and start QEMU a lot of times, you should have QEMU use the same
2671 source port each time by using something like @code{-serial
2672 udp::4555@@:4556} to QEMU. Another approach is to use a patched
2673 version of netcat which can listen to a TCP port and send and receive
2674 characters via udp. If you have a patched version of netcat which
2675 activates telnet remote echo and single char transfer, then you can
2676 use the following options to step up a netcat redirector to allow
2677 telnet on port 5555 to access the QEMU port.
2678 @table @code
2679 @item QEMU Options:
2680 -serial udp::4555@@:4556
2681 @item netcat options:
2682 -u -P 4555 -L 0.0.0.0:4556 -t -p 5555 -I -T
2683 @item telnet options:
2684 localhost 5555
2685 @end table
2687 @item tcp:[@var{host}]:@var{port}[,@var{server}][,nowait][,nodelay]
2688 The TCP Net Console has two modes of operation. It can send the serial
2689 I/O to a location or wait for a connection from a location. By default
2690 the TCP Net Console is sent to @var{host} at the @var{port}. If you use
2691 the @var{server} option QEMU will wait for a client socket application
2692 to connect to the port before continuing, unless the @code{nowait}
2693 option was specified. The @code{nodelay} option disables the Nagle buffering
2694 algorithm. If @var{host} is omitted, 0.0.0.0 is assumed. Only
2695 one TCP connection at a time is accepted. You can use @code{telnet} to
2696 connect to the corresponding character device.
2697 @table @code
2698 @item Example to send tcp console to 192.168.0.2 port 4444
2699 -serial tcp:192.168.0.2:4444
2700 @item Example to listen and wait on port 4444 for connection
2701 -serial tcp::4444,server
2702 @item Example to not wait and listen on ip 192.168.0.100 port 4444
2703 -serial tcp:192.168.0.100:4444,server,nowait
2704 @end table
2706 @item telnet:@var{host}:@var{port}[,server][,nowait][,nodelay]
2707 The telnet protocol is used instead of raw tcp sockets. The options
2708 work the same as if you had specified @code{-serial tcp}. The
2709 difference is that the port acts like a telnet server or client using
2710 telnet option negotiation. This will also allow you to send the
2711 MAGIC_SYSRQ sequence if you use a telnet that supports sending the break
2712 sequence. Typically in unix telnet you do it with Control-] and then
2713 type "send break" followed by pressing the enter key.
2715 @item unix:@var{path}[,server][,nowait]
2716 A unix domain socket is used instead of a tcp socket. The option works the
2717 same as if you had specified @code{-serial tcp} except the unix domain socket
2718 @var{path} is used for connections.
2720 @item mon:@var{dev_string}
2721 This is a special option to allow the monitor to be multiplexed onto
2722 another serial port. The monitor is accessed with key sequence of
2723 @key{Control-a} and then pressing @key{c}.
2724 @var{dev_string} should be any one of the serial devices specified
2725 above. An example to multiplex the monitor onto a telnet server
2726 listening on port 4444 would be:
2727 @table @code
2728 @item -serial mon:telnet::4444,server,nowait
2729 @end table
2730 When the monitor is multiplexed to stdio in this way, Ctrl+C will not terminate
2731 QEMU any more but will be passed to the guest instead.
2733 @item braille
2734 Braille device. This will use BrlAPI to display the braille output on a real
2735 or fake device.
2737 @item msmouse
2738 Three button serial mouse. Configure the guest to use Microsoft protocol.
2739 @end table
2740 ETEXI
2742 DEF("parallel", HAS_ARG, QEMU_OPTION_parallel, \
2743 "-parallel dev redirect the parallel port to char device 'dev'\n",
2744 QEMU_ARCH_ALL)
2745 STEXI
2746 @item -parallel @var{dev}
2747 @findex -parallel
2748 Redirect the virtual parallel port to host device @var{dev} (same
2749 devices as the serial port). On Linux hosts, @file{/dev/parportN} can
2750 be used to use hardware devices connected on the corresponding host
2751 parallel port.
2753 This option can be used several times to simulate up to 3 parallel
2754 ports.
2756 Use @code{-parallel none} to disable all parallel ports.
2757 ETEXI
2759 DEF("monitor", HAS_ARG, QEMU_OPTION_monitor, \
2760 "-monitor dev redirect the monitor to char device 'dev'\n",
2761 QEMU_ARCH_ALL)
2762 STEXI
2763 @item -monitor @var{dev}
2764 @findex -monitor
2765 Redirect the monitor to host device @var{dev} (same devices as the
2766 serial port).
2767 The default device is @code{vc} in graphical mode and @code{stdio} in
2768 non graphical mode.
2769 Use @code{-monitor none} to disable the default monitor.
2770 ETEXI
2771 DEF("qmp", HAS_ARG, QEMU_OPTION_qmp, \
2772 "-qmp dev like -monitor but opens in 'control' mode\n",
2773 QEMU_ARCH_ALL)
2774 STEXI
2775 @item -qmp @var{dev}
2776 @findex -qmp
2777 Like -monitor but opens in 'control' mode.
2778 ETEXI
2780 DEF("mon", HAS_ARG, QEMU_OPTION_mon, \
2781 "-mon [chardev=]name[,mode=readline|control][,default]\n", QEMU_ARCH_ALL)
2782 STEXI
2783 @item -mon [chardev=]name[,mode=readline|control][,default]
2784 @findex -mon
2785 Setup monitor on chardev @var{name}.
2786 ETEXI
2788 DEF("debugcon", HAS_ARG, QEMU_OPTION_debugcon, \
2789 "-debugcon dev redirect the debug console to char device 'dev'\n",
2790 QEMU_ARCH_ALL)
2791 STEXI
2792 @item -debugcon @var{dev}
2793 @findex -debugcon
2794 Redirect the debug console to host device @var{dev} (same devices as the
2795 serial port). The debug console is an I/O port which is typically port
2796 0xe9; writing to that I/O port sends output to this device.
2797 The default device is @code{vc} in graphical mode and @code{stdio} in
2798 non graphical mode.
2799 ETEXI
2801 DEF("pidfile", HAS_ARG, QEMU_OPTION_pidfile, \
2802 "-pidfile file write PID to 'file'\n", QEMU_ARCH_ALL)
2803 STEXI
2804 @item -pidfile @var{file}
2805 @findex -pidfile
2806 Store the QEMU process PID in @var{file}. It is useful if you launch QEMU
2807 from a script.
2808 ETEXI
2810 DEF("singlestep", 0, QEMU_OPTION_singlestep, \
2811 "-singlestep always run in singlestep mode\n", QEMU_ARCH_ALL)
2812 STEXI
2813 @item -singlestep
2814 @findex -singlestep
2815 Run the emulation in single step mode.
2816 ETEXI
2818 DEF("S", 0, QEMU_OPTION_S, \
2819 "-S freeze CPU at startup (use 'c' to start execution)\n",
2820 QEMU_ARCH_ALL)
2821 STEXI
2822 @item -S
2823 @findex -S
2824 Do not start CPU at startup (you must type 'c' in the monitor).
2825 ETEXI
2827 DEF("realtime", HAS_ARG, QEMU_OPTION_realtime,
2828 "-realtime [mlock=on|off]\n"
2829 " run qemu with realtime features\n"
2830 " mlock=on|off controls mlock support (default: on)\n",
2831 QEMU_ARCH_ALL)
2832 STEXI
2833 @item -realtime mlock=on|off
2834 @findex -realtime
2835 Run qemu with realtime features.
2836 mlocking qemu and guest memory can be enabled via @option{mlock=on}
2837 (enabled by default).
2838 ETEXI
2840 DEF("gdb", HAS_ARG, QEMU_OPTION_gdb, \
2841 "-gdb dev wait for gdb connection on 'dev'\n", QEMU_ARCH_ALL)
2842 STEXI
2843 @item -gdb @var{dev}
2844 @findex -gdb
2845 Wait for gdb connection on device @var{dev} (@pxref{gdb_usage}). Typical
2846 connections will likely be TCP-based, but also UDP, pseudo TTY, or even
2847 stdio are reasonable use case. The latter is allowing to start QEMU from
2848 within gdb and establish the connection via a pipe:
2849 @example
2850 (gdb) target remote | exec qemu-system-i386 -gdb stdio ...
2851 @end example
2852 ETEXI
2854 DEF("s", 0, QEMU_OPTION_s, \
2855 "-s shorthand for -gdb tcp::" DEFAULT_GDBSTUB_PORT "\n",
2856 QEMU_ARCH_ALL)
2857 STEXI
2858 @item -s
2859 @findex -s
2860 Shorthand for -gdb tcp::1234, i.e. open a gdbserver on TCP port 1234
2861 (@pxref{gdb_usage}).
2862 ETEXI
2864 DEF("d", HAS_ARG, QEMU_OPTION_d, \
2865 "-d item1,... enable logging of specified items (use '-d help' for a list of log items)\n",
2866 QEMU_ARCH_ALL)
2867 STEXI
2868 @item -d @var{item1}[,...]
2869 @findex -d
2870 Enable logging of specified items. Use '-d help' for a list of log items.
2871 ETEXI
2873 DEF("D", HAS_ARG, QEMU_OPTION_D, \
2874 "-D logfile output log to logfile (default stderr)\n",
2875 QEMU_ARCH_ALL)
2876 STEXI
2877 @item -D @var{logfile}
2878 @findex -D
2879 Output log in @var{logfile} instead of to stderr
2880 ETEXI
2882 DEF("L", HAS_ARG, QEMU_OPTION_L, \
2883 "-L path set the directory for the BIOS, VGA BIOS and keymaps\n",
2884 QEMU_ARCH_ALL)
2885 STEXI
2886 @item -L @var{path}
2887 @findex -L
2888 Set the directory for the BIOS, VGA BIOS and keymaps.
2889 ETEXI
2891 DEF("bios", HAS_ARG, QEMU_OPTION_bios, \
2892 "-bios file set the filename for the BIOS\n", QEMU_ARCH_ALL)
2893 STEXI
2894 @item -bios @var{file}
2895 @findex -bios
2896 Set the filename for the BIOS.
2897 ETEXI
2899 DEF("enable-kvm", 0, QEMU_OPTION_enable_kvm, \
2900 "-enable-kvm enable KVM full virtualization support\n", QEMU_ARCH_ALL)
2901 STEXI
2902 @item -enable-kvm
2903 @findex -enable-kvm
2904 Enable KVM full virtualization support. This option is only available
2905 if KVM support is enabled when compiling.
2906 ETEXI
2908 DEF("xen-domid", HAS_ARG, QEMU_OPTION_xen_domid,
2909 "-xen-domid id specify xen guest domain id\n", QEMU_ARCH_ALL)
2910 DEF("xen-create", 0, QEMU_OPTION_xen_create,
2911 "-xen-create create domain using xen hypercalls, bypassing xend\n"
2912 " warning: should not be used when xend is in use\n",
2913 QEMU_ARCH_ALL)
2914 DEF("xen-attach", 0, QEMU_OPTION_xen_attach,
2915 "-xen-attach attach to existing xen domain\n"
2916 " xend will use this when starting QEMU\n",
2917 QEMU_ARCH_ALL)
2918 STEXI
2919 @item -xen-domid @var{id}
2920 @findex -xen-domid
2921 Specify xen guest domain @var{id} (XEN only).
2922 @item -xen-create
2923 @findex -xen-create
2924 Create domain using xen hypercalls, bypassing xend.
2925 Warning: should not be used when xend is in use (XEN only).
2926 @item -xen-attach
2927 @findex -xen-attach
2928 Attach to existing xen domain.
2929 xend will use this when starting QEMU (XEN only).
2930 ETEXI
2932 DEF("no-reboot", 0, QEMU_OPTION_no_reboot, \
2933 "-no-reboot exit instead of rebooting\n", QEMU_ARCH_ALL)
2934 STEXI
2935 @item -no-reboot
2936 @findex -no-reboot
2937 Exit instead of rebooting.
2938 ETEXI
2940 DEF("no-shutdown", 0, QEMU_OPTION_no_shutdown, \
2941 "-no-shutdown stop before shutdown\n", QEMU_ARCH_ALL)
2942 STEXI
2943 @item -no-shutdown
2944 @findex -no-shutdown
2945 Don't exit QEMU on guest shutdown, but instead only stop the emulation.
2946 This allows for instance switching to monitor to commit changes to the
2947 disk image.
2948 ETEXI
2950 DEF("loadvm", HAS_ARG, QEMU_OPTION_loadvm, \
2951 "-loadvm [tag|id]\n" \
2952 " start right away with a saved state (loadvm in monitor)\n",
2953 QEMU_ARCH_ALL)
2954 STEXI
2955 @item -loadvm @var{file}
2956 @findex -loadvm
2957 Start right away with a saved state (@code{loadvm} in monitor)
2958 ETEXI
2960 #ifndef _WIN32
2961 DEF("daemonize", 0, QEMU_OPTION_daemonize, \
2962 "-daemonize daemonize QEMU after initializing\n", QEMU_ARCH_ALL)
2963 #endif
2964 STEXI
2965 @item -daemonize
2966 @findex -daemonize
2967 Daemonize the QEMU process after initialization. QEMU will not detach from
2968 standard IO until it is ready to receive connections on any of its devices.
2969 This option is a useful way for external programs to launch QEMU without having
2970 to cope with initialization race conditions.
2971 ETEXI
2973 DEF("option-rom", HAS_ARG, QEMU_OPTION_option_rom, \
2974 "-option-rom rom load a file, rom, into the option ROM space\n",
2975 QEMU_ARCH_ALL)
2976 STEXI
2977 @item -option-rom @var{file}
2978 @findex -option-rom
2979 Load the contents of @var{file} as an option ROM.
2980 This option is useful to load things like EtherBoot.
2981 ETEXI
2983 DEF("clock", HAS_ARG, QEMU_OPTION_clock, \
2984 "-clock force the use of the given methods for timer alarm.\n" \
2985 " To see what timers are available use '-clock help'\n",
2986 QEMU_ARCH_ALL)
2987 STEXI
2988 @item -clock @var{method}
2989 @findex -clock
2990 Force the use of the given methods for timer alarm. To see what timers
2991 are available use @code{-clock help}.
2992 ETEXI
2994 HXCOMM Options deprecated by -rtc
2995 DEF("localtime", 0, QEMU_OPTION_localtime, "", QEMU_ARCH_ALL)
2996 DEF("startdate", HAS_ARG, QEMU_OPTION_startdate, "", QEMU_ARCH_ALL)
2998 DEF("rtc", HAS_ARG, QEMU_OPTION_rtc, \
2999 "-rtc [base=utc|localtime|date][,clock=host|rt|vm][,driftfix=none|slew]\n" \
3000 " set the RTC base and clock, enable drift fix for clock ticks (x86 only)\n",
3001 QEMU_ARCH_ALL)
3003 STEXI
3005 @item -rtc [base=utc|localtime|@var{date}][,clock=host|vm][,driftfix=none|slew]
3006 @findex -rtc
3007 Specify @option{base} as @code{utc} or @code{localtime} to let the RTC start at the current
3008 UTC or local time, respectively. @code{localtime} is required for correct date in
3009 MS-DOS or Windows. To start at a specific point in time, provide @var{date} in the
3010 format @code{2006-06-17T16:01:21} or @code{2006-06-17}. The default base is UTC.
3012 By default the RTC is driven by the host system time. This allows using of the
3013 RTC as accurate reference clock inside the guest, specifically if the host
3014 time is smoothly following an accurate external reference clock, e.g. via NTP.
3015 If you want to isolate the guest time from the host, you can set @option{clock}
3016 to @code{rt} instead. To even prevent it from progressing during suspension,
3017 you can set it to @code{vm}.
3019 Enable @option{driftfix} (i386 targets only) if you experience time drift problems,
3020 specifically with Windows' ACPI HAL. This option will try to figure out how
3021 many timer interrupts were not processed by the Windows guest and will
3022 re-inject them.
3023 ETEXI
3025 DEF("icount", HAS_ARG, QEMU_OPTION_icount, \
3026 "-icount [shift=N|auto][,align=on|off]\n" \
3027 " enable virtual instruction counter with 2^N clock ticks per\n" \
3028 " instruction and enable aligning the host and virtual clocks\n", QEMU_ARCH_ALL)
3029 STEXI
3030 @item -icount [shift=@var{N}|auto]
3031 @findex -icount
3032 Enable virtual instruction counter. The virtual cpu will execute one
3033 instruction every 2^@var{N} ns of virtual time. If @code{auto} is specified
3034 then the virtual cpu speed will be automatically adjusted to keep virtual
3035 time within a few seconds of real time.
3037 Note that while this option can give deterministic behavior, it does not
3038 provide cycle accurate emulation. Modern CPUs contain superscalar out of
3039 order cores with complex cache hierarchies. The number of instructions
3040 executed often has little or no correlation with actual performance.
3042 @option{align=on} will activate the delay algorithm which will try to
3043 to synchronise the host clock and the virtual clock. The goal is to
3044 have a guest running at the real frequency imposed by the shift option.
3045 Whenever the guest clock is behind the host clock and if
3046 @option{align=on} is specified then we print a messsage to the user
3047 to inform about the delay.
3048 Currently this option does not work when @option{shift} is @code{auto}.
3049 Note: The sync algorithm will work for those shift values for which
3050 the guest clock runs ahead of the host clock. Typically this happens
3051 when the shift value is high (how high depends on the host machine).
3052 ETEXI
3054 DEF("watchdog", HAS_ARG, QEMU_OPTION_watchdog, \
3055 "-watchdog i6300esb|ib700\n" \
3056 " enable virtual hardware watchdog [default=none]\n",
3057 QEMU_ARCH_ALL)
3058 STEXI
3059 @item -watchdog @var{model}
3060 @findex -watchdog
3061 Create a virtual hardware watchdog device. Once enabled (by a guest
3062 action), the watchdog must be periodically polled by an agent inside
3063 the guest or else the guest will be restarted.
3065 The @var{model} is the model of hardware watchdog to emulate. Choices
3066 for model are: @code{ib700} (iBASE 700) which is a very simple ISA
3067 watchdog with a single timer, or @code{i6300esb} (Intel 6300ESB I/O
3068 controller hub) which is a much more featureful PCI-based dual-timer
3069 watchdog. Choose a model for which your guest has drivers.
3071 Use @code{-watchdog help} to list available hardware models. Only one
3072 watchdog can be enabled for a guest.
3073 ETEXI
3075 DEF("watchdog-action", HAS_ARG, QEMU_OPTION_watchdog_action, \
3076 "-watchdog-action reset|shutdown|poweroff|pause|debug|none\n" \
3077 " action when watchdog fires [default=reset]\n",
3078 QEMU_ARCH_ALL)
3079 STEXI
3080 @item -watchdog-action @var{action}
3081 @findex -watchdog-action
3083 The @var{action} controls what QEMU will do when the watchdog timer
3084 expires.
3085 The default is
3086 @code{reset} (forcefully reset the guest).
3087 Other possible actions are:
3088 @code{shutdown} (attempt to gracefully shutdown the guest),
3089 @code{poweroff} (forcefully poweroff the guest),
3090 @code{pause} (pause the guest),
3091 @code{debug} (print a debug message and continue), or
3092 @code{none} (do nothing).
3094 Note that the @code{shutdown} action requires that the guest responds
3095 to ACPI signals, which it may not be able to do in the sort of
3096 situations where the watchdog would have expired, and thus
3097 @code{-watchdog-action shutdown} is not recommended for production use.
3099 Examples:
3101 @table @code
3102 @item -watchdog i6300esb -watchdog-action pause
3103 @item -watchdog ib700
3104 @end table
3105 ETEXI
3107 DEF("echr", HAS_ARG, QEMU_OPTION_echr, \
3108 "-echr chr set terminal escape character instead of ctrl-a\n",
3109 QEMU_ARCH_ALL)
3110 STEXI
3112 @item -echr @var{numeric_ascii_value}
3113 @findex -echr
3114 Change the escape character used for switching to the monitor when using
3115 monitor and serial sharing. The default is @code{0x01} when using the
3116 @code{-nographic} option. @code{0x01} is equal to pressing
3117 @code{Control-a}. You can select a different character from the ascii
3118 control keys where 1 through 26 map to Control-a through Control-z. For
3119 instance you could use the either of the following to change the escape
3120 character to Control-t.
3121 @table @code
3122 @item -echr 0x14
3123 @item -echr 20
3124 @end table
3125 ETEXI
3127 DEF("virtioconsole", HAS_ARG, QEMU_OPTION_virtiocon, \
3128 "-virtioconsole c\n" \
3129 " set virtio console\n", QEMU_ARCH_ALL)
3130 STEXI
3131 @item -virtioconsole @var{c}
3132 @findex -virtioconsole
3133 Set virtio console.
3135 This option is maintained for backward compatibility.
3137 Please use @code{-device virtconsole} for the new way of invocation.
3138 ETEXI
3140 DEF("show-cursor", 0, QEMU_OPTION_show_cursor, \
3141 "-show-cursor show cursor\n", QEMU_ARCH_ALL)
3142 STEXI
3143 @item -show-cursor
3144 @findex -show-cursor
3145 Show cursor.
3146 ETEXI
3148 DEF("tb-size", HAS_ARG, QEMU_OPTION_tb_size, \
3149 "-tb-size n set TB size\n", QEMU_ARCH_ALL)
3150 STEXI
3151 @item -tb-size @var{n}
3152 @findex -tb-size
3153 Set TB size.
3154 ETEXI
3156 DEF("incoming", HAS_ARG, QEMU_OPTION_incoming, \
3157 "-incoming p prepare for incoming migration, listen on port p\n",
3158 QEMU_ARCH_ALL)
3159 STEXI
3160 @item -incoming @var{port}
3161 @findex -incoming
3162 Prepare for incoming migration, listen on @var{port}.
3163 ETEXI
3165 DEF("nodefaults", 0, QEMU_OPTION_nodefaults, \
3166 "-nodefaults don't create default devices\n", QEMU_ARCH_ALL)
3167 STEXI
3168 @item -nodefaults
3169 @findex -nodefaults
3170 Don't create default devices. Normally, QEMU sets the default devices like serial
3171 port, parallel port, virtual console, monitor device, VGA adapter, floppy and
3172 CD-ROM drive and others. The @code{-nodefaults} option will disable all those
3173 default devices.
3174 ETEXI
3176 #ifndef _WIN32
3177 DEF("chroot", HAS_ARG, QEMU_OPTION_chroot, \
3178 "-chroot dir chroot to dir just before starting the VM\n",
3179 QEMU_ARCH_ALL)
3180 #endif
3181 STEXI
3182 @item -chroot @var{dir}
3183 @findex -chroot
3184 Immediately before starting guest execution, chroot to the specified
3185 directory. Especially useful in combination with -runas.
3186 ETEXI
3188 #ifndef _WIN32
3189 DEF("runas", HAS_ARG, QEMU_OPTION_runas, \
3190 "-runas user change to user id user just before starting the VM\n",
3191 QEMU_ARCH_ALL)
3192 #endif
3193 STEXI
3194 @item -runas @var{user}
3195 @findex -runas
3196 Immediately before starting guest execution, drop root privileges, switching
3197 to the specified user.
3198 ETEXI
3200 DEF("prom-env", HAS_ARG, QEMU_OPTION_prom_env,
3201 "-prom-env variable=value\n"
3202 " set OpenBIOS nvram variables\n",
3203 QEMU_ARCH_PPC | QEMU_ARCH_SPARC)
3204 STEXI
3205 @item -prom-env @var{variable}=@var{value}
3206 @findex -prom-env
3207 Set OpenBIOS nvram @var{variable} to given @var{value} (PPC, SPARC only).
3208 ETEXI
3209 DEF("semihosting", 0, QEMU_OPTION_semihosting,
3210 "-semihosting semihosting mode\n",
3211 QEMU_ARCH_ARM | QEMU_ARCH_M68K | QEMU_ARCH_XTENSA | QEMU_ARCH_LM32)
3212 STEXI
3213 @item -semihosting
3214 @findex -semihosting
3215 Semihosting mode (ARM, M68K, Xtensa only).
3216 ETEXI
3217 DEF("old-param", 0, QEMU_OPTION_old_param,
3218 "-old-param old param mode\n", QEMU_ARCH_ARM)
3219 STEXI
3220 @item -old-param
3221 @findex -old-param (ARM)
3222 Old param mode (ARM only).
3223 ETEXI
3225 DEF("sandbox", HAS_ARG, QEMU_OPTION_sandbox, \
3226 "-sandbox <arg> Enable seccomp mode 2 system call filter (default 'off').\n",
3227 QEMU_ARCH_ALL)
3228 STEXI
3229 @item -sandbox @var{arg}
3230 @findex -sandbox
3231 Enable Seccomp mode 2 system call filter. 'on' will enable syscall filtering and 'off' will
3232 disable it. The default is 'off'.
3233 ETEXI
3235 DEF("readconfig", HAS_ARG, QEMU_OPTION_readconfig,
3236 "-readconfig <file>\n", QEMU_ARCH_ALL)
3237 STEXI
3238 @item -readconfig @var{file}
3239 @findex -readconfig
3240 Read device configuration from @var{file}. This approach is useful when you want to spawn
3241 QEMU process with many command line options but you don't want to exceed the command line
3242 character limit.
3243 ETEXI
3244 DEF("writeconfig", HAS_ARG, QEMU_OPTION_writeconfig,
3245 "-writeconfig <file>\n"
3246 " read/write config file\n", QEMU_ARCH_ALL)
3247 STEXI
3248 @item -writeconfig @var{file}
3249 @findex -writeconfig
3250 Write device configuration to @var{file}. The @var{file} can be either filename to save
3251 command line and device configuration into file or dash @code{-}) character to print the
3252 output to stdout. This can be later used as input file for @code{-readconfig} option.
3253 ETEXI
3254 DEF("nodefconfig", 0, QEMU_OPTION_nodefconfig,
3255 "-nodefconfig\n"
3256 " do not load default config files at startup\n",
3257 QEMU_ARCH_ALL)
3258 STEXI
3259 @item -nodefconfig
3260 @findex -nodefconfig
3261 Normally QEMU loads configuration files from @var{sysconfdir} and @var{datadir} at startup.
3262 The @code{-nodefconfig} option will prevent QEMU from loading any of those config files.
3263 ETEXI
3264 DEF("no-user-config", 0, QEMU_OPTION_nouserconfig,
3265 "-no-user-config\n"
3266 " do not load user-provided config files at startup\n",
3267 QEMU_ARCH_ALL)
3268 STEXI
3269 @item -no-user-config
3270 @findex -no-user-config
3271 The @code{-no-user-config} option makes QEMU not load any of the user-provided
3272 config files on @var{sysconfdir}, but won't make it skip the QEMU-provided config
3273 files from @var{datadir}.
3274 ETEXI
3275 DEF("trace", HAS_ARG, QEMU_OPTION_trace,
3276 "-trace [events=<file>][,file=<file>]\n"
3277 " specify tracing options\n",
3278 QEMU_ARCH_ALL)
3279 STEXI
3280 HXCOMM This line is not accurate, as some sub-options are backend-specific but
3281 HXCOMM HX does not support conditional compilation of text.
3282 @item -trace [events=@var{file}][,file=@var{file}]
3283 @findex -trace
3285 Specify tracing options.
3287 @table @option
3288 @item events=@var{file}
3289 Immediately enable events listed in @var{file}.
3290 The file must contain one event name (as listed in the @var{trace-events} file)
3291 per line.
3292 This option is only available if QEMU has been compiled with
3293 either @var{simple} or @var{stderr} tracing backend.
3294 @item file=@var{file}
3295 Log output traces to @var{file}.
3297 This option is only available if QEMU has been compiled with
3298 the @var{simple} tracing backend.
3299 @end table
3300 ETEXI
3302 HXCOMM Internal use
3303 DEF("qtest", HAS_ARG, QEMU_OPTION_qtest, "", QEMU_ARCH_ALL)
3304 DEF("qtest-log", HAS_ARG, QEMU_OPTION_qtest_log, "", QEMU_ARCH_ALL)
3306 #ifdef __linux__
3307 DEF("enable-fips", 0, QEMU_OPTION_enablefips,
3308 "-enable-fips enable FIPS 140-2 compliance\n",
3309 QEMU_ARCH_ALL)
3310 #endif
3311 STEXI
3312 @item -enable-fips
3313 @findex -enable-fips
3314 Enable FIPS 140-2 compliance mode.
3315 ETEXI
3317 HXCOMM Deprecated by -machine accel=tcg property
3318 DEF("no-kvm", 0, QEMU_OPTION_no_kvm, "", QEMU_ARCH_I386)
3320 HXCOMM Deprecated by kvm-pit driver properties
3321 DEF("no-kvm-pit-reinjection", 0, QEMU_OPTION_no_kvm_pit_reinjection,
3322 "", QEMU_ARCH_I386)
3324 HXCOMM Deprecated (ignored)
3325 DEF("no-kvm-pit", 0, QEMU_OPTION_no_kvm_pit, "", QEMU_ARCH_I386)
3327 HXCOMM Deprecated by -machine kernel_irqchip=on|off property
3328 DEF("no-kvm-irqchip", 0, QEMU_OPTION_no_kvm_irqchip, "", QEMU_ARCH_I386)
3330 HXCOMM Deprecated (ignored)
3331 DEF("tdf", 0, QEMU_OPTION_tdf,"", QEMU_ARCH_ALL)
3333 DEF("object", HAS_ARG, QEMU_OPTION_object,
3334 "-object TYPENAME[,PROP1=VALUE1,...]\n"
3335 " create an new object of type TYPENAME setting properties\n"
3336 " in the order they are specified. Note that the 'id'\n"
3337 " property must be set. These objects are placed in the\n"
3338 " '/objects' path.\n",
3339 QEMU_ARCH_ALL)
3340 STEXI
3341 @item -object @var{typename}[,@var{prop1}=@var{value1},...]
3342 @findex -object
3343 Create an new object of type @var{typename} setting properties
3344 in the order they are specified. Note that the 'id'
3345 property must be set. These objects are placed in the
3346 '/objects' path.
3347 ETEXI
3349 DEF("msg", HAS_ARG, QEMU_OPTION_msg,
3350 "-msg timestamp[=on|off]\n"
3351 " change the format of messages\n"
3352 " on|off controls leading timestamps (default:on)\n",
3353 QEMU_ARCH_ALL)
3354 STEXI
3355 @item -msg timestamp[=on|off]
3356 @findex -msg
3357 prepend a timestamp to each log message.(default:on)
3358 ETEXI
3360 DEF("dump-vmstate", HAS_ARG, QEMU_OPTION_dump_vmstate,
3361 "-dump-vmstate <file>\n"
3362 " Output vmstate information in JSON format to file.\n"
3363 " Use the scripts/vmstate-static-checker.py file to\n"
3364 " check for possible regressions in migration code\n"
3365 " by comparing two such vmstate dumps.",
3366 QEMU_ARCH_ALL)
3367 STEXI
3368 @item -dump-vmstate @var{file}
3369 @findex -dump-vmstate
3370 Dump json-encoded vmstate information for current machine type to file
3371 in @var{file}
3372 ETEXI
3374 HXCOMM This is the last statement. Insert new options before this line!
3375 STEXI
3376 @end table
3377 ETEXI