Chapter 7 VBoxManage

7.1. Introduction

As briefly mentioned in Section 1.17, “Alternative Front-Ends”, VBoxManage is the command-line interface to Oracle VM VirtualBox. With it, you can completely control Oracle VM VirtualBox from the command line of your host operating system. VBoxManage supports all the features that the graphical user interface gives you access to, but it supports a lot more than that. It exposes all the features of the virtualization engine, even those that cannot be accessed from the GUI.

You will need to use the command line if you want to do the following:

  • Use a different user interface than the main GUI such as the VBoxHeadless server.

  • Control some of the more advanced and experimental configuration settings for a VM.

There are two main things to keep in mind when using VBoxManage. First, VBoxManage must always be used with a specific subcommand, such as list or createvm or startvm. All the subcommands that VBoxManage supports are described in detail in Chapter 7, VBoxManage.

Second, most of these subcommands require that you specify a particular virtual machine after the subcommand. There are two ways you can do this:

  • You can specify the VM name, as it is shown in the Oracle VM VirtualBox GUI. Note that if that name contains spaces, then you must enclose the entire name in double quotes. This is always required with command line arguments that contain spaces. For example:

    VBoxManage startvm "Windows XP"
  • You can specify the UUID, which is the internal unique identifier that Oracle VM VirtualBox uses to refer to the virtual machine. Assuming that the VM called "Windows XP" has the UUID shown below, the following command has the same effect as the previous example:

    VBoxManage startvm 670e746d-abea-4ba6-ad02-2a3b043810a5

You can enter VBoxManage list vms to have all currently registered VMs listed with all their settings, including their respective names and UUIDs.

Some typical examples of how to control Oracle VM VirtualBox from the command line are listed below:

  • To create a new virtual machine from the command line and immediately register it with Oracle VM VirtualBox, use VBoxManage createvm with the --register option, as follows:

    $ VBoxManage createvm --name "SUSE 10.2" --register
    VirtualBox Command Line Management Interface Version version-number
    (C) 2005-2018 Oracle Corporation
    All rights reserved.
    
    Virtual machine 'SUSE 10.2' is created.
    UUID: c89fc351-8ec6-4f02-a048-57f4d25288e5
    Settings file: '/home/username/.config/VirtualBox/Machines/SUSE 10.2/SUSE 10.2.xml'

    As can be seen from the above output, a new virtual machine has been created with a new UUID and a new XML settings file.

    For more details, see Section 7.7, “VBoxManage createvm”.

  • To show the configuration of a particular VM, use VBoxManage showvminfo. See Section 7.5, “VBoxManage showvminfo” for details and an example.

  • To change settings while a VM is powered off, use VBoxManage modifyvm. For example:

    VBoxManage modifyvm "Windows XP" --memory 512

    See also Section 7.8, “VBoxManage modifyvm”.

  • To change the storage configuration, such as to add a storage controller and then a virtual disk, use VBoxManage storagectl and VBoxManage storageattach. See Section 7.18, “VBoxManage storagectl” and Section 7.17, “VBoxManage storageattach”.

  • To control VM operation, use one of the following:

7.2. Commands Overview

When running VBoxManage without parameters or when supplying an invalid command line, the following command syntax list is shown. Note that the output will be slightly different depending on the host platform. If in doubt, check the output of VBoxManage for the commands available on your particular host.

Usage:

  VBoxManage [<general option>] <command>
 
 
General Options:
 
  [-v|--version]            print version number and exit
  [-q|--nologo]             suppress the logo
  [--settingspw <pw>]       provide the settings password
  [--settingspwfile <file>] provide a file containing the settings password
  [@<response-file>]        load arguments from the given response file (bourne style)
 
 
Commands:
 
  list [--long|-l] [--sorted|-s]          vms|runningvms|ostypes|hostdvds|hostfloppies|
                            intnets|bridgedifs|hostonlyifs|natnets|dhcpservers|
                            hostinfo|hostcpuids|hddbackends|hdds|dvds|floppies|
                            usbhost|usbfilters|systemproperties|extpacks|
                            groups|webcams|screenshotformats|cloudproviders|
                            cloudprofiles|cloudnets

  showvminfo                <uuid|vmname> [--details]
                            [--machinereadable]
  showvminfo                <uuid|vmname> --log <idx>

  registervm                <filename>

  unregistervm              <uuid|vmname> [--delete]

  createvm                  --name <name>
                            [--groups <group>, ...]
                            [--ostype <ostype>]
                            [--register]
                            [--basefolder <path>]
                            [--uuid <uuid>]
                            [--default]

  modifyvm                  <uuid|vmname>
                            [--name <name>]
                            [--groups <group>, ...]
                            [--description <desc>]
                            [--ostype <ostype>]
                            [--iconfile <filename>]
                            [--memory <memorysize in MB>]
                            [--pagefusion on|off]
                            [--vram <vramsize in MB>]
                            [--acpi on|off]
                            [--ioapic on|off]
                            [--hpet on|off]
                            [--triplefaultreset on|off]
                            [--apic on|off]
                            [--x2apic on|off]
                            [--paravirtprovider none|default|legacy|minimal|
                                                hyperv|kvm]
                            [--paravirtdebug <key=value> [,<key=value> ...]]
                            [--hwvirtex on|off]
                            [--nestedpaging on|off]
                            [--largepages on|off]
                            [--vtxvpid on|off]
                            [--vtxux on|off]
                            [--pae on|off]
                            [--longmode on|off]
                            [--ibpb-on-vm-exit on|off]
                            [--ibpb-on-vm-entry on|off]
                            [--spec-ctrl on|off]
                            [--l1d-flush-on-sched on|off]
                            [--l1d-flush-on-vm-entry on|off]
                            [--mds-clear-on-sched on|off]
                            [--mds-clear-on-vm-entry on|off]
                            [--nested-hw-virt on|off]
                            [--cpu-profile "host|Intel 80[86|286|386]"]
                            [--cpuid-portability-level <0..3>]
                            [--cpuid-set <leaf[:subleaf]> <eax> <ebx> <ecx> <edx>]
                            [--cpuid-remove <leaf[:subleaf]>]
                            [--cpuidremoveall]
                            [--hardwareuuid <uuid>]
                            [--cpus <number>]
                            [--cpuhotplug on|off]
                            [--plugcpu <id>]
                            [--unplugcpu <id>]
                            [--cpuexecutioncap <1-100>]
                            [--rtcuseutc on|off]
                            [--graphicscontroller none|vboxvga|vmsvga|vboxsvga]
                            [--monitorcount <number>]
                            [--accelerate3d on|off]
                            [--accelerate2dvideo on|off]
                            [--firmware bios|efi|efi32|efi64]
                            [--chipset ich9|piix3]
                            [--bioslogofadein on|off]
                            [--bioslogofadeout on|off]
                            [--bioslogodisplaytime <msec>]
                            [--bioslogoimagepath <imagepath>]
                            [--biosbootmenu disabled|menuonly|messageandmenu]
                            [--biosapic disabled|apic|x2apic]
                            [--biossystemtimeoffset <msec>]
                            [--biospxedebug on|off]
                            [--system-uuid-le on|off]
                            [--boot<1-4> none|floppy|dvd|disk|net>]
                            [--nic<1-N> none|null|nat|bridged|intnet|hostonly|
                                        generic|natnetwork]
                            [--nictype<1-N> Am79C970A|Am79C973|Am79C960|
                                            82540EM|82543GC|82545EM|
                                            virtio]
                            [--cableconnected<1-N> on|off]
                            [--nictrace<1-N> on|off]
                            [--nictracefile<1-N> <filename>]
                            [--nicproperty<1-N> name=[value]]
                            [--nicspeed<1-N> <kbps>]
                            [--nicbootprio<1-N> <priority>]
                            [--nicpromisc<1-N> deny|allow-vms|allow-all]
                            [--nicbandwidthgroup<1-N> none|<name>]
                            [--bridgeadapter<1-N> none|<devicename>]
                            [--hostonlyadapter<1-N> none|<devicename>]
                            [--intnet<1-N> <network name>]
                            [--nat-network<1-N> <network name>]
                            [--nicgenericdrv<1-N> <driver>]
                            [--natnet<1-N> <network>|default]
                            [--natsettings<1-N> [<mtu>],[<socksnd>],
                                                [<sockrcv>],[<tcpsnd>],
                                                [<tcprcv>]]
                            [--natpf<1-N> [<rulename>],tcp|udp,[<hostip>],
                                          <hostport>,[<guestip>],<guestport>]
                            [--natpf<1-N> delete <rulename>]
                            [--nattftpprefix<1-N> <prefix>]
                            [--nattftpfile<1-N> <file>]
                            [--nattftpserver<1-N> <ip>]
                            [--natbindip<1-N> <ip>]
                            [--natdnspassdomain<1-N> on|off]
                            [--natdnsproxy<1-N> on|off]
                            [--natdnshostresolver<1-N> on|off]
                            [--nataliasmode<1-N> default|[log],[proxyonly],
                                                         [sameports]]
                            [--macaddress<1-N> auto|<mac>]
                            [--mouse ps2|usb|usbtablet|usbmultitouch]
                            [--keyboard ps2|usb]
                            [--uart<1-N> off|<I/O base> <IRQ>]
                            [--uartmode<1-N> disconnected|
                                             server <pipe>|
                                             client <pipe>|
                                             tcpserver <port>|
                                             tcpclient <hostname:port>|
                                             file <file>|
                                             <devicename>]
                            [--uarttype<1-N> 16450|16550A|16750]
                            [--lpt<1-N> off|<I/O base> <IRQ>]
                            [--lptmode<1-N> <devicename>]
                            [--guestmemoryballoon <balloonsize in MB>]
                            [--vm-process-priority default|flat|low|normal|high]
                            [--audio none|null|dsound|oss|alsa|pulse|
                                     oss|pulse|coreaudio]
                            [--audioin on|off]
                            [--audioout on|off]
                            [--audiocontroller ac97|hda|sb16]
                            [--audiocodec stac9700|ad1980|stac9221|sb16]
                            [--clipboard-mode disabled|hosttoguest|guesttohost|
                                              bidirectional]
                            [--draganddrop disabled|hosttoguest|guesttohost|
                                           bidirectional]
                            [--vrde on|off]
                            [--vrdeextpack default|<name>]
                            [--vrdeproperty <name=[value]>]
                            [--vrdeport <hostport>]
                            [--vrdeaddress <hostip>]
                            [--vrdeauthtype null|external|guest]
                            [--vrdeauthlibrary default|<name>]
                            [--vrdemulticon on|off]
                            [--vrdereusecon on|off]
                            [--vrdevideochannel on|off]
                            [--vrdevideochannelquality <percent>]
                            [--usbohci on|off]
                            [--usbehci on|off]
                            [--usbxhci on|off]
                            [--usbrename <oldname> <newname>]
                            [--snapshotfolder default|<path>]
                            [--teleporter on|off]
                            [--teleporterport <port>]
                            [--teleporteraddress <address|empty>]
                            [--teleporterpassword <password>]
                            [--teleporterpasswordfile <file>|stdin]
                            [--tracing-enabled on|off]
                            [--tracing-config <config-string>]
                            [--tracing-allow-vm-access on|off]
                            [--usbcardreader on|off]
                            [--autostart-enabled on|off]
                            [--autostart-delay <seconds>]
                            [--recording on|off]
                            [--recordingscreens all|<screen ID> [<screen ID> ...]]
                            [--recordingfile <filename>]
                            [--recordingvideores <width> <height>]
                            [--recordingvideorate <rate>]
                            [--recordingvideofps <fps>]
                            [--recordingmaxtime <s>]
                            [--recordingmaxsize <MB>]
                            [--recordingopts <key=value> [,<key=value> ...]]
                            [--defaultfrontend default|<name>]

  movevm                    <uuid|vmname>
                            --type basic
                            [--folder <path>]

  import                    <ovfname/ovaname>
                            [--dry-run|-n]
                            [--options keepallmacs|keepnatmacs|importtovdi]
                            [--vmname <name>]
                            [--cloud]
                            [--cloudprofile <cloud profile name>]
                            [--cloudinstanceid <instance id>]
                            [--cloudbucket <bucket name>]
                            [more options]
                            (run with -n to have options displayed
                             for a particular OVF. It doesn't work for the Cloud import.)

  export                    <machines> --output|-o <name>.<ovf/ova/tar.gz>
                            [--legacy09|--ovf09|--ovf10|--ovf20|--opc10]
                            [--manifest]
                            [--iso]
                            [--options manifest|iso|nomacs|nomacsbutnat]
                            [--vsys <number of virtual system>]
                                    [--vmname <name>]
                                    [--product <product name>]
                                    [--producturl <product url>]
                                    [--vendor <vendor name>]
                                    [--vendorurl <vendor url>]
                                    [--version <version info>]
                                    [--description <description info>]
                                    [--eula <license text>]
                                    [--eulafile <filename>]
                            [--cloud <number of virtual system>]
                                    [--vmname <name>]
                                    [--cloudprofile <cloud profile name>]
                                    [--cloudbucket <bucket name>]
                                    [--cloudkeepobject <true/false>]
                                    [--cloudlaunchmode EMULATED|PARAVIRTUALIZED]
                                    [--cloudlaunchinstance <true/false>]
                                    [--clouddomain <domain>]
                                    [--cloudshape <shape>]
                                    [--clouddisksize <disk size in GB>]
                                    [--cloudocivcn <OCI vcn id>]
                                    [--cloudocisubnet <OCI subnet id>]
                                    [--cloudpublicip <true/false>]
                                    [--cloudprivateip <ip>]

  startvm                   <uuid|vmname>...
                            [--type gui|sdl|headless|separate]
                            [-E|--putenv <NAME>[=<VALUE>]]

  controlvm                 <uuid|vmname>
                            pause|resume|reset|poweroff|savestate|
                            acpipowerbutton|acpisleepbutton|
                            keyboardputscancode <hex> [<hex> ...]|
                            keyboardputstring <string1> [<string2> ...]|
                            keyboardputfile <filename>|
                            setlinkstate<1-N> on|off |
                            nic<1-N> null|nat|bridged|intnet|hostonly|generic|
                                     natnetwork [<devicename>] |
                            nictrace<1-N> on|off |
                            nictracefile<1-N> <filename> |
                            nicproperty<1-N> name=[value] |
                            nicpromisc<1-N> deny|allow-vms|allow-all |
                            natpf<1-N> [<rulename>],tcp|udp,[<hostip>],
                                        <hostport>,[<guestip>],<guestport> |
                            natpf<1-N> delete <rulename> |
                            guestmemoryballoon <balloonsize in MB> |
                            usbattach <uuid>|<address>
                                      [--capturefile <filename>] |
                            usbdetach <uuid>|<address> |
                            audioin on|off |
                            audioout on|off |
                            clipboard mode disabled|hosttoguest|guesttohost|
                                           bidirectional |
                            draganddrop disabled|hosttoguest|guesttohost|
                                        bidirectional |
                            vrde on|off |
                            vrdeport <port> |
                            vrdeproperty <name=[value]> |
                            vrdevideochannelquality <percent> |
                            setvideomodehint <xres> <yres> <bpp>
                                            [[<display>] [<enabled:yes|no> |
                                              [<xorigin> <yorigin>]]] |
                            setscreenlayout <display> on|primary <xorigin> <yorigin> <xres> <yres> <bpp> | off
                            screenshotpng <file> [display] |
                            recording on|off |
                            recording screens all|none|<screen>,[<screen>...] |
                            recording filename <file> |
                            recording videores <width>x<height> |
                            recording videorate <rate> |
                            recording videofps <fps> |
                            recording maxtime <s> |
                            recording maxfilesize <MB> |
                            setcredentials <username>
                                           --passwordfile <file> | <password>
                                           <domain>
                                           [--allowlocallogon <yes|no>] |
                            teleport --host <name> --port <port>
                                     [--maxdowntime <msec>]
                                     [--passwordfile <file> |
                                      --password <password>] |
                            plugcpu <id> |
                            unplugcpu <id> |
                            cpuexecutioncap <1-100>
                            webcam <attach [path [settings]]> | <detach [path]> | <list>
                            addencpassword <id>
                                           <password file>|-
                                           [--removeonsuspend <yes|no>]
                            removeencpassword <id>
                            removeallencpasswords
                            changeuartmode<1-N> disconnected|
                                                server <pipe>|
                                                client <pipe>|
                                                tcpserver <port>|
                                                tcpclient <hostname:port>|
                                                file <file>|
                                                <devicename>
                            vm-process-priority default|flat|low|normal|high

  discardstate              <uuid|vmname>

  adoptstate                <uuid|vmname> <state_file>

  closemedium               [disk|dvd|floppy] <uuid|filename>
                            [--delete]

  storageattach             <uuid|vmname>
                            --storagectl <name>
                            [--port <number>]
                            [--device <number>]
                            [--type dvddrive|hdd|fdd]
                            [--medium none|emptydrive|additions|
                                      <uuid|filename>|host:<drive>|iscsi]
                            [--mtype normal|writethrough|immutable|shareable|
                                     readonly|multiattach]
                            [--comment <text>]
                            [--setuuid <uuid>]
                            [--setparentuuid <uuid>]
                            [--passthrough on|off]
                            [--tempeject on|off]
                            [--nonrotational on|off]
                            [--discard on|off]
                            [--hotpluggable on|off]
                            [--bandwidthgroup <name>]
                            [--forceunmount]
                            [--server <name>|<ip>]
                            [--target <target>]
                            [--tport <port>]
                            [--lun <lun>]
                            [--encodedlun <lun>]
                            [--username <username>]
                            [--password <password>]
                            [--passwordfile <file>]
                            [--initiator <initiator>]
                            [--intnet]

  storagectl                <uuid|vmname>
                            --name <name>
                            [--add ide|sata|scsi|floppy|sas|usb|pcie|virtio]
                            [--controller LSILogic|LSILogicSAS|BusLogic|
                                          IntelAHCI|PIIX3|PIIX4|ICH6|I82078|
                            [             USB|NVMe|VirtIO]
                            [--portcount <1-n>]
                            [--hostiocache on|off]
                            [--bootable on|off]
                            [--rename <name>]
                            [--remove]

  bandwidthctl              <uuid|vmname>
                            add <name> --type disk|network
                                --limit <megabytes per second>[k|m|g|K|M|G] |
                            set <name>
                                --limit <megabytes per second>[k|m|g|K|M|G] |
                            remove <name> |
                            list [--machinereadable]
                            (limit units: k=kilobit, m=megabit, g=gigabit,
                                          K=kilobyte, M=megabyte, G=gigabyte)

  showmediuminfo            [disk|dvd|floppy] <uuid|filename>

  createmedium              [disk|dvd|floppy] --filename <filename>
                            [--size <megabytes>|--sizebyte <bytes>]
                            [--diffparent <uuid>|<filename>]
                            [--format VDI|VMDK|VHD] (default: VDI)]
                            [--variant Standard,Fixed,Split2G,Stream,ESX,
                                       Formatted]
                            [[--property <name>=<value>] --property <name>=<value]...

  modifymedium              [disk|dvd|floppy] <uuid|filename>
                            [--type normal|writethrough|immutable|shareable|
                                    readonly|multiattach]
                            [--autoreset on|off]
                            [--property <name=[value]>]
                            [--compact]
                            [--resize <megabytes>|--resizebyte <bytes>]
                            [--move <path>]
                            [--setlocation <path>]
                            [--description <description string>]
  clonemedium               [disk|dvd|floppy] <uuid|inputfile> <uuid|outputfile>
                            [--format VDI|VMDK|VHD|RAW|<other>]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--existing]

  mediumproperty            [disk|dvd|floppy] set <uuid|filename>
                            <property> <value>

                            [disk|dvd|floppy] get <uuid|filename>
                            <property>

                            [disk|dvd|floppy] delete <uuid|filename>
                            <property>

  encryptmedium             <uuid|filename>
                            [--newpassword <file>|-]
                            [--oldpassword <file>|-]
                            [--cipher <cipher identifier>]
                            [--newpasswordid <password identifier>]

  checkmediumpwd            <uuid|filename>
                            <pwd file>|-

  convertfromraw            <filename> <outputfile>
                            [--format VDI|VMDK|VHD]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--uuid <uuid>]
  convertfromraw            stdin <outputfile> <bytes>
                            [--format VDI|VMDK|VHD]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--uuid <uuid>]

  getextradata              global|<uuid|vmname>
                            <key>|[enumerate]

  setextradata              global|<uuid|vmname>
                            <key>
                            [<value>] (no value deletes key)

  setproperty               machinefolder default|<folder> |
                            hwvirtexclusive on|off |
                            vrdeauthlibrary default|<library> |
                            websrvauthlibrary default|null|<library> |
                            vrdeextpack null|<library> |
                            autostartdbpath null|<folder> |
                            loghistorycount <value>
                            defaultfrontend default|<name>
                            logginglevel <log setting>
                            proxymode system|noproxy|manual
                            proxyurl <url>

  usbfilter                 add <index,0-N>
                            --target <uuid|vmname>|global
                            --name <string>
                            --action ignore|hold (global filters only)
                            [--active yes|no] (yes)
                            [--vendorid <XXXX>] (null)
                            [--productid <XXXX>] (null)
                            [--revision <IIFF>] (null)
                            [--manufacturer <string>] (null)
                            [--product <string>] (null)
                            [--remote yes|no] (null, VM filters only)
                            [--serialnumber <string>] (null)
                            [--maskedinterfaces <XXXXXXXX>]

  usbfilter                 modify <index,0-N>
                            --target <uuid|vmname>|global
                            [--name <string>]
                            [--action ignore|hold] (global filters only)
                            [--active yes|no]
                            [--vendorid <XXXX>|""]
                            [--productid <XXXX>|""]
                            [--revision <IIFF>|""]
                            [--manufacturer <string>|""]
                            [--product <string>|""]
                            [--remote yes|no] (null, VM filters only)
                            [--serialnumber <string>|""]
                            [--maskedinterfaces <XXXXXXXX>]

  usbfilter                 remove <index,0-N>
                            --target <uuid|vmname>|global

  guestproperty             get <uuid|vmname>
                            <property> [--verbose]

  guestproperty             set <uuid|vmname>
                            <property> [<value> [--flags <flags>]]

  guestproperty             delete|unset <uuid|vmname>
                            <property>

  guestproperty             enumerate <uuid|vmname>
                            [--patterns <patterns>]

  guestproperty             wait <uuid|vmname> <patterns>
                            [--timeout <msec>] [--fail-on-timeout]

  guestcontrol              <uuid|vmname> [--verbose|-v] [--quiet|-q]
                              [--username <name>] [--domain <domain>]
                              [--passwordfile <file> | --password <password>]

                              run [common-options]
                              [--exe <path to executable>] [--timeout <msec>]
                              [-E|--putenv <NAME>[=<VALUE>]] [--unquoted-args]
                              [--ignore-operhaned-processes] [--profile]
                              [--no-wait-stdout|--wait-stdout]
                              [--no-wait-stderr|--wait-stderr]
                              [--dos2unix] [--unix2dos]
                              -- <program/arg0> [argument1] ... [argumentN]]

                              start [common-options]
                              [--exe <path to executable>] [--timeout <msec>]
                              [-E|--putenv <NAME>[=<VALUE>]] [--unquoted-args]
                              [--ignore-operhaned-processes] [--profile]
                              -- <program/arg0> [argument1] ... [argumentN]]

                              copyfrom [common-options]
                              [--follow] [-R|--recursive]
                              <guest-src0> [guest-src1 [...]] <host-dst>

                              copyfrom [common-options]
                              [--follow] [-R|--recursive]
                              [--target-directory <host-dst-dir>]
                              <guest-src0> [guest-src1 [...]]

                              copyto [common-options]
                              [--follow] [-R|--recursive]
                              <host-src0> [host-src1 [...]] <guest-dst>

                              copyto [common-options]
                              [--follow] [-R|--recursive]
                              [--target-directory <guest-dst>]
                              <host-src0> [host-src1 [...]]

                              mkdir|createdir[ectory] [common-options]
                              [--parents] [--mode <mode>]
                              <guest directory> [...]

                              rmdir|removedir[ectory] [common-options]
                              [-R|--recursive]
                              <guest directory> [...]

                              removefile|rm [common-options] [-f|--force]
                              <guest file> [...]

                              mv|move|ren[ame] [common-options]
                              <source> [source1 [...]] <dest>

                              mktemp|createtemp[orary] [common-options]
                              [--secure] [--mode <mode>] [--tmpdir <directory>]
                              <template>

                              stat [common-options]
                              <file> [...]

  guestcontrol              <uuid|vmname> [--verbose|-v] [--quiet|-q]

                              list <all|sessions|processes|files> [common-opts]

                              closeprocess [common-options]
                              <   --session-id <ID>
                                | --session-name <name or pattern>
                              <PID1> [PID1 [...]]

                              closesession [common-options]
                              <  --all | --session-id <ID>
                                | --session-name <name or pattern> >

                              updatega|updateguestadditions|updateadditions
                              [--source <guest additions .ISO>]
                              [--wait-start] [common-options]
                              [-- [<argument1>] ... [<argumentN>]]

                              watch [common-options]

  metrics                   list [*|host|<vmname> [<metric_list>]]
                                                 (comma-separated)

  metrics                   setup
                            [--period <seconds>] (default: 1)
                            [--samples <count>] (default: 1)
                            [--list]
                            [*|host|<vmname> [<metric_list>]]

  metrics                   query [*|host|<vmname> [<metric_list>]]

  metrics                   enable
                            [--list]
                            [*|host|<vmname> [<metric_list>]]

  metrics                   disable
                            [--list]
                            [*|host|<vmname> [<metric_list>]]

  metrics                   collect
                            [--period <seconds>] (default: 1)
                            [--samples <count>] (default: 1)
                            [--list]
                            [--detach]
                            [*|host|<vmname> [<metric_list>]]

  natnetwork                add --netname <name>
                            --network <network>
                            [--enable|--disable]
                            [--dhcp on|off]
                            [--port-forward-4 <rule>]
                            [--loopback-4 <rule>]
                            [--ipv6 on|off]
                            [--port-forward-6 <rule>]
                            [--loopback-6 <rule>]

  natnetwork                remove --netname <name>

  natnetwork                modify --netname <name>
                            [--network <network>]
                            [--enable|--disable]
                            [--dhcp on|off]
                            [--port-forward-4 <rule>]
                            [--loopback-4 <rule>]
                            [--ipv6 on|off]
                            [--port-forward-6 <rule>]
                            [--loopback-6 <rule>]

  natnetwork                start --netname <name>

  natnetwork                stop --netname <name>

  natnetwork                list [<pattern>]

  hostonlyif                ipconfig <name>
                            [--dhcp |
                            --ip<ipv4> [--netmask<ipv4> (def: 255.255.255.0)] |
                            --ipv6<ipv6> [--netmasklengthv6<length> (def: 64)]]
                            create |
                            remove <name>

  usbdevsource              add <source name>
                            --backend <backend>
                            --address <address>
  usbdevsource              remove <source name>

VBoxManage snapshot { uuid|vmname }
VBoxManage snapshot { uuid|vmname } take { snapshot-name } [--description=description] [--live] [--uniquename Number,Timestamp,Space,Force]
VBoxManage snapshot { uuid|vmname } delete { snapshot-name }
VBoxManage snapshot { uuid|vmname } restore { snapshot-name }
VBoxManage snapshot { uuid|vmname } restorecurrent
VBoxManage snapshot { uuid|vmname } edit { snapshot-name | --current } [--description=description] [--name=new-name]
VBoxManage snapshot { uuid|vmname } list [[--details] | [--machinereadable]]
VBoxManage snapshot { uuid|vmname } showvminfo { snapshot-name }

VBoxManage clonevm { vmname|uuid } [--basefolder=basefolder] [--groups=group,...] [ --mode=machine | --mode=machinechildren | --mode=all ] [--name=name] [--options=option,...] [--register] [--snapshot=snapshot-name] [--uuid=uuid]

VBoxManage mediumio { --disk=uuid|filename | --dvd=uuid|filename | --floppy=uuid|filename } [--password-file=-|filename] formatfat [--quick]
VBoxManage mediumio { --disk=uuid|filename | --dvd=uuid|filename | --floppy=uuid|filename } [--password-file=-|filename] cat [--hex] [--offset=byte-offset] [--size=bytes] [--output=-|filename]
VBoxManage mediumio { --disk=uuid|filename | --dvd=uuid|filename | --floppy=uuid|filename } [--password-file=-|filename] stream [--format=image-format] [--variant=image-variant] [--output=-|filename]

VBoxManage sharedfolder add { uuid | vmname } {--name=name} {--hostpath=hostpath} [--readonly] [--transient] [--automount] [--auto-mount-point=path]
VBoxManage sharedfolder remove { uuid | vmname } {--name=name} [--transient]

VBoxManage dhcpserver add { --network=netname | --interface=ifname } {--server-ip=address} {--netmask=mask} {--lower-ip=address} {--upper-ip=address} { --enable | --disable }
[ [--global] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--incl-mac=address...] [--excl-mac=address...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--incl-vendor=string...] [--excl-vendor=string...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--incl-user=string...] [--excl-user=string...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--vm=name|uuid} [--nic=1-N] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]
[ {--mac-address=address} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]
VBoxManage dhcpserver modify { --network=netname | --interface=ifname } [--server-ip=address] [--lower-ip=address] [--upper-ip=address] [--netmask=mask] [ --enable | --disable ]
[ [--global] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--del-mac=address...] [--incl-mac=address...] [--excl-mac=address...] [--del-mac-wild=pattern...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--del-vendor=string...] [--incl-vendor=string...] [--excl-vendor=string...] [--del-vendor-wild=pattern...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--del-user=string...] [--incl-user=string...] [--excl-user=string...] [--del-user-wild=pattern...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--zap-conditions] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--vm=name|uuid} [--nic=1-N] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]
[ {--mac-address=address} [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]
VBoxManage dhcpserver remove { --network=netname | --interface=ifname }
VBoxManage dhcpserver restart { --network=netname | --interface=ifname }
VBoxManage dhcpserver findlease { --network=netname | --interface=ifname } {--mac-address=mac}

VBoxManage debugvm { uuid|vmname } dumpvmcore [--filename=name]
VBoxManage debugvm { uuid|vmname } info { item } [ args ...]
VBoxManage debugvm { uuid|vmname } injectnmi
VBoxManage debugvm { uuid|vmname } log [[--release] | [--debug]] [ group-settings ...]
VBoxManage debugvm { uuid|vmname } logdest [[--release] | [--debug]] [ destinations ...]
VBoxManage debugvm { uuid|vmname } logflags [[--release] | [--debug]] [ flags ...]
VBoxManage debugvm { uuid|vmname } osdetect
VBoxManage debugvm { uuid|vmname } osinfo
VBoxManage debugvm { uuid|vmname } osdmesg [--lines=lines]
VBoxManage debugvm { uuid|vmname } getregisters [--cpu=id] [ reg-set.reg-name ...]
VBoxManage debugvm { uuid|vmname } setregisters [--cpu=id] [ reg-set.reg-name=value ...]
VBoxManage debugvm { uuid|vmname } show [[--human-readable] | [--sh-export] | [--sh-eval] | [--cmd-set]] [ settings-item ...]
VBoxManage debugvm { uuid|vmname } stack [--cpu=id]
VBoxManage debugvm { uuid|vmname } statistics [--reset] [--descriptions] [--pattern=pattern]

VBoxManage extpack install [--replace] [--accept-license=sha256] { tarball }
VBoxManage extpack uninstall [--force] { name }
VBoxManage extpack cleanup

VBoxManage unattended detect {--iso=install-iso} [--machine-readable]
VBoxManage unattended install { uuid|vmname } {--iso=install-iso} [--user=login] [--password=password] [--password-file=file] [--full-user-name=name] [--key=product-key] [--install-additions] [--no-install-additions] [--additions-iso=add-iso] [--install-txs] [--no-install-txs] [--validation-kit-iso=testing-iso] [--locale=ll_CC] [--country=CC] [--time-zone=tz] [--hostname=fqdn] [--package-selection-adjustment=keyword] [--dry-run] [--auxiliary-base-path=path] [--image-index=number] [--script-template=file] [--post-install-template=file] [--post-install-command=command] [--extra-install-kernel-parameters=params] [--language=lang] [--start-vm=session-type]

VBoxManage cloud {--provider=name} {--profile=name} list instances [--state=string] [--compartment-id=string]
VBoxManage cloud {--provider=name} {--profile=name} list images {--compartment-id=string} [--state=string]
VBoxManage cloud {--provider=name} {--profile=name} instance create {--domain-name=name} {{--image-id=id} | {--boot-volume-id=id}} {--display-name=name} {--shape=type} {--subnet=id} [--boot-disk-size=size in GB] [--publicip=true/false] [--privateip=IP address] [--public-ssh-key=key string...] [--launch-mode=NATIVE/EMULATED/PARAVIRTUALIZED] [--cloud-init-script-path=path to a script]
VBoxManage cloud {--provider=name} {--profile=name} instance info {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} instance terminate {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} instance start {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} instance pause {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} image create {--display-name=name} [--bucket-name=name] [--object-name=name] [--instance-id=unique id]
VBoxManage cloud {--provider=name} {--profile=name} image info {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} image delete {--id=unique id}
VBoxManage cloud {--provider=name} {--profile=name} image import {--id=unique id} [--bucket-name=name] [--object-name=name]
VBoxManage cloud {--provider=name} {--profile=name} image export {--id=unique id} {--display-name=name} [--bucket-name=name] [--object-name=name]
VBoxManage cloud {--provider=name} {--profile=name} network setup {--local-gateway-iso=path} [--gateway-os-name=string] [--gateway-os-version=string] [--gateway-shape=string] [--tunnel-network-name=string] [--tunnel-network-range=string] [--guest-additions-iso=path] [--proxy=string] [--compartment-id=string]
VBoxManage cloud {--provider=name} {--profile=name} network create {--name=string} {--network-id=string} [ --enable | --disable ]
VBoxManage cloud network update {--name=string} [--network-id=string] [ --enable | --disable ]
VBoxManage cloud network delete {--name=string}
VBoxManage cloud network info {--name=string}

VBoxManage cloudprofile {--provider=name} {--profile=name} add [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]
VBoxManage cloudprofile {--provider=name} {--profile=name} update [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]
VBoxManage cloudprofile {--provider=name} {--profile=name} delete
VBoxManage cloudprofile {--provider=name} {--profile=name} show

Each time VBoxManage is invoked, only one command can be executed. However, a command might support several subcommands which then can be invoked in one single call. The following sections provide detailed reference information on the different commands.

7.3. General Options

  • -v|--version: Show the version of this tool and exit.

  • --nologo: Suppress the output of the logo information. This option is useful for scripts.

  • --settingspw: Specifiy a settings password.

  • --settingspwfile: Specify a file containing the settings password.

The settings password is used for certain settings which need to be stored in encrypted form for security reasons. At the moment, the only encrypted setting is the iSCSI initiator secret, see Section 7.17, “VBoxManage storageattach”. As long as no settings password is specified, this information is stored in plain text. After using the --settingspw|--settingspwfile option once, it must be always used. Otherwise, the encrypted setting cannot be unencrypted.

7.4. VBoxManage list

The list command gives relevant information about your system and information about Oracle VM VirtualBox's current settings.

The following subcommands are available with VBoxManage list:

  • vms: Lists all virtual machines currently registered with Oracle VM VirtualBox. By default this displays a compact list with each VM's name and UUID. If you also specify --long or -l, this will be a detailed list as with the showvminfo command, see Section 7.5, “VBoxManage showvminfo”.

  • runningvms: Lists all currently running virtual machines by their unique identifiers (UUIDs) in the same format as with vms.

  • ostypes: Lists all guest operating systems presently known to Oracle VM VirtualBox, along with the identifiers used to refer to them with the modifyvm command.

  • hostdvds, hostfloppies: Lists the DVD, floppy, bridged networking, and host-only networking interfaces on the host, along with the name used to access them from within Oracle VM VirtualBox.

  • intnets: Displays information about the internal networks.

  • bridgedifs, hostonlyifs, natnets, dhcpservers: Lists the bridged network interfaces, host-only network interfaces, NAT network interfaces, and DHCP servers currently available on the host. See Chapter 6, Virtual Networking.

  • hostinfo: Displays information about the host system, such as CPUs, memory size, and operating system version.

  • hostcpuids: Lists the CPUID parameters for the host CPUs. This can be used for a more fine grained analyis of the host's virtualization capabilities.

  • hddbackends: Lists all known virtual disk back-ends of Oracle VM VirtualBox. For each such format, such as VDI, VMDK, or RAW, this subcommand lists the back-end's capabilities and configuration.

  • hdds, dvds, floppies: Shows information about virtual disk images currently in use by Oracle VM VirtualBox, including all their settings, the unique identifiers (UUIDs) associated with them by Oracle VM VirtualBox and all files associated with them. This is the command-line equivalent of the Virtual Media Manager. See Section 5.3, “The Virtual Media Manager”.

  • usbhost: Shows information about USB devices attached to the host, including information useful for constructing USB filters and whether they are currently in use by the host.

  • usbfilters: Lists all global USB filters registered with Oracle VM VirtualBox and displays the filter parameters. Global USB filters are for devices which are accessible to all virtual machines.

  • systemproperties: Displays some global Oracle VM VirtualBox settings, such as minimum and maximum guest RAM and virtual hard disk size, folder settings and the current authentication library in use.

  • extpacks: Displays all Oracle VM VirtualBox extension packs that are currently installed. See Section 1.5, “Installing Oracle VM VirtualBox and Extension Packs” and Section 7.41, “VBoxManage extpack”.

  • groups: Displays details of the VM Groups. See Section 1.9, “Using VM Groups”.

  • webcams: Displays a list of webcams attached to the running VM. The output format is a list of absolute paths or aliases that were used for attaching the webcams to the VM using the webcam attach command.

  • screenshotformats: Displays a list of available screenshot formats.

  • cloudproviders: Displays a list of cloud providers that are supported by Oracle VM VirtualBox. Oracle Cloud Infrastructure is an example of a cloud provider.

  • cloudprofiles: Displays a list of cloud profiles that have been configured.

    Cloud profiles are used when exporting VMs to a cloud service. See Section 1.15.7, “Exporting an Appliance to Oracle Cloud Infrastructure”.

7.5. VBoxManage showvminfo

The showvminfo command shows information about a particular virtual machine. This is the same information as VBoxManage list vms --long would show for all virtual machines.

You will see information as shown in the following example.

$ VBoxManage showvminfo "Windows XP"
VirtualBox Command Line Management Interface Version version-number
(C) 2005-2018 Oracle Corporation
All rights reserved.

Name:            Windows XP
Guest OS:        Other/Unknown
UUID:            1bf3464d-57c6-4d49-92a9-a5cc3816b7e7
Config file:     /home/username/.config/VirtualBox/Machines/Windows XP/Windows XP.xml
Memory size:     512MB
VRAM size:       12MB
Number of CPUs:  2
Boot menu mode:  message and menu
Boot Device (1): DVD
Boot Device (2): HardDisk
Boot Device (3): Not Assigned
Boot Device (4): Not Assigned
ACPI:            on
IOAPIC:          on
...
    

Use the --machinereadable option to produce the same output, but in machine readable format with a property=value string on each line. For example:

...
groups="/"
ostype="Oracle (64-bit)"
UUID="457af700-bc0a-4258-aa3c-13b03da171f2"
...
 

7.6. VBoxManage registervm/unregistervm

The registervm command enables you to import a virtual machine definition in an XML file into Oracle VM VirtualBox. The machine must not conflict with one already registered in Oracle VM VirtualBox and it may not have any hard or removable disks attached. It is advisable to place the definition file in the machines folder before registering it.

Note

When creating a new virtual machine with VBoxManage createvm, as shown in Section 7.7, “VBoxManage createvm”, you can directly specify the --register option to avoid having to register it separately.

The unregistervm command unregisters a virtual machine. If --delete is also specified, the following files will also be deleted automatically:

  • All hard disk image files, including differencing files, which are used by the machine and not shared with other machines.

  • Saved state files that the machine created. One if the machine was in Saved state and one for each online snapshot.

  • The machine XML file and its backups.

  • The machine log files.

  • The machine directory, if it is empty after having deleted all of the above files.

7.7. VBoxManage createvm

The VBoxManage createvm command creates a new XML virtual machine definition file.

You must specify the name of the VM by using --name name. This name is used by default as the file name of the settings file that has the .xml extension and the machine folder, which is a subfolder of the .config/VirtualBox/Machines folder. Note that the machine folder path name varies based on the OS type and the Oracle VM VirtualBox version.

Ensure that the VM name conforms to the host OS's file name requirements. If you later rename the VM, the file and folder names will be updated to match the new name automatically.

The --basefolder path option specifies the machine folder path name. Note that the names of the file and the folder do not change if you rename the VM.

The --group group-ID, ... option assigns the VM to the specified groups. Note that group IDs always start with / so that they can be nested. By default, each VM is assigned membership to the / group.

The --ostype ostype option specifies the guest OS to run in the VM. Run the VBoxManage list ostypes command to see the available OS types.

The --uuid uuid option specifies the universal unique identifier (UUID) of the VM. The UUID must be unique within the namespace of the host or of its VM group memberships. By default, the VBoxManage command automatically generates the UUID.

The --default option applies a default hardware configuration for the specified guest OS. By default, the VM is created with minimal hardware.

The --register option registers the VM with your Oracle VM VirtualBox installation. By default, the VBoxManage createvm command creates only the XML configuration for the VM but does not registered the VM. If you do not register the VM at creation, you can run the VBoxManage registervm command after you create the VM.

7.8. VBoxManage modifyvm

This command changes the properties of a registered virtual machine which is not running. Most of the properties that this command makes available correspond to the VM settings that the VirtualBox Manager displays in each VM's Settings dialog. These are described in Chapter 3, Configuring Virtual Machines. However, some of the more advanced settings are only available through the VBoxManage interface.

These commands require that the machine is powered off, neither running nor in a Saved state. Some machine settings can also be changed while a machine is running. Those settings will then have a corresponding subcommand with the VBoxManage controlvm subcommand. See Section 7.13, “VBoxManage controlvm”.

7.8.1. General Settings

The following general settings are available through VBoxManage modifyvm:

  • --name <name>: Changes the VM's name and can be used to rename the internal virtual machine files, as described in Section 7.7, “VBoxManage createvm”.

  • --groups <group>, ...: Changes the group membership of a VM. Groups always start with a / and can be nested. By default VMs are in group /.

  • --description <desc>: Changes the VM's description, which is a way to record details about the VM in a way which is meaningful for the user. The GUI interprets HTML formatting, the command line allows arbitrary strings potentially containing multiple lines.

  • --ostype <ostype>: Specifies what guest operating system is supposed to run in the VM. To learn about the various identifiers that can be used here, use VBoxManage list ostypes.

  • --iconfile <filename>: Specifies the absolute path on the host file system for the Oracle VM VirtualBox icon to be displayed in the VM.

  • --memory <memorysize>: Sets the amount of RAM, in MB, that the virtual machine should allocate for itself from the host. See Section 1.7, “Creating Your First Virtual Machine”.

  • --pagefusion on|off: Enables and disables the Page Fusion feature. Page Fusion is disabled by default. The Page Fusion feature minimises memory duplication between VMs with similar configurations running on the same host. See Section 4.10.2, “Page Fusion”.

  • --vram <vramsize>: Sets the amount of RAM that the virtual graphics card should have. See Section 3.6, “Display Settings”.

  • --acpi on|off and --ioapic on|off: Determines whether the VM has ACPI and I/O APIC support. See Section 3.5.1, “Motherboard Tab”.

  • --pciattach <host PCI address [@ guest PCI bus address]>: Attaches a specified PCI network controller on the host to a specified PCI bus on the guest.

  • --pcidetach <host PCI address>: Detaches a specified PCI network controller on the host from the attached PCI bus on the guest.

  • --hardwareuuid <uuid>: The UUID presented to the guest through memory tables (DMI/SMBIOS), hardware, and guest properties. By default this is the same as the VM UUID. This setting is useful when cloning a VM. Teleporting takes care of this automatically.

  • --cpus <cpucount>: Sets the number of virtual CPUs for the virtual machine, see Section 3.5.2, “Processor Tab”. If CPU hot-plugging is enabled, this then sets the maximum number of virtual CPUs that can be plugged into the virtual machines.

  • --cpuhotplug on|off: Enables CPU hot-plugging. When enabled, virtual CPUs can be added to and removed from a virtual machine while it is running. See CPU Hot-Plugging.

  • --plugcpu|unplugcpu <id>: If CPU hot-plugging is enabled, this setting adds or removes a virtual CPU on the virtual machine. <id> specifies the index of the virtual CPU to be added or removed and must be a number from 0 to the maximum number of CPUs configured with the --cpus option. CPU 0 can never be removed.

  • --cpuexecutioncap <1-100>: Controls how much CPU time a virtual CPU can use. A value of 50 implies a single virtual CPU can use up to 50% of a single host CPU.

  • --pae on|off: Enables and disables PAE. See Section 3.5.2, “Processor Tab”.

  • --longmode on|off: Enables and disables long mode. See Section 3.5.2, “Processor Tab”.

  • --spec-ctrl on|off: Enables and disables the exposure of speculation control interfaces to the guest, provided they are available on the host. Depending on the host CPU and workload, enabling speculation control may significantly reduce performance.

  • --cpu-profile <host|intel 80[86|286|386]>: Enables specification of a profile for guest CPU emulation. Specify either one based on the host system CPU (host), or one from a number of older Intel Micro-architectures: 8086, 80286, 80386.

  • --hpet on|off: Enables and disables a High Precision Event Timer (HPET) which can replace the legacy system timers. This is turned off by default. Note that Windows supports a HPET only from Vista onwards.

  • --hwvirtex on|off: Enables and disables the use of hardware virtualization extensions, such as Intel VT-x or AMD-V, in the processor of your host system. See Hardware Virtualization.

  • --triplefaultreset on|off: Enables resetting of the guest instead of triggering a Guru Meditation. Some guests raise a triple fault to reset the CPU so sometimes this is desired behavior. Works only for non-SMP guests.

  • --apic on|off: Enables and disables I/O APIC. With I/O APIC, operating systems can use more than 16 interrupt requests (IRQs) thus avoiding IRQ sharing for improved reliability. This setting is enabled by default. See Section 3.5.1, “Motherboard Tab”.

  • --x2apic on|off: Enables and disables CPU x2APIC support. CPU x2APIC support helps operating systems run more efficiently on high core count configurations, and optimizes interrupt distribution in virtualized environments. This setting is enabled by default. Disable this setting when using host or guest operating systems that are incompatible with x2APIC support.

  • --paravirtprovider none|default|legacy|minimal|hyperv|kvm: Specifies which paravirtualization interface to provide to the guest operating system. Specifying none explicitly turns off exposing any paravirtualization interface. The option default selects an appropriate interface when starting the VM, depending on the guest OS type. This is the default option chosen when creating new VMs. The legacy option is used for VMs which were created with older Oracle VM VirtualBox versions and will pick a paravirtualization interface when starting the VM with Oracle VM VirtualBox 5.0 and newer. The minimal provider is mandatory for Mac OS X guests. kvm and hyperv are recommended for Linux and Windows guests respectively. These options are explained in Paravirtualization Providers.

  • --paravirtdebug <keyword=value> [,<keyword=value> ...]: Specifies debugging options specific to the paravirtualization provider configured for this VM. See the provider specific options in Paravirtualized Debugging for a list of supported keyword-value pairs for each provider.

  • --nestedpaging on|off: If hardware virtualization is enabled, this additional setting enables or disables the use of the nested paging feature in the processor of your host system. See Hardware Virtualization and CVE-2018-3646.

  • --largepages on|off: If hardware virtualization and nested paging are enabled, for Intel VT-x only, an additional performance improvement of up to 5% can be obtained by enabling this setting. This causes the hypervisor to use large pages to reduce TLB use and overhead.

  • --vtxvpid on|off: If hardware virtualization is enabled, for Intel VT-x only, this additional setting enables or disables the use of the tagged TLB (VPID) feature in the processor of your host system. See Hardware Virtualization.

  • --vtxux on|off: If hardware virtualization is enabled, for Intel VT-x only, this setting enables or disables the use of the unrestricted guest mode feature for executing your guest.

  • --nested-hw-virt on|off: If hardware virtualization is enabled, this setting enables or disables passthrough of hardware virtualization features to the guest. See Nested Virtualization.

  • --accelerate3d on|off: If the Guest Additions are installed, this setting enables or disables hardware 3D acceleration. See Section 4.5.1, “Hardware 3D Acceleration (OpenGL and Direct3D 8/9)”.

  • --accelerate2dvideo on|off: If the Guest Additions are installed, this setting enables or disables 2D video acceleration. See Section 4.5.2, “Hardware 2D Video Acceleration for Windows Guests”.

  • --chipset piix3|ich9: By default, Oracle VM VirtualBox emulates an Intel PIIX3 chipset. Usually there is no reason to change the default setting unless this is required to relax some of its constraints. See Section 3.5.1, “Motherboard Tab”.

  • You can influence the BIOS logo that is displayed when a virtual machine starts up with a number of settings. By default, an Oracle VM VirtualBox logo is displayed.

    With --bioslogofadein on|off and --bioslogofadeout on|off, you can determine whether the logo should fade in and out, respectively.

    With --bioslogodisplaytime <msec> you can set how long the logo should be visible, in milliseconds.

    With --bioslogoimagepath <imagepath> you can replace the image that is shown with your own logo. The image must be an uncompressed 256 color BMP file without color space information (Windows 3.0 format). The image must not be bigger than 640 x 480.

  • --biosbootmenu disabled|menuonly|messageandmenu: Specifies whether the BIOS enables the user to select a temporary boot device. The menuonly option suppresses the message, but the user can still press F12 to select a temporary boot device.

  • --biosapic x2apic|apic|disabled: Specifies the firmware APIC level to be used. Options are: x2apic, apic or disabled (no apic or x2apic) respectively.

    Note that if x2apic is specified and x2APIC is unsupported by the VCPU, biosapic downgrades to apic, if supported. Otherwise biosapic downgrades to disabled. Similarly, if apic is specified, and APIC is unsupported, a downgrade to disabled results.

  • --biossystemtimeoffset <ms>: Specifies a fixed time offset, in milliseconds, of the guest relative to the host time. If the offset is positive, the guest time runs ahead of the host time.

  • --biospxedebug on|off: Enables or disables additional debugging output when using the Intel PXE boot ROM. The output is written to the release log file. See Collecting Debugging Information.

  • --system-uuid-le on|off: Enables or disables representing the system UUID in little endian form. The default value is on for new VMs. For old VMs the setting is off to keep the content of the DMI/SMBIOS table unchanged, which can be important for Windows license activation.

  • --boot<1-4> none|floppy|dvd|disk|net: Specifies the boot order for the virtual machine. There are four slots, which the VM will try to access from 1 to 4, and for each of which you can set a device that the VM should attempt to boot from.

  • --rtcuseutc on|off: Sets the real-time clock (RTC) to operate in UTC time. See Section 3.5.1, “Motherboard Tab”.

  • --graphicscontroller none|vboxvga|vmsvga|vboxsvga: Specifies the use of a graphics controller, with an option to choose a specific type. See Section 3.6.1, “Screen Tab”.

  • --snapshotfolder default|<path>: Specifies the folder where snapshots are kept for a virtual machine.

  • --firmware bios|efi|efi32|efi64: Specifies the firmware to be used to boot the VM: Available options are: BIOS, or one of the EFI options: efi, efi32, or efi64. Use EFI options with care.

  • --guestmemoryballoon <size> Sets the default size of the guest memory balloon. This is the memory allocated by the Oracle VM VirtualBox Guest Additions from the guest operating system and returned to the hypervisor for reuse by other virtual machines. <size> must be specified in megabytes. The default size is 0 megabytes. See Section 4.10.1, “Memory Ballooning”.

  • --defaultfrontend default|<name>: Specifies the default frontend to be used when starting this VM. See Section 7.12, “VBoxManage startvm”.

  • --vm-process-priority default|flat|low|normal|high: Specifies the priority scheme of the VM process to be used when starting this VM and during VM execution. See Section 7.12, “VBoxManage startvm”.

7.8.2. Networking Settings

The following networking settings are available through VBoxManage modifyvm. With all these settings, the decimal number directly following the option name, 1-N in the list below, specifies the virtual network adapter whose settings should be changed.

  • --nic<1-N> none|null|nat|natnetwork|bridged|intnet|hostonly|generic: Configures the type of networking for each of the VM's virtual network cards. Options are: not present (none), not connected to the host (null), use network address translation (nat), use the new network address translation engine (natnetwork), bridged networking (bridged), or use internal networking (intnet), host-only networking (hostonly), or access rarely used sub-modes (generic). These options correspond to the modes described in Section 6.2, “Introduction to Networking Modes”.

  • --nictype<1-N> Am79C970A|Am79C973|Am79C970|82540EM|82543GC|82545EM|virtio: Enables you to specify the networking hardware that Oracle VM VirtualBox presents to the guest for a specified VM virtual network card. See Section 6.1, “Virtual Networking Hardware”.

  • --cableconnected<1-N> on|off: Enables you to temporarily disconnect a virtual network interface, as if a network cable had been pulled from a real network card. This might be useful, for example for resetting certain software components in the VM.

  • With the nictrace options, you can optionally trace network traffic by dumping it to a file, for debugging purposes.

    With --nictrace<1-N> on|off, you can enable network tracing for a particular virtual network card.

    If enabled, you must specify with --nictracefile<1-N> <filename> the absolute path of the file the trace should be logged to.

  • --nicproperty<1-N> <paramname>="paramvalue": This option, in combination with nicgenericdrv enables you to pass parameters to rarely-used network backends.

    These parameters are backend engine-specific, and are different between UDP Tunnel and the VDE backend drivers. For examples, see Section 6.8, “UDP Tunnel Networking”.

  • --nicspeed<1-N> <kbps>: Only has an effect if generic networking has been enabled for a particular virtual network card. See the --nic option. This mode enables access to rarely used networking sub-modes, such as VDE network or UDP Tunnel. This option specifies the throughput rate in KBps.

  • --nicbootprio<1-N> <priority>: Specifies the order in which NICs are tried for booting over the network, using PXE. The priority is an integer in the 0 to 4 range. Priority 1 is the highest, priority 4 is low. Priority 0, which is the default unless otherwise specified, is the lowest.

    Note that this option only has an effect when the Intel PXE boot ROM is used.

  • --nicpromisc<1-N> deny|allow-vms|allow-all: Enables you to specify how promiscuous mode is handled for the specified VM virtual network card. This setting is only relevant for bridged networking. deny, the default setting, hides any traffic not intended for the VM. allow-vms hides all host traffic from the VM, but allows the VM to see traffic to and from other VMs. allow-all removes this restriction completely.

  • --nicbandwidthgroup<1-N> none|<name>: Adds and removes an assignment of a bandwidth group for the specified virtual network interface. Specifying none removes any current bandwidth group assignment from the specified virtual network interface. Specifying <name> adds an assignment of a bandwidth group to the specified virtual network interface.

    See Section 6.10, “Limiting Bandwidth for Network Input/Output”.

  • --bridgeadapter<1-N> none|<devicename>: Only has an effect if bridged networking has been enabled for a virtual network card. See the --nic option. Use this option to specify which host interface the given virtual network interface will use. See Section 6.5, “Bridged Networking”.

  • --hostonlyadapter<1-N> none|<devicename>: Only has an effect if host-only networking has been enabled for a virtual network card. See the --nic option. Use this option to specify which host-only networking interface the given virtual network interface will use. See Section 6.7, “Host-Only Networking”.

  • --intnet<1-N> network: Only has an effect if internal networking has been enabled for a virtual network card. See the --nic option. Use this option to specify the name of the internal network. See Section 6.6, “Internal Networking”.

  • --nat-network<1-N> <network name>: If the networking type is set to natnetwork, not nat, then this setting specifies the name of the NAT network this adapter is connected to. Optional.

  • --nicgenericdrv<1-N> <backend driver>: Only has an effect if generic networking has been enabled for a virtual network card. See the --nic option. This mode enables you to access rarely used networking sub-modes, such as VDE network or UDP Tunnel.

  • --macaddress<1-N> auto|<mac>: With this option you can set the MAC address of a particular network adapter on the VM. Normally, each network adapter is assigned a random address by Oracle VM VirtualBox at VM creation.

7.8.2.1. NAT Networking Settings

The following NAT networking settings are available through VBoxManage modifyvm. With all these settings, the decimal number directly following the option name, 1-N in the list below, specifies the virtual network adapter whose settings should be changed.

7.8.3. Miscellaneous Settings

The following hardware settings, such as serial port, audio, clipboard, drag and drop, monitor, and USB settings are available through VBoxManage modifyvm:

  • --mouse <ps2|usb|usbtablet|usbmultitouch>: Specifies the mode of the mouse to be used in the VM. Available options are: ps2, usb, usbtablet, usbmultitouch.

  • --keyboard <ps2|usb>: Specifies the mode of the keyboard to be used in the VM. Available options are: ps2, usb.

  • --uart<1-N> off|<I/O base> <IRQ>: Configures virtual serial ports for the VM. See Section 3.10, “Serial Ports”.

  • --uartmode<1-N> <arg>: Controls how Oracle VM VirtualBox connects a given virtual serial port, configured with the --uartX setting, to the host on which the virtual machine is running. As described in Section 3.10, “Serial Ports”, for each such port, you can specify <arg> as one of the following options:

    • disconnected: Even though the serial port is shown to the guest, it has no "other end". This is like a real COM port without a cable.

    • server <pipename>: On a Windows host, this tells Oracle VM VirtualBox to create a named pipe on the host named <pipename> and connect the virtual serial device to it. Note that Windows requires that the name of a named pipe begins with \\.\pipe\.

      On a Linux host, instead of a named pipe, a local domain socket is used.

    • client <pipename>: Operates as for server, except that the pipe, or local domain socket, is not created by Oracle VM VirtualBox but is assumed to exist already.

    • tcpserver <port>: Configures Oracle VM VirtualBox to create a TCP socket on the host with TCP <port> and connect the virtual serial device to it. Note that UNIX-like systems require ports over 1024 for normal users.

    • tcpclient <hostname:port>: Operates as for tcpserver, except that the TCP socket is not created by Oracle VM VirtualBox, but is assumed to exist already.

    • file <file>: Redirects the serial port output to a raw file <file> specified by its absolute path on the host file system.

    • <devicename>: If, instead of the above options, the device name of a physical hardware serial port of the host is specified, the virtual serial port is connected to that hardware port. On a Windows host, the device name will be a COM port such as COM1. On a Linux host, the device name will be /dev/ttyS0 or similar. This enables you to wire up a real serial port to a virtual machine.

  • uarttype <1-N> 16450|16550A|16750: Configures the UART type for a virtual serial port. The default UART type is 16550A.

  • --lptmode<1-N> <Device>: Specifies the Device Name of the parallel port that the Parallel Port feature will be using. Use this before --lpt. This feature depends on the host operating system. For Windows hosts, use a device name such as lpt1. On Linux hosts, use a device name such as /dev/lp0.

  • --lpt<1-N> <I/O base> <IRQ>: Specifies the I/O address of the parallel port and the IRQ number that the Parallel Port feature will be using. Optional. Use this after --lptmod. I/O base address and IRQ are the values that guest sees. For example, the values avalable under guest Device Manager.

  • --audio none|null|dsound|oss|alsa|pulse|coreaudio: Specifies whether the VM should have audio support, and if so, which type. The list of supported audio types depends on the host and can be determined with VBoxManage modifyvm.

  • --audiocontroller ac97|hda|sb16: Specifies the audio controller to be used with the VM.

  • --audiocodec stac9700|ad1980|stac9221|sb16: Specifies the audio codec to be used with the VM.

  • --audioin on: Specifies whether capturing audio from the host is enabled or disabled.

  • --audioout on: Specifies whether audio playback from the guest is enabled or disabled.

  • --clipboard-mode disabled|hosttoguest|guesttohost|bidirectional: Configues how the guest or host operating system's clipboard should be shared with the host or guest. See Section 3.4, “General Settings”. This setting requires that the Guest Additions be installed in the virtual machine.

  • --clipboard-file-transfers enabled|disabled: Specifies if clipboard file transfers are allowed between host and guest OSes or not.

  • --draganddrop disabled|hosttoguest|guesttohost|bidirectional: Specifies the drag and drop mode to use between the host and the virtual machine. See Section 4.4, “Drag and Drop”. This requires that the Guest Additions be installed in the virtual machine.

  • --monitorcount <count>: Enables multi-monitor support. See Section 3.6, “Display Settings”.

  • --usb on|off: Enables and disables the VM's virtual USB controller. See Section 3.11.1, “USB Settings”.

  • --usbehci on|off: Enables and disables the VM's virtual USB 2.0 controller. See Section 3.11.1, “USB Settings”.

  • --usbxhci on|off: Enables and disables the VM's virtual USB 3.0 controller. See Section 3.11.1, “USB Settings”.

  • --usbrename <oldname> <newname>: Enables renaming of the VM's virtual USB controller from <oldname> to <newname>.

7.8.4. Recording Settings

The VBoxManage modifyvm command enables you to modify recording settings for video recording, audio recording, or both.

Use the following options to update the recording settings:

  • --recording on|off enables or disables the recording of a VM session into a WebM/VP8 file. When this option value is on, recording begins when the VM session starts.

  • --recordingscreens all|screen-ID [screen-ID ...] enables you to specify which VM screens to record. The recording for each screen that you specify is saved to its own file.

  • --recordingfile filename specifies the file in which to save the recording.

  • --recordingmaxsize MB specifies the maximum size of the recorded video file in megabytes. The recording stops when the file reaches the specified size. If this value is zero, the recording continues until you stop the recording.

  • --recordingmaxtime seconds specifies the maximum amount time to record in seconds. The recording stops after the specified number of seconds elapses. If this value is zero, the recording continues until you stop the recording.

  • --recordingopts keyword=value[,keyword=value ...] specifies additional video-recording options in a comma-separated keyword-value format. For example, foo=bar,a=b.

    Only use this option only if you are an advanced user. For information about keywords, see Oracle VM VirtualBox Programming Guide and Reference.

  • --recordingvideofps fps specifies the maximum number of video frames per second (FPS) to record. Frames that have a higher frequency are skipped. Increasing this value reduces the number of skipped frames and increases the file size.

  • --recordingvideorate bit-rate specifies the bit rate of the video in kilobits per second. Increasing this value improves the appearance of the video at the cost of an increased file size.

  • --recordingvideores widthxheight specifies the video resolution of the recorded video in pixels.

7.8.5. Remote Machine Settings

The following settings that affect remote machine behavior are available through VBoxManage modifyvm:

  • --vrde on|off: Enables and disables the VirtualBox Remote Desktop Extension (VRDE) server.

  • --vrdeproperty "TCP/Ports|Address=<value>": Sets the port numbers and IP address on the VM that the VRDE server can bind to.

    • For TCP/Ports, <value> should be a port or a range of ports that the VRDE server can bind to. default or 0 means port 3389, the standard port for RDP. See the description for the --vrdeport option in Section 7.8.5, “Remote Machine Settings”.

    • For TCP/Address, <value> should be the IP address of the host network interface that the VRDE server will bind to. If specified, the server will accept connections only on the specified host network interface. See the description for the --vrdeaddress option in Section 7.8.5, “Remote Machine Settings”.

  • --vrdeproperty "VideoChannel/Enabled|Quality|DownscaleProtection=<value>": Sets the VRDP video redirection properties.

    • For VideoChannel/Enabled, <value> can be set to "1", switching the VRDP video channel on. See VRDP Video Redirection.

    • For VideoChannel/Quality, <value> should be set between 10 and 100% inclusive, representing a JPEG compression level on the VRDE server video channel. Lower values mean lower quality but higher compression. See VRDP Video Redirection.

    • For VideoChannel/DownscaleProtection, <value> can be set to "1" to enable the videochannel downscale protection feature. When enabled, if a video's size equals the shadow buffer size, then it is regarded as a full screen video, and is displayed. But if its size is between fullscreen and the downscale threshold then it is not displayed, as it could be an application window, which would be unreadable when downscaled. When the downscale protection feature is disabled, an attempt is always made to display videos.

  • --vrdeproperty "Client/DisableDisplay|DisableInput|DisableAudio|DisableUSB=1": Disables one of the VRDE server features: Display, Input, Audio or USB respectively. To reenable a feature, use "Client/DisableDisplay=" for example. See VRDP Customization.

  • --vrdeproperty "Client/DisableClipboard|DisableUpstreamAudio=1": Disables one of the VRDE server features: Clipboard or UpstreamAudio respectively. To reenable a feature, use "Client/DisableClipboard=" for example. See VRDP Customization.

  • --vrdeproperty "Client/DisableRDPDR=1": Disables the VRDE server feature: RDP device redirection for smart cards. To reenable this feature, use "Client/DisableRDPR=".

  • --vrdeproperty "H3DRedirect/Enabled=1": Enables the VRDE server feature: 3D redirection. To disable this feature, use "H3DRedirect/Enabled=".

  • --vrdeproperty "Security/Method|ServerCertificate|ServerPrivateKey|CACertificate=<value>": Sets the desired security method and path of server certificate, path of server private key, path of CA certificate, that are used for a connection.

    • --vrdeproperty "Security/Method=<value>" sets the desired security method, which is used for a connection. Valid values are:

      • Negotiate: Both Enhanced (TLS) and Standard RDP Security connections are allowed. The security method is negotiated with the client. This is the default setting.

      • RDP: Only Standard RDP Security is accepted.

      • TLS: Only Enhanced RDP Security is accepted. The client must support TLS.

      See RDP Encryption.

    • --vrdeproperty "Security/ServerCertificate=<value>" where <value> is the absolute path of the server certificate. See RDP Encryption.

    • --vrdeproperty "Security/ServerPrivateKey=<value>" where <value> is the absolute path of the server private key. See RDP Encryption.

    • --vrdeproperty "Security/CACertificate=<value>" where <value> is the absolute path of the CA self signed certificate. See RDP Encryption.

  • --vrdeproperty "Audio/RateCorrectionMode|LogPath=<value>" sets the audio connection mode, or path of the audio logfile.

    • --vrdeproperty "Audio/RateCorrectionMode=<value>" where <value> is the desired rate correction mode. Allowed values are:

      • VRDP_AUDIO_MODE_VOID: No mode specified, use to unset any Audio mode already set.

      • VRDP_AUDIO_MODE_RC: Rate correction mode.

      • VRDP_AUDIO_MODE_LPF: Low pass filter mode.

      • VRDP_AUDIO_MODE_CS: Client sync mode to prevent underflow or overflow of the client queue.

    • --vrdeproperty "Audio/LogPath=<value>" where <value> is the absolute path of the Audio log file.

  • --vrdeextpack default|<name>: Specifies the library to use for accessing the VM remotely. The default is to use the RDP code which is part of the Oracle VM VirtualBox Extension Pack.

  • --vrdeport default|<ports>: A port or a range of ports the VRDE server can bind to. default or 0 means port 3389, the standard port for RDP. You can specify a comma-separated list of ports or ranges of ports. Use a dash between two port numbers to specify a range. The VRDE server will bind to one of the available ports from the specified list. Only one machine can use a given port at a time. For example, the option --vrdeport 5000,5010-5012 will tell the server to bind to one of following ports: 5000, 5010, 5011, or 5012.

  • --vrdeaddress <IP address>: The IP address of the host network interface the VRDE server will bind to. If specified, the server will accept connections only on the specified host network interface.

    The setting can be used to specify whether the VRDP server should accept either IPv4, IPv6, or both connections:

    • Only IPv4: --vrdeaddress "0.0.0.0"

    • Only IPv6: --vrdeaddress "::"

    • Both IPv6 and IPv4: --vrdeaddress ""

      This is the default setting.

  • --vrdeauthtype null|external|guest: Enables you to indicate use of authorization, and specify how authorization will be performed. See RDP Authentication.

  • --vrdeauthlibrary default|<name>: Specifies the library used for RDP authentication. See RDP Authentication.

  • --vrdemulticon on|off: Enables multiple connections to be made to the same VRDE server, if the server supports this feature. See Multiple Connections to the VRDP Server.

  • --vrdereusecon on|off: This specifies the VRDE server behavior when multiple connections are disabled. When this option is enabled, the server will allow a new client to connect and will drop the existing connection. When this option is disabled, the default setting, a new connection will not be accepted if there is already a client connected to the server.

  • --vrdevideochannel on|off: Enables video redirection, if it is supported by the VRDE server. See VRDP Video Redirection.

  • --vrdevideochannelquality <percent>: Specifies the image quality for video redirection. See VRDP Video Redirection.

7.8.6. Teleporting Settings

With the following commands for VBoxManage modifyvm you can configure a machine to be a target for teleporting. See Teleporting.

  • --teleporter on|off: Enables and disables the teleporter feature whereby when the machine is started, it waits to receive a teleporting request from the network instead of booting normally. Teleporting requests are received on the port and address specified using the following parameters.

  • --teleporterport <port>, --teleporteraddress <address>: These settings must be used with --teleporter. They specify the port and address the virtual machine should listen to in order to receive a teleporting request sent from another virtual machine. <port> can be any free TCP/IP port number, such as 6000. <address> can be any IP address or hostname and specifies the TCP/IP socket to bind to. The default is 0.0.0.0, which means any address.

  • --teleporterpassword <password>: If this optional setting is used, then the teleporting request will only succeed if the source machine specifies the same password as the one given with this command.

  • --teleporterpasswordfile <password>: If this optional setting is used, then the teleporting request will only succeed if the source machine specifies the same password as the one specified in the file give with this command. Use stdin to read the password from stdin.

  • --cpuid <leaf> <eax> <ebx> <ecx> <edx>: Advanced users can use this setting before a teleporting operation, to restrict the virtual CPU capabilities that Oracle VM VirtualBox presents to the guest operating system. This must be run on both the source and the target machines involved in the teleporting and will then modify what the guest sees when it executes the CPUID machine instruction. This might help with misbehaving applications that wrongly assume that certain CPU capabilities are present. The meaning of the parameters is hardware dependent, refer to the AMD or Intel processor documentation.

7.8.7. Debugging Settings

The following settings are only relevant for low-level VM debugging. Regular users will never need these settings.

  • --tracing-enabled on|off: Enables the tracebuffer. This consumes some memory for the tracebuffer and adds extra overhead.

  • --tracing-config <config-string>: Enables tracing configuration. In particular, this defines which group of tracepoints are enabled.

  • --tracing-allow-vm-access on|off: Enables and disables VM access to the tracebuffer. By default, this setting is disabled.

7.8.8. USB Card Reader Settings

The following setting defines access to a USB Card Reader by the guest environment. USB card readers are typically used for accessing data on memory cards such as CompactFlash (CF), Secure Digital (SD), or MultiMediaCard (MMC).

  • --usbcardreader on|off: Enables and disables the USB card reader interface.

7.8.9. Autostarting VMs During Host System Boot

These settings configure the VM autostart feature, which automatically starts the VM at host system boot-up. Note that there are prerequisites that need to be addressed before using this feature. See Starting Virtual Machines During System Boot.

  • --autostart-enabled on|off: Enables and disables VM autostart at host system boot-up, using the specified user name.

  • --autostart-delay <seconds>: Specifies a delay, in seconds, following host system boot-up, before the VM autostarts.

7.9. VBoxManage movevm

This command moves a virtual machine to a new location on the host.

Associated files of the virtual machine, such as settings files and disk image files, are moved to the new location. The Oracle VM VirtualBox configuration is updated automatically.

The movevm subcommand requires the name of the virtual machine which should be moved.

Also required is the type of move operation, specified by --type basic. Other types of move operation may be supported in future releases.

The --folder setting configures the new location on the host file system. Enter a relative pathname or a full pathname.

7.10. VBoxManage import

This command imports one or more virtual machines into Oracle VM VirtualBox. You can import from either of the following:

  • A virtual appliance in OVF format.

  • A cloud service, such as Oracle Cloud Infrastructure. Only a single cloud instance can be imported.

See Section 1.14, “Importing and Exporting Virtual Machines” for more details on importing VMs into Oracle VM VirtualBox.

7.10.1. Import from OVF

The import subcommand takes at least the path name of an OVF file as input and expects the disk images, if needed, to be in the same directory as the OVF file. Many additional command-line options are supported. These enable you to control in detail what is being imported and to modify the import parameters, depending on the content of the OVF file.

It is therefore recommended to first run the import subcommand with the --dry-run or -n option. This will then print a description of the appliance's contents to the screen how it would be imported into Oracle VM VirtualBox, together with the optional command-line options to influence the import behavior.

Use of the --options keepallmacs|keepnatmacs|keepdisknames option enables additional fine tuning of the import operation. The first two options enable you to specify how the MAC addresses of every virtual network card should be handled. They can either be reinitialized, which is the default setting, left unchanged (keepallmacs) or left unchanged when the network type is NAT (keepnatmacs). If you add keepdisknames all new disk images are assigned the same names as the originals, otherwise they are renamed.

As an example, the following is a screen output for a sample appliance containing a Windows XP guest:

VBoxManage import WindowsXp.ovf --dry-run
      Interpreting WindowsXp.ovf...
      OK.
      Virtual system 0:
       0: Suggested OS type: "WindowsXP"
          (change with "--vsys 0 --ostype <type>"; use "list ostypes" to list all)
       1: Suggested VM name "Windows XP Professional_1"
          (change with "--vsys 0 --vmname <name>")
       2: Suggested VM group "/"
          (change with "--vsys 0 --group <group>")
       3: Suggested VM settings file name "/home/klaus/VirtualBox VMs/dummy2 2/dummy2 2.vbox"
          (change with "--vsys 0 --settingsfile <filename>")
       4: Suggested VM base folder "/home/klaus/VirtualBox VMs"
          (change with "--vsys 0 --basefolder <path>")
       5: End-user license agreement
          (display with "--vsys 0 --eula show";
          accept with "--vsys 0 --eula accept")
       6: Number of CPUs: 1
          (change with "--vsys 0 --cpus <n>")
       7: Guest memory: 956 MB (change with "--vsys 0 --memory <MB>")
       8: Sound card (appliance expects "ensoniq1371", can change on import)
          (disable with "--vsys 0 --unit 8 --ignore")
       9: USB controller
          (disable with "--vsys 0 --unit 9 --ignore")
      10: Network adapter: orig bridged, config 2, extra type=bridged
      11: Floppy
          (disable with "--vsys 0 --unit 11 --ignore")
      12: SCSI controller, type BusLogic
          (change with "--vsys 0 --unit 12 --scsitype {BusLogic|LsiLogic}";
          disable with "--vsys 0 --unit 12 --ignore")
      13: IDE controller, type PIIX4
          (disable with "--vsys 0 --unit 13 --ignore")
      14: Hard disk image: source image=WindowsXp.vmdk,
            target path=/home/user/disks/WindowsXp.vmdk, controller=12;channel=0
          (change target path with "--vsys 0 --unit 14 --disk <path>";
          change controller with "--vsys 0 --unit 14 --controller <index>";
          change controller port with "--vsys 0 --unit 14 --port <n>";
          disable with "--vsys 0 --unit 14 --ignore")

The individual configuration items are numbered, and depending on their type support different command-line options. The import subcommand can be directed to ignore many such items with a --vsys X --unit Y --ignore option, where X is the number of the virtual system and Y the item number, as printed on the screen. X is zero, unless there are several virtual system descriptions in the appliance.

In the above example, Item #1 specifies the name of the target machine in Oracle VM VirtualBox. Items #12 and #13 specify hard disk controllers, respectively. Item #14 describes a hard disk image. In this case, the additional --controller option indicates which item the disk image should be connected to, with the default coming from the OVF file.

You can combine several items for the same virtual system using the --vsys option. For example, to import a machine as described in the OVF, but without the sound card and without the USB controller, and with the disk image connected to the IDE controller instead of the SCSI controller, use the following command:

VBoxManage import WindowsXp.ovf \
  --vsys 0 --unit 8 --ignore --unit 9 --ignore --unit 14 --controller 13

7.10.2. Import from Oracle Cloud Infrastructure

As the result of this operation, a file with the suffix .oci is downloaded to the local host. This file is a TAR archive which contains a bootable instance image in QCOW2 format and a JSON file with some metadata related to the imported instance.

The downloaded file is deleted after a successful import. If import fails, the downloaded file may not be deleted and the VBoxSVC log file may indicate the location where the file was stored.

During import the bootable image is extracted from the archive and converted into VMDK format. The JSON file is also extracted and stored in the VM machine folder.

The command syntax for importing an Oracle Cloud Infrastructure instance begins with VBoxManage import OCI:// --cloud.

You can list the available Oracle Cloud Infrastructure VM instances and their IDs by using the following command:

VBoxManage cloud --provider=OCI --profile=cloud-profile-name list instances

To import a VM from a cloud service such as Oracle Cloud Infrastructure, use the --cloud option to specify the import from the Cloud. Some of the following options are settings for the VM, for others you must enter an Oracle Cloud Identifier (OCID) for a resource. Use the Oracle Cloud Infrastructure Console to view OCIDs.

The following parameters can be specified:

  • --vmname: Specifies a new name for the imported VM. This name is used as the VM name by Oracle VM VirtualBox.

  • --cloudinstanceid: The ID of an existing instance in the Cloud.

  • --cloudprofile: Specifies the cloud profile that is used to connect to the cloud service provider. The cloud profile contains your Oracle Cloud Infrastructure account details, such as your user OCID and the fingerprint for your public key. To use a cloud profile, you must have the required permissions on Oracle Cloud Infrastructure.

  • --cloudbucket: Specifies the bucket name in which to store the object created from an instance bootable volume. In Oracle Cloud Infrastructure, a bucket is a logical container for storing objects.

The following import options have the same meaning as for OVF import:

  • --ostype: An OS type supported by Oracle VM VirtualBox. Use the VBoxManage list ostypes command to see the whole list of supported OSes. If the type was not set, the Unknown type is used.

  • --basefolder: The folder where the new VM is stored.

  • --description: A string describing the VM.

  • --memory: The amount of RAM memory assigned for the VM, in MB. If this option is not set either the default memory size for the OS type is used, or the value is taken from the Oracle Cloud Infrastructure instance.

  • --cpus: the number of virtual CPUs assigned for the VM. If this option is not set, either the default virtual CPUs setting for the OS type is used, or the value is taken from the Oracle Cloud Infrastructure instance.

The import options --disk, --controller, --scsitype, --port, --unit, --settingsfile are not valid for cloud import.

The following example shows a typical command line for importing an instance from Oracle Cloud Infrastructure:

# VBoxManage import OCI:// --cloud --vmname import_from_oci --memory 4000 \
  --cpus 3 --ostype FreeBSD_64 --cloudprofile "standard user" \
  --cloudinstanceid ocid1.instance.oc1.iad.abuwc... --cloudbucket myBucket

7.11. VBoxManage export

This command exports one or more virtual machines from Oracle VM VirtualBox. You can export to either of the following:

  • A virtual appliance in OVF format, including copying their virtual disk images to compressed VMDK.

  • A cloud service, such as Oracle Cloud Infrastructure. A single VM can be exported in VMDK format.

See Section 1.14, “Importing and Exporting Virtual Machines” for more details on exporting VMs from Oracle VM VirtualBox.

7.11.1. Export to OVF

List the machine, or the machines, that you would like to export to the same OVF file and specify the target OVF file after an additional --output or -o option. Note that the directory of the target OVF file will also receive the exported disk images in the compressed VMDK format, regardless of the original format, and should have enough disk space left for them.

Beside a simple export of a given virtual machine, you can append several product information to the appliance file. Use --product, --producturl, --vendor, --vendorurl, --version and --description to specify this additional information. For legal reasons you may add a license text or the content of a license file by using the --eula and --eulafile option respectively.

As with OVF import, you use the --vsys X option to apply these options to the correct virtual machine.

For virtualization products which are not fully compatible with the OVF standard 1.0 you can enable an OVF 0.9 legacy mode with the --legacy09 option. Other options are --ovf09, --ovf10, --ovf20.

To specify options controlling the exact content of the appliance file, you can use --options to request the creation of a manifest file, which enables detection of corrupted appliances on import, the additional export of DVD images, and the exclusion of MAC addresses. You can specify a list of options, such as --options manifest,nomacs. For details, check the help output of VBoxManage export.

7.11.2. Export to Oracle Cloud Infrastructure

By default, an exported disk image is converted into stream VMDK format. This ensures compatibility with Oracle Cloud Infrastructure.

List the machine that you want to export to Oracle Cloud Infrastructure and specify the target cloud service provider by using the --output or -o option.

To export a VM to a cloud service such as Oracle Cloud Infrastructure, use the --cloud option to specify the VM to export. This option works in the same way as the --vsys option for OVF export.

Some of the following options are settings for the VM instance. As a result, you must enter an Oracle Cloud Identifier (OCID) for a resource. Use the Oracle Cloud Infrastructure Console to view OCIDs.

  • --output/-o: Specifies the short name of the cloud service provider to which you export. For Oracle Cloud Infrastructure, enter OCI://.

  • --cloud number-of-virtual-system: Specifies a number that identifies the VM that you are exporting. Numbering starts at 0 for the first VM.

  • --vmname name: Specifies the name of the exported VM. This name is used as the VM instance name in Oracle Cloud Infrastructure.

  • --cloudprofile cloud-profile-name: Specifies the cloud profile that is used to connect to the cloud service provider. The cloud profile contains your Oracle Cloud Infrastructure account details, such as your user OCID and the fingerprint for your public key. See Section 1.15.7, “Exporting an Appliance to Oracle Cloud Infrastructure”.

    To use a cloud profile, you must have the required permissions on Oracle Cloud Infrastructure.

  • --cloudshape shape: Specifies the shape used for the VM instance. The shape defines the number of CPUs and the amount of memory allocated to the VM instance. The shape must be compatible with the exported image.

  • --clouddomain domain: Specifies the availability domain to use for the VM instance. Enter the full name of the availability domain.

  • --clouddisksize disk-size-in-GB: Specifies the disk size used for the exported disk image in gigabytes. The minimum value is 50 GB and the maximum value is 300 GB.

  • --cloudbucket bucket-name: Specifies the bucket in which to store the uploaded files. In Oracle Cloud Infrastructure, a bucket is a logical container for storing objects.

  • --cloudocivcn OCI-vcn-ID: Specifies the virtual cloud network (VCN) to use for the VM instance. Enter the OCID for the VCN.

  • --cloudocisubnet OCI-subnet-ID: Specifies the subnet of the VCN to use for the VM instance. Enter the OCID for the subnet.

  • --cloudkeepobject true | false: Specifies whether to store the exported disk image in Oracle Object Storage.

  • --cloudlaunchinstance true | false: Specifies whether to start the VM instance after the export to Oracle Cloud Infrastructure completes.

  • --cloudpublicip true | false: Specifies whether to enable a public IP address for the VM instance.

The following example shows a typical command line for exporting a VM to Oracle Cloud Infrastructure.

# VBoxManage export myVM --output OCI:// --cloud 0 --vmname myVM_Cloud \
--cloudprofile "standard user" --cloudbucket myBucket \
--cloudshape VM.Standard2.1 --clouddomain US-ASHBURN-AD-1 --clouddisksize 50  \
--cloudocivcn ocid1.vcn.oc1.iad.aaaa... --cloudocisubnet ocid1.subnet.oc1.iad.aaaa... \
--cloudkeepobject true --cloudlaunchinstance true --cloudpublicip true

7.12. VBoxManage startvm

This command starts a virtual machine that is currently in the Powered Off or Saved states.

The optional --type specifier determines whether the machine will be started in a window or whether the output should go through VBoxHeadless, with VRDE enabled or not. See VBoxHeadless, the Remote Desktop Server. The list of types is subject to change, and it is not guaranteed that all types are accepted by any product variant.

The global or per-VM default value for the VM frontend type will be taken if the type is not explicitly specified. If none of these are set, the GUI variant will be started.

The following values are allowed:

gui

Starts a VM showing a GUI window. This is the default.

headless

Starts a VM without a window for remote display only.

separate

Starts a VM with a detachable UI. Technically, it is a headless VM with user interface in a separate process. This is an experimental feature as it lacks certain functionality, such as 3D acceleration.

Note

If you experience problems with starting virtual machines with particular frontends and there is no conclusive error information, consider starting virtual machines directly by running the respective front-end, as this can give additional error information.

7.13. VBoxManage controlvm

The controlvm subcommand enables you to change the state of a virtual machine that is currently running. The following can be specified:

  • VBoxManage controlvm <vm> pause: Temporarily puts a virtual machine on hold, without permanently changing its state. The VM window is gray, to indicate that the VM is currently paused. This is equivalent to selecting the Pause item in the Machine menu of the GUI.

  • Use VBoxManage controlvm <vm> resume: Undoes a previous pause command. This is equivalent to selecting the Resume item in the Machine menu of the GUI.

  • VBoxManage controlvm <vm> reset: Has the same effect on a virtual machine as pressing the Reset button on a real computer. A cold reboot of the virtual machine is done, which immediately restarts and reboots the guest operating system. The state of the VM is not saved beforehand, and data may be lost. This is equivalent to selecting the Reset item in the Machine menu of the GUI.

  • VBoxManage controlvm <vm> poweroff: Has the same effect on a virtual machine as pulling the power cable on a real computer. The state of the VM is not saved beforehand, and data may be lost. This is equivalent to selecting the Close item in the Machine menu of the GUI, or clicking the VM window's close button, and then selecting Power Off the Machine in the displayed dialog.

    After this, the VM's state will be Powered Off. From that state, it can be started again. See Section 7.12, “VBoxManage startvm”.

  • VBoxManage controlvm <vm> savestate: Saves the current state of the VM to disk and then stops the VM. This is equivalent to selecting the Close item in the Machine menu of the GUI or clicking the VM window's close button, and then selecting Save the Machine State in the displayed dialog.

    After this, the VM's state will be Saved. From this state, it can be started again. See Section 7.12, “VBoxManage startvm”.

  • VBoxManage controlvm <vm> acpipowerbutton: Sends an ACPI shutdown signal to the VM, as if the power button on a real computer had been pressed. So long as the VM is running a fairly modern guest operating system providing ACPI support, this should trigger a proper shutdown mechanism from within the VM.

  • VBoxManage controlvm <vm> keyboardputscancode <hex> [<hex>...]: Sends commands using keycodes to the VM. Keycodes are documented in the public domain. For example: http://www.win.tue.nl/~aeb/linux/kbd/scancodes-1.html.

  • VBoxManage controlvm "VM name" teleport --hostname <name> --port <port> [--passwordfile <file> | --password <password>]: Makes the machine the source of a teleporting operation and initiates a teleport to the given target. See Teleporting. If the optional password is specified, it must match the password that was given to the modifyvm command for the target machine. See Section 7.8.6, “Teleporting Settings”.

The following extra options are available with controlvm that do not directly affect the VM's running state:

  • setlinkstate<1-N> on|off: Connects or disconnects virtual network cables from their network interfaces.

  • nic<1-N> null|nat|bridged|intnet|hostonly|generic|natnetwork[<devicename>]: Specifies the type of networking that should be made available on the specified VM virtual network card. They available types are: not connected to the host (null), use network address translation (nat), bridged networking (bridged), communicate with other virtual machines using internal networking (intnet), host-only networking (hostonly), natnetwork networking (natnetwork), or access to rarely used submodes (generic). These options correspond to the modes which are described in detail in Section 6.2, “Introduction to Networking Modes”.

  • With the nictrace options, you can optionally trace network traffic by dumping it to a file, for debugging purposes.

    nictrace<1-N> on|off: Enables network tracing for a particular virtual network card.

    Before enabling you should specify a file name to which the trace should be logged. This can be done with the nictracefile<1-N> <filename> option to VBoxManage controlvm at runtime or with the <filename> option to VBoxManage modifyvm otherwise.

  • nicpromisc<1-N> deny|allow-vms|allow-all: Specifies how the promiscious mode is handled for the specified VM virtual network card. This setting is only relevant for bridged networking. The default setting of deny hides any traffic not intended for this VM. allow-vms hides all host traffic from this VM but enables the VM to see traffic to and from other VMs. allow-all removes this restriction completely.

  • nicproperty<1-N> <paramname>="paramvalue": This option, in combination with nicgenericdrv enables you to pass parameters to rarely-used network backends.

    Those parameters are backend engine-specific, and are different between UDP Tunnel and the VDE backend drivers. See Section 6.8, “UDP Tunnel Networking”.

  • natpf<1-N> [<name>],tcp|udp,[<hostip>],<hostport>,[<guestip>], <guestport>: Specifies a NAT port-forwarding rule. See Section 6.3.1, “Configuring Port Forwarding with NAT”.

  • natpf<1-N> delete <name>: Deletes a NAT port-forwarding rule. See Section 6.3.1, “Configuring Port Forwarding with NAT”.

  • The guestmemoryballoon<balloon size in MB>: Changes the size of the guest memory balloon. This is the memory allocated by the Oracle VM VirtualBox Guest Additions from the guest operating system and returned to the hypervisor for reuse by other virtual machines. This must be specified in megabytes. See Section 4.10.1, “Memory Ballooning”.

  • usbattach<uuid|address> [--capturefile <filename>]

    and usbdetach <uuid|address> [--capturefile <filename>]: Makes host USB devices visible or invisible to the virtual machine on the fly, without the need for creating filters first. The USB devices can be specified by UUID (unique identifier) or by address on the host system. Use the --capturefile option to specify the absolute path of a file for writing activity logging data.

    You can use VBoxManage list usbhost to locate this information.

  • audioin on: Selects whether capturing audio from the host is enabled or disabled.

  • audioout on: Selects whether audio playback from the guest is enabled or disabled.

  • clipboard mode disabled|hosttoguest|guesttohost|bidirectional: Selects how the guest or host operating system's clipboard should be shared with the host or guest. See Section 3.4, “General Settings”. This requires that the Guest Additions be installed in the virtual machine.

  • clipboard filetransfers enabled|disabled: Specifies if clipboard file transfers are allowed between host and guest OSes or not.

  • draganddrop disabled|hosttoguest|guesttohost|bidirectional: Selects the current drag and drop mode being used between the host and the virtual machine. See Section 4.4, “Drag and Drop”. This requires that the Guest Additions be installed in the virtual machine.

  • vrde on|off: Enables and disables the VRDE server, if it is installed.

  • vrdeport default|<ports>: Changes the port or a range of ports that the VRDE server can bind to. default or 0 means port 3389, the standard port for RDP. See the description for the --vrdeport option in Section 7.8.5, “Remote Machine Settings”.

  • vrdeproperty "TCP/Ports|Address=<value>": Sets the port numbers and IP address on the VM to which the VRDE server can bind.

    • For TCP/Ports, <value> should be a port or a range of ports to which the VRDE server can bind. default or 0 means port 3389, the standard port for RDP. See the description for the --vrdeport option in Section 7.8.5, “Remote Machine Settings”.

    • For TCP/Address, <value>: The IP address of the host network interface that the VRDE server will bind to. If specified, the server will accept connections only on the specified host network interface. See the description for the --vrdeaddress option in Section 7.8.5, “Remote Machine Settings”.

  • vrdeproperty "VideoChannel/Enabled|Quality|DownscaleProtection=<value>": Sets the VRDP video redirection properties.

    • For VideoChannel/Enabled, <value> can be set to "1" switching the VRDP video channel on. See VRDP Video Redirection.

    • For VideoChannel/Quality, <value> should be set between 10 and 100% inclusive, representing a JPEG compression level on the VRDE server video channel. Lower values mean lower quality but higher compression. See VRDP Video Redirection.

    • For VideoChannel/DownscaleProtection, <value> can be set to "1" to enable the videochannel downscale protection feature. When enabled, if a video's size equals the shadow buffer size, then it is regarded as a full screen video, and is displayed. If its size is between fullscreen and the downscale threshold it is not displayed, as it could be an application window, which would be unreadable when downscaled. When the downscale protection feature is disabled, an attempt is always made to display videos.

  • vrdeproperty "Client/DisableDisplay|DisableInput|DisableAudio|DisableUSB=1": Disables one of the VRDE server features: Display, Input, Audio, or USB. To reenable a feature, use "Client/DisableDisplay=" for example. See VRDP Customization.

  • vrdeproperty "Client/DisableClipboard|DisableUpstreamAudio=1". Disables one of the VRDE server features: Clipboard or UpstreamAudio. To reenable a feature, use "Client/DisableClipboard=" for example. See VRDP Customization.

  • vrdeproperty "Client/DisableRDPDR=1": Disables the VRDE server feature: RDP device redirection for smart cards. To reenable this feature, use "Client/DisableRDPR=".

  • vrdeproperty "H3DRedirect/Enabled=1": Enables the VRDE server feature: 3D redirection. To disable this feature, use "H3DRedirect/Enabled=".

  • vrdeproperty "Security/Method|ServerCertificate|ServerPrivateKey|CACertificate=<value>": Sets the desired security method, path of the server certificate, path of the server private key, and path of CA certificate, used for a connection.

    • vrdeproperty "Security/Method=<value>": Sets the desired security method, which is used for a connection. Valid values are as follows:

      • Negotiate: Both Enhanced (TLS) and Standard RDP Security connections are allowed. The security method is negotiated with the client. This is the default setting.

      • RDP: Only Standard RDP Security is accepted.

      • TLS: Only Enhanced RDP Security is accepted. The client must support TLS.

      See RDP Encryption.

    • vrdeproperty "Security/ServerCertificate=<value>" where <value> is the absolute path of the server certificate. See RDP Encryption.

    • vrdeproperty "Security/ServerPrivateKey=<value>" where <value> is the absolute path of the server private key. See RDP Encryption.

    • vrdeproperty "Security/CACertificate=<value>" where <value> is the absolute path of the CA self signed certificate. See RDP Encryption.

  • vrdeproperty "Audio/RateCorrectionMode|LogPath=<value>": Sets the audio connection mode, or path of the audio logfile.

    • vrdeproperty "Audio/RateCorrectionMode=<value>" where <value> is the desired rate correction mode, allowed values are:

      • VRDP_AUDIO_MODE_VOID: No mode specified, use to unset any Audio mode already set.

      • VRDP_AUDIO_MODE_RC: Rate correction mode.

      • VRDP_AUDIO_MODE_LPF: Low pass filter mode.

      • VRDP_AUDIO_MODE_CS: Client sync mode to prevent underflow or overflow of the client queue.

    • vrdeproperty "Audio/LogPath=<value>" where <value> is the absolute path of the audio log file.

  • vrdevideochannelquality <percent>: Sets the image quality for video redirection. See VRDP Video Redirection.

  • setvideomodehint: Requests that the guest system change to a particular video mode. This requires that the Guest Additions be installed, and will not work for all guest systems.

  • screenshotpng: Takes a screenshot of the guest display and saves it in PNG format.

  • recording on|off enables or disables the recording of a VM session into a WebM/VP8 file. When this option value is on, recording begins when the VM session starts.

  • recordingscreens all|screen-ID [screen-ID ...] enables you to specify which VM screens to record. The recording for each screen that you specify is saved to its own file. You cannot modify this setting while recording is enabled.

  • recordingfile filename specifies the file in which to save the recording. You cannot modify this setting while recording is enabled.

  • recordingvideores widthxheight specifies the resolution of the recorded video in pixels. You cannot modify this setting while recording is enabled.

  • recordingvideorate bit-rate specifies the bit rate of the video in kilobits per second. Increasing this value improves the appearance of the video at the cost of an increased file size. You cannot modify this setting while recording is enabled.

  • recordingvideofps fps specifies the maximum number of video frames per second (FPS) to record. Frames that have a higher frequency are skipped. Increasing this value reduces the number of skipped frames and increases the file size. You cannot modify this setting while recording is enabled.

  • recordingmaxtime seconds specifies the maximum amount time to record in seconds. The recording stops after the specified number of seconds elapses. If this value is zero, the recording continues until you stop the recording.

  • recordingmaxsize MB specifies the maximum size of the recorded video file in megabytes. The recording stops when the file reaches the specified size. If this value is zero, the recording continues until you stop the recording. You cannot modify this setting while recording is enabled.

  • recordingopts keyword=value[,keyword=value ...] specifies additional recording options in a comma-separated keyword-value format. For example, foo=bar,a=b. You cannot modify this setting while recording is enabled.

    Only use this option only if you are an advanced user. For information about keywords, see Oracle VM VirtualBox Programming Guide and Reference.

  • setcredentials: Used for remote logins on Windows guests. See Automated Guest Logins.

  • teleport --host <name> --port <port>: Configures a VM as a target for teleporting. <name> specifies the virtual machine name. <port> specifies the port on the virtual machine which should listen for teleporting requests from other virtual machines. It can be any free TCP/IP port number, such as 6000. See Teleporting.

    • --maxdowntime <msec>: Specifies the maximum downtime, in milliseconds, for the teleporting target VM. Optional.

    • --password <password>: The teleporting request will only succeed if the source machine specifies the same password as the one given with this command. Optional.

    • --passwordfile <password file>: The teleporting request will only succeed if the source machine specifies the same password as the one specified in the password file with the path specified with this command. Use stdin to read the password from stdin. Optional.

  • plugcpu|unplugcpu <id>: If CPU hot-plugging is enabled, this setting adds and removes a virtual CPU to the virtual machine. <id> specifies the index of the virtual CPU to be added or removed and must be a number from 0 to the maximum number of CPUs configured. CPU 0 can never be removed.

  • The cpuexecutioncap <1-100>: Controls how much CPU time a virtual CPU can use. A value of 50 implies a single virtual CPU can use up to 50% of a single host CPU.

  • vm-process-priority default|flat|low|normal|high: Changes the priority scheme of the VM process. See Section 7.12, “VBoxManage startvm”.

  • webcam attach <path|alias> [<keyword=value>[;<keyword=value>...]]: Attaches a webcam to a running VM. Specify the absolute path of the webcam on the host operating system, or use its alias, obtained by using the command: VBoxManage list webcams.

    Note that alias '.0' means the default video input device on the host operating system, '.1', '.2', etc. mean first, second, etc. video input device. The device order is host-specific.

    The optional settings parameter is a ; delimited list of name-value pairs, enabling configuration of the emulated webcam device.

    The following settings are supported:

    MaxFramerate: Specifies the highest rate in frames per second, at which video frames are sent to the guest. Higher frame rates increase CPU load, so this setting can be useful when there is a need to reduce CPU load. The default setting is no maximum limit, thus enabling the guest to use all frame rates supported by the host webcam.

    MaxPayloadTransferSize: Specifies the maximum number of bytes the emulated webcam can send to the guest in one buffer. The default setting is 3060 bytes, which is used by some webcams. Higher values can slightly reduce CPU load, if the guest is able to use larger buffers. Note that higher MaxPayloadTransferSize values may be not supported by some guest operating systems.

  • webcam detach <path|alias>: Detaches a webcam from a running VM. Specify the absolute path of the webcam on the host, or use its alias obtained from the webcam list command.

    Please note the following points, relating to specific host operating systems:

    • Windows hosts: When the webcam device is detached from the host, the emulated webcam device is automatically detached from the guest.

    • Mac OS X hosts: OS X version 10.7 or newer is required.

      When the webcam device is detached from the host, the emulated webcam device remains attached to the guest and must be manually detached using the VBoxManage controlvm webcam detach command.

    • Linux hosts: When the webcam is detached from the host, the emulated webcam device is automatically detached from the guest only if the webcam is streaming video. If the emulated webcam is inactive, it should be manually detached using the VBoxManage controlvm webcam detach command.

  • webcam list: Lists webcams attached to the running VM. The output is a list of absolute paths or aliases that were used for attaching the webcams to the VM using the webcam attach command.

  • addencpassword <id> <password file>|- [--removeonsuspend <yes|no>]: Supplies an encrypted VM specified by <id> with the encryption password to enable a headless start. Either specify the absolute path of a password file on the host file system: <password file>, or use - to instruct VBoxManage to prompt the user for the encryption password.

    --removeonsuspend <yes|no>: Specifies whether to remove the passsword or keep the password in VM memory when the VM is suspended. If the VM has been suspended and the password has been removed, the user needs to resupply the password before the VM can be resumed. This feature is useful in cases where the user does not want the password to be stored in VM memory, and the VM is suspended by a host suspend event.

    Note

    On Oracle VM VirtualBox versions 5.0 and later, data stored on hard disk images can be transparently encrypted for the guest. Oracle VM VirtualBox uses the AES algorithm in XTS mode and supports 128 or 256 bit data encryption keys (DEK). The DEK is stored encrypted in the medium properties, and is decrypted during VM startup by supplying the encryption password.

    The VBoxManage encryptmedium command is used to create a DEK encrypted medium. See Encrypting Disk Images. When starting an encrypted VM from the Oracle VM VirtualBox GUI, the user will be prompted for the encryption password.

    For a headless encrypted VM start, use the following command:

              VBoxManage startvm "vmname" --type headless
            

    Then supply the required encryption password as follows:

              VBoxManage "vmname" controlvm "vmname" addencpassword ...
            

  • removeencpassword <id>: Removes encryption password authorization for password <id> for all encrypted media attached to the VM.

  • removeallencpasswords: Removes encryption password authorization for all passwords for all encrypted media attached to the VM.

  • changeuartmode <1-N>: Changes the connection mode for a given virtual serial port.

7.14. VBoxManage discardstate

This command discards the saved state of a virtual machine which is not currently running. This will cause the VM's operating system to restart next time you start it. This is the equivalent of pulling out the power cable on a physical machine, and should be avoided if possible.

7.15. VBoxManage adoptstate

If you have a Saved state file (.sav) that is separate from the VM configuration, you can use this command to adopt the file. This will change the VM to saved state and when you start it, Oracle VM VirtualBox will attempt to restore it from the saved state file you indicated. This command should only be used in special setups.

7.16. VBoxManage closemedium

This command removes a hard disk, DVD, or floppy image from a Oracle VM VirtualBox media registry.

VBoxManage closemedium      [disk|dvd|floppy] <uuid|filename>
                            [--delete]

Optionally, you can request that the image be deleted. You will get appropriate diagnostics that the deletion failed, however the image will become unregistered in any case.

7.17. VBoxManage storageattach

This command attaches, modifies, and removes a storage medium connected to a storage controller that was previously added with the storagectl command. The syntax is as follows:

VBoxManage storageattach    <uuid|vmname>
                            --storagectl <name>
                            [--port <number>]
                            [--device <number>]
                            [--type dvddrive|hdd|fdd]
                            [--medium none|emptydrive|additions|
                                      <uuid>|<filename>|host:<drive>|iscsi]
                            [--mtype normal|writethrough|immutable|shareable
                                     readonly|multiattach]
                            [--comment <text>]
                            [--setuuid <uuid>]
                            [--setparentuuid <uuid>]
                            [--passthrough on|off]
                            [--tempeject on|off]
                            [--nonrotational on|off]
                            [--discard on|off]
                            [--hotpluggable on|off]
                            [--bandwidthgroup name|none]
                            [--forceunmount]
                            [--server <name>|<ip>]
                            [--target <target>]
                            [--tport <port>]
                            [--lun <lun>]
                            [--encodedlun <lun>]
                            [--username <username>]
                            [--password <password>]
                            [--passwordfile <file>]
                            [--initiator <initiator>]
                            [--intnet]

A number of parameters are commonly required. Some parameters are required only for iSCSI targets.

The common parameters are as follows:

uuid|vmname

The VM UUID or VM Name. Mandatory.

--storagectl

Name of the storage controller. Mandatory. The list of the storage controllers currently attached to a VM can be obtained with VBoxManage showvminfo. See Section 7.5, “VBoxManage showvminfo”.

--port

The number of the storage controller's port which is to be modified. Mandatory, unless the storage controller has only a single port.

--device

The number of the port's device which is to be modified. Mandatory, unless the storage controller has only a single device per port.

--type

Define the type of the drive to which the medium is being attached, detached, or modified. This argument can only be omitted if the type of medium can be determined from either the medium given with the --medium argument or from a previous medium attachment.

--medium

Specifies what is to be attached. The following values are supported:

  • none: Any existing device should be removed from the given slot.

  • emptydrive: For a virtual DVD or floppy drive only, this makes the device slot behave like a removeable drive into which no media has been inserted.

  • additions: For a virtual DVD drive only, this attaches the VirtualBox Guest Additions image to the given device slot.

  • If a UUID is specified, it must be the UUID of a storage medium that is already known to Oracle VM VirtualBox. For example, because it has been attached to another virtual machine. See Section 7.4, “VBoxManage list” for details of how to list known media. This medium is then attached to the given device slot.

  • If a filename is specified, it must be the full path of an existing disk image in ISO, RAW, VDI, VMDK, or other format. The disk image is then attached to the given device slot.

  • host:<drive>: For a virtual DVD or floppy drive only, this connects the given device slot to the specified DVD or floppy drive on the host computer.

  • iscsi: For virtual hard disks only, this is used for specifying an iSCSI target. In this case, additional parameters must be given. These are described below.

Some of the above changes, in particular for removeable media such as floppies and CDs/DVDs, can be effected while a VM is running. Others, such as device changes or changes in hard disk device slots, require the VM to be powered off.

--mtype

Defines how this medium behaves with respect to snapshots and write operations. See Section 5.4, “Special Image Write Modes”.

--comment

An optional description that you want to have stored with this medium. For example, for an iSCSI target, "Big storage server downstairs". This is purely descriptive and not needed for the medium to function correctly.

--setuuid, --setparentuuid

Modifies the UUID or parent UUID of a medium before attaching it to a VM. This is an expert option. Inappropriate use can make the medium unusable or lead to broken VM configurations if any other VM is referring to the same media already. The most frequently used variant is --setuuid "", which assigns a new random UUID to an image. This option is useful for resolving duplicate UUID errors if you duplicated an image using a file copy utility.

--passthrough

For a virtual DVD drive only, you can enable DVD writing support. This feature is currently experimental, see Section 5.9, “CD/DVD Support”.

--tempeject

For a virtual DVD drive only, you can configure the behavior for guest-triggered medium eject. If this is set to on, the eject has only a temporary effect. If the VM is powered off and restarted the originally configured medium will be still in the drive.

--nonrotational

Enables you to enable the non-rotational flag for virtual hard disks. Some guests, such as Windows 7 or later, treat such disks like SSDs and do not perform disk fragmentation on such media.

--discard

Enables the auto-discard feature for a virtual hard disks. This specifies that a VDI image will be shrunk in response to the trim command from the guest OS. The following requirements must be met:

  • The disk format must be VDI.

  • The size of the cleared area must be at least 1 MB.

  • Oracle VM VirtualBox will only trim whole 1 MB blocks. The VDIs themselves are organized into 1 MB blocks, so this will only work if the space being trimmed is at least a 1 MB contiguous block at a 1 MB boundary. On Windows, occasional defragmentation with defrag.exe /D, or on Linux running btrfs filesystem defrag as a background cron job may be beneficial.

Note

The Guest OS must be configured to issue the trim command, and typically this means that the guest OS is made to see the disk as an SSD. Ext4 supports the -o discard mount flag. Mac OS X probably requires additional settings. Windows should automatically detect and support SSDs, at least in versions 7, 8, and 10. The Linux exFAT driver from Samsung supports the trim command.

It is unclear whether Microsoft's implementation of exFAT supports this feature, even though that file system was originally designed for flash.

Alternatively, there are other methods to issue trim. For example, the Linux fstrim command, part of the util-linux package. Earlier solutions required a user to zero out unused areas, using zerofree or similar, and to compact the disk. This is only possible when the VM is offline.

--bandwidthgroup

Sets the bandwidth group to use for the given device. See Section 5.8, “Limiting Bandwidth for Disk Images”.

--forceunmount

For a virtual DVD or floppy drive only, this forcibly unmounts the DVD/CD/Floppy or mounts a new DVD/CD/Floppy even if the previous one is locked down by the guest for reading. See Section 5.9, “CD/DVD Support”.

When iscsi is used with the --medium parameter for iSCSI support, additional parameters must or can be used. See also Section 5.10, “iSCSI Servers”.

--server

The host name or IP address of the iSCSI target. Required.

--target

Target name string. This is determined by the iSCSI target and used to identify the storage resource. Required.

--tport

TCP/IP port number of the iSCSI service on the target. Optional.

--lun

Logical Unit Number of the target resource. Optional. Often, this value is zero.

--encodedlun

Hex-encoded Logical Unit Number of the target resource. Optional. Often, this value is zero.

--username, --password, --passwordfile

Username and password, called the initiator secret, for target authentication, if required. Optional.

Note

Username and password are stored without encryption, in clear text, in the XML machine configuration file if no settings password is provided. When a settings password is specified for the first time, the password is stored in encrypted form. As an alternative to providing the password on the command line, a reference to a file containing the text can be provided using the passwordfile option.

--initiator

iSCSI Initiator. Optional.

Microsoft iSCSI Initiator is a system, such as a server that attaches to an IP network and initiates requests and receives responses from an iSCSI target. The SAN components in Microsoft iSCSI Initiator are largely analogous to Fibre Channel SAN components, and they include the following:

  • To transport blocks of iSCSI commands over the IP network, an iSCSI driver must be installed on the iSCSI host. An iSCSI driver is included with Microsoft iSCSI Initiator.

  • A gigabit Ethernet adapter that transmits 1000 megabits per second (Mbps) is recommended for the connection to an iSCSI target. Like standard 10/100 adapters, most gigabit adapters use a preexisting Category 5 or Category 6E cable. Each port on the adapter is identified by a unique IP address.

  • An iSCSI target is any device that receives iSCSI commands. The device can be an end node, such as a storage device, or it can be an intermediate device, such as a network bridge between IP and Fibre Channel devices. Each port on the storage array controller or network bridge is identified by one or more IP addresses

--intnet

If specified, connect to the iSCSI target using Internal Networking. This needs further configuration, see Access iSCSI Targets Using Internal Networking.

7.18. VBoxManage storagectl

This command attaches, modifies, and removes a storage controller. After this, virtual media can be attached to the controller with the storageattach command.

The syntax for this command is as follows:

VBoxManage storagectl       <uuid|vmname>
                            --name <name>
                            [--add ide|sata|scsi|floppy|sas|usb|pcie]
                            [--controller LSILogic|LSILogicSAS|BusLogic|
                                          IntelAhci|PIIX3|PIIX4|ICH6|I82078|
                                          USB|NVMe|VirtIO]
                            [--portcount <1-30>]
                            [--hostiocache on|off]
                            [--bootable on|off]
                            [--rename <name>]
                            [--remove]

The parameters are as follows:

uuid|vmname

The VM UUID or VM Name. Mandatory.

--name

Specifies the name of the storage controller. Mandatory.

--add

Specifies the type of the system bus to which the storage controller must be connected.

--controller

Enables a choice of chipset type being emulated for the given storage controller.

--portcount

This specifies the number of ports the storage controller should support.

--hostiocache

Configures the use of the host I/O cache for all disk images attached to this storage controller. See Section 5.7, “Host Input/Output Caching”.

--bootable

Specifies whether this controller is bootable.

--rename

Specifies a new name for the storage controller.

--remove

Removes the storage controller from the VM configuration.

7.19. VBoxManage bandwidthctl

This command creates, deletes, modifies, and shows bandwidth groups of the given virtual machine.

VBoxManage bandwidthctl    <uuid|vmname>
                           add <name> --type disk|network --limit <MBps>[k|m|g|K|M|G] |
                           set <name> --limit <MBps>[k|m|g|K|M|G] |
                           remove <name> |
                           list [--machinereadable]

The following subcommands are available:

  • add: Creates a new bandwidth group of a given type.

  • set: Modifies the limit for an existing bandwidth group.

  • remove: Deletes a bandwidth group.

  • list: Shows all bandwidth groups defined for the given VM. Use the --machinereadable option to produce the same output, but in machine readable format. This is of the form: name="value" on a line by line basis.

The parameters are as follows:

uuid|vmname

The VM UUID or VM Name. Mandatory.

--name

Name of the bandwidth group. Mandatory.

--type

Type of the bandwidth group. Mandatory. Two types are supported: disk and network. See Section 5.8, “Limiting Bandwidth for Disk Images” or Section 6.10, “Limiting Bandwidth for Network Input/Output” for the description of a particular type.

--limit

Specifies the limit for the given bandwidth group. This can be changed while the VM is running. The default unit is megabytes per second. The unit can be changed by specifying one of the following suffixes: k for kilobits per second, m for megabits per second, g for gigabits per second, K for kilobytes per second, M for megabytes per second, G for gigabytes per second.

Note

The network bandwidth limits apply only to the traffic being sent by virtual machines. The traffic being received by VMs is unlimited.

Note

To remove a bandwidth group it must not be referenced by any disks or adapters in the running VM.

7.20. VBoxManage showmediuminfo

This command shows information about a medium, notably its size, its size on disk, its type, and the virtual machines which use it.

Note

For compatibility with earlier versions of Oracle VM VirtualBox, the showvdiinfo command is also supported and mapped internally to the showmediuminfo command.

VBoxManage showmediuminfo     [disk|dvd|floppy] <uuid|filename>

The medium must be specified either by its UUID, if the medium is registered, or by its filename. Registered images can be listed using VBoxManage list hdds, VBoxManage list dvds, or VBoxManage list floppies, as appropriate. See Section 7.4, “VBoxManage list”.

7.21. VBoxManage createmedium

This command creates a new medium. The syntax is as follows:

VBoxManage createmedium     [disk|dvd|floppy]    --filename <filename>
                            [--size <megabytes>|--sizebyte <bytes>]
                            [--diffparent <uuid>|<filename>
                            [--format VDI|VMDK|VHD] (default: VDI)
                            [--variant Standard,Fixed,Split2G,Stream,ESX]

The parameters are as follows:

--filename <filename>

Specifies a file name <filename> as an absolute path on the host file system. Mandatory.

--size <megabytes>

Specifies the image capacity, in 1 MB units. Optional.

--diffparent <uuid>|<filename>

Specifies the differencing image parent, either as a UUID or by the absolute pathname of the file on the host file system. Useful for sharing a base box disk image among several VMs.

--format VDI|VMDK|VHD

Specifies the file format for the output file. Available options are VDI, VMDK, VHD. The default format is VDI. Optional.

--variant

Specifies any required file format variants for the output file. This is a comma-separated list of variant flags. Options are Standard,Fixed,Split2G,Stream,ESX. Not all combinations are supported, and specifying mutually incompatible flags results in an error message. Optional.

Note

For compatibility with earlier versions of Oracle VM VirtualBox, the createvdi and createhd commands are also supported and mapped internally to the createmedium command.

7.22. VBoxManage modifymedium

With the modifymedium command, you can change the characteristics of a disk image after it has been created.

VBoxManage modifymedium  [disk|dvd|floppy]    <uuid|filename>
                         [--type normal|writethrough|immutable|shareable|
                                 readonly|multiattach]
                         [--autoreset on|off]
                         [--property <name=[value]>]
                         [--compact]
                         [--resize <megabytes>|--resizebyte <bytes>]
                         [--move <path>]
                         [--setlocation <path>]
Note

For compatibility with earlier versions of Oracle VM VirtualBox, the modifyvdi and modifyhd commands are also supported and mapped internally to the modifymedium command.

The disk image to modify must be specified either by its UUID, if the medium is registered, or by its filename. Registered images can be listed using VBoxManage list hdds, see Section 7.4, “VBoxManage list”. A filename must be specified as a valid path, either as an absolute path or as a relative path starting from the current directory.

The following options are available:

  • With the --type argument, you can change the type of an existing image between the normal, immutable, write-through and other modes. See Section 5.4, “Special Image Write Modes”.

  • For immutable hard disks only, the --autoreset on|off option determines whether the disk is automatically reset on every VM startup. See Section 5.4, “Special Image Write Modes”. By default, autoreset is on.

  • The --compact option can be used to compact disk images. Compacting removes blocks that only contains zeroes. Using this option will shrink a dynamically allocated image. It will reduce the physical size of the image without affecting the logical size of the virtual disk. Compaction works both for base images and for differencing images created as part of a snapshot.

    For this operation to be effective, it is required that free space in the guest system first be zeroed out using a suitable software tool. For Windows guests, you can use the sdelete tool provided by Microsoft. Run sdelete -z in the guest to zero the free disk space, before compressing the virtual disk image. For Linux, use the zerofree utility which supports ext2/ext3 filesystems. For Mac OS X guests, use the diskutil secureErase freespace 0 / command from an elevated Terminal.

    Please note that compacting is currently only available for VDI images. A similar effect can be achieved by zeroing out free blocks and then cloning the disk to any other dynamically allocated format. You can use this workaround until compacting is also supported for disk formats other than VDI.

  • The --resize x option, where x is the desired new total space in megabytes enables you to change the capacity of an existing image. This adjusts the logical size of a virtual disk without affecting the physical size much.

    This option currently works only for VDI and VHD formats, and only for the dynamically allocated variants. It can only be used to expand, but not shrink, the capacity. For example, if you originally created a 10 GB disk which is now full, you can use the --resize 15360 command to change the capacity to 15 GB (15,360 MB) without having to create a new image and copy all data from within a virtual machine. Note however that this only changes the drive capacity. You will typically next need to use a partition management tool inside the guest to adjust the main partition to fill the drive.

    The --resizebyte x option does almost the same thing, except that x is expressed in bytes instead of megabytes.

  • The --move <path> option can be used to relocate a medium to a different location <path> on the host file system. The path can be either relative to the current directory or absolute.

  • The --setlocation <path> option can be used to set the new location <path> of the medium on the host file system if the medium has been moved for any reasons. The path can be either relative to the current directory or absolute.

    Note

    The new location is used as is, without any sanity checks. The user is responsible for setting the correct path.

7.23. VBoxManage clonemedium

This command duplicates a virtual disk, DVD, or floppy medium to a new medium, usually an image file, with a new unique identifier (UUID). The new image can be transferred to another host system or reimported into Oracle VM VirtualBox using the Virtual Media Manager. See Section 5.3, “The Virtual Media Manager” and Section 5.6, “Cloning Disk Images”. The syntax is as follows:

VBoxManage clonemedium      [disk|dvd|floppy] <uuid|inputfile> <uuid|outputfile>

                            [--format VDI|VMDK|VHD|RAW|<other>]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--existing]

The medium to clone as well as the target image must be described either by its UUIDs, if the mediums are registered, or by its filename. Registered images can be listed by VBoxManage list hdds. See Section 7.4, “VBoxManage list”. A filename must be specified as valid path, either as an absolute path or as a relative path starting from the current directory.

The following options are available:

--format

Set a file format for the output file different from the file format of the input file.

--variant

Set a file format variant for the output file. This is a comma-separated list of variant flags. Not all combinations are supported, and specifying inconsistent flags will result in an error message.

--existing

Perform the clone operation to an already existing destination medium. Only the portion of the source medium which fits into the destination medium is copied. This means if the destination medium is smaller than the source only a part of it is copied, and if the destination medium is larger than the source the remaining part of the destination medium is unchanged.

Note

For compatibility with earlier versions of Oracle VM VirtualBox, the clonevdi and clonehd commands are still supported and mapped internally to the clonemedium command.

7.24. VBoxManage mediumproperty

This command sets, gets, or deletes a medium property. The syntax is as follows:

VBoxManage mediumproperty [disk|dvd|floppy] set <uuid|filename>
                                                <property> <value>
  • Use <disk|dvd|floppy> to optionally specify the type of medium: disk (hard drive), dvd, or floppy.

  • Use <uuid|filename> to supply either the UUID or absolute path of the medium or image.

  • Use <property> to supply the name of the property.

  • Use <value> to supply the property value.

VBoxManage mediumproperty [disk|dvd|floppy] get <uuid|filename>
                                                <property>
  • Use <disk|dvd|floppy> to optionally specify the type of medium: disk (hard drive), dvd, or floppy.

  • Use <uuid|filename> to supply either the UUID or absolute path of the medium or image.

  • Use <property> to supply the name of the property.

VBoxManage mediumproperty [disk|dvd|floppy] delete <uuid|filename>
                                                   <property>
  • Use <disk|dvd|floppy> to optionally specify the type of medium: disk (hard drive), dvd, or floppy.

  • Use <uuid|filename> to supply either the UUID or absolute path of the medium or image.

  • Use <property> to supply the name of the property.

7.25. VBoxManage encryptmedium

This command is used to create a DEK encrypted medium or image. See Encrypting Disk Images.

The syntax is as follows:

VBoxManage encryptmedium <uuid|filename>
                         [--newpassword <file|->]
                         [--oldpassword <file|->]
                         [--cipher <cipher id>]
                         [--newpasswordid <password id>]
  • Use <uuid|filename> to supply the UUID or absolute path of the medium or image to be encrypted.

  • Use --newpassword <file|-> to supply a new encryption password. Either specify the absolute pathname of a password file on the host operating system, or - to prompt you for the password on the command line. Always use the --newpasswordid option with this option.

  • Use --oldpassword <file|-> to supply any old encryption password. Either specify the absolute pathname of a password file on the host operating system, or - to prompt you for the old password on the command line.

    Use this option to gain access to an encrypted medium or image to either change its password using --newpassword or change its encryption using --cipher.

  • Use --cipher <cipher> to specify the cipher to use for encryption. This can be either AES-XTS128-PLAIN64 or AES-XTS256-PLAIN64.

    Use this option to change any existing encryption on the medium or image, or to set up new encryption on it for the first time.

  • Use --newpasswordid <password id> to supply the new password identifier. This can be chosen by the user, and is used for correct identification when supplying multiple passwords during VM startup.

    If the user uses the same password when encrypting multiple images and also the same password identifier, the user needs to supply the password only once during VM startup.

7.26. VBoxManage checkmediumpwd

This command is used to check the current encryption password on a DEK encrypted medium or image. See Encrypting Disk Images.

The syntax is as follows:

VBoxManage checkmediumpwd <uuid|filename>
                                      <pwd file|->
  • Use <uuid|filename> to supply the UUID or absolute path of the medium or image to be checked.

  • Use <pwd file|-> to supply the password identifier to be checked. Either specify the absolute pathname of a password file on the host operating system, or - to prompt you for the password on the command line.

7.27. VBoxManage convertfromraw

This command converts a raw disk image to an Oracle VM VirtualBox Disk Image (VDI) file. The syntax is as follows:

VBoxManage convertfromraw   <filename> <outputfile>
                            [--format VDI|VMDK|VHD]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--uuid <uuid>]
VBoxManage convertfromraw   stdin <outputfile> <bytes>
                            [--format VDI|VMDK|VHD]
                            [--variant Standard,Fixed,Split2G,Stream,ESX]
                            [--uuid <uuid>]

The parameters are as follows:

--bytes

The size of the image file, in bytes, provided through stdin.

--format

Select the disk image format to create. The default format is VDI. Other options are VMDK and VHD.

--variant

Choose a file format variant for the output file. This is a comma-separated list of variant flags. Not all combinations are supported, and specifying inconsistent flags will result in an error message.

--uuid

Specify the UUID of the output file.

The stdin form of the command forces VBoxManage to read the content of the disk image from standard input. This useful when using the command in a pipe.

Note

For compatibility with earlier versions of Oracle VM VirtualBox, the convertdd command is also supported and mapped internally to the convertfromraw command.

7.28. VBoxManage getextradata/setextradata

These commands enable you to attach and retrieve string data for a virtual machine or for an Oracle VM VirtualBox configuration, by specifying global instead of a virtual machine name. You must specify a keyword as a text string to associate the data with, which you can later use to retrieve it. For example:

VBoxManage setextradata Fedora5 installdate 2006.01.01
VBoxManage setextradata SUSE10 installdate 2006.02.02

This example would associate the string "2006.01.01" with the keyword installdate for the virtual machine Fedora5, and "2006.02.02" on the machine SUSE10. You could then retrieve the information as follows:

VBoxManage getextradata Fedora5 installdate

This would return the following:

VirtualBox Command Line Management Interface Version version-number
(C) 2005-2018 Oracle Corporation
All rights reserved.

Value: 2006.01.01

You could retrieve the information for all keywords as follows:

VBoxManage getextradata Fedora5 enumerate

To remove a keyword, the setextradata command must be run without specifying data, only the keyword. For example:

VBoxManage setextradata Fedora5 installdate

7.29. VBoxManage setproperty

This command is used to change global settings which affect the entire Oracle VM VirtualBox installation. Some of these correspond to the settings in the Preferences dialog in the VirtualBox Manager. The following properties are available:

machinefolder

Specifies the default folder in which virtual machine definitions are kept. See Where Oracle VM VirtualBox Stores its Files.

hwvirtexclusive

Specifies whether Oracle VM VirtualBox will make exclusive use of the hardware virtualization extensions (Intel VT-x or AMD-V) of the host system's processor. See Hardware Virtualization. If you wish to share these extensions with other hypervisors running at the same time, you must disable this setting. Doing so has negative performance implications.

vrdeauthlibrary

Specifies which library to use when external authentication has been selected for a particular virtual machine. See RDP Authentication.

websrvauthlibrary

Specifies which library the web service uses to authenticate users. For details about the Oracle VM VirtualBox web service, see the Oracle VM VirtualBox SDK reference, Oracle VM VirtualBox Programming Interfaces.

vrdeextpack

Specifies which library implements the VirtualBox Remote Desktop Extension.

loghistorycount

Selects how many rotated VM logs are retained.

autostartdbpath

Selects the path to the autostart database. See Starting Virtual Machines During System Boot.

defaultfrontend

Selects the global default VM frontend setting. See Section 7.12, “VBoxManage startvm”.

logginglevel

Configures the VBoxSVC release logging details. See http://www.virtualbox.org/wiki/VBoxLogging.

proxymode

Configures the mode for an HTTP proxy server.

proxyurl

Configures the URL for an HTTP proxy server. Used when a manual proxy is configured using the manual setting of the proxymode property.

7.30. VBoxManage usbfilter add/modify/remove

VBoxManage usbfilter        add <index,0-N>
                          --target <uuid|vmname>global
                          --name <string>
                          --action ignore|hold (global filters only)
                         [--active yes|no (yes)]
                         [--vendorid <XXXX> (null)]
                         [--productid <XXXX> (null)]
                         [--revision <IIFF> (null)]
                         [--manufacturer <string> (null)]
                         [--product <string> (null)]
                         [--remote yes|no (null, VM filters only)]
                         [--serialnumber <string> (null)]
                         [--maskedinterfaces <XXXXXXXX>]
    
VBoxManage usbfilter        modify <index,0-N>
                          --target <uuid|vmname>global
                         [--name <string>]
                         [--action ignore|hold (global filters only)]
                         [--active yes|no]
                         [--vendorid <XXXX>]
                         [--productid <XXXX>]
                         [--revision <IIFF>]
                         [--manufacturer <string>]
                         [--product <string>]
                         [--remote yes|no (null, VM filters only)]
                         [--serialnumber <string>]
                         [--maskedinterfaces <XXXXXXXX>]
    
VBoxManage usbfilter        remove <index,0-N>
                          --target <uuid|vmname>global
    

The usbfilter commands are used for working with USB filters in virtual machines, or global filters which affect the whole Oracle VM VirtualBox setup. Global filters are applied before machine-specific filters, and may be used to prevent devices from being captured by any virtual machine. Global filters are always applied in a particular order, and only the first filter which fits a device is applied. For example, if the first global filter says to hold, or make available, a particular Kingston memory stick device and the second filter says to ignore all Kingston devices. That particular Kingston memory stick will be available to any machine with the appropriate filter, but no other Kingston device will.

When creating a USB filter using usbfilter add, you must supply three or four mandatory parameters. The index specifies the position in the list at which the filter should be placed. If there is already a filter at that position, then it and the following ones will be shifted back one place. Otherwise, the new filter will be added onto the end of the list. The target parameter selects the virtual machine that the filter should be attached to or use global to apply it to all virtual machines. name is a name for the new filter. For global filters, action says whether to allow VMs access to devices that fit the filter description (hold) or not to give them access (ignore). In addition, you should specify parameters to filter by. You can find the parameters for devices attached to your system using VBoxManage list usbhost. Finally, you can specify whether the filter should be active. For local filters, whether they are for local devices, remote devices over an RDP connection, or either.

When you modify a USB filter using usbfilter modify, you must specify the filter by index and by target, which is either a virtual machine or global. See the output of VBoxManage list usbfilters to find global filter indexes and VBoxManage showvminfo to find indexes for individual machines. The properties which can be changed are the same as for usbfilter add. To remove a filter, use usbfilter remove and specify the index and the target.

The following is a list of the additional usbfilter add and usbfilter modify options, with details of how to use them.

  • --action ignore|hold: Specifies whether devices that fit the filter description are allowed access by machines (hold), or have access denied (ignore). Applies to global filters only.

  • --active yes|no: Specifies whether the USB Filter is active or temporarily disabled. For usbfilter create the default is active.

  • --vendorid <XXXX>|"": Specifies a vendor ID filter. The string representation for an exact match has the form XXXX, where X is the hexadecimal digit, including leading zeroes.

  • --productid <XXXX>|"": Specifies a product ID filter. The string representation for an exact match has the form XXXX, where X is the hexadecimal digit, including leading zeroes.

  • --revision <IIFF>|"": Specifies a revision ID filter. The string representation for an exact match has the form IIFF, where I is the decimal digit of the integer part of the revision, and F is the decimal digit of its fractional part, including leading and trailing zeros. Note that for interval filters, it is best to use the hexadecimal form, because the revision is stored as a 16-bit packed BCD value. Therefore, the expression int:0x0100-0x0199 will match any revision from 1.0 to 1.99 inclusive.

  • --manufacturer <string>|"": Specifies a manufacturer ID filter, as a string.

  • --product <string>|"": Specifies a product ID filter, as a string.

  • --remote yes|no"": Specifies a remote filter, indicating whether the device is physically connected to a remote VRDE client or to a local host machine. Applies to VM filters only.

  • --serialnumber <string>|"": Specifies a serial number filter, as a string.

  • --maskedinterfaces <XXXXXXXX>: Specifies a masked interface filter, for hiding one or more USB interfaces from the guest. The value is a bit mask where the set bits correspond to the USB interfaces that should be hidden, or masked off. This feature only works on Linux hosts.

7.31. VBoxManage guestproperty

The guestproperty commands enable you to get or set properties of a running virtual machine. See Section 4.7, “Guest Properties”. Guest properties are arbitrary keyword-value string pairs which can be written to and read from by either the guest or the host, so they can be used as a low-volume communication channel for strings, provided that a guest is running and has the Guest Additions installed. In addition, a number of values whose keywords begin with /VirtualBox/are automatically set and maintained by the Guest Additions.

The following subcommands are available, where <vm> can either be a VM name or a VM UUID, as with the other VBoxManage commands:

  • enumerate <vm> [--patterns <pattern>]: Lists all the guest properties that are available for the given VM, including the value. This list will be very limited if the guest's service process cannot be contacted, for example because the VM is not running or the Guest Additions are not installed.

    If --patterns <pattern> is specified, it acts as a filter to only list properties that match the given pattern. The pattern can contain the following wildcard characters:

    • * (asterisk): Represents any number of characters. For example, "/VirtualBox*" would match all properties beginning with "/VirtualBox".

    • ? (question mark): Represents a single arbitrary character. For example, "fo?" would match both "foo" and "for".

    • | (pipe symbol): Can be used to specify multiple alternative patterns. For example, "s*|t*" would match anything starting with either "s" or "t".

  • get <vm> <property>: Retrieves the value of a single property only. If the property cannot be found, for example because the guest is not running, the following message is shown:

    No value set!
  • set <vm> <property> [<value> [--flags <flags>]]: Enables you to set a guest property by specifying the keyword and value. If <value> is omitted, the property is deleted. With --flags, you can specify additional behavior. You can combine several flags by separating them with commas.

    • TRANSIENT: The value will not be stored with the VM data when the VM exits.

    • TRANSRESET: The value will be deleted as soon as the VM restarts or exits.

    • RDONLYGUEST: The value can only be changed by the host, but the guest can only read it.

    • RDONLYHOST: The value can only be changed by the guest, but the host can only read it.

    • READONLY: The value cannot be changed at all.

  • wait <vm> <pattern> --timeout <timeout>: Waits for a particular value described by the pattern string to change or to be deleted or created. The pattern rules are the same as for the enumerate subcommand.

  • delete <vm> <property>: Deletes a guest property which has been set previously.

7.32. VBoxManage guestcontrol

The guestcontrol commands enable control of the guest from the host. See Section 4.9, “Guest Control of Applications” for an introduction.

The guestcontrol command has two sets of subcommands. The first set requires guest credentials to be specified, the second does not.

The first set of subcommands is of the following form:

VBoxManage guestcontrol <uuid|vmname> <sub-command>
            [--username <name> ]
            [--passwordfile <file> | --password <password>]
            [--domain <domain> ]
            [-v|--verbose] [-q|quiet] ...
    

The common options are as follows:

           [--username <name> ]
           [--passwordfile <file> | --password <password>]
           [--domain <domain> ]
           [-v|--verbose] [-q|quiet]
    

The common options for the first set of subcommands are explained in the following list.

<uuid|vmname>

Specifies the VM UUID or VM name. Mandatory.

--username <name>

Specifies the user name on guest OS under which the process should run. This user name must already exist on the guest OS. If unspecified, the host user name is used. Optional

--passwordfile <file>|--password

Specifies the absolute path on guest file system of password file containing the password for the specified user account or password for the specified user account. Optional. If both are omitted, empty password is assumed.

--domain <domain>

User domain for Windows guests. Optional.

-v|--verbose

Makes the subcommand execution more verbose. Optional

-q|--quiet

Makes the subcommand execution quieter. Optional.

The first set of subcommands are as follows:

  • run: Executes a guest program, forwarding stdout, stderr, and stdin to and from the host until it completes.

    VBoxManage guestcontrol <uuid|vmname> run [common-options]
                --exe <path to executable> [--timeout <msec>]
               [-E|--putenv <NAME>[=<VALUE>]] [--unquoted-args]
               [--ignore-operhaned-processes] [--profile]
               [--no-wait-stdout|--wait-stdout]
               [--no-wait-stderr|--wait-stderr]
               [--dos2unix] [--unix2dos]
                -- <program/arg0> [argument1] ... [argumentN]]
              
    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --exe <path to executable>

    Specifies the absolute path of the executable on the guest OS file system. Mandatory. For example: C:\Windows\System32\calc.exe.

    --timeout <msec>

    Specifies the maximum time, in microseconds, that the executable can run, during which VBoxManage receives its output. Optional. If unspecified, VBoxManage waits indefinitely for the process to end, or an error occurs.

    -E|--putenv <NAME>=<VALUE>

    Sets, modifies, and unsets environment variables in the environment in which the program will run. Optional.

    The guest process is created with the standard default guest OS environment. Use this option to modify that default environment. To set or modify a variable use: <NAME>=<VALUE>. To unset a variable use: <NAME>=

    Any spaces in names and values should be enclosed by quotes.

    To set, modify, and unset multiple variables, use multiple instances of the --E|--putenv option.

    --unquoted-args

    Disables escaped double quoting, such as \"fred\", on arguments passed to the executed program. Optional.

    --ignore-operhaned-processes

    Ignore orphaned processes. Not yet implemented. Optional.

    --profile

    Use Profile. Not yet implemented. Optional.

    --no-wait-stdout|--wait-stdout

    Does not wait or waits until the guest process ends and receives its exit code and reason/flags. In the case of --wait-stdout, VBoxManage receives its stdout while the process runs. Optional.

    --no-wait-stderr|--wait-stderr

    Does not wait or waits until the guest process ends and receives its exit code, error messages, and flags. In the case of --wait-stderr, VBoxManage receives its stderr while the process runs. Optional.

    --dos2unix

    Converts output from DOS/Windows guests to UNIX/Linux-compatible line endings, CR + LF to LF. Not yet implemented. Optional.

    --unix2dos

    Converts output from a UNIX/Linux guests to DOS/Windows-compatible line endings, LF to CR + LF. Not yet implemented. Optional.

    [-- <program/arg0> [<argument1>] ... [<argumentN>]]

    Specifies the program name, followed by one or more arguments to pass to the program. Optional.

    Any spaces in arguments should be enclosed by quotes.

    Note

    On Windows there are certain limitations for graphical applications. See Known Limitations.

    Examples of using the guestcontrol run command are as follows:

    VBoxManage --nologo guestcontrol "My VM" run --exe "/bin/ls"
              --username foo --passwordfile bar.txt --wait-stdout -- -l /usr
    VBoxManage --nologo guestcontrol "My VM" run --exe "c:\\windows\\system32\\ipconfig.exe"
              --username foo --passwordfile bar.txt --wait-stdout

    Note that the double backslashes in the second example are only required on UNIX hosts.

    Note

    For certain commands a user name of an existing user account on the guest must be specified. Anonymous executions are not supported for security reasons. A user account password, however, is optional and depends on the guest's OS security policy or rules. If no password is specified for a given user name, an empty password will be used. On certain OSes like Windows the security policy may needs to be adjusted in order to allow user accounts with an empty password set. Also, global domain rules might apply and therefore cannot be changed.

    Starting at Oracle VM VirtualBox 4.1.2 guest process execution by default is limited to serve up to five guest processes at a time. If a new guest process gets started which would exceed this limit, the oldest not running guest process will be discarded in order to be able to run that new process. Also, retrieving output from this old guest process will not be possible anymore then. If all five guest processes are still active and running, starting a new guest process will result in an appropriate error message.

    To raise or lower the guest process execution limit, either use the guest property /VirtualBox/GuestAdd/VBoxService/--control-procs-max-kept or VBoxService command line by specifying --control-procs-max-kept needs to be modified. A restart of the guest OS is required afterwards. To serve unlimited guest processes, a value of 0 needs to be set, but this is not recommended.

  • start: Executes a guest program until it completes.

    VBoxManage guestcontrol <uuid|vmname> start [common-options]
               [--exe <path to executable>] [--timeout <msec>]
               [-E|--putenv <NAME>[=<VALUE>]] [--unquoted-args]
               [--ignore-operhaned-processes] [--profile]
                -- <program/arg0> [argument1] ... [argumentN]]
              

    Where the options are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --exe <path to executable>

    Specifies the absolute path of the executable on the guest OS file system. Mandatory. For example: C:\Windows\System32\calc.exe

    --timeout <msec>

    Specifies the maximum time, in microseconds, that the executable can run. Optional. If unspecified, VBoxManage waits indefinitely for the process to end, or an error occurs.

    -E|--putenv <NAME>=<VALUE>

    Sets, modifies, and unsets environment variables in the environment in which the program will run. Optional.

    The guest process is created with the standard default guest OS environment. Use this option to modify that default environment. To set or modify a variable use: <NAME>=<VALUE>. To unset a variable use: <NAME>=

    Any spaces in names and values should be enclosed by quotes.

    To set, modify, or unset multiple variables, use multiple instances of the --E|--putenv option.

    --unquoted-args

    Disables escaped double quoting, such as \"fred\", on arguments passed to the executed program. Optional.

    --ignore-operhaned-processes

    Ignores orphaned processes. Not yet implemented. Optional.

    --profile

    Use a profile. Not yet implemented. Optional.

    [-- <program/arg0> [<argument1>] ... [<argumentN>]]

    Specifies the program name, followed by one or more arguments to pass to the program. Optional.

    Any spaces in arguments should be enclosed by quotes.

    Note

    On Windows there are certain limitations for graphical applications. See Known Limitations.

    Examples of using the guestcontrol start command are as follows:

    VBoxManage --nologo guestcontrol "My VM" start --exe "/bin/ls"
              --username foo --passwordfile bar.txt -- -l /usr
    VBoxManage --nologo guestcontrol "My VM" start --exe "c:\\windows\\system32\\ipconfig.exe"
              --username foo --passwordfile bar.txt

    Note that the double backslashes in the second example are only required on UNIX hosts.

    Note

    For certain commands a user name of an existing user account on the guest must be specified. Anonymous executions are not supported for security reasons. A user account password, however, is optional and depends on the guest's OS security policy or rules. If no password is specified for a given user name, an empty password will be used. On certain OSes like Windows the security policy may needs to be adjusted in order to allow user accounts with an empty password set. Also, global domain rules might apply and therefore cannot be changed.

    Starting at Oracle VM VirtualBox 4.1.2 guest process execution by default is limited to serve up to five guest processes at a time. If a new guest process gets started which would exceed this limit, the oldest not running guest process will be discarded in order to be able to run that new process. Also, retrieving output from this old guest process will not be possible anymore then. If all five guest processes are still active and running, starting a new guest process will result in an appropriate error message.

    To raise or lower the guest process execution limit, either use the guest property /VirtualBox/GuestAdd/VBoxService/--control-procs-max-kept or VBoxService command line by specifying --control-procs-max-kept needs to be modified. A restart of the guest OS is required afterwards. To serve unlimited guest processes, a value of 0 needs to be set, but this is not recommended.

  • copyfrom: Copies files from the guest to the host file system. Only available with Guest Additions 4.0 or later installed.

    VBoxManage guestcontrol <uuid|vmname> copyfrom [common-options]
               [--follow] [--R|recursive]
                --target-directory <host-dst-dir>
                <guest-src0> [<guest-src1> [...]] 

    Where the parameters are as follows:

    <uid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --follow

    Enables symlink following on the guest file system. Optional.

    -R|--recursive

    Enables recursive copying of files and directories from the specified guest file system directory. Optional.

    --target-directory <host-dst-dir>

    Specifies the absolute path of the host file system destination directory. Mandatory. For example: C:\Temp.

    <guest-src0> [<guest-src1> [...]]

    Specifies the absolute paths of guest file system files to be copied. Mandatory. For example: C:\Windows\System32\calc.exe. Wildcards can be used in the expressions. For example: C:\Windows\System*\*.dll.

  • copyto: Copies files from the host to the guest file system. Only available with Guest Additions 4.0 or later installed.

    VBoxManage guestcontrol <uuid|vmname> copyto [common-options]
               [--follow] [--R|recursive]
                --target-directory <guest-dst>
                <host-src0> [<host-src1> [...]] 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --follow

    Enables symlink following on the host file system. Optional.

    -R|--recursive

    Enables recursive copying of files and directories from the specified host file system directory. Optional.

    --target-directory <guest-dst>

    Specifies the absolute path of the guest file system destination directory. Mandatory. For example: C:\Temp.

    <host-src0> [<host-src1> [...]]

    Specifies the absolute paths of host file system files to be copied. Mandatory. For example: C:\Windows\System32\calc.exe. Wildcards can be used in the expressions. For example: C:\Windows\System*\*.dll.

  • md|mkdir|createdir|createdirectory: Creates one or more directories on the guest file system. Only available with Guest Additions 4.0 or later installed.

    VBoxManage guestcontrol <uuid|vmname>  md|mkdir|createdir|createdirectory [common-options]
                [--parents] [--mode <mode>]
                <guest-dir0> [<guest-dir1> [...]] 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --parents

    Creates any absent parent directories of the specified directory. Optional.

    For example: If specified directory is D:\Foo\Bar and D:\Foo is absent, it will be created. In such a case, had the --parents option not been used, this command would have failed.

    --mode <mode>

    Specifies the permission mode on the specified directories, and any parents, if the --parents option is used. Currently octal modes only, such as. 0755, are supported.

    <guest-dir0> [<guest-dir1> [...]]

    Specifies a list of absolute paths of directories to be created on guest file system. Mandatory. For example: D:\Foo\Bar.

    All parent directories must already exist unless the switch --parents is used. For example, in the above example D:\Foo. The specified user must have sufficient rights to create the specified directories, and any parents that need to be created.

  • rmdir|removedir|removedirectory: Deletes specified guest file system directories. Only available with installed Guest Additions 4.3.2 and later.

    VBoxManage guestcontrol <uuid|vmname> rmdir|removedir|removedirectory [common-options]
               [--recursive|-R]
                <guest-dir0> [<guest-dir1> [...]]
              

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --recursive

    Recursively removes directories and contents. Optional.

    <guest-dir0> [<guest-dir1> [...]]

    Specifies a list of the absolute paths of directories to be deleted on guest file system. Mandatory. Wildcards are allowed. For example: D:\Foo\*Bar. The specified user must have sufficient rights to delete the specified directories.

  • rm|removefile: Deletes specified files on the guest file system. Only available with installed Guest Additions 4.3.2 and later.

    VBoxManage guestcontrol <uuid|vmname> rm|removefile [common-options]
               [-f|--force]
                <guest-file0> [<guest-file1> [...]] 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    -f|--force

    Enforce operation and override any requests for confirmations. Optional.

    <guest-file0> [<guest-file1> [...]]

    Specifies a list of absolute paths of files to be deleted on guest file system. Mandatory. Wildcards are allowed. For example: D:\Foo\Bar\text*.txt. The specified user should have sufficient rights to delete the specified files.

  • mv|move|ren|rename: Renames files and/or directories on the guest file system. Only available with installed Guest Additions 4.3.2 and later.

    VBoxManage guestcontrol <uuid|vmname> mv|move|ren|rename [common-options]
               <guest-source0> [<guest-source1> [...]] <guest-dest>

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    <guest-source0> [<guest-source1> [...]]

    Specifies absolute paths of files or a single directory to be moved and renamed on guest file system. Mandatory. Wildcards are allowed in file names. The specified user should have sufficient rights to access the specified files.

    <dest>

    Specifies the absolute path of the destination file or directory to which the files are to be moved. Mandatory. If only one file to be moved, <dest> can be file or directory, else it must be a directory. The specified user must have sufficient rights to access the destination file or directory.

  • mktemp|createtemp|createtemporary: Creates a temporary file or directory on the guest file system, to assist subsequent copying of files from the host to the guest file systems. By default, the file or directory is created in the guest's platform specific temp directory. Not currently supported. Only available with installed Guest Additions 4.2 and later.

    VBoxManage guestcontrol <uuid|vmname> mktemp|createtemp|createtemporary [common-options]
               [--directory] [--secure] [--mode <mode>] [--tmpdir <directory>]
                <template>
                

    The parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --directory

    Creates a temporary directory instead of a file, specified by the <template> parameter. Optional.

    --secure

    Enforces secure file and directory creation. Optional. The permission mode is set to 0755. Operation fails if it cannot be performed securely.

    --mode <mode>

    Specifies the permission mode of the specified directory. Optional. Currently only octal modes, such as 0755, are supported.

    --tmpdir <directory>

    Specifies the absolute path of the directory on the guest file system where the file or directory specified will be created. Optional. If unspecified, the platform-specific temp directory is used.

    <template>

    Specifies a file name without a directory path, containing at least one sequence of three consecutive X characters, or ending in X. Mandatory.

  • stat: Displays file or file system statuses on the guest.

    VBoxManage guestcontrol <uuid|vmname> stat [common-options]
               <file0> [<file1> [...]]

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    <file0> [<file1> [...]]

    Specifies absolute paths of files or file systems on the guest file system. Mandatory. For example: /home/foo/a.out. The specified user should have sufficient rights to access the specified files or file systems.

The second set of subcommands is of the form:

VBoxManage guestcontrol <uuid|vmname> <sub-command>
           [-v|--verbose] [-q|quiet] ...
    

The common options are as follows:

            [-v|--verbose] [-q|--quiet]
    

Details of the common options for the second set of subcommands are as follows:

-v|--verbose

Makes the subcommand execution more verbose. Optional.

-q|--quiet

Makes the subcommand execution quieter. Optional.

The second set of subcommands are as follows:

  • list: Lists guest control configuration and status data. For example: open guest sessions, guest processes, and files.

    VBoxManage guestcontrol <uuid|vmname> list [common-opts]
               <all|sessions|processes|files> 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    all|sessions|processes|files

    Indicates whether to list all available data or guest sessions, processes or files. Mandatory.

  • closeprocess: Terminates guest processes specified by PIDs running in a guest session, specified by the session ID or name.

    VBoxManage guestcontrol <uuid|vmname> closeprocess [common-options]
               --session-id <ID> | --session-name <name or pattern>
               <PID0> [<PID1> [...]] 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --session-id <ID>

    Specifies the guest session by its ID. Optional.

    --session-name <name or pattern>

    Specifies the guest session by its name, or multiple sessions using a pattern containing wildcards. Optional.

    <PID0> [<PID1> [...]]

    Specifies a list of process identifiers (PIDs) of guest processes to be terminated. Mandatory.

  • closesession: Closes specified guest sessions, specified either by session ID or name.

    VBoxManage guestcontrol <uuid|vmname> closesession [common-options]
               --session-id <ID> | --session-name <name or pattern> | --all 

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --session-id <ID>

    Specifies the guest session to be closed by ID. Optional.

    --session-name <name or pattern>

    Specifies the guest session to be closed by name. Optional. Multiple sessions can be specified by using a pattern containing wildcards.

    --all

    Close all guest sessions. Optional.

  • updatega|updateadditions|updateguestadditions: Ugrades Guest Additions already installed on the guest. Only available for already installed Guest Additions 4.0 and later.

    VBoxManage guestcontrol <uuid|vmname> updatega|updateadditions|updateguestadditions
               [common-options]
               [--source <New .ISO path>]
               [--wait-start]
               [-- <argument0> [<argument1> [...]]]

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

    --source <New .ISO path>

    Specifies the absolute path on the guest file system of the .ISO file for the Guest Additions update. Mandatory.

    --wait-start

    Indicates that VBoxManage starts the usual updating process on the guest and then waits until the actual Guest Additions updating begins, at which point VBoxManage self-terminates. Optional.

    Default behavior is that VBoxManage waits for completion of the Guest Additions update before terminating. Use of this option is sometimes necessary, as a running VBoxManage can affect the interaction between the installer and the guest OS.

    [-- <argument0> [<argument1> [...]]]

    Specifies optional command line arguments to be supplied to the Guest Additions updater. Useful for retrofitting features which are not currently installed.

    Arguments containing spaces should be enclosed by quotes.

  • watch: Prints current guest control activity.

    VBoxManage guestcontrol <uuid|vmname> watch [common-options]
              

    Where the parameters are as follows:

    <uuid|vmname>

    Specifies the VM UUID or VM name. Mandatory.

7.33. VBoxManage metrics

This command supports monitoring the usage of system resources. Resources are represented by various metrics associated with the host system or a particular VM. For example, the host system has a CPU/Load/User metric that shows the percentage of time CPUs spend executing in user mode over a specific sampling period.

Metric data is collected and retained internally. It may be retrieved at any time with the VBoxManage metrics query subcommand. The data is available as long as the background VBoxSVC process is alive. That process terminates shortly after all VMs and frontends have been closed.

By default no metrics are collected at all. Metrics collection does not start until VBoxManage metrics setup is invoked with a proper sampling interval and the number of metrics to be retained. The interval is measured in seconds. For example, to enable collecting the host processor and memory usage metrics every second and keeping the five most current samples, the following command can be used:

VBoxManage metrics setup --period 1 --samples 5 host CPU/Load,RAM/Usage

Metric collection can only be enabled for started VMs. Collected data and collection settings for a particular VM will disappear as soon as it shuts down. Use the VBoxManage metrics list subcommand to see which metrics are currently available. You can also use the --list option with any subcommand that modifies metric settings to find out which metrics were affected.

Note that the VBoxManage metrics setup subcommand discards all samples that may have been previously collected for the specified set of objects and metrics.

To enable or disable metrics collection without discarding the data, VBoxManage metrics enable and VBoxManage metrics disable subcommands can be used. Note that these subcommands expect metrics as parameters, not submetrics such as CPU/Load or RAM/Usage. In other words enabling CPU/Load/User while disabling CPU/Load/Kernel is not supported.

The host and VMs have different sets of associated metrics. Available metrics can be listed with VBoxManage metrics list subcommand.

A complete metric name may include an aggregate function. The name has the following form: Category/Metric[/SubMetric][:aggregate]. For example, RAM/Usage/Free:min stands for the minimum amount of available memory over all retained data if applied to the host object.

Subcommands may apply to all objects and metrics or can be limited to one object and a list of metrics. If no objects or metrics are given in the parameters, the subcommands will apply to all available metrics of all objects. You may use an asterisk "*" to explicitly specify that the command should be applied to all objects or metrics. Use host as the object name to limit the scope of the command to host-related metrics. To limit the scope to a subset of metrics, use a metric list with names separated by commas.

For example, to query metric data on the CPU time spent in user and kernel modes by the virtual machine named test, use the following command:

VBoxManage metrics query test CPU/Load/User,CPU/Load/Kernel

The following list summarizes the available subcommands:

list

Shows the parameters of the currently existing metrics. Note that VM-specific metrics are only available when a particular VM is running.

setup

Sets the interval between taking two samples of metric data and the number of samples retained internally. The retained data is available for displaying with the query subcommand. The --list option shows which metrics have been modified as the result of the command execution.

enable

Resumes data collection after it has been stopped with the disable subcommand. Note that specifying submetrics as parameters will not enable underlying metrics. Use --list to find out if the command worked as expected.

disable

Suspends data collection without affecting collection parameters or collected data. Note that specifying submetrics as parameters will not disable underlying metrics. Use --list to find out if the command worked as expected.

query

Retrieves and displays the currently retained metric data.

Note

The query subcommand does not remove or flush retained data. If you query often enough you will see how old samples are gradually being phased out by new samples.

collect

Sets the interval between taking two samples of metric data and the number of samples retained internally. The collected data is displayed periodically until Ctrl+C is pressed, unless the --detach option is specified. With the --detach option, this subcommand operates the same way as setup does. The --list option shows which metrics match the specified filter.

7.34. VBoxManage natnetwork

NAT networks use the Network Address Translation (NAT) service, which works in a similar way to a home router. It groups systems using it into a network and prevents outside systems from directly accessing those inside, while letting systems inside communicate with each other and outside systems using TCP and UDP over IPv4 and IPv6.

A NAT service is attached to an internal network. Virtual machines to make use of one should be attached to it. The name of an internal network is chosen when the NAT service is created, and the internal network will be created if it does not already exist. The following is an example command to create a NAT network:

VBoxManage natnetwork add --netname natnet1 --network "192.168.15.0/24" --enable

Here, natnet1 is the name of the internal network to be used and 192.168.15.0/24 is the network address and mask of the NAT service interface. By default, in this static configuration the gateway will be assigned the address 192.168.15.1, the address after the interface address, though this is subject to change.

To add a DHCP server to the NAT network after creation, run the following command:

VBoxManage natnetwork modify --netname natnet1 --dhcp on

The subcommands for VBoxManage natnetwork are as follows:

VBoxManage natnetwork add --netname <name>
                         [--network <network>]
                         [--enable|--disable]
                         [--dhcp on|off]
                         [--port-forward-4 <rule>]
                         [--loopback-4 <rule>]
                         [--ipv6 on|off]
                         [--port-forward-6 <rule>]
                         [--loopback-6 <rule>]
    

VBoxManage natnetwork add: Creates a new internal network interface, and adds a NAT network service. This command is a prerequisite for enabling attachment of VMs to the NAT network. Parameters are as follows:

--netname <name>

Where <name> is the name of the new internal network interface on the host OS.

--network <network>

Where <network> specifies the static or DHCP network address and mask of the NAT service interface. The default is a static network address.

--enable|--disable

Enables and disables the NAT network service.

--dhcp on|off

Enables and disables a DHCP server specified by --netname. Use of this option also indicates that it is a DHCP server.

--port-forward-4 <rule>

Enables IPv4 port forwarding, with a rule specified by <rule>.

--loopback-4 <rule>

Enables the IPv4 loopback interface, with a rule specified by <rule>.

--ipv6 on|off

Enables and disables IPv6. The default setting is IPv4, disabling IPv6 enables IPv4.

--port-forward-6 <rule>

Enables IPv6 port forwarding, with a rule specified by <rule>.

--loopback-6 <rule>

Enables the IPv6 loopback interface, with a rule specified by <rule>.

VBoxManage natnetwork remove --netname <name> 

VBoxManage natnetwork remove: Removes a NAT network service. Parameters are as follows:

--netname <name>

Where <name> specifies an existing NAT network service. Does not remove any DHCP server enabled on the network.

VBoxManage natnetwork modify --netname <name>
                            [--network <network>]
                            [--enable|--disable]
                            [--dhcp on|off]
                            [--port-forward-4 <rule>]
                            [--loopback-4 <rule>]
                            [--ipv6 on|off]
                            [--port-forward-6 <rule>]
                            [--loopback-6 <rule>]
    

VBoxManage natnetwork modify: Modifies an existing NAT network service. Parameters are as follows:

--netname <name>

Where <name> specifies an existing NAT network service.

--network <network>

Where <network> specifies the new static or DHCP network address and mask of the NAT service interface. The default is a static network address.

--enable|--disable

Enables and disables the NAT network service.

--dhcp on|off

Enables and disables a DHCP server. If a DHCP server is not present, using enable adds a new DHCP server.

--port-forward-4 <rule>

Enables IPv4 port forwarding, with a rule specified by <rule>.

--loopback-4 <rule>

Enables the IPv4 loopback interface, with a rule specified by <rule>.

--ipv6 on|off

Enables and disables IPv6. The default setting is IPv4, disabling IPv6 enables IPv4.

--port-forward-6 <rule>

Enables IPv6 port forwarding, with a rule specified by <rule>.

--loopback-6 <rule>

Enables IPv6 loopback interface, with a rule specified by <rule>.

VBoxManage natnetwork start --netname <name>
    

VBoxManage natnetwork start: Starts the specified NAT network service and any associated DHCP server. Parameters are as follows:

--netname <name>

Where <name> specifies an existing NAT network service.

VBoxManage natnetwork stop --netname <name>
    

VBoxManage natnetwork stop: Stops the specified NAT network service and any DHCP server. Parameters are as follows:

--netname <name>

Where <name> specifies an existing NAT network service.

VBoxManage natnetwork list [<pattern>] 

VBoxManage natnetwork list: Lists all NAT network services, with optional filtering. Parameters are as follows:

[<pattern>]

Where <pattern> is an optional filtering pattern.

7.35. VBoxManage hostonlyif

The hostonlyif command enables you to change the IP configuration of a host-only network interface. For a description of host-only networking, see Section 6.7, “Host-Only Networking”. Each host-only interface is identified by a name and can either use the internal DHCP server or a manual IP configuration, both IP4 and IP6.

The following list summarizes the available subcommands:

ipconfig "<name>"

Configures a host-only interface.

create

Creates a new vboxnet<N> interface on the host OS. This command is essential before you can attach VMs to a host-only network.

remove vboxnet<N>

Removes a vboxnet<N> interface from the host OS.

7.36. VBoxManage usbdevsource

The usbdevsource commands enable you to add and remove USB devices globally.

The following command adds a USB device.

VBoxManage usbdevsource add <source name>
                            --backend <backend>
                            --address <address>
    

Where the command line options are as follows:

  • <source name>: Specifies the ID of the source USB device to be added. Mandatory.

  • --backend <backend>: Specifies the USB proxy service backend to use. Mandatory.

  • --address <address>: Specifies the backend specific address. Mandatory.

The following command removes a USB device.

VBoxManage usbdevsource remove <source name>
    

Where the command line options are as follows:

  • <source name>: Specifies the ID of the source USB device to be removed. Mandatory.

7.37. VBoxManage unattended

Unattended guest OS installation.

7.37.1. Synopsis

VBoxManage unattended detect {--iso=install-iso} [--machine-readable]

VBoxManage unattended install { uuid|vmname } {--iso=install-iso} [--user=login] [--password=password] [--password-file=file] [--full-user-name=name] [--key=product-key] [--install-additions] [--no-install-additions] [--additions-iso=add-iso] [--install-txs] [--no-install-txs] [--validation-kit-iso=testing-iso] [--locale=ll_CC] [--country=CC] [--time-zone=tz] [--hostname=fqdn] [--package-selection-adjustment=keyword] [--dry-run] [--auxiliary-base-path=path] [--image-index=number] [--script-template=file] [--post-install-template=file] [--post-install-command=command] [--extra-install-kernel-parameters=params] [--language=lang] [--start-vm=session-type]

7.37.2. Description

7.37.2.1. unattended detect

VBoxManage unattended detect {--iso=install-iso} [--machine-readable]

Detects the guest operating system (OS) on the specified installation ISO and displays the result. This can be used as input when creating a VM for the ISO to be installed in.

--iso=install-iso

The installation ISO to run the detection on.

--machine-readable

Produce output that is simpler to parse from a script.

7.37.2.2. unattended install

VBoxManage unattended install { uuid|vmname } {--iso=install-iso} [--user=login] [--password=password] [--password-file=file] [--full-user-name=name] [--key=product-key] [--install-additions] [--no-install-additions] [--additions-iso=add-iso] [--install-txs] [--no-install-txs] [--validation-kit-iso=testing-iso] [--locale=ll_CC] [--country=CC] [--time-zone=tz] [--hostname=fqdn] [--package-selection-adjustment=keyword] [--dry-run] [--auxiliary-base-path=path] [--image-index=number] [--script-template=file] [--post-install-template=file] [--post-install-command=command] [--extra-install-kernel-parameters=params] [--language=lang] [--start-vm=session-type]

Reconfigures the specified VM for installation and optionally starts it up.

uuid|vmname

Either the UUID or the name (case sensitive) of a VM.

--iso=install-iso

The installation ISO to run the detection on.

--user=login

The login name. (default: vboxuser)

--password=password

The login password. This is used for the user given by --user as well as the root/administrator user. (default: changeme)

--password-file=file

Alternative to --password for providing the password. Special filename stdin can be used to read the password from standard input.

--full-user-name=name

The full user name. (default: --user)

--key=product-key

The guest OS product key. Not all guest OSes requires this.

--install-additions, --no-install-additions

Whether to install the VirtualBox guest additions. (default: --no-install-addations)

--additions-iso=add-iso

Path to the VirtualBox guest additions ISO. (default: installed/downloaded GAs)

--install-txs, --no-install-txs

Whether to install the test execution service (TXS) from the VirtualBox ValidationKit. This is useful when preparing VMs for testing or similar. (default: --no-install-txs)

--validation-kit-iso=testing-iso

Path to the VirtualBox ValidationKit ISO. This is required if --install-txs is specified.

--locale=ll_CC

The base locale specification for the guest, like en_US, de_CH, or nn_NO. (default: host or en_US)

--country=CC

The two letter country code if it differs from the specified by --location.

--time-zone=tz

The time zone to set up the guest OS with. (default: host time zone or UTC)

--hostname=fqdn

The fully qualified domain name of the guest machine. (default: vmname.myguest.virtualbox.org)

--package-selection-adjustment=keyword

Adjustments to the guest OS packages/components selection. This can be specfied more than once. Currently the only recognized keyword is minimal which triggers a minimal installation for some of the guest OSes.

--dry-run

Do not create any files or make any changes to the VM configuration.

--start-vm=session-type

Start the VM using the front end given by session-type. This is the same as the --type option for the startvm command, but we have add none for indicating that the VM should not be started. (default: none)

Advanced options:

--auxiliary-base-path=path

The path prefix to the media related files generated for the installation. (default: vm-config-dir/Unattended-vm-uuid-)

--image-index=number

Windows installation image index. (default: 1)

--script-template=file

The unattended installation script template. (default: IMachine::OSTypeId dependent)

--post-install-template=file

The post installation script template. (default: IMachine::OSTypeId dependent)

--post-install-command=command

A single command to run after the installation is completed. The exact format and exactly when this is run is guest OS installer dependent.

--extra-install-kernel-parameters=params

List of extra linux kernel parameters to use during the installation. (default: IMachine::OSTypeId dependent)

--language=lang

Specifies the UI language for a Windows installation. The lang is generally on the form {ll}-{CC}. See detectedOSLanguages results from VBoxManage unattended detect. (default: detectedOSLanguages[0])

7.38. VBoxManage snapshot

Manage Oracle VM VirtualBox virtual machine snapshots.

7.38.1. Synopsis

VBoxManage snapshot { uuid|vmname }

VBoxManage snapshot { uuid|vmname } take { snapshot-name } [--description=description] [--live] [--uniquename Number,Timestamp,Space,Force]

VBoxManage snapshot { uuid|vmname } delete { snapshot-name }

VBoxManage snapshot { uuid|vmname } restore { snapshot-name }

VBoxManage snapshot { uuid|vmname } restorecurrent

VBoxManage snapshot { uuid|vmname } edit { snapshot-name | --current } [--description=description] [--name=new-name]

VBoxManage snapshot { uuid|vmname } list [[--details] | [--machinereadable]]

VBoxManage snapshot { uuid|vmname } showvminfo { snapshot-name }

7.38.2. Description

The VBoxManage snapshot command manages snapshots.

Oracle VM VirtualBox uses the snapshot to capture the state of a virtual machine (VM). You can later use the snapshot to revert to the state described by the snapshot.

A snapshot is a complete copy of a VM's settings. If you take the snapshot while the VM is running, the snapshot also includes the VM's state file.

After you take a snapshot, Oracle VM VirtualBox creates a differencing hard disk for each normal hard disk that is associated with the host machine. When you restore a snapshot, Oracle VM VirtualBox uses these differencing files to quickly reset the contents of the VM's virtual hard disks.

For each VBoxManage snapshot command, you must specify the name or the universal unique identifier (UUID) of the VM for which you want to take a snapshot.

7.38.2.1. General Command Operand

uuid|vmname

Specifies the UUID or name of the VM.

7.38.2.2. Take a Snapshot of a Virtual Machine

VBoxManage snapshot { uuid|vmname } take { snapshot-name } [--description=description] [--live] [--uniquename Number,Timestamp,Space,Force]

The VBoxManage snapshot take command takes a snapshot of the current state of the VM. You must supply a name for the snapshot and can optionally supply a description. The new snapshot is inserted into the snapshots tree as a child of the current snapshot and then becomes the new current snapshot.

--description=description

Specifies a description of the snapshot.

--live

Specifies that the VM is not stopped while you create the snapshot. This operation is know as live snapshotting.

--uniquename Number,Timestamp,Space,Force

TBD.

snapshot-name

Specifies the name of the snapshot to create.

7.38.2.3. Delete a Snapshot

VBoxManage snapshot { uuid|vmname } delete { snapshot-name }

The VBoxManage snapshot delete command removes the specified snapshot.

The delete operation may take some time to finish. This is because the differencing images that are associated with the snapshot may need to be merged with their child differencing images.

snapshot-name

Specifies the UUID or name of the snapshot.

7.38.2.4. Restore a Snapshot

VBoxManage snapshot { uuid|vmname } restore { snapshot-name }

The VBoxManage snapshot restore command restores the specified snapshot. This operation resets the VM's settings and current state to that of the snapshot. The state of the VM on which you restore a snapshot is lost. When restored, the specified snapshot becomes the new current snapshot and subsequent snapshots are children of that snapshot.

snapshot-name

Specifies the UUID or name of the snapshot.

7.38.2.5. Restore the Current Snapshot

VBoxManage snapshot { uuid|vmname } restorecurrent

The VBoxManage snapshot restorecurrent command restores the current snapshot. The current snapshot is the one from which the current state is derived. This command is equivalent to using the VBoxManage snapshot restore command and specifying the name or UUID of the current snapshot.

7.38.2.6. Change the Name or Description of an Existing Snapshot

VBoxManage snapshot { uuid|vmname } edit { snapshot-name | --current } [--description=description] [--name=new-name]

The VBoxManage snapshot edit command enables you to change the name or the description of a specified snapshot.

snapshot-name

Specifies the UUID or name of the snapshot to edit.

This option is mutually exclusive with the --current option.

--current

Specifies that you update the current version of the snapshot.

This option is mutually exclusive with a specific snapshot name or its UUID.

--description=description

Specifies a new description for the snapshot.

--name=new-name

Specifies a new name for the snapshot.

7.38.2.7. List the Snapshots

VBoxManage snapshot { uuid|vmname } list [[--details] | [--machinereadable]]

The VBoxManage snapshot list command lists all the snapshots for a VM.

--details

Specifies that the output shows detailed information about the snapshot.

This option is mutually exclusive with the --machinereadable option.

--machinereadable

Specifies that the output is shown in a machine-readable format.

This option is mutually exclusive with the --details option.

7.38.2.8. Show Information About a Snapshot's Settings

VBoxManage snapshot { uuid|vmname } showvminfo { snapshot-name }

The VBoxManage snapshot showvminfo command enables you to view the VM settings that are part of an existing snapshot.

snapshot-name

Specifies the UUID or name of the snapshot.

7.38.3. Examples

The following command creates a snapshot of the ol7u4 VM. The snapshot is called ol7u4-snap-001. The command uses the --description option to provide a description of the snapshot contents.

$ VBoxManage snapshot ol7u4 take ol7u4-snap-001 \
--description="Oracle Linux 7.4"

The following command lists the snapshots for the ol7u4 VM.

$ VBoxManage snapshot ol7u4 list

The following command changes the description for the ol7u4-snap-001 snapshot of the ol7u4 VM.

$ VBoxManage snapshot ol7u4 edit ol7u4-snap-001 \
--description="Oracle Linux 7.4 with UEK4 kernel"

The following command shows VM settings for the ol7u1-snap-001 snapshot of the ol7u4 VM.

$ VBoxManage snapshot ol7u4 showvminfo ol7u4-snap-001
Name:            ol7u4
Groups:          /
Guest OS:        Oracle (64-bit)
UUID:            43349d78-2ab3-4cb8-978f-0e755cd98090
Config file:     C:\Users\user1\VirtualBox VMs\ol7u4\ol7u4.vbox
...
Snapshots:

   Name: ol7u4-snap-001 (UUID: 1cffc37d-5c37-4b86-b9c5-a0f157a55f43)
   Description: Oracle Linux 7.4 with UEK4 kernel

7.39. VBoxManage clonevm

Create a clone of an existing Oracle VM VirtualBox virtual machine.

7.39.1. Synopsis

VBoxManage clonevm { vmname|uuid } [--basefolder=basefolder] [--groups=group,...] [ --mode=machine | --mode=machinechildren | --mode=all ] [--name=name] [--options=option,...] [--register] [--snapshot=snapshot-name] [--uuid=uuid]

7.39.2. Description

The VBoxManage clonevm command creates a clone of an existing virtual machine (VM). The clone can be a full copy of the VM or a linked copy of a VM.

You must specify the name or the universal unique identifier (UUID) of the VM you want to clone.

7.39.3. Command Operand and Options

The following list describes the operand and the options that you can use with the VBoxManage clonevm command:

vmname|uuid

Specifies the name or UUID of the VM to clone.

--basefolder=basefolder

Specifies the name of the folder in which to save the configuration for the new VM.

--groups=group,...

Assigns the clone to the specified group or groups. If you specify more than one group, separate each group name with a comma.

Note that each group is identified by a group ID that starts with a slash character (/) so that groups can be nested. By default, a clone is always assigned membership to the / group.

--mode=machine|machineandchildren|all

Specifies which of the following cloning modes to use:

  • machine mode clones the current state of the existing VM without any snapshots. This is the default mode.

  • machineandchildren mode clones the snapshot specified by by the --snapshot option and all child snapshots.

  • all mode clones all snapshots and the current state of the existing VM.

--name=name

Specifies a new name for the new VM. The default value is original-name Clone where original-name is the original name of the VM.

--options=option,...

Specifies how to create the new clone.

The --options argument can be used multiple times to enable multiple options, or the options can be given as a comma separated list. The options are case insensitive.

The following options (case-insensitive) are recognized:

Link

Creates a linked clone from a snapshot only.

KeepAllMACs

Specifies that the new clone reuses the MAC addresses of each virtual network card from the existing VM.

If you do not specify this option or the --options=keepnatmacs option, the default behavior is to reinitialize the MAC addresses of each virtual network card.

KeepNATMACs

Specifies that the new clone reuses the MAC addresses of each virtual network card from the existing VM when the network type is NAT.

If you do not specify this option or the KeepAllMACs option, the default behavior is to reinitialize the MAC addresses of each virtual network card.

KeepDiskNames

Specifies that the new clone reuses the disk image names from the existing VM. By default, disk images are renamed.

KeepHwUUIDs

Specifies that the new clone reuses the hardware IDs from the existing VM. By default, new UUIDs are used.

--register

Automatically registers the new clone in this Oracle VM VirtualBox installation. You can manually register the new VM later by using the VBoxManage registervm command. See Section 7.6, “VBoxManage registervm/unregistervm”.

--snapshot=snapshot-name

Specifies the snapshot on which to base the new VM. By default, the clone is created from the current state of the specified VM.

--uuid=uuid

Specifies the UUID for the new VM. Ensure that this ID is unique for the Oracle VM VirtualBox instance if you decide to register this new VM. By default, Oracle VM VirtualBox provides a new UUID.

7.39.4. Examples

The following command creates and registers an exact clone of the ol7 VM. The clone is called ol7-dev-001.

The new clone includes all of the source VM's snapshots. The new VM also reuses all network interface MAC addresses, disk names, and UUIDs from the source VM.

$ VBoxManage clonevm ol7 --name="ol7-dev-001" --register --mode=all \
    --options=keepallmacs --options=keepdisknames --options=keephwuuids

The following command creates and registers a clone of the Snapshot 1 snapshot of the ol7 VM. The clone is called ol7-dev-002.

$ VBoxManage clonevm ol7 --name="ol7-dev-002" --register --snapshot="Snapshot 1"

7.39.5. See Also

Section 7.6, “VBoxManage registervm/unregistervm”

7.40. VBoxManage sharedfolder

Add and remove shared folders.

7.40.1. Synopsis

VBoxManage sharedfolder add { uuid | vmname } {--name=name} {--hostpath=hostpath} [--readonly] [--transient] [--automount] [--auto-mount-point=path]

VBoxManage sharedfolder remove { uuid | vmname } {--name=name} [--transient]

7.40.2. Description

Shared folders enable you to share data between the host system and guests. To use shared folders, you must first install the Oracle VM VirtualBox Guest Additions software on the guest OS.

The shared folder is associated with a share name and the full path name of the folder or directory on the host system. The share name is a unique name within the namespace of the host OS.

7.40.2.1. Add a Shared Folder

VBoxManage sharedfolder add { uuid | vmname } {--name=name} {--hostpath=hostpath} [--readonly] [--transient] [--automount] [--auto-mount-point=path]

The VBoxManage sharedfolder add command creates a shared folder. The folder you specify is on the host computer. When configured, the contents of the folder on the host system can be shared with the guest OS.

uuid|vmname

Specifies the name or UUID of the guest VM that shares a folder with the host system.

--name=name

Specifies the name of the share, which is a unique name within the namespace of the host OS.

--hostpath=hostpath

Specifies the absolute path of the folder or directory on the host OS to share with the guest OS.

--readonly

Specifies that the share has only read-only access to files at the host path.

By default, shared folders have read-write access to the files at the host path. However on Linux distributions, shared folders are mounted with 770 file permissions with the root user and the vboxsf group. By using this option, the file permissions become 700.

--transient

Specifies that the share is transient, which means that it can be added and removed at runtime and does not persist after the VM stops.

--automount

Specifies that the share is automatically mounted.

--auto-mount-point=path

Specifies the mount point of the share. This guest OS specific.

For Windows and OS/2 guest this must be an unused drive letter. If left blank (or if the drive letter is already in use), the last unused drive letter is used instead (i.e. searching from Z: thru A:).

For Linux, Solaris and other unix guest, it must be an absolute path like /mnt/mysharedfolder. If left empty the default location is /media/sf_sharename.

7.40.2.2. Remove a Shared Folder

VBoxManage sharedfolder remove { uuid | vmname } {--name=name} [--transient]

The VBoxManage sharedfolder remove command removes a shared folder.

uuid|vmname

Specifies the name or UUID of the guest VM that shares a folder with the host system.

--name=name

Specifies the name of the share to remove.

--transient

Specifies that the share is transient, which means that it can be added and removed at runtime and does not persist after the VM stops.

7.40.3. Examples

The following command creates a shared folder called o7share for the ol7 VM. The share is mounted automatically when the VM is started.

$ VBoxManage sharedfolder add ol7 --name ol7share --hostpath "/home/user/ol7share" --automount

The following command removes the shared folder called o7share for the ol7 VM.

$ VBoxManage sharedfolder remove ol7 --name ol7share

7.41. VBoxManage extpack

Extension package management.

7.41.1. Synopsis

VBoxManage extpack install [--replace] [--accept-license=sha256] { tarball }

VBoxManage extpack uninstall [--force] { name }

VBoxManage extpack cleanup

7.41.2. Description

7.41.2.1. extpack install

VBoxManage extpack install [--replace] [--accept-license=sha256] { tarball }

Installs a new extension pack on the system. This command will fail if an older version of the same extension pack is already installed. The --replace option can be used to uninstall any old package before the new one is installed.

--replace

Uninstall existing extension pack version.

--accept-license=sha256

Accept the license text with the given SHA-256 hash value.

VBoxManage will display the SHA-256 value when performing a manual installation. The hash can of course be calculated by looking inside the extension pack and using sha256sum or similar on the license file.

tarball

The file containing the extension pack to be installed.

7.41.2.2. extpack uninstall

VBoxManage extpack uninstall [--force] { name }

Uninstalls an extension pack from the system. The subcommand will also succeed in the case where the specified extension pack is not present on the system. You can use VBoxManage list extpacks to show the names of the extension packs which are currently installed.

--force

Overrides most refusals to uninstall an extension pack

name

The name of the extension pack to be uninstalled.

7.41.2.3. extpack cleanup

VBoxManage extpack cleanup

Used to remove temporary files and directories that may have been left behind if a previous install or uninstall command failed.

7.41.3. Examples

How to list extension packs:

$ VBoxManage list extpacks
Extension Packs: 1
Pack no. 0:   Oracle VM VirtualBox Extension Pack
Version:      4.1.12
Revision:     77218
Edition:
Description:  USB 2.0 Host Controller, VirtualBox RDP, PXE ROM with E1000 support.
VRDE Module:  VBoxVRDP
Usable:       true
Why unusable:

How to remove an extension pack:

$ VBoxManage extpack uninstall "Oracle VM VirtualBox Extension Pack"
0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
Successfully uninstalled "Oracle VM VirtualBox Extension Pack".

7.42. VBoxManage dhcpserver

DHCP server management.

7.42.1. Synopsis

VBoxManage dhcpserver add { --network=netname | --interface=ifname } {--server-ip=address} {--netmask=mask} {--lower-ip=address} {--upper-ip=address} { --enable | --disable }
[ [--global] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--incl-mac=address...] [--excl-mac=address...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--incl-vendor=string...] [--excl-vendor=string...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--incl-user=string...] [--excl-user=string...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--vm=name|uuid} [--nic=1-N] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]
[ {--mac-address=address} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]

VBoxManage dhcpserver modify { --network=netname | --interface=ifname } [--server-ip=address] [--lower-ip=address] [--upper-ip=address] [--netmask=mask] [ --enable | --disable ]
[ [--global] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--del-mac=address...] [--incl-mac=address...] [--excl-mac=address...] [--del-mac-wild=pattern...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--del-vendor=string...] [--incl-vendor=string...] [--excl-vendor=string...] [--del-vendor-wild=pattern...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--del-user=string...] [--incl-user=string...] [--excl-user=string...] [--del-user-wild=pattern...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--zap-conditions] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--vm=name|uuid} [--nic=1-N] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]
[ {--mac-address=address} [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]

VBoxManage dhcpserver remove { --network=netname | --interface=ifname }

VBoxManage dhcpserver restart { --network=netname | --interface=ifname }

VBoxManage dhcpserver findlease { --network=netname | --interface=ifname } {--mac-address=mac}

7.42.2. Description

The dhcpserver commands enable you to control the DHCP server that is built into VirtualBox. You may find this useful when using internal or host-only networking. Theoretically, you can also enable it for a bridged network, but that may cause conflicts with other DHCP servers in your physical network.

7.42.2.1. Common options

The subcommands of dhcpserver all operate on an internal network that can be identified via its name or in the host-only case via the host-only interface name:

--network=netname

The internal network name. This is the same as you would use as value to the VBoxManage modifyvm --intnet option when configuring a VM for internal networking. Or you see as VBoxNetworkName in the output from VBoxManage list intnets, VBoxManage list natnets, or VBoxManage list hostonlyifs.

--interface=ifname

The host only interface name. This would be same value as you would use for the VBoxManage modifyvm --hostonlyadapter option when configuring a VM to use a host-only network. The value can also be found in the Name row in VBoxManage list hostonlyifs.

7.42.2.2. dhcpserver add

VBoxManage dhcpserver add { --network=netname | --interface=ifname } {--server-ip=address} {--netmask=mask} {--lower-ip=address} {--upper-ip=address} { --enable | --disable }
[ [--global] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--incl-mac=address...] [--excl-mac=address...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--incl-vendor=string...] [--excl-vendor=string...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--incl-user=string...] [--excl-user=string...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] ...]
[ {--vm=name|uuid} [--nic=1-N] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]
[ {--mac-address=address} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] ...]

Adds a new DHCP server to a network or host-only interface.

Options configuring the DHCP server core:

--server-ip=address

The IP address the DHCP server should use.

--lower-ip=address, --upper-ip=address

The IP address range for the DHCP server to manage. This should not include the address of the DHCP server itself, but it must be in the same network as it. The boundraries are inclusive, so both the lower and upper addresses will be handed out to clients.

--netmask=mask

The network mask. Typically 255.255.255.0.

--enable, --disable

Whether to enable the DHCP server or disable it. If not specified, the server will be created in disabled state and no IP addresses handed out.

Options selecting the scope:

--global

Set the configuration scope to global. Any subsequent --set-opt options will be apply to all the DHCP clients.

--vm=vmname|uuid

Set the configuration scope to the first NIC of the specified VM. Any subsequent --set-opt options will apply just to that interface, nothing else.

--nic=1-N

Set the configuration scope to a NIC other than first of the VM specified the in --vm.

--mac-address=address

Set the configuration scope to the specified MAC address.

--group=name

Set the configuration scope to the specified group.

Options configuring the currently selected scope:

--set-opt=dhcp-opt-no value

Adds the specified DHCP option number (0-255) and value. The value format is option specific (typically human readable) and will be validated by the API and the DHCP server.

--set-opt-hex=dhcp-opt-no hexstring

Adds the specified DHCP option number (0-255) and value. The option value is specified as a raw series of hex bytes, optionally separated by colons. No validation is performed on these by the API or the DHCP server, they will be pass as specified to the client.

--force-opt=dhcp-opt-no

Forces the specified DHCP option number (0-255) onto to be sent to the client whether it requested it or not (provided the option is configured with a value at some level).

--suppress-opt=dhcp-opt-no

Prevents the specified DHCP option number (0-255) from being sent to the client when present in this or a high configuration scope.

--min-lease-time=seconds

Sets the minimum lease time for the current scope in seconds. Zero means taking the value from a higher option level or use default.

--default-lease-time=seconds

Sets the default lease time for the current scope in seconds. Zero means taking the value from a higher option level or use default.

--max-lease-time=seconds

Sets the maximum lease time for the current scope in seconds. Zero means taking the value from a higher option level or use default.

--fixed-address=address

Fixed address assignment for a --vm or --mac-address configuration scope. Any empty address turns it back to dynamic address assignment.

Options configuring group membership conditions (excludes overrides includes):

--incl-mac=address

Include the specific MAC address in the group.

--excl-mac=address

Exclude the specific MAC address from the group.

--incl-mac-wild=pattern

Include the specific MAC address pattern in the group.

--excl-mac-wild=pattern

Exclude the specific MAC address pattern from the group.

--incl-vendor=string

Include the specific vendor class ID in the group.

--excl-vendor=string

Exclude the specific vendor class ID from the group.

--incl-vendor-wild=pattern

Include the specific vendor class ID pattern in the group.

--excl-vendor-wild=pattern

Exclude the specific vendor class ID pattern from the group.

--incl-user=string

Include the specific user class ID in the group.

--excl-user=string

Exclude the specific user class ID from the group.

--incl-user-wild=pattern

Include the specific user class ID pattern in the group.

--excl-user-wild=pattern

Exclude the specific user class ID pattern from the group.

7.42.2.3. dhcpserver modify

VBoxManage dhcpserver modify { --network=netname | --interface=ifname } [--server-ip=address] [--lower-ip=address] [--upper-ip=address] [--netmask=mask] [ --enable | --disable ]
[ [--global] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--group=name} [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--del-mac=address...] [--incl-mac=address...] [--excl-mac=address...] [--del-mac-wild=pattern...] [--incl-mac-wild=pattern...] [--excl-mac-wild=pattern...] [--del-vendor=string...] [--incl-vendor=string...] [--excl-vendor=string...] [--del-vendor-wild=pattern...] [--incl-vendor-wild=pattern...] [--excl-vendor-wild=pattern...] [--del-user=string...] [--incl-user=string...] [--excl-user=string...] [--del-user-wild=pattern...] [--incl-user-wild=pattern...] [--excl-user-wild=pattern...] [--zap-conditions] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--remove-config] ...]
[ {--vm=name|uuid} [--nic=1-N] [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]
[ {--mac-address=address} [--del-opt=dhcp-opt-no...] [--set-opt=dhcp-opt-no value...] [--set-opt-hex=dhcp-opt-no hexstring...] [--force-opt=dhcp-opt-no...] [--unforce-opt=dhcp-opt-no...] [--supress-opt=dhcp-opt-no...] [--unsupress-opt=dhcp-opt-no...] [--min-lease-time=seconds] [--default-lease-time=seconds] [--max-lease-time=seconds] [--fixed-address=address] [--remove-config] ...]

This modifies an existing DHCP server configuration. It takes the same options as the add command with the addition of the following on scope configuration:

--del-opt=dhcp-opt-no

Counterpart to --set-opt that will cause the specified DHCP option number (0-255) to be deleted from the server settings. Like with --set-opt the scope of the deletion is governed by the --global, --vm, --mac-address and --group options.

--unforce-opt=dhcp-opt-no

Removes the specified DHCP option number (0-255) from the forced option list (i.e. the reverse of --force-opt). Like with --set-opt the scope of the deletion is governed by the --global, --vm, --mac-address and --group options.

--unsuppress-opt=dhcp-opt-no

Removes the specified DHCP option number (0-255) from the supressed option list (i.e. the reverse of --suppress-opt). Like with --set-opt the scope of the deletion is governed by the --global, --vm, --mac-address and --group options.

--remove-config

Removes the configuration currently being scoped. The --global scope is not removable. The configuration scope will change to --global after this option.

And the addition of these group membership condition options:

--del-mac=address

Delete the specific MAC address from the group conditions.

--del-mac-wild=pattern

Delete the specific MAC address pattern from the group conditions.

--del-vendor=string

Delete the specific vendor class ID from the group conditions.

--del-vendor-wild=pattern

Delete the specific vendor class ID pattern from the group conditions.

--del-user=string

Delete the specific user class ID pattern from the group conditions.

--del-user-wild=pattern

Delete the specific user class ID pattern from the group conditions.

--zap-conditions

Deletes all the group conditions.

7.42.2.4. dhcpserver remove

VBoxManage dhcpserver remove { --network=netname | --interface=ifname }

Removes the specified DHCP server.

7.42.2.5. dhcpserver restart

VBoxManage dhcpserver restart { --network=netname | --interface=ifname }

Restarts the specified DHCP server. The DHCP server must be running.

7.42.2.6. dhcpserver findlease

VBoxManage dhcpserver findlease { --network=netname | --interface=ifname } {--mac-address=mac}

Performs a lease database lookup. This is mainly for getting the IP address of a running VM.

--mac-address=mac

The MAC address to lookup in the lease database.

7.42.2.7. Common DHCP Options:

1 - SubnetMask

IPv4 netmask. Set to the value of the --netmask option by default.

2 - TimeOffset

UTC offset in seconds (32-bit decimal value).

3 - Routers

Space separated list of IPv4 router addresses.

4 - TimeServers

Space separated list of IPv4 time server (RFC 868) addresses.

5 - NameServers

Space separated list of IPv4 name server (IEN 116) addresses.

6 - DomainNameServers

Space separated list of IPv4 DNS addresses.

7 - LogServers

Space separated list of IPv4 log server addresses.

8 - CookieServers

Space separated list of IPv4 cookie server (RFC 865) addresses.

9 - LPRServers

Space separated list of IPv4 line printer server (RFC 1179) addresses.

10 - ImpressServers

Space separated list of IPv4 imagen impress server addresses.

11 - ResourseLocationServers

Space separated list of IPv4 resource location (RFC 887) addresses.

12 - HostName

The client name. See RFC 1035 for character limits.

13 - BootFileSize

Number of 512 byte blocks making up the boot file (16-bit decimal value).

14 - MeritDumpFile

Client core file.

15 - DomainName

Domain name for the client.

16 - SwapServer

IPv4 address of the swap server that the client should use.

17 - RootPath

The path to the root disk the client should use.

18 - ExtensionPath

Path to a file containing additional DHCP options (RFC2123).

19 - IPForwarding

Whether IP forwarding should be enabled by the client (boolean).

20 - OptNonLocalSourceRouting

Whether non-local datagrams should be forwarded by the client (boolean)

21 - PolicyFilter

List of IPv4 addresses and masks paris controlling non-local source routing.

22 - MaxDgramReassemblySize

The maximum datagram size the client should reassemble (16-bit decimal value).

23 - DefaultIPTTL

The default time-to-leave on outgoing (IP) datagrams (8-bit decimal value).

24 - PathMTUAgingTimeout

RFC1191 path MTU discovery timeout value in seconds (32-bit decimal value).

25 - PathMTUPlateauTable

RFC1191 path MTU discovery size table, sorted in ascending order (list of 16-bit decimal values).

26 - InterfaceMTU

The MTU size for the interface (16-bit decimal value).

27 - AllSubnetsAreLocal

Indicates whether the MTU size is the same for all subnets (boolean).

28 - BroadcastAddress

Broadcast address (RFC1122) for the client to use (IPv4 address).

29 - PerformMaskDiscovery

Whether to perform subnet mask discovery via ICMP (boolean).

30 - MaskSupplier

Whether to respond to subnet mask requests via ICMP (boolean).

31 - PerformRouterDiscovery

Whether to perform router discovery (RFC1256) (boolean).

32 - RouterSolicitationAddress

Where to send router solicitation requests (RFC1256) (IPv4 address).

33 - StaticRoute

List of network and router address pairs addresses.

34 - TrailerEncapsulation

Whether to negotiate the use of trailers for ARP (RTF893) (boolean).

35 - ARPCacheTimeout

The timeout in seconds for ARP cache entries (32-bit decimal value).

36 - EthernetEncapsulation

Whether to use IEEE 802.3 (RTF1042) rather than of v2 (RFC894) ethernet encapsulation (boolean).

37 - TCPDefaultTTL

Default time-to-live for TCP sends (non-zero 8-bit decimal value).

38 - TCPKeepaliveInterval

The interface in seconds between TCP keepalive messages (32-bit decimal value).

39 - TCPKeepaliveGarbage

Whether to include a byte of garbage in TCP keepalive messages for backward compatibility (boolean).

40 - NISDomain

The NIS (Sun Network Information Services) domain name (string).

41 - NISServers

Space separated list of IPv4 NIS server addresses.

42 - NTPServers

Space separated list of IPv4 NTP (RFC1035) server addresses.

43 - VendorSpecificInfo

Vendor specific information. Only accessible using --set-opt-hex.

44 - NetBIOSNameServers

Space separated list of IPv4 NetBIOS name server (NBNS) addresses (RFC1001,RFC1002).

45 - NetBIOSDatagramServers

Space separated list of IPv4 NetBIOS datagram distribution server (NBDD) addresses (RFC1001,RFC1002).

46 - NetBIOSNodeType

NetBIOS node type (RFC1001,RFC1002): 1=B-node, 2=P-node, 4=M-node, and 8=H-node (8-bit decimal value).

47 - NetBIOSScope

NetBIOS scope (RFC1001,RFC1002). Only accessible using --set-opt-hex.

48 - XWindowsFontServers

Space separated list of IPv4 X windows font server addresses.

49 - XWindowsDisplayManager

Space separated list of IPv4 X windows display manager addresses.

62 - NetWareIPDomainName

Netware IP domain name (RFC2242) (string).

63 - NetWareIPInformation

Netware IP information (RFC2242). Only accessible using --set-opt-hex.

64 - NISPlusDomain

The NIS+ domain name (string).

65 - NISPlusServers

Space separated list of IPv4 NIS+ server addresses.

66 - TFTPServerName

TFTP server name (string).

67 - BootfileName

Bootfile name (string).

68 - MobileIPHomeAgents

Space separated list of IPv4 mobile IP agent addresses.

69 - SMTPServers

Space separated list of IPv4 simple mail transport protocol (SMPT) server addresses.

70 - POP3Servers

Space separated list of IPv4 post office protocol 3 (POP3) server addresses.

71 - NNTPServers

Space separated list of IPv4 network news transport protocol (NTTP) server addresses.

72 - WWWServers

Space separated list of default IPv4 world wide web (WWW) server addresses.

73 - FingerServers

Space separated list of default IPv4 finger server addresses.

74 - IRCServers

Space separated list of default IPv4 internet relay chat (IRC) server addresses.

75 - StreetTalkServers

Space separated list of IPv4 StreetTalk server addresses.

76 - STDAServers

Space separated list of IPv4 StreetTalk directory assistance (STDA) server addresses.

78 - SLPDirectoryAgent

Addresses of one or more service location protocol (SLP) directory agent, and an indicator of whether their use is mandatory. Only accessible using --set-opt-hex.

79 - SLPServiceScope

List of service scopes for the service location protocol (SLP) and whether using the list is mandator. Only accessible using --set-opt-hex.

119 - DomainSearch

Domain search list, see RFC3397 and section 4.1.4 in RFC1035 for encoding. Only accessible using --set-opt-hex.

7.43. VBoxManage debugvm

Introspection and guest debugging.

7.43.1. Synopsis

VBoxManage debugvm { uuid|vmname } dumpvmcore [--filename=name]

VBoxManage debugvm { uuid|vmname } info { item } [ args ...]

VBoxManage debugvm { uuid|vmname } injectnmi

VBoxManage debugvm { uuid|vmname } log [[--release] | [--debug]] [ group-settings ...]

VBoxManage debugvm { uuid|vmname } logdest [[--release] | [--debug]] [ destinations ...]

VBoxManage debugvm { uuid|vmname } logflags [[--release] | [--debug]] [ flags ...]

VBoxManage debugvm { uuid|vmname } osdetect

VBoxManage debugvm { uuid|vmname } osinfo

VBoxManage debugvm { uuid|vmname } osdmesg [--lines=lines]

VBoxManage debugvm { uuid|vmname } getregisters [--cpu=id] [ reg-set.reg-name ...]

VBoxManage debugvm { uuid|vmname } setregisters [--cpu=id] [ reg-set.reg-name=value ...]

VBoxManage debugvm { uuid|vmname } show [[--human-readable] | [--sh-export] | [--sh-eval] | [--cmd-set]] [ settings-item ...]

VBoxManage debugvm { uuid|vmname } stack [--cpu=id]

VBoxManage debugvm { uuid|vmname } statistics [--reset] [--descriptions] [--pattern=pattern]

7.43.2. Description

The "debugvm" commands are for experts who want to tinker with the exact details of virtual machine execution. Like the VM debugger described in The Built-In VM Debugger, these commands are only useful if you are very familiar with the details of the PC architecture and how to debug software.

7.43.2.1. Common options

The subcommands of debugvm all operate on a running virtual machine:

uuid|vmname

Either the UUID or the name (case sensitive) of a VM.

7.43.2.2. debugvm dumpvmcore

VBoxManage debugvm { uuid|vmname } dumpvmcore [--filename=name]

Creates a system dump file of the specified VM. This file will have the standard ELF core format (with custom sections); see VM Core Format.

This corresponds to the writecore command in the debugger.

--filename=filename

The name of the output file.

7.43.2.3. debugvm info

VBoxManage debugvm { uuid|vmname } info { item } [ args ...]

Displays info items relating to the VMM, device emulations and associated drivers.

This corresponds to the info command in the debugger.

info

Name of the info item to display. The special name help will list all the available info items and hints about optional arguments.

args

Optional argument string for the info item handler. Most info items does not take any extra arguments. Arguments not recognized are generally ignored.

7.43.2.4. debugvm injectnmi

VBoxManage debugvm { uuid|vmname } injectnmi

Causes a non-maskable interrupt (NMI) to be injected into the guest. This might be useful for certain debugging scenarios. What happens exactly is dependent on the guest operating system, but an NMI can crash the whole guest operating system. Do not use unless you know what you're doing.

7.43.2.5. debugvm log

VBoxManage debugvm { uuid|vmname } log [[--release] | [--debug]] [ group-settings ...]

Changes the group settings for either debug (--debug) or release (--release) logger of the VM process.

The group-settings are typically strings on the form em.e.f.l, hm=~0 and -em.f. Basic wildcards are supported for group matching. The all group is an alias for all the groups.

Please do keep in mind that the group settings are applied as modifications to the current ones.

This corresponds to the log command in the debugger.

7.43.2.6. debugvm logdest

VBoxManage debugvm { uuid|vmname } logdest [[--release] | [--debug]] [ destinations ...]

Changes the destination settings for either debug (--debug) or release (--release) logger of the VM process. For details on the destination format, the best source is src/VBox/Runtime/common/log/log.cpp.

The destinations is one or more mnemonics, optionally prefixed by "no" to disable them. Some of them take values after a ":" or "=" separator. Multiple mnemonics can be separated by space or given as separate arguments on the command line.

List of available destination:

file[=file], nofile

Specifies a log file. It no filname is given, one will be generated based on the current UTC time and VM process name and placed in the current directory of the VM process. Note that this will currently not have any effect if the log file has already been opened.

dir=directory, nodir

Specifies the output directory for log files. Note that this will currently not have any effect if the log file has already been opened.

history=count, nohistory

A non-zero value enables log historization, with the value specifying how many old log files to keep.

histsize=bytes

The max size of a log file before it is historized. Default is infinite.

histtime=seconds

The max age (in seconds) of a log file before it is historized. Default is infinite.

ringbuffer, noringbuffer

Only log to the log buffer until an explicit flush (e.g. via an assertion) occurs. This is fast and saves diskspace.

stdout, nostdout

Write the log content to standard output.

stdout, nostdout

Write the log content to standard error.

debugger, nodebugger

Write the log content to the debugger, if supported by the host OS.

com, nocom

Writes logging to the COM port. This is only applicable for raw-mode and ring-0 logging.

user, nouser

Custom destination which has no meaning to VM processes..

This corresponds to the logdest command in the debugger.

7.43.2.7. debugvm logflags

VBoxManage debugvm { uuid|vmname } logflags [[--release] | [--debug]] [ flags ...]

Changes the flags on either debug (--debug) or release (--release) logger of the VM process. Please note that the modifications are applied onto the existing changes, they are not replacing them.

The flags are a list of flag mnemonics, optionally prefixed by a "no", "!", "~" or "-" to negate their meaning. The "+" prefix can be used to undo previous negation or use as a separator, though better use whitespace or separate arguments for that.

List of log flag mnemonics, with their counter form where applicable (asterisk indicates defaults):

enabled*, disabled

Enables or disables logging.

buffered, unbuffered*

Enabling buffering of log output before it hits the destinations.

writethrough(/writethru)

Whether to open the destination file with writethru buffering settings or not.

flush

Enables flushing of the output file (to disk) after each log statement.

lockcnts

Prefix each log line with lock counts for the current thread.

cpuid

Prefix each log line with the ID of the current CPU.

pid

Prefix each log line with the current process ID.

flagno

Prefix each log line with the numberic flags corresponding to the log statement.

flag

Prefix each log line with the flag mnemonics corresponding to the log statement.

groupno

Prefix each log line with the log group number for the log statement producing it.

group

Prefix each log line with the log group name for the log statement producing it.

tid

Prefix each log line with the current thread identifier.

thread

Prefix each log line with the current thread name.

time

Prefix each log line with the current UTC wall time.

timeprog

Prefix each log line with the current monotonic time since the start of the program.

msprog

Prefix each log line with the current monotonic timestamp value in milliseconds since the start of the program.

ts

Prefix each log line with the current monotonic timestamp value in nanoseconds.

tsc

Prefix each log line with the current CPU timestamp counter (TSC) value.

rel, abs*

Selects the whether ts and tsc prefixes should be displayed as relative to the previous log line or as absolute time.

hex*, dec

Selects the whether the ts and tsc prefixes should be formatted as hexadecimal or decimal.

custom

Custom log prefix, has by default no meaning for VM processes.

usecrlf, uself*

Output with DOS style (CRLF) or just UNIX style (LF) line endings.

overwrite*, append

Overwrite the destination file or append to it.

This corresponds to the logflags command in the debugger.

7.43.2.8. debugvm osdetect

VBoxManage debugvm { uuid|vmname } osdetect

Make the VMM's debugger facility (re)-detect the guest operating system (OS). This will first load all debugger plug-ins.

This corresponds to the detect command in the debugger.

7.43.2.9. debugvm osinfo

VBoxManage debugvm { uuid|vmname } osinfo

Displays information about the guest operating system (OS) previously detected by the VMM's debugger facility.

7.43.2.10. debugvm osdmesg

VBoxManage debugvm { uuid|vmname } osdmesg [--lines=lines]

Displays the guest OS kernel log, if detected and supported.

--lines=lines

Number of lines of the log to display, counting from the end. The default is infinite.

7.43.2.11. debugvm getregisters

VBoxManage debugvm { uuid|vmname } getregisters [--cpu=id] [ reg-set.reg-name ...]

Retrieves register values for guest CPUs and emulated devices.

reg-set.reg-name

One of more registers, each having one of the following forms:

  1. register-set.register-name.sub-field

  2. register-set.register-name

  3. cpu-register-name.sub-field

  4. cpu-register-name

  5. all

The all form will cause all registers to be shown (no sub-fields). The registers names are case-insensitive.

--cpu=id

Selects the CPU register set when specifying just a CPU register (3rd and 4th form). The default is 0.

7.43.2.12. debugvm setregisters

VBoxManage debugvm { uuid|vmname } setregisters [--cpu=id] [ reg-set.reg-name=value ...]

Changes register values for guest CPUs and emulated devices.

reg-set.reg-name=value

One of more register assignment, each having one of the following forms:

  1. register-set.register-name.sub-field=value

  2. register-set.register-name=value

  3. cpu-register-name.sub-field=value

  4. cpu-register-name=value

The value format should be in the same style as what getregisters displays, with the exception that both octal and decimal can be used instead of hexadecimal.

--cpu=id

Selects the CPU register set when specifying just a CPU register (3rd and 4th form). The default is 0.

7.43.2.13. debugvm show

VBoxManage debugvm { uuid|vmname } show [[--human-readable] | [--sh-export] | [--sh-eval] | [--cmd-set]] [ settings-item ...]

Shows logging settings for the VM.

--human-readable

Selects human readable output.

--sh-export

Selects output format as bourne shell style export commands.

--sh-eval

Selects output format as bourne shell style eval command input.

--cmd-set

Selects output format as DOS style SET commands.

settings-item

What to display. One or more of the following:

  • logdbg-settings - debug log settings.

  • logrel-settings - release log settings.

  • log-settings - alias for both debug and release log settings.

7.43.2.14. debugvm stack

VBoxManage debugvm { uuid|vmname } stack [--cpu=id]

Unwinds the guest CPU stacks to the best of our ability. It is recommended to first run the osdetect command, as this gives both symbols and perhaps unwind information.

--cpu=id

Selects a single guest CPU to display the stack for. The default is all CPUs.

7.43.2.15. debugvm statistics

VBoxManage debugvm { uuid|vmname } statistics [--reset] [--descriptions] [--pattern=pattern]

Displays or resets VMM statistics.

Retrieves register values for guest CPUs and emulated devices.

--pattern=pattern

DOS/NT-style wildcards patterns for selecting statistics. Multiple patterns can be specified by using the '|' (pipe) character as separator.

--reset

Select reset instead of display mode.

7.44. VBoxManage cloudprofile

Manage the cloud profiles.

7.44.1. Synopsis

VBoxManage cloudprofile {--provider=name} {--profile=name} add [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]

VBoxManage cloudprofile {--provider=name} {--profile=name} update [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]

VBoxManage cloudprofile {--provider=name} {--profile=name} delete

VBoxManage cloudprofile {--provider=name} {--profile=name} show

7.44.2. Description

7.44.2.1. Common options

The subcommands of cloudprofile implement the standard CRUD operations for a cloud profile. The next common options must be placed between the "cloud" and the following sub-commands:

--provider=name

Short cloud provider name.

--profile=name

Cloud profile name.

7.44.2.2. cloudprofile add

VBoxManage cloudprofile {--provider=name} {--profile=name} add [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]

Add new cloud profile for a specified cloud provider.

--clouduser

The name which fully identifies the user in the specified cloud provider.

--fingerprint

Fingerprint for the key pair being used.

--keyfile

Full path and filename of the private key.

--passphrase

Passphrase used for the key, if it is encrypted.

--tenancy

ID of your tenancy.

--compartment

ID of your compartment.

--region

Region name. Region is where you plan to deploy an application.

7.44.2.3. cloudprofile show

VBoxManage cloudprofile {--provider=name} {--profile=name} show

Display information about a cloud profile for a specified cloud provider.

7.44.2.4. cloudprofile update

VBoxManage cloudprofile {--provider=name} {--profile=name} update [--clouduser=unique id] [--fingerprint=MD5 string] [--keyfile=path] [--passphrase=string] [--tenancy=unique id] [--compartment=unique id] [--region=string]

Modify a cloud profile for the specified cloud provider.

--clouduser

The name which fully identifies the user in the specified cloud provider.

--fingerprint

Fingerprint for the key pair being used.

--keyfile

Full path and filename of the private key.

--passphrase

Passphrase used for the key, if it is encrypted.

--tenancy

ID of your tenancy.

--compartment

ID of your compartment.

--region

Region name. Region is where you plan to deploy an application.

7.44.2.5. cloudprofile delete

VBoxManage cloudprofile {--provider=name} {--profile=name} delete

Delete a cloud profile for a specified cloud provider.

7.45. VBoxManage cloud

Manage the cloud entities.

7.45.1. Synopsis

VBoxManage cloud {--provider=name} {--profile=name} list instances [--state=string] [--compartment-id=string]

VBoxManage cloud {--provider=name} {--profile=name} list images {--compartment-id=string} [--state=string]

VBoxManage cloud {--provider=name} {--profile=name} instance create {--domain-name=name} {{--image-id=id} | {--boot-volume-id=id}} {--display-name=name} {--shape=type} {--subnet=id} [--boot-disk-size=size in GB] [--publicip=true/false] [--privateip=IP address] [--public-ssh-key=key string...] [--launch-mode=NATIVE/EMULATED/PARAVIRTUALIZED] [--cloud-init-script-path=path to a script]

VBoxManage cloud {--provider=name} {--profile=name} instance info {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} instance terminate {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} instance start {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} instance pause {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} image create {--display-name=name} [--bucket-name=name] [--object-name=name] [--instance-id=unique id]

VBoxManage cloud {--provider=name} {--profile=name} image info {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} image delete {--id=unique id}

VBoxManage cloud {--provider=name} {--profile=name} image import {--id=unique id} [--bucket-name=name] [--object-name=name]

VBoxManage cloud {--provider=name} {--profile=name} image export {--id=unique id} {--display-name=name} [--bucket-name=name] [--object-name=name]

VBoxManage cloud {--provider=name} {--profile=name} network setup {--local-gateway-iso=path} [--gateway-os-name=string] [--gateway-os-version=string] [--gateway-shape=string] [--tunnel-network-name=string] [--tunnel-network-range=string] [--guest-additions-iso=path] [--proxy=string] [--compartment-id=string]

VBoxManage cloud {--provider=name} {--profile=name} network create {--name=string} {--network-id=string} [ --enable | --disable ]

VBoxManage cloud network update {--name=string} [--network-id=string] [ --enable | --disable ]

VBoxManage cloud network delete {--name=string}

VBoxManage cloud network info {--name=string}

7.45.2. Description

7.45.2.1. Common options

The word "cloud" is an umbrella for all commands related to the interconnection with the Cloud. The next common options must be placed between the "cloud" and the following sub-commands:

--provider=name

Short cloud provider name.

--profile=name

Cloud profile name.

7.45.2.2. cloud list instances

VBoxManage cloud {--provider=name} {--profile=name} list instances [--state=string] [--compartment-id=string]

Displays the list of the instances for a specified compartment.

--state"running/paused/terminated"

The state of cloud instance. The possible states are "running/paused/terminated" at moment. If the state isn't provided the list of instances with all possible states is returned.

--compartment-id

A compartment is the logical container used to organize and isolate cloud resources. The different cloud providers can have the different names for this entity.

7.45.2.3. cloud list images

VBoxManage cloud {--provider=name} {--profile=name} list images {--compartment-id=string} [--state=string]

Displays the list of the images for a specified compartment.

--state"available/disabled/deleted"

The state of cloud image. The possible states are "available/disabled/deleted" at moment. If the state isn't provided the list of images with all possible states is returned.

--compartment-id

A compartment is the logical container used to organize and isolate cloud resources. The different cloud providers can have the different names for this entity.

7.45.2.4. cloud instance create

VBoxManage cloud {--provider=name} {--profile=name} instance create {--domain-name=name} {{--image-id=id} | {--boot-volume-id=id}} {--display-name=name} {--shape=type} {--subnet=id} [--boot-disk-size=size in GB] [--publicip=true/false] [--privateip=IP address] [--public-ssh-key=key string...] [--launch-mode=NATIVE/EMULATED/PARAVIRTUALIZED] [--cloud-init-script-path=path to a script]

Creates new instance in the Cloud. There are two standard ways to create an instance in the Cloud: 1. Create an instance from an existing custom image. 2. Create an instance from an existing bootable volume. This bootable volume shouldn't be attached to any instance. For the 1st approach next parameters are required: image-id and boot-disk-size. For the 2nd approach next parameters are required: boot-volume-id; The rest parameters are common for both cases: display-name, launch-mode, subnet-id, publicIP, privateIP, shape, domain.

--domain-name

Cloud domain where new instance is created.

--image-id

Unique identifier which fully identifies a custom image in the Cloud.

--boot-volume-id

Unique identifier which fully identifies a boot volume in the Cloud.

--display-name

Name for new instance in the Cloud.

--shape

The shape of instance, defines the number of CPUs and RAM memory.

--subnet

Unique identifier which fully identifies an existing subnet in the Cloud which will be used by the instance.

--boot-disk-size

The size of bootable image in GB. Default is 50GB.

--publicip

Whether the instance will have a public IP or not.

--privateip

Private IP address for the created instance.

--public-ssh-key

Public SSH key used to connect to the instance via SSH. This parameter may be repeated if you plan to use more than one key as: "--public-ssh-key=firstSSHKey --public-ssh-key=secondSSHKey".

--launch-mode

The most known values here may be EMULATED, NATIVE, PARAVIRTUALIZED.

--cloud-init-script-path

Absolute path to the user cloud-init script.

7.45.2.5. cloud instance info

Display information about a cloud instance with a specified id.

--id

Unique identifier which fully identify the instance in the Cloud.

7.45.2.6. cloud instance termination

Delete a cloud instance with a specified id.

--id

Unique identifier which fully identify the instance in the Cloud.

7.45.2.7. cloud instance start

Start a cloud instance with a specified id.

--id

Unique identifier which fully identify the instance in the Cloud.

7.45.2.8. cloud instance pause

Pause a cloud instance with a specified id.

--id

Unique identifier which fully identify the instance in the Cloud.

7.45.2.9. cloud image create

VBoxManage cloud {--provider=name} {--profile=name} image create {--display-name=name} [--bucket-name=name] [--object-name=name] [--instance-id=unique id]

Creates new image in the Cloud. There are two standard ways to create an image in the Cloud: 1. Create an image from an object in the Cloud Storage; 2. Create an image from an existing cloud instance. For the 1st approach next parameters are required: bucket-name - cloud bucket name where an object is located; object-name - name of object in the bucket; display-name - name for new image in the Cloud. For the 2d approach next parameters are required: instance-id - Id of instance in the Cloud; display-name - name for new image in the Cloud.

--display-name

Name for new image in the Cloud.

--bucket-name

Cloud bucket name where an object is located.

--object-name

Name of object in the bucket.

--instance-id

Unique identifier which fully identifies the instance in the Cloud.

7.45.2.10. cloud image info

VBoxManage cloud {--provider=name} {--profile=name} image info {--id=unique id}

Display information about a cloud image with a specified id.

--id

Unique identifier which fully identifies the image in the Cloud.

7.45.2.11. cloud image delete

VBoxManage cloud {--provider=name} {--profile=name} image delete {--id=unique id}

Delete an image with a specified id from the Cloud.

--id

Unique identifier which fully identifies the image in the Cloud.

7.45.2.12. cloud image import

VBoxManage cloud {--provider=name} {--profile=name} image import {--id=unique id} [--bucket-name=name] [--object-name=name]

Import an image with a specified id from the Cloud to a local host. The result is an object in the local "temp" folder on the local host. Possible approach may have two general steps: 1. Create an object from an image in the Cloud Storage; 2. Download the object to the local host. So the next parameters may be required: bucket-name - cloud bucket name where the object will be created; object-name - name of object in the bucket. if parameter "object-name" is absent a displayed image name is used. If the first step isn't needed only the parameter "id" is required.

--id

Unique identifier which fully identifies the image in the Cloud.

--bucket-name

Cloud bucket name where an object will be created.

--object-name

Name of created object in the bucket. The downloaded object will have this name.

7.45.2.13. cloud image export

VBoxManage cloud {--provider=name} {--profile=name} image export {--id=unique id} {--display-name=name} [--bucket-name=name] [--object-name=name]

Export an existing VBox image with a specified uuid from a local host to the Cloud. The result is new image in the Cloud. Possible approach may have two general steps: 1. Upload VBox image to the Cloud Storage; 2. Create an image from the uploaded object. So the next parameters may be required: bucket-name -cloud bucket name where the object will be uploaded; object-name - name of object in the bucket. If parameter "object-name" is absent the image id is used; display-name - name for new image in the Cloud. If the first step isn't needed the parameters "id" and "display-name" are required only.

--id

Unique identifier of the image in the VirtualBox.

--display-name

Name for new image in the Cloud.

--bucket-name

Cloud bucket name where the image (object) will be uploaded.

--object-name

Name of object in the bucket.

7.45.2.14. cloud network setup

VBoxManage cloud {--provider=name} {--profile=name} network setup {--local-gateway-iso=path} [--gateway-os-name=string] [--gateway-os-version=string] [--gateway-shape=string] [--tunnel-network-name=string] [--tunnel-network-range=string] [--guest-additions-iso=path] [--proxy=string] [--compartment-id=string]

Set up a cloud network environment for the specified cloud profile.

--local-gateway-iso

The local path to an installation media for a local gateway.

--gateway-os-name

The name of OS to use for a cloud gateway.

--gateway-os-version

The version of OS to use for a cloud gateway.

--gateway-shape

The instance shape to use for a cloud gateway.

--tunnel-network-name

The name of VCN/subnet to use for tunneling.

--tunnel-network-range

The IP address range to use for tunneling.

--guest-additions-iso

The local path to an installation media for VirtualBox guest additions.

--proxy

The proxy URL to be used in local gateway installation.

--compartment-id

The compartment to create the tunnel network in.

7.45.2.15. cloud network create

VBoxManage cloud {--provider=name} {--profile=name} network create {--name=string} {--network-id=string} [ --enable | --disable ]

Create a new cloud network descriptor associated with an existing cloud subnet.

--name

The name to assign to the cloud network descriptor.

--network-id

The unique identifier of an existing subnet in the cloud.

--enable, --disable

Whether to enable the network descriptor or disable it. If not specified, the network will be enabled.

7.45.2.16. cloud network update

VBoxManage cloud network update {--name=string} [--network-id=string] [ --enable | --disable ]

Modify an existing cloud network descriptor.

--name

The name of an existing cloud network descriptor.

--network-id

The unique identifier of an existing subnet in the cloud.

--enable, --disable

Whether to enable the network descriptor or disable it.

7.45.2.17. cloud network delete

VBoxManage cloud network delete {--name=string}

Delete an existing cloud network descriptor.

--name

The name of an existing cloud network descriptor.

7.45.2.18. cloud network info

VBoxManage cloud network info {--name=string}

Display information about a cloud network descriptor.

--name

The name of an existing cloud network descriptor.

7.46. vboximg-mount

FUSE mount a virtual disk image for Mac OS and Linux hosts.

7.46.1. Synopsis

vboximg-mount { -? | -h | --help }

vboximg-mount {--image=image-UUID} [--guest-filesystem] [-o=FUSE-option[,FUSE-option]] [--root] [--rw] { mountpoint }

vboximg-mount {--list} [--image=image-UUID] [--guest-filesystem] [--verbose] [--vm=vm-UUID] [--wide]

7.46.2. Description

The vboximg-mount command enables you to make Oracle VM VirtualBox disk images available to a Mac OS or Linux host operating system (OS) for privileged or non-priviliged access. You can mount any version of the disk from its available history of snapshots. Use this command to mount, view, and optionally modify the contents of an Oracle VM VirtualBox virtual disk image, and you can also use this command to view information about registered virtual machines (VMs).

This command uses the Filesystem in Userspace (FUSE) technology to provide raw access to an Oracle VM VirtualBox virtual disk image.

When you use the --image option to specify a base image identifier, only the base image is mounted. Any related snapshots are disregarded. Alternatively, if you use the --image option to specify a snapshot, the state of the FUSE-mounted virtual disk is synthesized from the implied chain of snapshots, including the base image.

The vboximg-mount command includes experimental read-only access to file systems inside a VM disk image. This feature enables you to extract some files from the VM disk image without starting the VM and without requiring third-party file system drivers on the host system. Oracle VM VirtualBox supports the FAT, NTFS, ext2, ext3, and ext4 file systems.

The virtual disk is exposed as a device node within a FUSE-based file system that overlays the specified mount point.

The FUSE file system includes a directory that contains a number of files. The file system can also contain a directory that includes a symbolic link that has the same base name (see the basename(1) man page) as the virtual disk base image and points to the location of the virtual disk base image. The directory can be of the following types:

  • vhdd provides access to the raw disk image data as a flat image

  • volID provides access to an individual volume on the specified disk image

  • fsID provides access to a supported file system without requiring a host file system driver

7.46.2.1. General Command Options

vboximg-mount { -? | -h | --help }

Use the following options to obtain information about the vboximg-mount command and its options.

--help, --h, or--?

Shows usage information.

7.46.2.2. Mounting an Oracle VM VirtualBox Disk Image

vboximg-mount {--image=image-UUID} [--guest-filesystem] [-o=FUSE-option[,FUSE-option]] [--root] [--rw] { mountpoint }

Use the vboximg-mount command to mount an Oracle VM VirtualBox virtual disk image on a Mac OS or Linux host system. When mounted, you can view the contents of the disk image or modify the contents of the disk image.

You can use the vboximg-mount command to restrict FUSE-based access to a subsection of the virtual disk.

--image=disk-image

Specifies the Universally Unique Identifier (UUID), name, or path of the Oracle VM VirtualBox disk image.

The short form of the --image option is -i.

--guest-filesystem

Enables experimental read-only support for guest file systems. When you specify this option, all known file systems are made available to access.

The short form of the --guest-filesystem option is -g.

-o=FUSE-option[,FUSE-option...]

Specifies FUSE mount options.

The vboximg-mount command enables you to use the FUSE mount options that are described in the mount.fuse(8) man page.

--root

Overrides the security measure that restricts file access to the file system owner by also granting file access to the root user.

Same as the -o allow_root option. See the -o option description.

This option is incompatible with the -o allow_other option.

--rw

Mounts the specified image as read-write, which is required if you want to modify its contents. By default, images are mounted as read-only.

mount-point

Specifies the path name of a directory on which to mount the Oracle VM VirtualBox disk image.

7.46.2.3. Viewing Oracle VM VirtualBox Disk Image Information

vboximg-mount {--list} [--image=image-UUID] [--guest-filesystem] [--verbose] [--vm=vm-UUID] [--wide]

Use the vboximg-mount command to view information about registered VMs or an Oracle VM VirtualBox virtual disk image.

--image=disk-image

Specifies the UUID, name, or path of the Oracle VM VirtualBox disk image.

The short form of the --image option is -i.

--guest-filesystem

Enables experimental read-only support for guest file systems. When you specify this option, all known file systems are made available to access.

The short form of the --guest-filesystem option is -g.

--list

Shows information about the disks that are associated with the registered VMs. If you specify a disk image, this option shows information about the partitions of the specified image.

When you specify the --verbose option, the output includes detailed information about the VMs and media, including snapshot images and file paths.

The short form of the --list option is -l.

--verbose

Shows or logs detailed information.

The short form of the --verbose option is -v.

--vm=vm-UUID

Outputs information about the VM that is associated with the specified UUID.

--wide

Outputs information in a wide format. This output includes the lock state information of running VMs. For VMs that are not running, the state is created.

The wide output uses a tree-like structure in the VM column to show the relationship between a VM base image and its snapshots.

7.46.3. Examples

The following example shows how to mount a virtual disk image on the host operating system (OS).

$ mkdir fuse_mount_point
$ vboximg-mount --image=b490e578-08be-4f7d-98e9-4c0ef0952377 fuse_mount_point
$ ls fuse_mount_point
ubu.vdi[32256:2053029880]   vhdd
$ sudo mount fuse_mount_point/vhdd /mnt

The mkdir command creates a mount point called fuse_mount_point on the host OS. The vboximg-mount command is then used to mount the specified disk image on the fuse_mount_point mount point. The mount includes all snapshots for the disk image.

The ls command shows the contents of fuse_mount_point. The mount command is then used to mount the FUSE-mounted device node, vhdd, on the /mnt mount point. The vhdd device node represents the virtual disk image.

The following example shows how to make the known file systems of the b490e578-08be-4f7d-98e9-4c0ef0952377 disk image accessible when the image is mounted on the fuse_mount_point mount point:

$ vboximg-mount --image=b490e578-08be-4f7d-98e9-4c0ef0952377 \
--guest-filesystem fuse_mount_point

The following command outputs detailed information about all registered VMs and their snapshots:

$ vboximg-mount --list --verbose

The following command shows an excerpt of the list output in wide format.

$ vboximg-mount --list --wide

VM  Image                 Size Type State   UUID (hierarchy)
------------------------------------------  ------------------------------------
Proxy                                       0833f5bc-6304-42e1-b799-cdc81c576c60
 |
 +- Proxy.vdi             4.8G VDI  rlock   d5f84afb-0794-4952-ab71-6bbcbee07737
 |  +- <snapshot>        12.3G VDI  rlock     dffc67aa-3023-477f-8033-b27e3daf4f54
 |  +- <snapshot>         8.8G VDI  rlock       3b2755bd-5f2a-4171-98fe-647d510b6274
 |  +- <snapshot>        14.6G VDI  rlock         e2ccdb5f-49e8-4123-8623-c61f363cc5cf
 |  +- <snapshot>         7.4G VDI  wlock           3c1e6794-9091-4be3-9e80-11aba40c2649

------------------------------------------  ------------------------------------
Oracle Linux 7                              5365ab5f-470d-44c0-9863-dad532ee5905
 |
 +- Oracle Linux 7.vdi     7.0G VDI created 96d2e92e-0d4e-46ab-a0f1-008fdbf997e7
 | +- <snapshot>          15.9G VDI created   f9cc866a-9166-42e9-a503-bbfe9b7312e8
 |
 +- kernel.vdi            11.1G VDI created 79a370bd-0c4f-480a-30bb-10cdea68423f

The output shows that the Proxy VM is running the fourth snapshot of the Proxy.vdi virtual disk image. The running state is indicated by the wlock value in the State column.

The Oracle Linux 7 VM is not running. It has two images: Oracle Linux 7.vdi and kernel.vdi. The Oracle Linux 7.vdi image has a snapshot.

The following command shows information about the VM with the specified UUID:

$ vboximg-mount --list --vm=b1d5563b-2a5b-4013-89f1-26c81d6bbfa0
-----------------------------------------------------------------
VM:   ubu
UUID: b1d5563b-2a5b-4013-89f1-26c81d6bbfa0

  Image:   ubu.vdi
  UUID:    b490e578-08be-4f7d-98e9-4c0ef0952377

       Snapshot: 35afe1e0-0a51-44f3-a228-caf172f3306f
       Size:     12.1G

       Snapshot: 874279c1-4425-4282-ada8-a9c07c00bbf9
       Size:     13.6G

  Image:   kernel.vdi
  UUID:    79a370bd-6eb7-4dbf-8bc6-d29118f127e0