Statistics
| Branch: | Revision:

root / qemu-options.hx @ fb5590f7

History | View | Annotate | Download (92.1 kB)

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