3.2. Oracle VM VirtualBox Executables and Components

Oracle VM VirtualBox was designed to be modular and flexible. When the Oracle VM VirtualBox graphical user interface (GUI) is opened and a VM is started, at least the following three processes are running:

  • VBoxSVC, the Oracle VM VirtualBox service process which always runs in the background. This process is started automatically by the first Oracle VM VirtualBox client process and exits a short time after the last client exits. The first Oracle VM VirtualBox service can be the GUI, VBoxManage, VBoxHeadless, the web service amongst others. The service is responsible for bookkeeping, maintaining the state of all VMs, and for providing communication between Oracle VM VirtualBox components. This communication is implemented using COM/XPCOM.

    Note

    When we refer to clients here, we mean the local clients of a particular VBoxSVC server process, not clients in a network. Oracle VM VirtualBox employs its own client/server design to allow its processes to cooperate, but all these processes run under the same user account on the host operating system, and this is totally transparent to the user.

  • The GUI process, VirtualBoxVM, a client application based on the cross-platform Qt library. When started without the --startvm option, this application acts as the VirtualBox Manager, displaying the VMs and their settings. It then communicates settings and state changes to VBoxSVC and also reflects changes effected through other means, such as the VBoxManage command.

  • If the VirtualBoxVM client application is started with the --startvm argument, it loads the VMM library which includes the actual hypervisor and then runs a virtual machine and provides the input and output for the guest.

Any Oracle VM VirtualBox front-end, or client, will communicate with the service process and can both control and reflect the current state. For example, either the VM selector or the VM window or VBoxManage can be used to pause the running VM, and other components will always reflect the changed state.

The Oracle VM VirtualBox GUI application is only one of several available front ends, or clients. The complete list shipped with Oracle VM VirtualBox is as follows:

  • VirtualBoxVM: The Qt front end implementing the VirtualBox Manager and running VMs.

  • VBoxManage: A less user-friendly but more powerful alternative. See VBoxManage.

  • VBoxHeadless: A VM front end which does not directly provide any video output and keyboard or mouse input, but enables redirection through the VirtualBox Remote Desktop Extension. See Section 1.1.2, “VBoxHeadless, the Remote Desktop Server”.

  • vboxwebsrv: The Oracle VM VirtualBox web service process which enables control of an Oracle VM VirtualBox host remotely. This is described in detail in the Oracle VM VirtualBox Software Development Kit (SDK) reference. See Chapter 4, Oracle VM VirtualBox Programming Interfaces.

  • The Oracle VM VirtualBox Python shell: A Python alternative to VBoxManage. This is also described in the SDK reference.

Internally, Oracle VM VirtualBox consists of many more or less separate components. You may encounter these when analyzing Oracle VM VirtualBox internal error messages or log files. These include the following:

  • IPRT: A portable runtime library which abstracts file access, threading, and string manipulation. Whenever Oracle VM VirtualBox accesses host operating features, it does so through this library for cross-platform portability.

  • VMM (Virtual Machine Monitor): The heart of the hypervisor.

  • EM (Execution Manager): Controls execution of guest code.

  • REM (Recompiled Execution Monitor): Provides software emulation of CPU instructions.

  • TRPM (Trap Manager): Intercepts and processes guest traps and exceptions.

  • HM (Hardware Acceleration Manager): Provides support for VT-x and AMD-V.

  • GIM (Guest Interface Manager): Provides support for various paravirtualization interfaces to the guest.

  • PDM (Pluggable Device Manager): An abstract interface between the VMM and emulated devices which separates device implementations from VMM internals and makes it easy to add new emulated devices. Through PDM, third-party developers can add new virtual devices to Oracle VM VirtualBox without having to change Oracle VM VirtualBox itself.

  • PGM (Page Manager): A component that controls guest paging.

  • PATM (Patch Manager): Patches guest code to improve and speed up software virtualization.

  • TM (Time Manager): Handles timers and all aspects of time inside guests.

  • CFGM (Configuration Manager): Provides a tree structure which holds configuration settings for the VM and all emulated devices.

  • SSM (Saved State Manager): Saves and loads VM state.

  • VUSB (Virtual USB): A USB layer which separates emulated USB controllers from the controllers on the host and from USB devices. This component also enables remote USB.

  • DBGF (Debug Facility): A built-in VM debugger.

  • Oracle VM VirtualBox emulates a number of devices to provide the hardware environment that various guests need. Most of these are standard devices found in many PC compatible machines and widely supported by guest operating systems. For network and storage devices in particular, there are several options for the emulated devices to access the underlying hardware. These devices are managed by PDM.

  • Guest Additions for various guest operating systems. This is code that is installed from within a virtual machine. See Guest Additions.

  • The "Main" component is special. It ties all the above bits together and is the only public API that Oracle VM VirtualBox provides. All the client processes listed above use only this API and never access the hypervisor components directly. As a result, third-party applications that use the Oracle VM VirtualBox Main API can rely on the fact that it is always well-tested and that all capabilities of Oracle VM VirtualBox are fully exposed. It is this API that is described in the Oracle VM VirtualBox SDK. See Chapter 4, Oracle VM VirtualBox Programming Interfaces.