]> git.proxmox.com Git - pve-docs.git/blame - qm.1-synopsis.adoc
move guest-example-hookscript into new examples directory
[pve-docs.git] / qm.1-synopsis.adoc
CommitLineData
1f554f76
DM
1*qm* `<COMMAND> [ARGS] [OPTIONS]`
2
4d47f125 3*qm agent*
32d876b5 4
4d47f125 5An alias for 'qm guest cmd'.
32d876b5 6
e2d681b3
TL
7*qm cleanup* `<vmid> <clean-shutdown> <guest-requested>`
8
9Cleans up resources like tap devices, vgpus, etc. Called after a vm shuts
10down, crashes, etc.
11
12`<vmid>`: `<integer> (1 - N)` ::
13
14The (unique) ID of the VM.
15
16`<clean-shutdown>`: `<boolean>` ::
17
18Indicates if qemu shutdown cleanly.
19
20`<guest-requested>`: `<boolean>` ::
21
22Indicates if the shutdown was requested by the guest or via qmp.
23
1f554f76
DM
24*qm clone* `<vmid> <newid>` `[OPTIONS]`
25
26Create a copy of virtual machine/template.
27
013dc89f 28`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
29
30The (unique) ID of the VM.
31
013dc89f 32`<newid>`: `<integer> (1 - N)` ::
1f554f76
DM
33
34VMID for the clone.
35
2489d6df 36`--description` `<string>` ::
1f554f76
DM
37
38Description for the new VM.
39
2489d6df 40`--format` `<qcow2 | raw | vmdk>` ::
1f554f76 41
27a7acb2 42Target format for file storage. Only valid for full clone.
1f554f76 43
27a7acb2 44`--full` `<boolean>` ::
1f554f76 45
27a7acb2 46Create a full copy of all disks. This is always done when you clone a normal VM. For VM templates, we try to create a linked clone by default.
1f554f76 47
2489d6df 48`--name` `<string>` ::
1f554f76
DM
49
50Set a name for the new VM.
51
2489d6df 52`--pool` `<string>` ::
1f554f76
DM
53
54Add the new VM to the specified pool.
55
2489d6df 56`--snapname` `<string>` ::
1f554f76
DM
57
58The name of the snapshot.
59
2489d6df 60`--storage` `<string>` ::
1f554f76
DM
61
62Target storage for full clone.
1f554f76 63
2489d6df 64`--target` `<string>` ::
1f554f76
DM
65
66Target node. Only allowed if the original VM is on shared storage.
67
1f554f76
DM
68*qm config* `<vmid>` `[OPTIONS]`
69
70Get current virtual machine configuration. This does not include pending
71configuration changes (see 'pending' API).
72
013dc89f 73`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
74
75The (unique) ID of the VM.
76
2489d6df 77`--current` `<boolean>` ('default =' `0`)::
1f554f76
DM
78
79Get current values (instead of pending values).
80
1f554f76
DM
81*qm create* `<vmid>` `[OPTIONS]`
82
83Create or restore a virtual machine.
84
013dc89f 85`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
86
87The (unique) ID of the VM.
88
2489d6df 89`--acpi` `<boolean>` ('default =' `1`)::
1f554f76
DM
90
91Enable/disable ACPI.
92
4d47f125 93`--agent` `[enabled=]<1|0> [,fstrim_cloned_disks=<1|0>]` ::
1f554f76 94
4d47f125 95Enable/disable Qemu GuestAgent and its properties.
1f554f76 96
e2d681b3
TL
97`--arch` `<aarch64 | x86_64>` ::
98
99Virtual processor architecture. Defaults to the host.
100
2489d6df 101`--archive` `<string>` ::
1f554f76
DM
102
103The backup file.
104
2489d6df 105`--args` `<string>` ::
1f554f76 106
c2993fe5 107Arbitrary arguments passed to kvm.
1f554f76 108
2489d6df 109`--autostart` `<boolean>` ('default =' `0`)::
1f554f76
DM
110
111Automatic restart after crash (currently ignored).
112
2489d6df 113`--balloon` `<integer> (0 - N)` ::
1f554f76 114
c2993fe5 115Amount of target RAM for the VM in MB. Using zero disables the ballon driver.
1f554f76 116
2489d6df 117`--bios` `<ovmf | seabios>` ('default =' `seabios`)::
1f554f76
DM
118
119Select BIOS implementation.
120
2489d6df 121`--boot` `[acdn]{1,4}` ('default =' `cdn`)::
1f554f76
DM
122
123Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).
124
2489d6df 125`--bootdisk` `(ide|sata|scsi|virtio)\d+` ::
1f554f76
DM
126
127Enable booting from specified disk.
128
27a7acb2
DM
129`--bwlimit` `<integer> (0 - N)` ::
130
131Override i/o bandwidth limit (in KiB/s).
132
2489d6df 133`--cdrom` `<volume>` ::
1f554f76
DM
134
135This is an alias for option -ide2
136
27a7acb2
DM
137`--cipassword` `<password>` ::
138
139cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords.
140
141`--citype` `<configdrive2 | nocloud>` ::
142
143Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows.
144
145`--ciuser` `<string>` ::
146
147cloud-init: User name to change ssh keys and password for instead of the image's configured default user.
148
2489d6df 149`--cores` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
150
151The number of cores per socket.
152
35a75dd3 153`--cpu` `[cputype=]<enum> [,flags=<+FLAG[;-FLAG...]>] [,hidden=<1|0>]` ::
1f554f76
DM
154
155Emulated CPU type.
156
2489d6df 157`--cpulimit` `<number> (0 - 128)` ('default =' `0`)::
1f554f76 158
9b3e4991 159Limit of CPU usage.
1f554f76 160
2489d6df 161`--cpuunits` `<integer> (2 - 262144)` ('default =' `1024`)::
1f554f76 162
c2993fe5 163CPU weight for a VM.
1f554f76 164
2489d6df 165`--description` `<string>` ::
1f554f76 166
c2993fe5 167Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.
1f554f76 168
2489d6df 169`--efidisk0` `[file=]<volume> [,format=<enum>] [,size=<DiskSize>]` ::
2c0dde61
DM
170
171Configure a Disk for storing EFI vars
172
2489d6df 173`--force` `<boolean>` ::
1f554f76
DM
174
175Allow to overwrite existing VM.
176+
177NOTE: Requires option(s): `archive`
178
2489d6df 179`--freeze` `<boolean>` ::
1f554f76
DM
180
181Freeze CPU at startup (use 'c' monitor command to start execution).
182
e2d681b3 183`--hostpci[n]` `[host=]<HOSTPCIID[;HOSTPCIID2...]> [,mdev=<string>] [,pcie=<1|0>] [,rombar=<1|0>] [,romfile=<string>] [,x-vga=<1|0>]` ::
1f554f76 184
c2993fe5 185Map host PCI devices into guest.
1f554f76 186
2489d6df 187`--hotplug` `<string>` ('default =' `network,disk,usb`)::
1f554f76 188
c2993fe5 189Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.
1f554f76 190
2489d6df 191`--hugepages` `<1024 | 2 | any>` ::
2c0dde61
DM
192
193Enable/disable hugepages memory.
194
25203dc1 195`--ide[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
196
197Use volume as IDE hard disk or CD-ROM (n is 0 to 3).
198
27a7acb2
DM
199`--ipconfig[n]` `[gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>]` ::
200
201cloud-init: Specify IP addresses and gateways for the corresponding interface.
202+
203IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.
204+
205The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided.
206For IPv6 the special string 'auto' can be used to use stateless autoconfiguration.
207+
208If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4.
209
35a75dd3 210`--keyboard` `<da | de | de-ch | en-gb | en-us | es | fi | fr | fr-be | fr-ca | fr-ch | hu | is | it | ja | lt | mk | nl | no | pl | pt | pt-br | sl | sv | tr>` ::
1f554f76 211
5da3d723 212Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.cfg' configuration file.It should not be necessary to set it.
1f554f76 213
2489d6df 214`--kvm` `<boolean>` ('default =' `1`)::
1f554f76
DM
215
216Enable/disable KVM hardware virtualization.
217
2489d6df 218`--localtime` `<boolean>` ::
1f554f76 219
c2993fe5 220Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.
1f554f76 221
2489d6df 222`--lock` `<backup | migrate | rollback | snapshot>` ::
1f554f76
DM
223
224Lock/unlock the VM.
225
e2d681b3 226`--machine` `(pc|pc(-i440fx)?-\d+\.\d+(\.pxe)?|q35|pc-q35-\d+\.\d+(\.pxe)?|virt(?:-\d+\.\d+)?)` ::
1f554f76 227
4d47f125 228Specifies the Qemu machine type.
1f554f76 229
2489d6df 230`--memory` `<integer> (16 - N)` ('default =' `512`)::
1f554f76 231
c2993fe5 232Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.
1f554f76 233
2489d6df 234`--migrate_downtime` `<number> (0 - N)` ('default =' `0.1`)::
1f554f76
DM
235
236Set maximum tolerated downtime (in seconds) for migrations.
237
2489d6df 238`--migrate_speed` `<integer> (0 - N)` ('default =' `0`)::
1f554f76
DM
239
240Set maximum speed (in MB/s) for migrations. Value 0 is no limit.
241
2489d6df 242`--name` `<string>` ::
1f554f76
DM
243
244Set a name for the VM. Only used on the configuration web interface.
245
27a7acb2
DM
246`--nameserver` `<string>` ::
247
248cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set.
249
2489d6df 250`--net[n]` `[model=]<enum> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]` ::
1f554f76
DM
251
252Specify network devices.
1f554f76 253
2489d6df 254`--numa` `<boolean>` ('default =' `0`)::
1f554f76 255
9b3e4991 256Enable/disable NUMA.
1f554f76 257
2489d6df 258`--numa[n]` `cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]` ::
1f554f76 259
c2993fe5 260NUMA topology.
1f554f76 261
2489d6df 262`--onboot` `<boolean>` ('default =' `0`)::
1f554f76
DM
263
264Specifies whether a VM will be started during system bootup.
265
2489d6df 266`--ostype` `<l24 | l26 | other | solaris | w2k | w2k3 | w2k8 | win10 | win7 | win8 | wvista | wxp>` ::
1f554f76 267
c2993fe5 268Specify guest operating system.
1f554f76 269
2489d6df 270`--parallel[n]` `/dev/parport\d+|/dev/usb/lp\d+` ::
1f554f76
DM
271
272Map host parallel devices (n is 0 to 2).
1f554f76 273
2489d6df 274`--pool` `<string>` ::
1f554f76
DM
275
276Add the VM to the specified pool.
277
2489d6df 278`--protection` `<boolean>` ('default =' `0`)::
1f554f76 279
c2993fe5 280Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.
1f554f76 281
2489d6df 282`--reboot` `<boolean>` ('default =' `1`)::
1f554f76
DM
283
284Allow reboot. If set to '0' the VM exit on reboot.
285
25203dc1 286`--sata[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
287
288Use volume as SATA hard disk or CD-ROM (n is 0 to 5).
289
25203dc1 290`--scsi[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,scsiblock=<1|0>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
291
292Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).
293
2489d6df 294`--scsihw` `<lsi | lsi53c810 | megasas | pvscsi | virtio-scsi-pci | virtio-scsi-single>` ('default =' `lsi`)::
1f554f76 295
c2993fe5 296SCSI controller model
1f554f76 297
27a7acb2
DM
298`--searchdomain` `<string>` ::
299
300cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set.
301
2489d6df 302`--serial[n]` `(/dev/.+|socket)` ::
1f554f76 303
c2993fe5 304Create a serial device inside the VM (n is 0 to 3)
1f554f76 305
2489d6df 306`--shares` `<integer> (0 - 50000)` ('default =' `1000`)::
1f554f76 307
5da3d723 308Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning. Auto-ballooning is done by pvestatd.
1f554f76 309
2489d6df 310`--smbios1` `[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]` ::
1f554f76
DM
311
312Specify SMBIOS type 1 fields.
313
2489d6df 314`--smp` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
315
316The number of CPUs. Please use option -sockets instead.
317
2489d6df 318`--sockets` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
319
320The number of CPU sockets.
321
27a7acb2
DM
322`--sshkeys` `<filepath>` ::
323
324cloud-init: Setup public SSH keys (one key per line, OpenSSH format).
325
5da3d723
TL
326`--start` `<boolean>` ('default =' `0`)::
327
328Start VM after it was created successfully.
329
2489d6df 330`--startdate` `(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)` ('default =' `now`)::
1f554f76 331
c2993fe5 332Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.
1f554f76 333
2489d6df 334`--startup` `[[order=]\d+] [,up=\d+] [,down=\d+] ` ::
1f554f76 335
c2993fe5 336Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.
1f554f76 337
2489d6df 338`--storage` `<string>` ::
1f554f76
DM
339
340Default storage.
341
2489d6df 342`--tablet` `<boolean>` ('default =' `1`)::
1f554f76 343
c2993fe5 344Enable/disable the USB tablet device.
1f554f76 345
2489d6df 346`--tdf` `<boolean>` ('default =' `0`)::
1f554f76
DM
347
348Enable/disable time drift fix.
349
2489d6df 350`--template` `<boolean>` ('default =' `0`)::
1f554f76
DM
351
352Enable/disable Template.
353
2489d6df 354`--unique` `<boolean>` ::
1f554f76
DM
355
356Assign a unique random ethernet address.
357+
358NOTE: Requires option(s): `archive`
359
2489d6df 360`--unused[n]` `<string>` ::
1f554f76 361
c2993fe5 362Reference to unused volumes. This is used internally, and should not be modified manually.
1f554f76 363
2489d6df 364`--usb[n]` `[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]` ::
1f554f76 365
c2993fe5 366Configure an USB device (n is 0 to 4).
1f554f76 367
2489d6df 368`--vcpus` `<integer> (1 - N)` ('default =' `0`)::
1f554f76
DM
369
370Number of hotplugged vcpus.
371
e2d681b3 372`--vga` `[[type=]<enum>] [,memory=<integer>]` ::
1f554f76 373
e2d681b3 374Configure the VGA hardware.
1f554f76 375
27a7acb2 376`--virtio[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
377
378Use volume as VIRTIO hard disk (n is 0 to 15).
379
4d47f125
TL
380`--vmgenid` `<UUID>` ('default =' `1 (autogenerated)`)::
381
382Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly.
383
2489d6df
WB
384`--vmstatestorage` `<string>` ::
385
386Default storage for VM state volumes/files.
387
388`--watchdog` `[[model=]<i6300esb|ib700>] [,action=<enum>]` ::
1f554f76 389
c2993fe5 390Create a virtual hardware watchdog device.
1f554f76 391
1f554f76
DM
392*qm delsnapshot* `<vmid> <snapname>` `[OPTIONS]`
393
394Delete a VM snapshot.
395
013dc89f 396`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
397
398The (unique) ID of the VM.
399
013dc89f 400`<snapname>`: `<string>` ::
1f554f76
DM
401
402The name of the snapshot.
403
2489d6df 404`--force` `<boolean>` ::
1f554f76
DM
405
406For removal from config file, even if removing disk snapshots fails.
407
1f554f76
DM
408*qm destroy* `<vmid>` `[OPTIONS]`
409
410Destroy the vm (also delete all used/owned volumes).
411
013dc89f 412`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
413
414The (unique) ID of the VM.
415
2489d6df 416`--skiplock` `<boolean>` ::
1f554f76
DM
417
418Ignore locks - only root is allowed to use this option.
419
4d47f125
TL
420*qm guest cmd* `<vmid> <command>`
421
422Execute Qemu Guest Agent commands.
423
424`<vmid>`: `<integer> (1 - N)` ::
425
426The (unique) ID of the VM.
427
428`<command>`: `<fsfreeze-freeze | fsfreeze-status | fsfreeze-thaw | fstrim | get-fsinfo | get-host-name | get-memory-block-info | get-memory-blocks | get-osinfo | get-time | get-timezone | get-users | get-vcpus | info | network-get-interfaces | ping | shutdown | suspend-disk | suspend-hybrid | suspend-ram>` ::
429
430The QGA command.
431
432*qm guest exec* `<vmid> [<extra-args>]` `[OPTIONS]`
433
434Executes the given command via the guest agent
435
436`<vmid>`: `<integer> (1 - N)` ::
437
438The (unique) ID of the VM.
439
440`<extra-args>`: `<array>` ::
441
442Extra arguments as array
443
444`--synchronous` `<boolean>` ('default =' `1`)::
445
446If set to off, returns the pid immediately instead of waiting for the commmand to finish or the timeout.
447
448`--timeout` `<integer> (0 - N)` ('default =' `30`)::
449
450The maximum time to wait synchronously for the command to finish. If reached, the pid gets returned. Set to 0 to deactivate
451
452*qm guest exec-status* `<vmid> <pid>`
453
454Gets the status of the given pid started by the guest-agent
455
456`<vmid>`: `<integer> (1 - N)` ::
457
458The (unique) ID of the VM.
459
460`<pid>`: `<integer>` ::
461
462The PID to query
463
464*qm guest passwd* `<vmid> <username>` `[OPTIONS]`
465
466Sets the password for the given user to the given password
467
468`<vmid>`: `<integer> (1 - N)` ::
469
470The (unique) ID of the VM.
471
472`<username>`: `<string>` ::
473
474The user to set the password for.
475
476`--crypted` `<boolean>` ('default =' `0`)::
477
478set to 1 if the password has already been passed through crypt()
479
35a75dd3 480*qm help* `[OPTIONS]`
1f554f76
DM
481
482Get help about specified command.
483
35a75dd3 484`--extra-args` `<array>` ::
1f554f76 485
35a75dd3 486Shows help for a specific command
1f554f76 487
2489d6df 488`--verbose` `<boolean>` ::
1f554f76
DM
489
490Verbose output format.
491
5d9c884c
DM
492*qm importdisk* `<vmid> <source> <storage>` `[OPTIONS]`
493
494Import an external disk image as an unused disk in a VM. The
495 image format has to be supported by qemu-img(1).
496
497`<vmid>`: `<integer> (1 - N)` ::
498
499The (unique) ID of the VM.
500
501`<source>`: `<string>` ::
502
503Path to the disk image to import
504
505`<storage>`: `<string>` ::
506
507Target storage ID
508
2489d6df
WB
509`--format` `<qcow2 | raw | vmdk>` ::
510
511Target format
512
2489d6df
WB
513*qm importovf* `<vmid> <manifest> <storage>` `[OPTIONS]`
514
515Create a new VM using parameters read from an OVF manifest
516
517`<vmid>`: `<integer> (1 - N)` ::
518
519The (unique) ID of the VM.
520
521`<manifest>`: `<string>` ::
522
523path to the ovf file
524
525`<storage>`: `<string>` ::
526
527Target storage ID
528
529`--dryrun` `<boolean>` ::
530
531Print a parsed representation of the extracted OVF parameters, but do not create a VM
532
533`--format` `<qcow2 | raw | vmdk>` ::
5d9c884c
DM
534
535Target format
536
9b3e4991 537*qm list* `[OPTIONS]`
1f554f76
DM
538
539Virtual machine index (per node).
540
2489d6df 541`--full` `<boolean>` ::
9b3e4991
DM
542
543Determine the full status of active VMs.
544
de0983cb
DM
545*qm listsnapshot* `<vmid>`
546
547List all snapshots.
548
013dc89f 549`<vmid>`: `<integer> (1 - N)` ::
de0983cb
DM
550
551The (unique) ID of the VM.
552
1f554f76
DM
553*qm migrate* `<vmid> <target>` `[OPTIONS]`
554
555Migrate virtual machine. Creates a new migration task.
556
013dc89f 557`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
558
559The (unique) ID of the VM.
560
013dc89f 561`<target>`: `<string>` ::
1f554f76
DM
562
563Target node.
564
2489d6df 565`--force` `<boolean>` ::
1f554f76 566
c2993fe5 567Allow to migrate VMs which use local devices. Only root may use this option.
1f554f76 568
2489d6df 569`--migration_network` `<string>` ::
de0983cb
DM
570
571CIDR of the (sub) network that is used for migration.
572
2489d6df 573`--migration_type` `<insecure | secure>` ::
de0983cb
DM
574
575Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance.
576
2489d6df 577`--online` `<boolean>` ::
1f554f76
DM
578
579Use online/live migration.
580
2489d6df 581`--targetstorage` `<string>` ::
52e44c50
FG
582
583Default target storage.
584
2489d6df 585`--with-local-disks` `<boolean>` ::
52e44c50
FG
586
587Enable live storage migration for local disk
588
1f554f76
DM
589*qm monitor* `<vmid>`
590
591Enter Qemu Monitor interface.
592
013dc89f 593`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
594
595The (unique) ID of the VM.
596
1f554f76
DM
597*qm move_disk* `<vmid> <disk> <storage>` `[OPTIONS]`
598
599Move volume to different storage.
600
013dc89f 601`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
602
603The (unique) ID of the VM.
604
013dc89f 605`<disk>`: `<efidisk0 | ide0 | ide1 | ide2 | ide3 | sata0 | sata1 | sata2 | sata3 | sata4 | sata5 | scsi0 | scsi1 | scsi10 | scsi11 | scsi12 | scsi13 | scsi2 | scsi3 | scsi4 | scsi5 | scsi6 | scsi7 | scsi8 | scsi9 | virtio0 | virtio1 | virtio10 | virtio11 | virtio12 | virtio13 | virtio14 | virtio15 | virtio2 | virtio3 | virtio4 | virtio5 | virtio6 | virtio7 | virtio8 | virtio9>` ::
1f554f76
DM
606
607The disk you want to move.
608
013dc89f 609`<storage>`: `<string>` ::
1f554f76
DM
610
611Target storage.
612
2489d6df 613`--delete` `<boolean>` ('default =' `0`)::
1f554f76 614
c2993fe5 615Delete the original disk after successful copy. By default the original disk is kept as unused disk.
1f554f76 616
2489d6df 617`--digest` `<string>` ::
1f554f76 618
c2993fe5 619Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.
1f554f76 620
2489d6df 621`--format` `<qcow2 | raw | vmdk>` ::
1f554f76
DM
622
623Target Format.
624
1f554f76
DM
625*qm mtunnel*
626
627Used by qmigrate - do not use manually.
628
52e44c50
FG
629*qm nbdstop* `<vmid>`
630
631Stop embedded nbd server.
632
633`<vmid>`: `<integer> (1 - N)` ::
634
635The (unique) ID of the VM.
636
1f554f76
DM
637*qm pending* `<vmid>`
638
639Get virtual machine configuration, including pending changes.
640
013dc89f 641`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
642
643The (unique) ID of the VM.
644
1f554f76
DM
645*qm rescan* `[OPTIONS]`
646
647Rescan all storages and update disk sizes and unused disk images.
648
4d47f125
TL
649`--dryrun` `<boolean>` ('default =' `0`)::
650
651Do not actually write changes out to VM config(s).
652
2489d6df 653`--vmid` `<integer> (1 - N)` ::
1f554f76
DM
654
655The (unique) ID of the VM.
656
1f554f76
DM
657*qm reset* `<vmid>` `[OPTIONS]`
658
659Reset virtual machine.
660
013dc89f 661`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
662
663The (unique) ID of the VM.
664
2489d6df 665`--skiplock` `<boolean>` ::
1f554f76
DM
666
667Ignore locks - only root is allowed to use this option.
668
1f554f76
DM
669*qm resize* `<vmid> <disk> <size>` `[OPTIONS]`
670
671Extend volume size.
672
013dc89f 673`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
674
675The (unique) ID of the VM.
676
013dc89f 677`<disk>`: `<efidisk0 | ide0 | ide1 | ide2 | ide3 | sata0 | sata1 | sata2 | sata3 | sata4 | sata5 | scsi0 | scsi1 | scsi10 | scsi11 | scsi12 | scsi13 | scsi2 | scsi3 | scsi4 | scsi5 | scsi6 | scsi7 | scsi8 | scsi9 | virtio0 | virtio1 | virtio10 | virtio11 | virtio12 | virtio13 | virtio14 | virtio15 | virtio2 | virtio3 | virtio4 | virtio5 | virtio6 | virtio7 | virtio8 | virtio9>` ::
1f554f76
DM
678
679The disk you want to resize.
680
013dc89f 681`<size>`: `\+?\d+(\.\d+)?[KMGT]?` ::
1f554f76 682
5d9c884c 683The new size. With the `+` sign the value is added to the actual size of the volume and without it, the value is taken as an absolute one. Shrinking disk size is not supported.
1f554f76 684
2489d6df 685`--digest` `<string>` ::
1f554f76 686
c2993fe5 687Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.
1f554f76 688
2489d6df 689`--skiplock` `<boolean>` ::
1f554f76
DM
690
691Ignore locks - only root is allowed to use this option.
692
1f554f76
DM
693*qm resume* `<vmid>` `[OPTIONS]`
694
695Resume virtual machine.
696
013dc89f 697`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
698
699The (unique) ID of the VM.
700
2489d6df 701`--nocheck` `<boolean>` ::
1f554f76
DM
702
703no description available
704
2489d6df 705`--skiplock` `<boolean>` ::
1f554f76
DM
706
707Ignore locks - only root is allowed to use this option.
708
1f554f76
DM
709*qm rollback* `<vmid> <snapname>`
710
711Rollback VM state to specified snapshot.
712
013dc89f 713`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
714
715The (unique) ID of the VM.
716
013dc89f 717`<snapname>`: `<string>` ::
1f554f76
DM
718
719The name of the snapshot.
720
1f554f76
DM
721*qm sendkey* `<vmid> <key>` `[OPTIONS]`
722
723Send key event to virtual machine.
724
013dc89f 725`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
726
727The (unique) ID of the VM.
728
013dc89f 729`<key>`: `<string>` ::
1f554f76
DM
730
731The key (qemu monitor encoding).
732
2489d6df 733`--skiplock` `<boolean>` ::
1f554f76
DM
734
735Ignore locks - only root is allowed to use this option.
736
1f554f76
DM
737*qm set* `<vmid>` `[OPTIONS]`
738
739Set virtual machine options (synchrounous API) - You should consider using
740the POST method instead for any actions involving hotplug or storage
741allocation.
742
013dc89f 743`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
744
745The (unique) ID of the VM.
746
2489d6df 747`--acpi` `<boolean>` ('default =' `1`)::
1f554f76
DM
748
749Enable/disable ACPI.
750
4d47f125 751`--agent` `[enabled=]<1|0> [,fstrim_cloned_disks=<1|0>]` ::
1f554f76 752
4d47f125 753Enable/disable Qemu GuestAgent and its properties.
1f554f76 754
e2d681b3
TL
755`--arch` `<aarch64 | x86_64>` ::
756
757Virtual processor architecture. Defaults to the host.
758
2489d6df 759`--args` `<string>` ::
1f554f76 760
c2993fe5 761Arbitrary arguments passed to kvm.
1f554f76 762
2489d6df 763`--autostart` `<boolean>` ('default =' `0`)::
1f554f76
DM
764
765Automatic restart after crash (currently ignored).
766
2489d6df 767`--balloon` `<integer> (0 - N)` ::
1f554f76 768
c2993fe5 769Amount of target RAM for the VM in MB. Using zero disables the ballon driver.
1f554f76 770
2489d6df 771`--bios` `<ovmf | seabios>` ('default =' `seabios`)::
1f554f76
DM
772
773Select BIOS implementation.
774
2489d6df 775`--boot` `[acdn]{1,4}` ('default =' `cdn`)::
1f554f76
DM
776
777Boot on floppy (a), hard disk (c), CD-ROM (d), or network (n).
778
2489d6df 779`--bootdisk` `(ide|sata|scsi|virtio)\d+` ::
1f554f76
DM
780
781Enable booting from specified disk.
782
2489d6df 783`--cdrom` `<volume>` ::
1f554f76
DM
784
785This is an alias for option -ide2
786
27a7acb2
DM
787`--cipassword` `<password>` ::
788
789cloud-init: Password to assign the user. Using this is generally not recommended. Use ssh keys instead. Also note that older cloud-init versions do not support hashed passwords.
790
791`--citype` `<configdrive2 | nocloud>` ::
792
793Specifies the cloud-init configuration format. The default depends on the configured operating system type (`ostype`. We use the `nocloud` format for Linux, and `configdrive2` for windows.
794
795`--ciuser` `<string>` ::
796
797cloud-init: User name to change ssh keys and password for instead of the image's configured default user.
798
2489d6df 799`--cores` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
800
801The number of cores per socket.
802
35a75dd3 803`--cpu` `[cputype=]<enum> [,flags=<+FLAG[;-FLAG...]>] [,hidden=<1|0>]` ::
1f554f76
DM
804
805Emulated CPU type.
806
2489d6df 807`--cpulimit` `<number> (0 - 128)` ('default =' `0`)::
1f554f76 808
9b3e4991 809Limit of CPU usage.
1f554f76 810
2489d6df 811`--cpuunits` `<integer> (2 - 262144)` ('default =' `1024`)::
1f554f76 812
c2993fe5 813CPU weight for a VM.
1f554f76 814
2489d6df 815`--delete` `<string>` ::
1f554f76
DM
816
817A list of settings you want to delete.
818
2489d6df 819`--description` `<string>` ::
1f554f76 820
c2993fe5 821Description for the VM. Only used on the configuration web interface. This is saved as comment inside the configuration file.
1f554f76 822
2489d6df 823`--digest` `<string>` ::
1f554f76 824
c2993fe5 825Prevent changes if current configuration file has different SHA1 digest. This can be used to prevent concurrent modifications.
1f554f76 826
2489d6df 827`--efidisk0` `[file=]<volume> [,format=<enum>] [,size=<DiskSize>]` ::
2c0dde61
DM
828
829Configure a Disk for storing EFI vars
830
2489d6df 831`--force` `<boolean>` ::
1f554f76 832
c2993fe5 833Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.
1f554f76
DM
834+
835NOTE: Requires option(s): `delete`
836
2489d6df 837`--freeze` `<boolean>` ::
1f554f76
DM
838
839Freeze CPU at startup (use 'c' monitor command to start execution).
840
e2d681b3 841`--hostpci[n]` `[host=]<HOSTPCIID[;HOSTPCIID2...]> [,mdev=<string>] [,pcie=<1|0>] [,rombar=<1|0>] [,romfile=<string>] [,x-vga=<1|0>]` ::
1f554f76 842
c2993fe5 843Map host PCI devices into guest.
1f554f76 844
2489d6df 845`--hotplug` `<string>` ('default =' `network,disk,usb`)::
1f554f76 846
c2993fe5 847Selectively enable hotplug features. This is a comma separated list of hotplug features: 'network', 'disk', 'cpu', 'memory' and 'usb'. Use '0' to disable hotplug completely. Value '1' is an alias for the default 'network,disk,usb'.
1f554f76 848
2489d6df 849`--hugepages` `<1024 | 2 | any>` ::
2c0dde61
DM
850
851Enable/disable hugepages memory.
852
25203dc1 853`--ide[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,model=<model>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
854
855Use volume as IDE hard disk or CD-ROM (n is 0 to 3).
856
27a7acb2
DM
857`--ipconfig[n]` `[gw=<GatewayIPv4>] [,gw6=<GatewayIPv6>] [,ip=<IPv4Format/CIDR>] [,ip6=<IPv6Format/CIDR>]` ::
858
859cloud-init: Specify IP addresses and gateways for the corresponding interface.
860+
861IP addresses use CIDR notation, gateways are optional but need an IP of the same type specified.
862+
863The special string 'dhcp' can be used for IP addresses to use DHCP, in which case no explicit gateway should be provided.
864For IPv6 the special string 'auto' can be used to use stateless autoconfiguration.
865+
866If cloud-init is enabled and neither an IPv4 nor an IPv6 address is specified, it defaults to using dhcp on IPv4.
867
35a75dd3 868`--keyboard` `<da | de | de-ch | en-gb | en-us | es | fi | fr | fr-be | fr-ca | fr-ch | hu | is | it | ja | lt | mk | nl | no | pl | pt | pt-br | sl | sv | tr>` ::
1f554f76 869
5da3d723 870Keybord layout for vnc server. Default is read from the '/etc/pve/datacenter.cfg' configuration file.It should not be necessary to set it.
1f554f76 871
2489d6df 872`--kvm` `<boolean>` ('default =' `1`)::
1f554f76
DM
873
874Enable/disable KVM hardware virtualization.
875
2489d6df 876`--localtime` `<boolean>` ::
1f554f76 877
c2993fe5 878Set the real time clock to local time. This is enabled by default if ostype indicates a Microsoft OS.
1f554f76 879
2489d6df 880`--lock` `<backup | migrate | rollback | snapshot>` ::
1f554f76
DM
881
882Lock/unlock the VM.
883
e2d681b3 884`--machine` `(pc|pc(-i440fx)?-\d+\.\d+(\.pxe)?|q35|pc-q35-\d+\.\d+(\.pxe)?|virt(?:-\d+\.\d+)?)` ::
1f554f76 885
4d47f125 886Specifies the Qemu machine type.
1f554f76 887
2489d6df 888`--memory` `<integer> (16 - N)` ('default =' `512`)::
1f554f76 889
c2993fe5 890Amount of RAM for the VM in MB. This is the maximum available memory when you use the balloon device.
1f554f76 891
2489d6df 892`--migrate_downtime` `<number> (0 - N)` ('default =' `0.1`)::
1f554f76
DM
893
894Set maximum tolerated downtime (in seconds) for migrations.
895
2489d6df 896`--migrate_speed` `<integer> (0 - N)` ('default =' `0`)::
1f554f76
DM
897
898Set maximum speed (in MB/s) for migrations. Value 0 is no limit.
899
2489d6df 900`--name` `<string>` ::
1f554f76
DM
901
902Set a name for the VM. Only used on the configuration web interface.
903
27a7acb2
DM
904`--nameserver` `<string>` ::
905
906cloud-init: Sets DNS server IP address for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set.
907
2489d6df 908`--net[n]` `[model=]<enum> [,bridge=<bridge>] [,firewall=<1|0>] [,link_down=<1|0>] [,macaddr=<XX:XX:XX:XX:XX:XX>] [,queues=<integer>] [,rate=<number>] [,tag=<integer>] [,trunks=<vlanid[;vlanid...]>] [,<model>=<macaddr>]` ::
1f554f76
DM
909
910Specify network devices.
1f554f76 911
2489d6df 912`--numa` `<boolean>` ('default =' `0`)::
1f554f76 913
9b3e4991 914Enable/disable NUMA.
1f554f76 915
2489d6df 916`--numa[n]` `cpus=<id[-id];...> [,hostnodes=<id[-id];...>] [,memory=<number>] [,policy=<preferred|bind|interleave>]` ::
1f554f76 917
c2993fe5 918NUMA topology.
1f554f76 919
2489d6df 920`--onboot` `<boolean>` ('default =' `0`)::
1f554f76
DM
921
922Specifies whether a VM will be started during system bootup.
923
2489d6df 924`--ostype` `<l24 | l26 | other | solaris | w2k | w2k3 | w2k8 | win10 | win7 | win8 | wvista | wxp>` ::
1f554f76 925
c2993fe5 926Specify guest operating system.
1f554f76 927
2489d6df 928`--parallel[n]` `/dev/parport\d+|/dev/usb/lp\d+` ::
1f554f76
DM
929
930Map host parallel devices (n is 0 to 2).
1f554f76 931
2489d6df 932`--protection` `<boolean>` ('default =' `0`)::
1f554f76 933
c2993fe5 934Sets the protection flag of the VM. This will disable the remove VM and remove disk operations.
1f554f76 935
2489d6df 936`--reboot` `<boolean>` ('default =' `1`)::
1f554f76
DM
937
938Allow reboot. If set to '0' the VM exit on reboot.
939
2489d6df 940`--revert` `<string>` ::
1f554f76
DM
941
942Revert a pending change.
943
25203dc1 944`--sata[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
945
946Use volume as SATA hard disk or CD-ROM (n is 0 to 5).
947
25203dc1 948`--scsi[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,queues=<integer>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,scsiblock=<1|0>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,ssd=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
949
950Use volume as SCSI hard disk or CD-ROM (n is 0 to 13).
951
2489d6df 952`--scsihw` `<lsi | lsi53c810 | megasas | pvscsi | virtio-scsi-pci | virtio-scsi-single>` ('default =' `lsi`)::
1f554f76 953
c2993fe5 954SCSI controller model
1f554f76 955
27a7acb2
DM
956`--searchdomain` `<string>` ::
957
958cloud-init: Sets DNS search domains for a container. Create will automatically use the setting from the host if neither searchdomain nor nameserver are set.
959
2489d6df 960`--serial[n]` `(/dev/.+|socket)` ::
1f554f76 961
c2993fe5 962Create a serial device inside the VM (n is 0 to 3)
1f554f76 963
2489d6df 964`--shares` `<integer> (0 - 50000)` ('default =' `1000`)::
1f554f76 965
5da3d723 966Amount of memory shares for auto-ballooning. The larger the number is, the more memory this VM gets. Number is relative to weights of all other running VMs. Using zero disables auto-ballooning. Auto-ballooning is done by pvestatd.
1f554f76 967
2489d6df 968`--skiplock` `<boolean>` ::
1f554f76
DM
969
970Ignore locks - only root is allowed to use this option.
971
2489d6df 972`--smbios1` `[family=<string>] [,manufacturer=<string>] [,product=<string>] [,serial=<string>] [,sku=<string>] [,uuid=<UUID>] [,version=<string>]` ::
1f554f76
DM
973
974Specify SMBIOS type 1 fields.
975
2489d6df 976`--smp` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
977
978The number of CPUs. Please use option -sockets instead.
979
2489d6df 980`--sockets` `<integer> (1 - N)` ('default =' `1`)::
1f554f76
DM
981
982The number of CPU sockets.
983
27a7acb2
DM
984`--sshkeys` `<filepath>` ::
985
986cloud-init: Setup public SSH keys (one key per line, OpenSSH format).
987
2489d6df 988`--startdate` `(now | YYYY-MM-DD | YYYY-MM-DDTHH:MM:SS)` ('default =' `now`)::
1f554f76 989
c2993fe5 990Set the initial date of the real time clock. Valid format for date are: 'now' or '2006-06-17T16:01:21' or '2006-06-17'.
1f554f76 991
2489d6df 992`--startup` `[[order=]\d+] [,up=\d+] [,down=\d+] ` ::
1f554f76 993
c2993fe5 994Startup and shutdown behavior. Order is a non-negative number defining the general startup order. Shutdown in done with reverse ordering. Additionally you can set the 'up' or 'down' delay in seconds, which specifies a delay to wait before the next VM is started or stopped.
1f554f76 995
2489d6df 996`--tablet` `<boolean>` ('default =' `1`)::
1f554f76 997
c2993fe5 998Enable/disable the USB tablet device.
1f554f76 999
2489d6df 1000`--tdf` `<boolean>` ('default =' `0`)::
1f554f76
DM
1001
1002Enable/disable time drift fix.
1003
2489d6df 1004`--template` `<boolean>` ('default =' `0`)::
1f554f76
DM
1005
1006Enable/disable Template.
1007
2489d6df 1008`--unused[n]` `<string>` ::
1f554f76 1009
c2993fe5 1010Reference to unused volumes. This is used internally, and should not be modified manually.
1f554f76 1011
2489d6df 1012`--usb[n]` `[host=]<HOSTUSBDEVICE|spice> [,usb3=<1|0>]` ::
1f554f76 1013
c2993fe5 1014Configure an USB device (n is 0 to 4).
1f554f76 1015
2489d6df 1016`--vcpus` `<integer> (1 - N)` ('default =' `0`)::
1f554f76
DM
1017
1018Number of hotplugged vcpus.
1019
e2d681b3 1020`--vga` `[[type=]<enum>] [,memory=<integer>]` ::
1f554f76 1021
e2d681b3 1022Configure the VGA hardware.
1f554f76 1023
27a7acb2 1024`--virtio[n]` `[file=]<volume> [,aio=<native|threads>] [,backup=<1|0>] [,bps=<bps>] [,bps_max_length=<seconds>] [,bps_rd=<bps>] [,bps_rd_max_length=<seconds>] [,bps_wr=<bps>] [,bps_wr_max_length=<seconds>] [,cache=<enum>] [,cyls=<integer>] [,detect_zeroes=<1|0>] [,discard=<ignore|on>] [,format=<enum>] [,heads=<integer>] [,iops=<iops>] [,iops_max=<iops>] [,iops_max_length=<seconds>] [,iops_rd=<iops>] [,iops_rd_max=<iops>] [,iops_rd_max_length=<seconds>] [,iops_wr=<iops>] [,iops_wr_max=<iops>] [,iops_wr_max_length=<seconds>] [,iothread=<1|0>] [,mbps=<mbps>] [,mbps_max=<mbps>] [,mbps_rd=<mbps>] [,mbps_rd_max=<mbps>] [,mbps_wr=<mbps>] [,mbps_wr_max=<mbps>] [,media=<cdrom|disk>] [,replicate=<1|0>] [,rerror=<ignore|report|stop>] [,secs=<integer>] [,serial=<serial>] [,shared=<1|0>] [,size=<DiskSize>] [,snapshot=<1|0>] [,trans=<none|lba|auto>] [,werror=<enum>]` ::
1f554f76
DM
1025
1026Use volume as VIRTIO hard disk (n is 0 to 15).
1027
4d47f125
TL
1028`--vmgenid` `<UUID>` ('default =' `1 (autogenerated)`)::
1029
1030Set VM Generation ID. Use '1' to autogenerate on create or update, pass '0' to disable explicitly.
1031
2489d6df
WB
1032`--vmstatestorage` `<string>` ::
1033
1034Default storage for VM state volumes/files.
1035
1036`--watchdog` `[[model=]<i6300esb|ib700>] [,action=<enum>]` ::
1f554f76 1037
c2993fe5 1038Create a virtual hardware watchdog device.
1f554f76 1039
35a75dd3 1040*qm showcmd* `<vmid>` `[OPTIONS]`
1f554f76
DM
1041
1042Show command line which is used to start the VM (debug info).
1043
013dc89f 1044`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1045
1046The (unique) ID of the VM.
1047
35a75dd3 1048`--pretty` `<boolean>` ('default =' `0`)::
1f554f76 1049
35a75dd3 1050Puts each option on a new line to enhance human readability
1f554f76
DM
1051
1052*qm shutdown* `<vmid>` `[OPTIONS]`
1053
9b3e4991
DM
1054Shutdown virtual machine. This is similar to pressing the power button on a
1055physical machine.This will send an ACPI event for the guest OS, which
1056should then proceed to a clean shutdown.
1f554f76 1057
013dc89f 1058`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1059
1060The (unique) ID of the VM.
1061
2489d6df 1062`--forceStop` `<boolean>` ('default =' `0`)::
1f554f76
DM
1063
1064Make sure the VM stops.
1065
2489d6df 1066`--keepActive` `<boolean>` ('default =' `0`)::
1f554f76 1067
de0983cb 1068Do not deactivate storage volumes.
1f554f76 1069
2489d6df 1070`--skiplock` `<boolean>` ::
1f554f76
DM
1071
1072Ignore locks - only root is allowed to use this option.
1073
2489d6df 1074`--timeout` `<integer> (0 - N)` ::
1f554f76
DM
1075
1076Wait maximal timeout seconds.
1077
1f554f76
DM
1078*qm snapshot* `<vmid> <snapname>` `[OPTIONS]`
1079
1080Snapshot a VM.
1081
013dc89f 1082`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1083
1084The (unique) ID of the VM.
1085
013dc89f 1086`<snapname>`: `<string>` ::
1f554f76
DM
1087
1088The name of the snapshot.
1089
2489d6df 1090`--description` `<string>` ::
1f554f76
DM
1091
1092A textual description or comment.
1093
2489d6df 1094`--vmstate` `<boolean>` ::
1f554f76
DM
1095
1096Save the vmstate
1097
1f554f76
DM
1098*qm start* `<vmid>` `[OPTIONS]`
1099
1100Start virtual machine.
1101
013dc89f 1102`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1103
1104The (unique) ID of the VM.
1105
e2d681b3 1106`--machine` `(pc|pc(-i440fx)?-\d+\.\d+(\.pxe)?|q35|pc-q35-\d+\.\d+(\.pxe)?|virt(?:-\d+\.\d+)?)` ::
1f554f76 1107
4d47f125 1108Specifies the Qemu machine type.
1f554f76 1109
2489d6df 1110`--migratedfrom` `<string>` ::
1f554f76
DM
1111
1112The cluster node name.
1113
2489d6df 1114`--migration_network` `<string>` ::
de0983cb
DM
1115
1116CIDR of the (sub) network that is used for migration.
1117
2489d6df 1118`--migration_type` `<insecure | secure>` ::
de0983cb
DM
1119
1120Migration traffic is encrypted using an SSH tunnel by default. On secure, completely private networks this can be disabled to increase performance.
1121
2489d6df 1122`--skiplock` `<boolean>` ::
1f554f76
DM
1123
1124Ignore locks - only root is allowed to use this option.
1125
2489d6df 1126`--stateuri` `<string>` ::
1f554f76
DM
1127
1128Some command save/restore state from this location.
1129
2489d6df 1130`--targetstorage` `<string>` ::
52e44c50
FG
1131
1132Target storage for the migration. (Can be '1' to use the same storage id as on the source node.)
1133
1f554f76
DM
1134*qm status* `<vmid>` `[OPTIONS]`
1135
1136Show VM status.
1137
013dc89f 1138`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1139
1140The (unique) ID of the VM.
1141
2489d6df 1142`--verbose` `<boolean>` ::
1f554f76
DM
1143
1144Verbose output format
1145
1f554f76
DM
1146*qm stop* `<vmid>` `[OPTIONS]`
1147
9b3e4991
DM
1148Stop virtual machine. The qemu process will exit immediately. Thisis akin
1149to pulling the power plug of a running computer and may damage the VM data
1f554f76 1150
013dc89f 1151`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1152
1153The (unique) ID of the VM.
1154
2489d6df 1155`--keepActive` `<boolean>` ('default =' `0`)::
1f554f76 1156
de0983cb 1157Do not deactivate storage volumes.
1f554f76 1158
2489d6df 1159`--migratedfrom` `<string>` ::
1f554f76
DM
1160
1161The cluster node name.
1162
2489d6df 1163`--skiplock` `<boolean>` ::
1f554f76
DM
1164
1165Ignore locks - only root is allowed to use this option.
1166
2489d6df 1167`--timeout` `<integer> (0 - N)` ::
1f554f76
DM
1168
1169Wait maximal timeout seconds.
1170
1f554f76
DM
1171*qm suspend* `<vmid>` `[OPTIONS]`
1172
1173Suspend virtual machine.
1174
013dc89f 1175`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1176
1177The (unique) ID of the VM.
1178
2489d6df 1179`--skiplock` `<boolean>` ::
1f554f76
DM
1180
1181Ignore locks - only root is allowed to use this option.
1182
1f554f76
DM
1183*qm template* `<vmid>` `[OPTIONS]`
1184
1185Create a Template.
1186
013dc89f 1187`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1188
1189The (unique) ID of the VM.
1190
2489d6df 1191`--disk` `<efidisk0 | ide0 | ide1 | ide2 | ide3 | sata0 | sata1 | sata2 | sata3 | sata4 | sata5 | scsi0 | scsi1 | scsi10 | scsi11 | scsi12 | scsi13 | scsi2 | scsi3 | scsi4 | scsi5 | scsi6 | scsi7 | scsi8 | scsi9 | virtio0 | virtio1 | virtio10 | virtio11 | virtio12 | virtio13 | virtio14 | virtio15 | virtio2 | virtio3 | virtio4 | virtio5 | virtio6 | virtio7 | virtio8 | virtio9>` ::
1f554f76
DM
1192
1193If you want to convert only 1 disk to base image.
1194
1f554f76
DM
1195*qm terminal* `<vmid>` `[OPTIONS]`
1196
1197Open a terminal using a serial device (The VM need to have a serial device
1198configured, for example 'serial0: socket')
1199
013dc89f 1200`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1201
1202The (unique) ID of the VM.
1203
35a75dd3 1204`--escape` `<string>` ('default =' `^O`)::
1f554f76 1205
35a75dd3 1206Escape character.
1f554f76 1207
35a75dd3 1208`--iface` `<serial0 | serial1 | serial2 | serial3>` ::
1f554f76 1209
35a75dd3 1210Select the serial device. By default we simply use the first suitable device.
1f554f76 1211
2489d6df 1212*qm unlink* `<vmid> --idlist <string>` `[OPTIONS]`
1f554f76
DM
1213
1214Unlink/delete disk images.
1215
013dc89f 1216`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1217
1218The (unique) ID of the VM.
1219
2489d6df 1220`--force` `<boolean>` ::
1f554f76 1221
c2993fe5 1222Force physical removal. Without this, we simple remove the disk from the config file and create an additional configuration entry called 'unused[n]', which contains the volume ID. Unlink of unused[n] always cause physical removal.
1f554f76 1223
2489d6df 1224`--idlist` `<string>` ::
1f554f76
DM
1225
1226A list of disk IDs you want to delete.
1227
1f554f76
DM
1228*qm unlock* `<vmid>`
1229
1230Unlock the VM.
1231
013dc89f 1232`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1233
1234The (unique) ID of the VM.
1235
1f554f76
DM
1236*qm vncproxy* `<vmid>`
1237
1238Proxy VM VNC traffic to stdin/stdout
1239
013dc89f 1240`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1241
1242The (unique) ID of the VM.
1243
1f554f76
DM
1244*qm wait* `<vmid>` `[OPTIONS]`
1245
1246Wait until the VM is stopped.
1247
013dc89f 1248`<vmid>`: `<integer> (1 - N)` ::
1f554f76
DM
1249
1250The (unique) ID of the VM.
1251
2489d6df 1252`--timeout` `<integer> (1 - N)` ::
1f554f76
DM
1253
1254Timeout in seconds. Default is to wait forever.
1255
1256