pub struct Options {Show 106 fields
pub processors: u32,
pub memory: u64,
pub shared_memory: bool,
pub prefetch: bool,
pub memory_backing_file: Option<PathBuf>,
pub restore_snapshot: Option<PathBuf>,
pub private_memory: bool,
pub thp: bool,
pub paused: bool,
pub kernel: OptionalPathBuf,
pub initrd: OptionalPathBuf,
pub cmdline: Vec<String>,
pub hv: bool,
pub device_tree: bool,
pub vtl2: bool,
pub get: bool,
pub no_get: bool,
pub no_alias_map: bool,
pub isolation: Option<IsolationCli>,
pub vmbus_vsock_path: Option<String>,
pub vmbus_vtl2_vsock_path: Option<String>,
pub late_map_vtl0_policy: Vtl0LateMapPolicyCli,
pub no_enlightenments: bool,
pub user_mode_apic: bool,
pub disk: Vec<DiskCli>,
pub nvme: Vec<DiskCli>,
pub virtio_blk: Vec<DiskCli>,
pub scsi_sub_channels: u16,
pub nic: bool,
pub net: Vec<NicConfigCli>,
pub kernel_vmnic: Vec<String>,
pub gfx: bool,
pub vtl2_gfx: bool,
pub vnc: bool,
pub vnc_port: u16,
pub apic_id_offset: u32,
pub vps_per_socket: Option<u32>,
pub smt: SmtConfigCli,
pub x2apic: X2ApicConfig,
pub com1: Option<SerialConfigCli>,
pub com2: Option<SerialConfigCli>,
pub com3: Option<SerialConfigCli>,
pub com4: Option<SerialConfigCli>,
pub vmbus_com1_serial: Option<SerialConfigCli>,
pub vmbus_com2_serial: Option<SerialConfigCli>,
pub serial_tx_only: bool,
pub debugcon: Option<DebugconSerialConfigCli>,
pub uefi: bool,
pub uefi_firmware: OptionalPathBuf,
pub uefi_debug: bool,
pub uefi_enable_memory_protections: bool,
pub pcat_boot_order: Option<PcatBootOrderCli>,
pub pcat: bool,
pub pcat_firmware: Option<PathBuf>,
pub igvm: Option<PathBuf>,
pub igvm_vtl2_relocation_type: Vtl2BaseAddressType,
pub virtio_9p: Vec<FsArgs>,
pub virtio_9p_debug: bool,
pub virtio_fs: Vec<FsArgsWithOptions>,
pub virtio_fs_shmem: Vec<FsArgs>,
pub virtio_fs_bus: VirtioBusCli,
pub virtio_pmem: Option<VirtioPmemArgs>,
pub virtio_rng: bool,
pub virtio_rng_bus: VirtioBusCli,
pub virtio_rng_pcie_port: Option<String>,
pub virtio_console: Option<SerialConfigCli>,
pub virtio_console_pcie_port: Option<String>,
pub virtio_vsock_path: Option<String>,
pub virtio_net: Vec<NicConfigCli>,
pub log_file: Option<PathBuf>,
pub ttrpc: Option<PathBuf>,
pub grpc: Option<PathBuf>,
pub single_process: bool,
pub disable_frontpage: bool,
pub tpm: bool,
pub internal_worker: Option<Option<String>>,
pub vmbus_redirect: bool,
pub vmbus_max_version: Option<u32>,
pub vmgs: Option<VmgsCli>,
pub test_gsp_by_id: bool,
pub vga_firmware: Option<PathBuf>,
pub secure_boot: bool,
pub secure_boot_template: Option<SecureBootTemplateCli>,
pub custom_uefi_json: Option<PathBuf>,
pub relay_console_path: Option<PathBuf>,
pub relay_console_title: Option<String>,
pub gdb: Option<u16>,
pub mana: Vec<NicConfigCli>,
pub hypervisor: Option<String>,
pub custom_dsdt: Option<PathBuf>,
pub ide: Vec<IdeDiskCli>,
pub floppy: Vec<FloppyDiskCli>,
pub guest_watchdog: bool,
pub openhcl_dump_path: Option<PathBuf>,
pub halt_on_reset: bool,
pub write_saved_state_proto: Option<PathBuf>,
pub imc: Option<PathBuf>,
pub mcr: bool,
pub battery: bool,
pub uefi_console_mode: Option<UefiConsoleModeCli>,
pub efi_diagnostics_log_level: Option<EfiDiagnosticsLogLevelCli>,
pub default_boot_always_attempt: bool,
pub pcie_root_complex: Vec<PcieRootComplexCli>,
pub pcie_root_port: Vec<PcieRootPortCli>,
pub pcie_switch: Vec<GenericPcieSwitchCli>,
pub pcie_remote: Vec<PcieRemoteCli>,
}Expand description
OpenVMM virtual machine monitor.
This is not yet a stable interface and may change radically between versions.
Fields§
§processors: u32processor count
memory: u64guest RAM size
use shared memory segment
prefetch: boolprefetch guest RAM
memory_backing_file: Option<PathBuf>back guest RAM with a file instead of anonymous memory. The file is created/opened and sized to the guest RAM size. Enables snapshot save (fsync) and restore (open + mmap).
restore_snapshot: Option<PathBuf>Restore VM from a snapshot directory (implies file-backed memory from the snapshot’s memory.bin). Cannot be used with –memory-backing-file.
private_memory: booluse private anonymous memory for guest RAM
thp: boolenable transparent huge pages for guest RAM (Linux only, requires –private-memory)
paused: boolstart in paused state
kernel: OptionalPathBufkernel image (when using linux direct boot)
initrd: OptionalPathBufinitrd image (when using linux direct boot)
cmdline: Vec<String>extra kernel command line args
hv: boolenable HV#1 capabilities
device_tree: boolUse a full device tree instead of ACPI tables for ARM64 Linux direct boot. By default, ARM64 uses ACPI mode (stub DT + EFI + ACPI tables). This flag selects the legacy DT-only path. Rejected on x86.
vtl2: boolenable vtl2 - only supported in WHP and simulated without hypervisor support currently
Currently implies –get.
get: boolAdd GET and related devices for using the OpenHCL paravisor to the highest enabled VTL.
no_get: boolDisable GET and related devices for using the OpenHCL paravisor, even when –vtl2 is passed.
no_alias_map: booldisable the VTL0 alias map presented to VTL2 by default
isolation: Option<IsolationCli>enable isolation emulation
vmbus_vsock_path: Option<String>the hybrid vsock listener path
vmbus_vtl2_vsock_path: Option<String>the VTL2 hybrid vsock listener path
late_map_vtl0_policy: Vtl0LateMapPolicyClithe late map vtl0 ram access policy when vtl2 is enabled
no_enlightenments: booldisable in-hypervisor enlightenment implementation (where possible)
user_mode_apic: booldisable the in-hypervisor APIC and use the user-mode one (where possible)
disk: Vec<DiskCli>attach a disk (can be passed multiple times)
nvme: Vec<DiskCli>attach a disk via an NVMe controller
virtio_blk: Vec<DiskCli>attach a disk via a virtio-blk controller
scsi_sub_channels: u16number of sub-channels for the SCSI controller
nic: boolexpose a virtual NIC
net: Vec<NicConfigCli>expose a virtual NIC with the given backend (consomme | dio | tap | none)
Prefix with uh: to add this NIC via Mana emulation through OpenHCL,
vtl2: to assign this NIC to VTL2, or pcie_port=<port_name>: to
expose the NIC over emulated PCIe at the specified port.
kernel_vmnic: Vec<String>expose a virtual NIC using the Windows kernel-mode vmswitch.
Specify the switch ID or “default” for the default switch.
gfx: boolexpose a graphics device
vtl2_gfx: boolsupport a graphics device in vtl2
vnc: boollisten for vnc connections. implied by gfx.
vnc_port: u16VNC port number
apic_id_offset: u32set the APIC ID offset, for testing APIC IDs that don’t match VP index
vps_per_socket: Option<u32>the maximum number of VPs per socket
smt: SmtConfigClienable or disable SMT (hyperthreading) (auto | force | off)
x2apic: X2ApicConfigconfigure x2apic (auto | supported | off | on)
com1: Option<SerialConfigCli>COM1 binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
com2: Option<SerialConfigCli>COM2 binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
com3: Option<SerialConfigCli>COM3 binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
com4: Option<SerialConfigCli>COM4 binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
vmbus_com1_serial: Option<SerialConfigCli>vmbus com1 serial binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
vmbus_com2_serial: Option<SerialConfigCli>vmbus com2 serial binding (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
serial_tx_only: boolOnly allow guest to host serial traffic
debugcon: Option<DebugconSerialConfigCli>debugcon binding (port:serial, where port is a u16, and serial is (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none))
uefi: boolboot UEFI firmware
uefi_firmware: OptionalPathBufUEFI firmware file
uefi_debug: boolenable UEFI debugging on COM1
uefi_enable_memory_protections: boolenable memory protections in UEFI
pcat_boot_order: Option<PcatBootOrderCli>set PCAT boot order as comma-separated string of boot device types (e.g: floppy,hdd,optical,net).
If less than 4 entries are added, entries are added according to their default boot order (optical,hdd,net,floppy)
e.g: passing “floppy,optical” will result in a boot order equivalent to “floppy,optical,hdd,net”.
Passing duplicate types is an error.
pcat: boolBoot with PCAT BIOS firmware and piix4 devices
pcat_firmware: Option<PathBuf>PCAT firmware file
igvm: Option<PathBuf>boot IGVM file
igvm_vtl2_relocation_type: Vtl2BaseAddressTypespecify igvm vtl2 relocation type (absolute=<addr>, disable, auto=<filesize,or memory size>, vtl2=<filesize,or memory size>,)
virtio_9p: Vec<FsArgs>add a virtio_9p device (e.g. myfs,C:)
Prefix with pcie_port=<port_name>: to expose the device over
emulated PCIe at the specified port.
virtio_9p_debug: booloutput debug info from the 9p server
virtio_fs: Vec<FsArgsWithOptions>add a virtio_fs device (e.g. myfs,C:,uid=1000,gid=2000)
Prefix with pcie_port=<port_name>: to expose the device over
emulated PCIe at the specified port.
virtio_fs_shmem: Vec<FsArgs>add a virtio_fs device for sharing memory (e.g. myfs,\SectionDirectoryPath)
Prefix with pcie_port=<port_name>: to expose the device over
emulated PCIe at the specified port.
virtio_fs_bus: VirtioBusCliadd a virtio_fs device under either the PCI or MMIO bus, or whatever the hypervisor supports (pci | mmio | auto)
virtio_pmem: Option<VirtioPmemArgs>virtio PMEM device
Prefix with pcie_port=<port_name>: to expose the device over
emulated PCIe at the specified port.
virtio_rng: booladd a virtio entropy (RNG) device
virtio_rng_bus: VirtioBusCliadd a virtio-rng device under either the PCI or MMIO bus, or whatever the hypervisor supports (pci | mmio | vpci | auto)
virtio_rng_pcie_port: Option<String>attach the virtio-rng device to the specified PCIe port (overrides –virtio-rng-bus)
virtio_console: Option<SerialConfigCli>virtio console device backed by a serial backend (/dev/hvc0 in guest)
Accepts serial config (console | stderr | listen=<path> | file=<path> (overwrites) | listen=tcp:<ip>:<port> | term[=<program>][,name=<windowtitle>] | none)
virtio_console_pcie_port: Option<String>attach the virtio-console device to the specified PCIe port
virtio_vsock_path: Option<String>add a virtio vsock device with the given Unix socket base path
virtio_net: Vec<NicConfigCli>expose a virtio network with the given backend (dio | vmnic | tap | none)
Prefix with uh: to add this NIC via Mana emulation through OpenHCL,
vtl2: to assign this NIC to VTL2, or pcie_port=<port_name>: to
expose the NIC over emulated PCIe at the specified port.
log_file: Option<PathBuf>send log output from the worker process to a file instead of stderr. the file will be overwritten.
ttrpc: Option<PathBuf>run as a ttrpc server on the specified Unix socket
grpc: Option<PathBuf>run as a grpc server on the specified Unix socket
single_process: booldo not launch child processes
disable_frontpage: boolinstead of showing the frontpage the VM will shutdown instead
tpm: booladd a vtpm device
internal_worker: Option<Option<String>>the mesh worker host name.
Used internally for debugging and diagnostics.
vmbus_redirect: boolredirect the VTL 0 vmbus control plane to a proxy in VTL 2.
vmbus_max_version: Option<u32>limit the maximum protocol version allowed by vmbus; used for testing purposes
vmgs: Option<VmgsCli>The disk to use for the VMGS.
If this is not provided, guest state will be stored in memory.
test_gsp_by_id: boolUse GspById guest state encryption policy with a test seed
vga_firmware: Option<PathBuf>VGA firmware file
secure_boot: boolenable secure boot
secure_boot_template: Option<SecureBootTemplateCli>use secure boot template
custom_uefi_json: Option<PathBuf>custom uefi nvram json file
relay_console_path: Option<PathBuf>the path to a named pipe (Windows) or Unix socket (Linux) to relay to the connected tty.
This is a hidden argument used internally.
relay_console_title: Option<String>the title of the console window spawned from the relay console.
This is a hidden argument used internally.
gdb: Option<u16>enable in-hypervisor gdb debugger
mana: Vec<NicConfigCli>enable emulated MANA devices with the given network backend (see –net)
Prefix with pcie_port=<port_name>: to expose the nic over emulated PCIe
at the specified port.
hypervisor: Option<String>use a specific hypervisor interface
custom_dsdt: Option<PathBuf>(dev utility) boot linux using a custom (raw) DSDT table.
This is a very niche utility, and it’s unlikely you’ll need to use it.
e.g: this flag helped bring up certain Hyper-V Generation 1 legacy devices without needing to port the associated ACPI code into OpenVMM’s DSDT builder.
ide: Vec<IdeDiskCli>attach an ide drive (can be passed multiple times)
Each ide controller has two channels. Each channel can have up to two attachments.
If the s flag is not passed then the drive will we be attached to the
primary ide channel if space is available. If two attachments have already
been added to the primary channel then the drive will be attached to the
secondary channel.
floppy: Vec<FloppyDiskCli>attach a floppy drive (should be able to be passed multiple times). VM must be generation 1 (no UEFI)
guest_watchdog: boolenable guest watchdog device
openhcl_dump_path: Option<PathBuf>enable OpenHCL’s guest crash dump device, targeting the specified path
halt_on_reset: boolhalt the VM when the guest requests a reset, instead of resetting it
write_saved_state_proto: Option<PathBuf>write saved state .proto files to the specified path
imc: Option<PathBuf>specify the IMC hive file for booting Windows
mcr: boolExpose MCR device
battery: boolexpose a battery device
uefi_console_mode: Option<UefiConsoleModeCli>set the uefi console mode
efi_diagnostics_log_level: Option<EfiDiagnosticsLogLevelCli>set the EFI diagnostics log level
default_boot_always_attempt: boolPerform a default boot even if boot entries exist and fail
pcie_root_complex: Vec<PcieRootComplexCli>Attach a PCI Express root complex to the VM
pcie_root_port: Vec<PcieRootPortCli>Attach a PCI Express root port to the VM
pcie_switch: Vec<GenericPcieSwitchCli>Attach a PCI Express switch to the VM
pcie_remote: Vec<PcieRemoteCli>Attach a PCIe remote device to a downstream port
Trait Implementations§
Source§impl Args for Options
impl Args for Options
Source§fn group_id() -> Option<Id>
fn group_id() -> Option<Id>
ArgGroup::id][crate::ArgGroup::id] for this set of argumentsSource§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command] so it can instantiate self via
[FromArgMatches::update_from_arg_matches_mut] Read moreSource§impl FromArgMatches for Options
impl FromArgMatches for Options
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches to self.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches to self.