]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - usr.sbin/bhyve/bhyve_config.5
sqlite3: Vendor import of sqlite3 3.42.0
[FreeBSD/FreeBSD.git] / usr.sbin / bhyve / bhyve_config.5
1 .\" SPDX-License-Identifier: BSD-2-Clause
2 .\"
3 .\" Copyright (c) 2021 John H. Baldwin <jhb@FreeBSD.org>
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\" 1. Redistributions of source code must retain the above copyright
9 .\"    notice, this list of conditions and the following disclaimer.
10 .\" 2. Redistributions in binary form must reproduce the above copyright
11 .\"    notice, this list of conditions and the following disclaimer in the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\"
14 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 .\" SUCH DAMAGE.
25 .\"
26 .Dd August 19, 2022
27 .Dt BHYVE_CONFIG 5
28 .Os
29 .Sh NAME
30 .Nm bhyve_config
31 .Nd "bhyve configuration variables"
32 .Sh DESCRIPTION
33 .Xr bhyve 8
34 uses a hierarchical tree of configuration variables to describe global and
35 per-device settings.
36 Internal nodes in this tree do not have a value,
37 only leaf nodes have values.
38 This manual describes the configuration variables understood by
39 .Xr bhyve 8 .
40 If additional variables are defined,
41 .Xr bhyve 8
42 will ignore them and will not emit errors for unknown variables.
43 However, these additional variables can be referenced by other
44 variables as described below.
45 .Sh VARIABLE VALUES
46 Configuration variable values are stored as strings.
47 A configuration variable value may refer to one or more other
48 configuration values by name.
49 Instances of the pattern
50 .Sq % Ns Pq Ar var
51 are replaced by the value of the configuration variable
52 .Va var .
53 To avoid unwanted expansion,
54 .Sq %
55 characters can be escaped by a leading
56 .Sq % .
57 For example,
58 if a configuration variable
59 .Va disk
60 uses the value
61 .Pa /dev/zvol/bhyve/%(name) ,
62 then the final value of the
63 .Va disk
64 variable will be set to the path of a ZFS volume whose name matches
65 the name of the virtual machine on the pool
66 .Pa bhyve .
67 .Pp
68 Some configuration variables may be interpreted as a boolean value.
69 For those variables the following case-insensitive values may be used to
70 indicate true:
71 .Pp
72 .Bl -bullet -offset indent -compact
73 .It
74 true
75 .It
76 on
77 .It
78 yes
79 .It
80 1
81 .El
82 .Pp
83 The following values may be used to indicate false:
84 .Pp
85 .Bl -bullet -offset indent -compact
86 .It
87 false
88 .It
89 off
90 .It
91 no
92 .It
93 0
94 .El
95 .Pp
96 Some configuration variables may be interperted as an integer.
97 For those variables,
98 any syntax supported by
99 .Xr strtol 3
100 may be used.
101 .Sh GLOBAL SETTINGS
102 .Ss Architecture Neutral Settings
103 .Bl -column "memory.guest_in_core" "integer" "Default"
104 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
105 .It Va name Ta string Ta Ta
106 The name of the VM.
107 .It Va cpus Ta integer Ta 1 Ta
108 The total number of virtual CPUs.
109 .It Va cores Ta integer Ta 1 Ta
110 The number of virtual cores in each virtual socket.
111 .It Va threads Ta integer Ta 1 Ta
112 The number of virtual CPUs in each virtual core.
113 .It Va sockets Ta integer Ta 1 Ta
114 The number of virtual sockets.
115 .It Va memory.guest_in_core Ta bool Ta false Ta
116 Include guest memory in core file.
117 .It Va memory.size Ta string Ta 256M Ta
118 Guest physical memory size in bytes.
119 The value must be formatted as described in
120 .Xr expand_number 3 .
121 .It Va memory.wired Ta bool Ta false Ta
122 Wire guest memory.
123 .It Va acpi_tables Ta bool Ta false Ta
124 Generate ACPI tables.
125 .It Va destroy_on_poweroff Ta bool Ta false Ta
126 Destroy the VM on guest-initiated power-off.
127 .It Va gdb.address Ta string Ta localhost Ta
128 Hostname, IP address, or IPv6 address for the debug server.
129 .It Va gdb.port Ta integer Ta 0 Ta
130 TCP port number for the debug server.
131 If this is set to a non-zero value, a debug server
132 will listen for connections on this port.
133 .It Va gdb.wait Ta bool Ta false Ta
134 If the debug server is enabled, wait for a debugger to connect
135 before starting the guest.
136 .It Va keyboard.layout Ta string Ta Ta
137 Specify the keyboard layout name with the file name in
138 .Ar /usr/share/bhyve/kbdlayout .
139 This value only works when loaded with UEFI mode for VNC, and
140 used a VNC client that don't support QEMU Extended Key Event
141 Message (e.g. TightVNC).
142 .It Va rtc.use_localtime Ta bool Ta true Ta
143 The real time clock uses the local time of the host.
144 If this is set to false, the real time clock uses UTC.
145 .It Va uuid Ta string Ta Ta
146 The universally unique identifier (UUID) to use in the guest's
147 System Management BIOS System Information structure.
148 If an explicit value is not set, a valid UUID is generated from
149 the host's hostname and the VM name.
150 .It Va virtio_msix Ta bool Ta true Ta
151 Use MSI-X interrupts for PCI VirtIO devices.
152 If set to false, MSI interrupts are used instead.
153 .It Va config.dump Ta bool Ta false Ta
154 If this value is set to true after
155 .Xr bhyve 8
156 has finished parsing command line options,
157 then
158 .Xr bhyve 8
159 will write all of its configuration variables to stdout and exit.
160 No VM will be started.
161 .It Va bios.vendor Ta string Ta BHYVE Ta
162 This value is used for the guest's System Management BIOS System Information structure.
163 .It Va bios.version Ta string Ta 14.0 Ta
164 This value is used for the guest's System Management BIOS System Information structure.
165 .It Va bios.release_date Ta string Ta 10/17/2021 Ta
166 This value is used for the guest's System Management BIOS System Information structure.
167 .It Va system.family_name Ta string Ta Virtual Machine Ta
168 Family the computer belongs to.
169 This value is used for the guest's System Management BIOS System Information structure.
170 .It Va system.manufacturer Ta string Ta FreeBSD Ta
171 This value is used for the guest's System Management BIOS System Information structure.
172 .It Va system.product_name Ta string Ta BHYVE Ta
173 This value is used for the guest's System Management BIOS System Information structure.
174 .It Va system.serial_number Ta string Ta None Ta
175 This value is used for the guest's System Management BIOS System Information structure.
176 .It Va system.sku Ta string Ta None Ta
177 Stock keeping unit of the computer.
178 It's also called product ID or purchase order number.
179 This value is used for the guest's System Management BIOS System Information structure.
180 .It Va system.version Ta string Ta 1.0 Ta
181 This value is used for the guest's System Management BIOS System Information structure.
182 .It Va board.manufacturer Ta string Ta FreeBSD Ta
183 This value is used for the guest's System Management BIOS System Information structure.
184 .It Va board.product_name Ta string Ta BHYVE Ta
185 This value is used for the guest's System Management BIOS System Information structure.
186 .It Va board.version Ta string Ta 1.0 Ta
187 This value is used for the guest's System Management BIOS System Information structure.
188 .It Va board.serial_number Ta string Ta None Ta
189 This value is used for the guest's System Management BIOS System Information structure.
190 .It Va board.asset_tag Ta string Ta None Ta
191 This value is used for the guest's System Management BIOS System Information structure.
192 .It Va board.location Ta string Ta None Ta
193 Describes the board's location within the chassis.
194 This value is used for the guest's System Management BIOS System Information structure.
195 .It Va chassis.manufacturer Ta string Ta FreeBSD Ta
196 This value is used for the guest's System Management BIOS System Information structure.
197 .It Va chassis.version Ta string Ta 1.0 Ta
198 This value is used for the guest's System Management BIOS System Information structure.
199 .It Va chassis.serial_number Ta string Ta None Ta
200 This value is used for the guest's System Management BIOS System Information structure.
201 .It Va chassis.asset_tag Ta string Ta None Ta
202 This value is used for the guest's System Management BIOS System Information structure.
203 .It Va chassis.sku Ta string Ta None Ta
204 Stock keeping unit of the chassis.
205 It's also called product ID or purchase order number.
206 This value is used for the guest's System Management BIOS System Information structure.
207 .El
208 .Ss x86-Specific Settings
209 .Bl -column "x86.vmexit_on_pause" "integer" "Default"
210 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
211 .It Va x86.mptable Ta bool Ta true Ta
212 Generate an MPTable.
213 .It Va x86.x2apic Ta bool Ta false Ta
214 Configure guest's local APICs in x2APIC mode.
215 .It Va x86.strictio Ta bool Ta false Ta
216 Exit if a guest accesses an I/O port that is not emulated.
217 By default, writes are ignored and reads return all bits set.
218 .It Va x86.strictmsr Ta bool Ta true Ta
219 Inject a general protection fault if a guest accesses a Model Specific
220 Register (MSR) that is not emulated.
221 If this is false, writes are ignored and reads return zero.
222 .It Va x86.vmexit_on_hlt Ta bool Ta false Ta
223 Force a VM exit when a guest CPU executes the
224 .Dv HLT
225 instruction.
226 This allows idle guest CPUs to yield the host CPU.
227 .It Va x86.vmexit_on_pause Ta bool Ta false Ta
228 Force a VM exit when a guest CPU executes the
229 .Dv PAUSE
230 instruction.
231 .El
232 .Sh DEVICE SETTINGS
233 Device settings are stored under a device node.
234 The device node's name is set by the parent bus of the device.
235 .Ss PCI Device Settings
236 PCI devices are described by a device node named
237 .Dq pci . Ns Ar bus . Ns Ar slot . Ns Ar function
238 where each of
239 .Ar bus ,
240 .Ar slot ,
241 and
242 .Ar function
243 are formatted as decimal values with no padding.
244 All PCI device nodes must contain a configuration variable named
245 .Dq device
246 which specifies the device model to use.
247 The following PCI device models are supported:
248 .Bl -tag -indent
249 .It Li hostbridge
250 Provide a simple PCI-Host bridge device.
251 This is usually configured at pci0:0:0 and is required by most guest
252 operating systems.
253 .It Li ahci
254 AHCI storage controller.
255 .It Li e1000
256 Intel e82545 network interface.
257 .It Li fbuf
258 VGA framebuffer device attached to VNC server.
259 .It Li lpc
260 LPC PCI-ISA bridge with COM1-COM4 16550 serial ports,
261 a boot ROM,
262 an optional fwcfg type,
263 and an optional debug/test device.
264 This device must be configured on bus 0.
265 .It Li hda
266 High Definition audio controller.
267 .It Li nvme
268 NVM Express (NVMe) controller.
269 .It Li passthru
270 PCI pass-through device.
271 .It Li uart
272 PCI 16550 serial device.
273 .It Li virtio-9p
274 VirtIO 9p (VirtFS) interface.
275 .It Li virtio-blk
276 VirtIO block storage interface.
277 .It Li virtio-console
278 VirtIO console interface.
279 .It Li virtio-input
280 VirtIO input interface.
281 .It Li virtio-net
282 VirtIO network interface.
283 .It Li virtio-rnd
284 VirtIO RNG interface.
285 .It Li virtio-scsi
286 VirtIO SCSI interface.
287 .It Li xhci
288 Extensible Host Controller Interface (XHCI) USB controller.
289 .El
290 .Ss USB Device Settings
291 USB controller devices contain zero or more child USB devices
292 attached to slots.
293 Each USB device stores its settings in a node named
294 .Dq slot. Ns Va N
295 under the controller's device node.
296 .Va N
297 is the number of the slot to which the USB device is attached.
298 Note that USB slot numbers begin at 1.
299 All USB device nodes must contain a configuration variable named
300 .Dq device
301 which specifies the device model to use.
302 The following USB device models are supported:
303 .Bl -tag -indent
304 .It Li tablet
305 A USB tablet device which provides precise cursor synchronization
306 when using VNC.
307 .El
308 .Ss Block Device Settings
309 Block devices use the following settings to configure their backing store.
310 These settings are stored in the configuration node of the respective device.
311 .Bl -column "sectorsize" "logical[/physical]" "Default"
312 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
313 .It path Ta string Ta Ta
314 The path of the file or disk device to use as the backing store.
315 .It nocache Ta bool Ta false Ta
316 Disable caching on the backing file by opening the backing file with
317 .Dv O_DIRECT .
318 .It nodelete Ta bool Ta false Ta
319 Disable emulation of guest trim requests via
320 .Dv DIOCGDELETE
321 requests.
322 .It sync Ta bool Ta false Ta
323 Write changes to the backing file with synchronous writes.
324 .It direct Ta bool Ta false Ta
325 An alias for
326 .Va sync .
327 .It ro Ta bool Ta false Ta
328 Disable writes to the backing file.
329 .It sectorsize Ta Va logical Ns Op / Ns Va physical Ta Ta
330 Specify the logical and physical sector size of the emulated disk.
331 If the physical size is not specified,
332 it is equal to the logical size.
333 .El
334 .Ss Network Backend Settings
335 Network devices use the following settings to configure their backend.
336 The backend is responsible for passing packets between the device model
337 and a desired destination.
338 Configuring a backend requires setting the
339 .Va backend
340 variable.
341 The type of a backend can either be set explicitly via the
342 .Va type
343 variable
344 or it can be inferred from the value of
345 .Va backend .
346 .Pp
347 The following types of backends are supported:
348 .Bl -tag -width "netgraph"
349 .It tap
350 Use the
351 .Xr tap 4
352 interface named in
353 .Va backend
354 as the backend.
355 .It netgraph
356 Use a
357 .Xr netgraph 4
358 socket hook as the backend.
359 This backend uses the following additional variables:
360 .Bl -column "peerhook" "Format" "Default"
361 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
362 .It Va path Ta string Ta Ta
363 The name of the
364 .Xr netgraph 4
365 destination node.
366 .It Va peerhook Ta string Ta Ta
367 The name of the destination hook.
368 .It Va socket Ta string Ta Ta
369 The name of the created
370 .Xr ng_socket 4
371 node.
372 .It Va hook Ta string Ta vmlink Ta
373 The name of the source hook on the created
374 .Xr ng_socket 4
375 node.
376 .El
377 .It netmap
378 Use
379 .Xr netmap 4
380 either on a network interface or a port on a
381 .Xr vale 4
382 bridge as the backend.
383 The value of
384 .Va backend
385 is passed to
386 .Xr nm_open
387 to connect to a netmap port.
388 .El
389 .Pp
390 If
391 .Va type
392 is not specified explicitly, then it is inferred from
393 .Va backend
394 based on the following patterns:
395 .Bl -column -offset indent "valuebridge:port"
396 .It Sy Pattern Ta Sy Type
397 .It tap Ns Va N Ta tap
398 .It vmnet Ns Va N Ta tap
399 .It netgraph Ta netgraph
400 .It netmap: Ns Va interface Ta netmap
401 .It vale Ns Va bridge : Ns Va port Ta netmap
402 .El
403 .Ss UART Device Settings
404 .Bl -column "Name" "Format" "Default"
405 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
406 .It Va path Ta path Ta Ta
407 Backend device for the serial port.
408 Either the pathname of a character device or
409 .Dq stdio
410 to use standard input and output of the
411 .Xr bhyve 8
412 process.
413 .El
414 .Ss Host Bridge Settings
415 .Bl -column "pcireg.*" "integer" "Default"
416 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
417 .It Va pcireg.* Ta integer Ta Ta
418 Values of PCI register.
419 .Bl -column "device" "Default"
420 .It Sy Name Ta Sy Default
421 .It Va vendor Ta integer Ta 0x1275 Ta
422 .It Va device Ta integer Ta 0x1275 Ta
423 .El
424 .El
425 .Ss AHCI Controller Settings
426 AHCI controller devices contain zero or more ports each of which
427 provides a storage device.
428 Each port stores its settings in a node named
429 .Dq port. Ns Va N
430 under the controller's device node.
431 The
432 .Va N
433 values are formatted as successive decimal values starting with 0.
434 In addition to the block device settings described above, each
435 port supports the following settings:
436 .Bl -column "model" "integer" "generated"
437 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
438 .It Va type Ta string Ta Ta
439 The type of storage device to emulate.
440 Must be set to either
441 .Dq cd
442 or
443 .Dq hd .
444 .It Va nmrr Ta integer Ta 0 Ta
445 Nominal Media Rotation Rate, also known as RPM.
446 A value 1 of indicates a device with no rate such as a Solid State Disk.
447 .It Va ser Ta string Ta generated Ta
448 Serial number of up to twenty characters.
449 A default serial number is generated using a hash of the backing
450 store's pathname.
451 .It Va rev Ta string Ta 001 Ta
452 Revision number of up to eight characters.
453 .It Va model Ta string Ta Ta
454 Model number of up to forty characters.
455 Separate default model strings are used for
456 .Dq cd
457 and
458 .Dq hd
459 device types.
460 .El
461 .Ss e1000 Settings
462 In addition to the network backend settings,
463 Intel e82545 network interfaces support the following variables:
464 .Bl -column "Name" "MAC address" "generated"
465 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
466 .It Va mac Ta MAC address Ta generated Ta
467 MAC address.
468 If an explicit address is not provided,
469 a MAC address is generated from a hash of the device's PCI address.
470 .El
471 .Ss Frame Buffer Settings
472 .Bl -column "password" "[IP:]port" "127.0.0.1:5900"
473 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
474 .It Va wait Ta bool Ta false Ta
475 Wait for a remote connection before starting the VM.
476 .It Va rfb Ta Oo Ar IP Ns : Oc Ns Ar port Ta 127.0.0.1:5900 Ta
477 TCP address to listen on for remote connections.
478 The IP address must be given as a numeric address.
479 IPv6 addresses must be enclosed in square brackets and
480 support scoped identifiers as described in
481 .Xr getaddrinfo 3 .
482 A bare port number may be given in which case the IPv4
483 localhost address is used.
484 .It Va vga Ta string Ta io Ta
485 VGA configuration.
486 More details are provided in
487 .Xr bhyve 8 .
488 .It Va w Ta integer Ta 1024 Ta
489 Frame buffer width in pixels.
490 .It Va h Ta integer Ta 768 Ta
491 Frame buffer height in pixels.
492 .It Va password Ta string Ta Ta
493 Password to use for VNC authentication.
494 This type of authentication is known to be cryptographically weak and is not
495 intended for use on untrusted networks.
496 .El
497 .Ss High Definition Audio Settings
498 .Bl -column "Name" "Format" "Default"
499 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
500 .It Va play Ta path Ta Ta
501 Host playback device,
502 typically
503 .Pa /dev/dsp0 .
504 .It Va rec Ta path Ta Ta
505 Host recording device,
506 typically
507 .Pa /dev/dsp0 .
508 .El
509 .Ss LPC Device Settings
510 The LPC bridge stores its configuration under a top-level
511 .Va lpc
512 node rather than under the PCI LPC device's node.
513 The following nodes are available under
514 .Va lpc :
515 .Bl -column "pc-testdev" "Format" "Default"
516 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
517 .It Va bootrom Ta path Ta Ta
518 Path to a boot ROM.
519 The contents of this file are copied into the guest's
520 memory ending just before the 4GB physical address.
521 If a boot ROM is present, a firmware interface device is
522 also enabled for use by the boot ROM.
523 .It Va bootvars Ta path Ta Ta
524 Path to boot VARS.
525 The contents of this file are copied beneath the boot ROM.
526 Firmware can write to it to save variables.
527 All variables will be persistent even on reboots of the guest.
528 .It Va com1 Ta node Ta Ta
529 Settings for the COM1 serial port device.
530 .It Va com2 Ta node Ta Ta
531 Settings for the COM2 serial port device.
532 .It Va com3 Ta node Ta Ta
533 Settings for the COM3 serial port device.
534 .It Va com4 Ta node Ta Ta
535 Settings for the COM4 serial port device.
536 .It Va fwcfg Ta string Ta bhyve Ta
537 The fwcfg type to be used.
538 Supported values are
539 .Dq bhyve
540 for fwctl and
541 .Dq qemu
542 for fwcfg.
543 .It Va pc-testdev Ta bool Ta false Ta
544 Enable the PC debug/test device.
545 .It Va pcireg.* Ta integer Ta Ta
546 Values of PCI register.
547 It also accepts the value
548 .Ar host
549 to use the pci id of the host system.
550 This value is required for the Intel GOP driver to work properly.
551 .Bl -column "subvendor" "Default"
552 .It Sy Name Ta Sy Default
553 .It Va vendor Ta 0x8086
554 .It Va device Ta 0x7000
555 .It Va revid Ta 0
556 .It Va subvendor Ta 0
557 .It Va subdevice Ta 0
558 .El
559 .El
560 .Ss NVMe Controller Settings
561 Each NVMe controller supports a single storage device.
562 The device can be backed either by a memory disk described by the
563 .Va ram
564 variable, or a block device using the block device settings described above.
565 In addition, each controller supports the following settings:
566 .Bl -column "ioslots" "Format" "Default"
567 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
568 .It Va maxq Ta integer Ta 16 Ta
569 Maximum number of I/O submission and completion queue pairs.
570 .It Va qsz Ta integer Ta 2058 Ta
571 Number of elements in each I/O queue.
572 .It Va ioslots Ta integer Ta 8 Ta
573 Maximum number of concurrent I/O requests.
574 .It Va sectsz Ta integer Ta Ta
575 Sector size.
576 Can be one of 512, 4096, or 8192.
577 Devices backed by a memory disk use 4096 as the default.
578 Devices backed by a block device use the block device's sector size
579 as the default.
580 .It Va ser Ta string Ta Ta
581 Serial number of up to twenty characters.
582 A default serial number is generated using a hash of the device's PCI address.
583 .It Va eui64 Ta integer Ta Ta
584 IEEE Extended Unique Identifier.
585 If an EUI is not provided, a default is generated using a checksum of the
586 device's PCI address.
587 .It Va dsm Ta string Ta auto Ta
588 Whether or not to advertise DataSet Management support.
589 One of
590 .Dq auto ,
591 .Dq enable ,
592 or
593 .Dq disable .
594 The
595 .Dq auto
596 setting only advertises support if the backing store supports
597 resource freeing, for example via TRIM.
598 .It Va ram Ta integer Ta Ta
599 If set, allocate a memory disk as the backing store.
600 The value of this variable is the size of the memory disk in megabytes.
601 .El
602 .Ss PCI Passthrough Settings
603 The
604 .Xr ppt 4
605 device driver must be attached to the
606 PCI device being passed through.
607 The device to pass through can be identified either by name or its
608 host PCI bus location.
609 .Bl -column "Name" "integer" "Default"
610 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
611 .It Va bus Ta integer Ta Ta
612 Host PCI bus address of device to pass through.
613 .It Va slot Ta integer Ta Ta
614 Host PCI slot address of device to pass through.
615 .It Va func Ta integer Ta Ta
616 Host PCI function address of device to pass through.
617 .It Va pptdev Ta string Ta Ta
618 Name of a
619 .Xr ppt 4
620 device to pass through.
621 .It Va rom Ta path Ta Ta
622 ROM file of the device which will be executed by OVMF to init the device.
623 .El
624 .Ss VirtIO 9p Settings
625 Each VirtIO 9p device exposes a single filesystem from a host path.
626 .Bl -column "sharename" "Format" "Default"
627 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
628 .It Va sharename Ta string Ta Ta
629 The share name exposed to the guest.
630 .It Va path Ta path Ta Ta
631 The path of a directory on the host to export to the guest.
632 .It Va ro Ta bool Ta false Ta
633 If true, the guest filesystem is read-only.
634 .El
635 .Ss VirtIO Block Device Settings
636 In addition to the block device settings described above, each
637 VirtIO block device supports the following settings:
638 .Bl -column "model" "integer" "generated"
639 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
640 .It Va ser Ta string Ta generated Ta
641 Serial number of up to twenty characters.
642 A default serial number is generated using a hash of the backing
643 store's pathname.
644 .El
645 .Ss VirtIO Console Device Settings
646 Each VirtIO Console device contains one or more console ports.
647 Each port stores its settings in a node named
648 .Dq port. Ns Va N
649 under the controller's device node.
650 The
651 .Va N
652 values are formatted as successive decimal values starting with 0.
653 Each port supports the following settings:
654 .Bl -column "Name" "Format" "Default"
655 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
656 .It Va name Ta string Ta Ta
657 The name of the port exposed to the guest.
658 .It Va path Ta path Ta Ta
659 The path of a UNIX domain socket providing the host connection for the port.
660 .El
661 .Ss VirtIO Input Interface Settings
662 Each VirtIO Input device contains one input event device.
663 All input events of the input event device are send to the guest by VirtIO Input interface.
664 VirtIO Input Interfaces support the following variables:
665 .Bl -column "Name" "Format" "Default"
666 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
667 .It Va path Ta path Ta Ta
668 The path of the input event device exposed to the guest
669 .El
670 .Ss VirtIO Network Interface Settings
671 In addition to the network backend settings,
672 VirtIO network interfaces support the following variables:
673 .Bl -column "Name" "MAC address" "generated"
674 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
675 .It Va mac Ta MAC address Ta generated Ta
676 MAC address.
677 If an explicit address is not provided,
678 a MAC address is generated from a hash of the device's PCI address.
679 .It Va mtu Ta integer Ta 1500 Ta
680 The largest supported MTU advertised to the guest.
681 .El
682 .Ss VirtIO SCSI Settings
683 .Bl -column "Name" "integer" "Default"
684 .It Sy Name Ta Sy Format Ta Sy Default Ta Sy Description
685 .It Va dev Ta path Ta Ta
686 The path of a CAM target layer (CTL) device to export:
687 .Pa /dev/cam/ctl Ns Oo Ar pp . Ns Ar vp Oc .
688 .It Va iid Ta integer Ta 0 Ta
689 Initiator ID to use when sending requests to the CTL port.
690 .El
691 .Sh SEE ALSO
692 .Xr expand_number 3 ,
693 .Xr getaddrinfo 3 ,
694 .Xr strtol 3 ,
695 .Xr netgraph 4 ,
696 .Xr netmap 4 ,
697 .Xr ng_socket 4 ,
698 .Xr tap 4 ,
699 .Xr vale 4 ,
700 .Xr vmnet 4 ,
701 .Xr bhyve 8