Project

General

Profile

QEMU Options » History » Version 2

Sergey Smolov, 11/19/2019 02:27 PM

1 1 Sergey Smolov
h1. QEMU Options
2
3 2 Sergey Smolov
The set of options that QEMU provides may depend on the selected architecture.
4
The output for *qemu-system-aarch64* with "-help" option is written below.
5 1 Sergey Smolov
6
<pre>
7
Standard options:
8
-h or -help     display this help and exit
9
-version        display version information and exit
10
-machine [type=]name[,prop[=value][,...]]
11
                selects emulated machine ('-machine help' for list)
12
                property accel=accel1[:accel2[:...]] selects accelerator
13 2 Sergey Smolov
                supported accelerators are kvm, xen, hax, hvf, whpx or tcg (default: tcg)
14 1 Sergey Smolov
                kernel_irqchip=on|off|split controls accelerated irqchip support (default=off)
15
                vmport=on|off|auto controls emulation of vmport (default: auto)
16
                kvm_shadow_mem=size of KVM shadow MMU in bytes
17
                dump-guest-core=on|off include guest memory in a core dump (default=on)
18
                mem-merge=on|off controls memory merge support (default: on)
19
                igd-passthru=on|off controls IGD GFX passthrough support (default=off)
20
                aes-key-wrap=on|off controls support for AES key wrapping (default=on)
21
                dea-key-wrap=on|off controls support for DEA key wrapping (default=on)
22
                suppress-vmdesc=on|off disables self-describing migration (default=off)
23
                nvdimm=on|off controls NVDIMM support (default=off)
24
                enforce-config-section=on|off enforce configuration section migration (default=off)
25 2 Sergey Smolov
                memory-encryption=@var{} memory encryption object to use (default=none)
26 1 Sergey Smolov
-cpu cpu        select CPU ('-cpu help' for list)
27
-accel [accel=]accelerator[,thread=single|multi]
28 2 Sergey Smolov
                select accelerator (kvm, xen, hax, hvf, whpx or tcg; use 'help' for a list)
29
                thread=single|multi (enable multi-threaded TCG)
30
-smp [cpus=]n[,maxcpus=cpus][,cores=cores][,threads=threads][,dies=dies][,sockets=sockets]
31 1 Sergey Smolov
                set the number of CPUs to 'n' [default=1]
32
                maxcpus= maximum number of total cpus, including
33
                offline CPUs for hotplug, etc
34 2 Sergey Smolov
                cores= number of CPU cores on one socket (for PC, it's on one die)
35 1 Sergey Smolov
                threads= number of threads on one CPU core
36 2 Sergey Smolov
                dies= number of CPU dies on one socket (for PC only)
37 1 Sergey Smolov
                sockets= number of discrete sockets in the system
38
-numa node[,mem=size][,cpus=firstcpu[-lastcpu]][,nodeid=node]
39
-numa node[,memdev=id][,cpus=firstcpu[-lastcpu]][,nodeid=node]
40 2 Sergey Smolov
-numa dist,src=source,dst=destination,val=distance
41
-numa cpu,node-id=node[,socket-id=x][,core-id=y][,thread-id=z]
42 1 Sergey Smolov
-add-fd fd=fd,set=set[,opaque=opaque]
43
                Add 'fd' to fd 'set'
44
-set group.id.arg=value
45
                set <arg> parameter for item <id> of type <group>
46
                i.e. -set drive.$id.file=/path/to/image
47
-global driver.property=value
48
-global driver=driver,property=property,value=value
49
                set a global default for a driver property
50
-boot [order=drives][,once=drives][,menu=on|off]
51
      [,splash=sp_name][,splash-time=sp_time][,reboot-timeout=rb_time][,strict=on|off]
52
                'drives': floppy (a), hard disk (c), CD-ROM (d), network (n)
53
                'sp_name': the file's name that would be passed to bios as logo picture, if menu=on
54
                'sp_time': the period that splash picture last if menu=on, unit is ms
55
                'rb_timeout': the timeout before guest reboot when boot failed, unit is ms
56
-m [size=]megs[,slots=n,maxmem=size]
57
                configure guest RAM
58
                size: initial amount of guest memory
59
                slots: number of hotplug slots (default: none)
60
                maxmem: maximum amount of guest memory (default: none)
61
NOTE: Some architectures might enforce a specific granularity
62
-mem-path FILE  provide backing storage for guest RAM
63
-mem-prealloc   preallocate guest memory (use with -mem-path)
64
-k language     use keyboard layout (for example 'fr' for French)
65 2 Sergey Smolov
-audio-help     show -audiodev equivalent of the currently specified audio settings
66
-audiodev [driver=]driver,id=id[,prop[=value][,...]]
67
                specifies the audio backend to use
68
                id= identifier of the backend
69
                timer-period= timer period in microseconds
70
                in|out.fixed-settings= use fixed settings for host audio
71
                in|out.frequency= frequency to use with fixed settings
72
                in|out.channels= number of channels to use with fixed settings
73
                in|out.format= sample format to use with fixed settings
74
                valid values: s8, s16, s32, u8, u16, u32
75
                in|out.voices= number of voices to use
76
                in|out.buffer-len= length of buffer in microseconds
77
-audiodev none,id=id,[,prop[=value][,...]]
78
                dummy driver that discards all output
79
-audiodev oss,id=id[,prop[=value][,...]]
80
                in|out.dev= path of the audio device to use
81
                in|out.buffer-count= number of buffers
82
                in|out.try-poll= attempt to use poll mode
83
                try-mmap= try using memory mapped access
84
                exclusive= open device in exclusive mode
85
                dsp-policy= set timing policy (0..10), -1 to use fragment mode
86
-audiodev wav,id=id[,prop[=value][,...]]
87
                path= path of wav file to record
88 1 Sergey Smolov
-soundhw c1,... enable audio support
89
                and only specified sound cards (comma separated list)
90
                use '-soundhw help' to get the list of supported cards
91
                use '-soundhw all' to enable all of them
92
-device driver[,prop[=value][,...]]
93
                add device (based on driver)
94
                prop=value,... sets driver properties
95
                use '-device help' to print all possible drivers
96
                use '-device driver,help' to print all possible properties
97
-name string1[,process=string2][,debug-threads=on|off]
98
                set the name of the guest
99 2 Sergey Smolov
                string1 sets the window title and string2 the process name
100
                When debug-threads is enabled, individual threads are given a separate name
101 1 Sergey Smolov
                NOTE: The thread names are for debugging and not a stable API.
102
-uuid %08x-%04x-%04x-%04x-%012x
103
                specify machine UUID
104 2 Sergey Smolov
105 1 Sergey Smolov
Block device options:
106
-fda/-fdb file  use 'file' as floppy disk 0/1 image
107
-hda/-hdb file  use 'file' as IDE hard disk 0/1 image
108
-hdc/-hdd file  use 'file' as IDE hard disk 2/3 image
109
-cdrom file     use 'file' as IDE cdrom image (cdrom is ide1 master)
110
-blockdev [driver=]driver[,node-name=N][,discard=ignore|unmap]
111
          [,cache.direct=on|off][,cache.no-flush=on|off]
112
          [,read-only=on|off][,detect-zeroes=on|off|unmap]
113
          [,driver specific parameters...]
114
                configure a block backend
115
-drive [file=file][,if=type][,bus=n][,unit=m][,media=d][,index=i]
116
       [,cache=writethrough|writeback|none|directsync|unsafe][,format=f]
117 2 Sergey Smolov
       [,snapshot=on|off][,rerror=ignore|stop|report]
118 1 Sergey Smolov
       [,werror=ignore|stop|report|enospc][,id=name][,aio=threads|native]
119
       [,readonly=on|off][,copy-on-read=on|off]
120
       [,discard=ignore|unmap][,detect-zeroes=on|off|unmap]
121
       [[,bps=b]|[[,bps_rd=r][,bps_wr=w]]]
122
       [[,iops=i]|[[,iops_rd=r][,iops_wr=w]]]
123
       [[,bps_max=bm]|[[,bps_rd_max=rm][,bps_wr_max=wm]]]
124
       [[,iops_max=im]|[[,iops_rd_max=irm][,iops_wr_max=iwm]]]
125
       [[,iops_size=is]]
126
       [[,group=g]]
127
                use 'file' as a drive image
128
-mtdblock file  use 'file' as on-board Flash memory image
129
-sd file        use 'file' as SecureDigital card image
130
-pflash file    use 'file' as a parallel flash image
131
-snapshot       write to temporary files instead of disk image files
132 2 Sergey Smolov
-fsdev local,id=id,path=path,security_model=mapped-xattr|mapped-file|passthrough|none
133
 [,writeout=immediate][,readonly][,fmode=fmode][,dmode=dmode]
134 1 Sergey Smolov
 [[,throttling.bps-total=b]|[[,throttling.bps-read=r][,throttling.bps-write=w]]]
135
 [[,throttling.iops-total=i]|[[,throttling.iops-read=r][,throttling.iops-write=w]]]
136
 [[,throttling.bps-total-max=bm]|[[,throttling.bps-read-max=rm][,throttling.bps-write-max=wm]]]
137
 [[,throttling.iops-total-max=im]|[[,throttling.iops-read-max=irm][,throttling.iops-write-max=iwm]]]
138
 [[,throttling.iops-size=is]]
139 2 Sergey Smolov
-fsdev proxy,id=id,socket=socket[,writeout=immediate][,readonly]
140
-fsdev proxy,id=id,sock_fd=sock_fd[,writeout=immediate][,readonly]
141
-fsdev synth,id=id
142
-virtfs local,path=path,mount_tag=tag,security_model=mapped-xattr|mapped-file|passthrough|none
143
        [,id=id][,writeout=immediate][,readonly][,fmode=fmode][,dmode=dmode]
144
-virtfs proxy,mount_tag=tag,socket=socket[,id=id][,writeout=immediate][,readonly]
145
-virtfs proxy,mount_tag=tag,sock_fd=sock_fd[,id=id][,writeout=immediate][,readonly]
146
-virtfs synth,mount_tag=tag[,id=id][,readonly]
147 1 Sergey Smolov
-virtfs_synth Create synthetic file system image
148 2 Sergey Smolov
-iscsi [user=user][,password=password]
149
       [,header-digest=CRC32C|CR32C-NONE|NONE-CRC32C|NONE
150
       [,initiator-name=initiator-iqn][,id=target-iqn]
151
       [,timeout=timeout]
152
                iSCSI session parameters
153
154 1 Sergey Smolov
USB options:
155 2 Sergey Smolov
-usb            enable the USB driver (if it is not used by default yet)
156 1 Sergey Smolov
-usbdevice name add the host or guest USB device 'name'
157 2 Sergey Smolov
158 1 Sergey Smolov
Display options:
159 2 Sergey Smolov
-display spice-app[,gl=on|off]
160 1 Sergey Smolov
-display sdl[,frame=on|off][,alt_grab=on|off][,ctrl_grab=on|off]
161 2 Sergey Smolov
            [,window_close=on|off][,gl=on|core|es|off]
162 1 Sergey Smolov
-display gtk[,grab_on_hover=on|off][,gl=on|off]|
163
-display vnc=<display>[,<optargs>]
164 2 Sergey Smolov
-display curses[,charset=<encoding>]
165
-display none
166
-display egl-headless[,rendernode=<file>]                select display type
167 1 Sergey Smolov
The default display is equivalent to
168 2 Sergey Smolov
	"-vnc localhost:0,to=99,id=default"
169 1 Sergey Smolov
-nographic      disable graphical output and redirect serial I/Os to console
170 2 Sergey Smolov
-trace-log      enables emulator logging in an execution format
171 1 Sergey Smolov
-print-pte-addr prints PTE address value to stdout every time it is calculated
172
-curses         shorthand for -display curses
173
-alt-grab       use Ctrl-Alt-Shift to grab mouse (instead of Ctrl-Alt)
174
-ctrl-grab      use Right-Ctrl to grab mouse (instead of Ctrl-Alt)
175
-no-quit        disable SDL window close capability
176
-sdl            shorthand for -display sdl
177
-spice [port=port][,tls-port=secured-port][,x509-dir=<dir>]
178
       [,x509-key-file=<file>][,x509-key-password=<file>]
179
       [,x509-cert-file=<file>][,x509-cacert-file=<file>]
180
       [,x509-dh-key-file=<file>][,addr=addr][,ipv4|ipv6|unix]
181
       [,tls-ciphers=<list>]
182
       [,tls-channel=[main|display|cursor|inputs|record|playback]]
183
       [,plaintext-channel=[main|display|cursor|inputs|record|playback]]
184
       [,sasl][,password=<secret>][,disable-ticketing]
185
       [,image-compression=[auto_glz|auto_lz|quic|glz|lz|off]]
186
       [,jpeg-wan-compression=[auto|never|always]]
187
       [,zlib-glz-wan-compression=[auto|never|always]]
188
       [,streaming-video=[off|all|filter]][,disable-copy-paste]
189
       [,disable-agent-file-xfer][,agent-mouse=[on|off]]
190
       [,playback-compression=[on|off]][,seamless-migration=[on|off]]
191
       [,gl=[on|off]][,rendernode=<file>]
192
   enable spice
193
   at least one of {port, tls-port} is mandatory
194
-portrait       rotate graphical output 90 deg left (only PXA LCD)
195
-rotate <deg>   rotate graphical output some deg left (only PXA LCD)
196
-vga [std|cirrus|vmware|qxl|xenfb|tcx|cg3|virtio|none]
197
                select video card type
198
-full-screen    start in full screen
199
-vnc <display>  shorthand for -display vnc=<display>
200
-no-acpi        disable ACPI
201
-smbios file=binary
202
                load SMBIOS entry from binary file
203
-smbios type=0[,vendor=str][,version=str][,date=str][,release=%d.%d]
204
              [,uefi=on|off]
205
                specify SMBIOS type 0 fields
206
-smbios type=1[,manufacturer=str][,product=str][,version=str][,serial=str]
207
              [,uuid=uuid][,sku=str][,family=str]
208
                specify SMBIOS type 1 fields
209
-smbios type=2[,manufacturer=str][,product=str][,version=str][,serial=str]
210
              [,asset=str][,location=str]
211
                specify SMBIOS type 2 fields
212
-smbios type=3[,manufacturer=str][,version=str][,serial=str][,asset=str]
213
              [,sku=str]
214
                specify SMBIOS type 3 fields
215
-smbios type=4[,sock_pfx=str][,manufacturer=str][,version=str][,serial=str]
216
              [,asset=str][,part=str]
217
                specify SMBIOS type 4 fields
218
-smbios type=17[,loc_pfx=str][,bank=str][,manufacturer=str][,serial=str]
219
               [,asset=str][,part=str][,speed=%d]
220
                specify SMBIOS type 17 fields
221 2 Sergey Smolov
222 1 Sergey Smolov
Network options:
223
-netdev user,id=str[,ipv4[=on|off]][,net=addr[/mask]][,host=addr]
224
         [,ipv6[=on|off]][,ipv6-net=addr[/int]][,ipv6-host=addr]
225
         [,restrict=on|off][,hostname=host][,dhcpstart=addr]
226 2 Sergey Smolov
         [,dns=addr][,ipv6-dns=addr][,dnssearch=domain][,domainname=domain]
227
         [,tftp=dir][,tftp-server-name=name][,bootfile=f][,hostfwd=rule][,guestfwd=rule][,smb=dir[,smbserver=addr]]
228 1 Sergey Smolov
                configure a user mode network backend with ID 'str',
229
                its DHCP server and optional services
230
-netdev tap,id=str[,fd=h][,fds=x:y:...:z][,ifname=name][,script=file][,downscript=dfile]
231
         [,br=bridge][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off]
232
         [,vhostfd=h][,vhostfds=x:y:...:z][,vhostforce=on|off][,queues=n]
233
         [,poll-us=n]
234
                configure a host TAP network backend with ID 'str'
235
                connected to a bridge (default=br0)
236
                use network scripts 'file' (default=/etc/qemu-ifup)
237
                to configure it and 'dfile' (default=/etc/qemu-ifdown)
238
                to deconfigure it
239
                use '[down]script=no' to disable script execution
240 2 Sergey Smolov
                use network helper 'helper' (default=/home/ssedai/projects/qemu4v/build/target/libexec/qemu-bridge-helper) to
241 1 Sergey Smolov
                configure it
242
                use 'fd=h' to connect to an already opened TAP interface
243
                use 'fds=x:y:...:z' to connect to already opened multiqueue capable TAP interfaces
244
                use 'sndbuf=nbytes' to limit the size of the send buffer (the
245
                default is disabled 'sndbuf=0' to enable flow control set 'sndbuf=1048576')
246
                use vnet_hdr=off to avoid enabling the IFF_VNET_HDR tap flag
247
                use vnet_hdr=on to make the lack of IFF_VNET_HDR support an error condition
248
                use vhost=on to enable experimental in kernel accelerator
249
                    (only has effect for virtio guests which use MSIX)
250
                use vhostforce=on to force vhost on for non-MSIX virtio guests
251
                use 'vhostfd=h' to connect to an already opened vhost net device
252
                use 'vhostfds=x:y:...:z to connect to multiple already opened vhost net devices
253
                use 'queues=n' to specify the number of queues to be created for multiqueue TAP
254
                use 'poll-us=n' to speciy the maximum number of microseconds that could be
255
                spent on busy polling for vhost net
256
-netdev bridge,id=str[,br=bridge][,helper=helper]
257
                configure a host TAP network backend with ID 'str' that is
258
                connected to a bridge (default=br0)
259 2 Sergey Smolov
                using the program 'helper (default=/home/ssedai/projects/qemu4v/build/target/libexec/qemu-bridge-helper)
260 1 Sergey Smolov
-netdev l2tpv3,id=str,src=srcaddr,dst=dstaddr[,srcport=srcport][,dstport=dstport]
261
         [,rxsession=rxsession],txsession=txsession[,ipv6=on/off][,udp=on/off]
262
         [,cookie64=on/off][,counter][,pincounter][,txcookie=txcookie]
263
         [,rxcookie=rxcookie][,offset=offset]
264
                configure a network backend with ID 'str' connected to
265
                an Ethernet over L2TPv3 pseudowire.
266
                Linux kernel 3.3+ as well as most routers can talk
267
                L2TPv3. This transport allows connecting a VM to a VM,
268
                VM to a router and even VM to Host. It is a nearly-universal
269
                standard (RFC3391). Note - this implementation uses static
270
                pre-configured tunnels (same as the Linux kernel).
271
                use 'src=' to specify source address
272
                use 'dst=' to specify destination address
273
                use 'udp=on' to specify udp encapsulation
274
                use 'srcport=' to specify source udp port
275
                use 'dstport=' to specify destination udp port
276
                use 'ipv6=on' to force v6
277
                L2TPv3 uses cookies to prevent misconfiguration as
278
                well as a weak security measure
279
                use 'rxcookie=0x012345678' to specify a rxcookie
280
                use 'txcookie=0x012345678' to specify a txcookie
281
                use 'cookie64=on' to set cookie size to 64 bit, otherwise 32
282
                use 'counter=off' to force a 'cut-down' L2TPv3 with no counter
283
                use 'pincounter=on' to work around broken counter handling in peer
284
                use 'offset=X' to add an extra offset between header and data
285
-netdev socket,id=str[,fd=h][,listen=[host]:port][,connect=host:port]
286
                configure a network backend to connect to another network
287
                using a socket connection
288
-netdev socket,id=str[,fd=h][,mcast=maddr:port[,localaddr=addr]]
289
                configure a network backend to connect to a multicast maddr and port
290
                use 'localaddr=addr' to specify the host address to send packets from
291
-netdev socket,id=str[,fd=h][,udp=host:port][,localaddr=host:port]
292
                configure a network backend to connect to another network
293
                using an UDP tunnel
294
-netdev vhost-user,id=str,chardev=dev[,vhostforce=on|off]
295
                configure a vhost-user network, backed by a chardev 'dev'
296 2 Sergey Smolov
-netdev hubport,id=str,hubid=n[,netdev=nd]
297
                configure a hub port on the hub with ID 'n'
298
-nic [tap|bridge|user|l2tpv3|vhost-user|socket][,option][,...][mac=macaddr]
299
                initialize an on-board / default host NIC (using MAC address
300
                macaddr) and connect it to the given host network backend
301
-nic none       use it alone to have zero network devices (the default is to
302
                provided a 'user' network connection)
303
-net nic[,macaddr=mac][,model=type][,name=str][,addr=str][,vectors=v]
304
                configure or create an on-board (or machine default) NIC and
305
                connect it to hub 0 (please use -nic unless you need a hub)
306
-net [user|tap|bridge|socket][,option][,option][,...]
307 1 Sergey Smolov
                old way to initialize a host network interface
308
                (use the -netdev option if possible instead)
309 2 Sergey Smolov
310 1 Sergey Smolov
Character device options:
311
-chardev help
312
-chardev null,id=id[,mux=on|off][,logfile=PATH][,logappend=on|off]
313
-chardev socket,id=id[,host=host],port=port[,to=to][,ipv4][,ipv6][,nodelay][,reconnect=seconds]
314 2 Sergey Smolov
         [,server][,nowait][,telnet][,websocket][,reconnect=seconds][,mux=on|off]
315
         [,logfile=PATH][,logappend=on|off][,tls-creds=ID][,tls-authz=ID] (tcp)
316
-chardev socket,id=id,path=path[,server][,nowait][,telnet][,websocket][,reconnect=seconds]
317 1 Sergey Smolov
         [,mux=on|off][,logfile=PATH][,logappend=on|off] (unix)
318
-chardev udp,id=id[,host=host],port=port[,localaddr=localaddr]
319
         [,localport=localport][,ipv4][,ipv6][,mux=on|off]
320
         [,logfile=PATH][,logappend=on|off]
321
-chardev msmouse,id=id[,mux=on|off][,logfile=PATH][,logappend=on|off]
322
-chardev vc,id=id[[,width=width][,height=height]][[,cols=cols][,rows=rows]]
323
         [,mux=on|off][,logfile=PATH][,logappend=on|off]
324
-chardev ringbuf,id=id[,size=size][,logfile=PATH][,logappend=on|off]
325
-chardev file,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
326
-chardev pipe,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
327
-chardev pty,id=id[,mux=on|off][,logfile=PATH][,logappend=on|off]
328
-chardev stdio,id=id[,mux=on|off][,signal=on|off][,logfile=PATH][,logappend=on|off]
329
-chardev serial,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
330
-chardev tty,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
331
-chardev parallel,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
332
-chardev parport,id=id,path=path[,mux=on|off][,logfile=PATH][,logappend=on|off]
333 2 Sergey Smolov
334 1 Sergey Smolov
Bluetooth(R) options:
335
-bt hci,null    dumb bluetooth HCI - doesn't respond to commands
336
-bt hci,host[:id]
337
                use host's HCI with the given name
338
-bt hci[,vlan=n]
339
                emulate a standard HCI in virtual scatternet 'n'
340
-bt vhci[,vlan=n]
341
                add host computer to virtual scatternet 'n' using VHCI
342
-bt device:dev[,vlan=n]
343
                emulate a bluetooth device 'dev' in scatternet 'n'
344 2 Sergey Smolov
345 1 Sergey Smolov
TPM device options:
346
-tpmdev passthrough,id=id[,path=path][,cancel-path=path]
347
                use path to provide path to a character device; default is /dev/tpm0
348
                use cancel-path to provide path to TPM's cancel sysfs entry; if
349
                not provided it will be searched for in /sys/class/misc/tpm?/device
350 2 Sergey Smolov
-tpmdev emulator,id=id,chardev=dev
351
                configure the TPM device using chardev backend
352
353 1 Sergey Smolov
Linux/Multiboot boot specific:
354
-kernel bzImage use 'bzImage' as kernel image
355
-append cmdline use 'cmdline' as kernel command line
356
-initrd file    use 'file' as initial ram disk
357
-dtb    file    use 'file' as device tree image
358 2 Sergey Smolov
359 1 Sergey Smolov
Debug/Expert options:
360
-fw_cfg [name=]<name>,file=<file>
361
                add named fw_cfg entry with contents from file
362
-fw_cfg [name=]<name>,string=<str>
363
                add named fw_cfg entry with contents from string
364
-serial dev     redirect the serial port to char device 'dev'
365
-parallel dev   redirect the parallel port to char device 'dev'
366
-monitor dev    redirect the monitor to char device 'dev'
367
-qmp dev        like -monitor but opens in 'control' mode
368
-qmp-pretty dev like -qmp but uses pretty JSON formatting
369 2 Sergey Smolov
-mon [chardev=]name[,mode=readline|control][,pretty[=on|off]]
370 1 Sergey Smolov
-debugcon dev   redirect the debug console to char device 'dev'
371
-pidfile file   write PID to 'file'
372
-singlestep     always run in singlestep mode
373 2 Sergey Smolov
--preconfig     pause QEMU before machine is initialized (experimental)
374 1 Sergey Smolov
-S              freeze CPU at startup (use 'c' to start execution)
375
-realtime [mlock=on|off]
376
                run qemu with realtime features
377
                mlock=on|off controls mlock support (default: on)
378 2 Sergey Smolov
-overcommit [mem-lock=on|off][cpu-pm=on|off]
379
                run qemu with overcommit hints
380
                mem-lock=on|off controls memory lock support (default: off)
381
                cpu-pm=on|off controls cpu power management (default: off)
382 1 Sergey Smolov
-gdb dev        wait for gdb connection on 'dev'
383
-s              shorthand for -gdb tcp::1234
384
-d item1,...    enable logging of specified items (use '-d help' for a list of log items)
385
-D logfile      output log to logfile (default stderr)
386
-dfilter range,..  filter debug output to range of addresses (useful for -d cpu,exec,etc..)
387 2 Sergey Smolov
-seed number       seed the pseudo-random number generator
388 1 Sergey Smolov
-L path         set the directory for the BIOS, VGA BIOS and keymaps
389
-bios file      set the filename for the BIOS
390
-enable-kvm     enable KVM full virtualization support
391
-xen-domid id   specify xen guest domain id
392
-xen-attach     attach to existing xen domain
393 2 Sergey Smolov
                libxl will use this when starting QEMU
394
-xen-domid-restrict     restrict set of available xen operations
395
                        to specified domain id. (Does not affect
396
                        xenpv machine type).
397 1 Sergey Smolov
-no-reboot      exit instead of rebooting
398
-no-shutdown    stop before shutdown
399
-loadvm [tag|id]
400
                start right away with a saved state (loadvm in monitor)
401
-daemonize      daemonize QEMU after initializing
402
-option-rom rom load a file, rom, into the option ROM space
403 2 Sergey Smolov
-rtc [base=utc|localtime|<datetime>][,clock=host|rt|vm][,driftfix=none|slew]
404 1 Sergey Smolov
                set the RTC base and clock, enable drift fix for clock ticks (x86 only)
405
-icount [shift=N|auto][,align=on|off][,sleep=on|off,rr=record|replay,rrfile=<filename>,rrsnapshot=<snapshot>]
406
                enable virtual instruction counter with 2^N clock ticks per
407
                instruction, enable aligning the host and virtual clocks
408
                or disable real time cpu sleeping
409
-watchdog model
410
                enable virtual hardware watchdog [default=none]
411 2 Sergey Smolov
-watchdog-action reset|shutdown|poweroff|inject-nmi|pause|debug|none
412 1 Sergey Smolov
                action when watchdog fires [default=reset]
413
-echr chr       set terminal escape character instead of ctrl-a
414
-show-cursor    show cursor
415
-tb-size n      set TB size
416
-incoming tcp:[host]:port[,to=maxport][,ipv4][,ipv6]
417
-incoming rdma:host:port[,ipv4][,ipv6]
418
-incoming unix:socketpath
419
                prepare for incoming migration, listen on
420
                specified protocol and socket address
421
-incoming fd:fd
422
-incoming exec:cmdline
423
                accept incoming migration on given file descriptor
424
                or from given external command
425
-incoming defer
426
                wait for the URI to be specified via migrate_incoming
427
-only-migratable     allow only migratable devices
428
-nodefaults     don't create default devices
429
-chroot dir     chroot to dir just before starting the VM
430
-runas user     change to user id user just before starting the VM
431 2 Sergey Smolov
                user can be numeric uid:gid instead
432 1 Sergey Smolov
-semihosting    semihosting mode
433 2 Sergey Smolov
-semihosting-config [enable=on|off][,target=native|gdb|auto][,chardev=id][,arg=str[,...]]
434 1 Sergey Smolov
                semihosting configuration
435
-old-param      old param mode
436 2 Sergey Smolov
-sandbox on[,obsolete=allow|deny][,elevateprivileges=allow|deny|children]
437
          [,spawn=allow|deny][,resourcecontrol=allow|deny]
438
                Enable seccomp mode 2 system call filter (default 'off').
439
                use 'obsolete' to allow obsolete system calls that are provided
440
                    by the kernel, but typically no longer used by modern
441
                    C library implementations.
442
                use 'elevateprivileges' to allow or deny QEMU process to elevate
443
                    its privileges by blacklisting all set*uid|gid system calls.
444
                    The value 'children' will deny set*uid|gid system calls for
445
                    main QEMU process but will allow forks and execves to run unprivileged
446
                use 'spawn' to avoid QEMU to spawn new threads or processes by
447
                     blacklisting *fork and execve
448
                use 'resourcecontrol' to disable process affinity and schedular priority
449 1 Sergey Smolov
-readconfig <file>
450
-writeconfig <file>
451
                read/write config file
452
-no-user-config
453 2 Sergey Smolov
                do not load default user-provided config files at startup
454 1 Sergey Smolov
-trace [[enable=]<pattern>][,events=<file>][,file=<file>]
455
                specify tracing options
456
-enable-fips    enable FIPS 140-2 compliance
457
-msg timestamp[=on|off]
458
                change the format of messages
459
                on|off controls leading timestamps (default:on)
460
-dump-vmstate <file>
461
                Output vmstate information in JSON format to file.
462
                Use the scripts/vmstate-static-checker.py file to
463
                check for possible regressions in migration code
464
                by comparing two such vmstate dumps.
465 2 Sergey Smolov
-enable-sync-profile
466
                enable synchronization profiling
467
468 1 Sergey Smolov
Generic object creation:
469
-object TYPENAME[,PROP1=VALUE1,...]
470
                create a new object of type TYPENAME setting properties
471
                in the order they are specified.  Note that the 'id'
472
                property must be set.  These objects are placed in the
473
                '/objects' path.
474
475
During emulation, the following keys are useful:
476
ctrl-alt-f      toggle full screen
477
ctrl-alt-n      switch to virtual console 'n'
478
ctrl-alt        toggle mouse and keyboard grab
479
480
When using -nographic, press 'ctrl-a h' to get some help.
481
</pre>