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