VM usage

  • Start VM (headless):
    VBoxHeadless --startvm "ExampleLinux86" &


    VBoxManage startvm "ExampleLinux86" --type headless &
  • Shutdown VM:
    VBoxManage controlvm "ExampleLinux86" acpipowerbutton

    May require package acpid on VM Guest OS.

  • Stop VM:
    VBoxManage controlvm "ExampleLinux86" poweroff

    Beware: this does not shutdown VM properly!

  • Reset VM:
    VBoxManage controlvm "ExampleLinux86" reset

  • Show VM's:
    VBoxManage list vms
  • Show running VM's:
    VBoxManage list runningvms
  • Change VRDE (Remotedesktop) Port:
    VBoxManage modifyvm "ExampleLinux86" --vrdeport 3390

  • Show VM details:
    VBoxManage showvminfo "ExampleLinux86" --details

  • Remove VM:
    VBoxManage unregistervm "ExampleLinux86" --delete

    Beware: This also deltes all Files !

  • Add Medium:
    VBoxManage storageattach "ExampleLinux86" --storagectl "IDE-Controller" --port 1 --device 0 --type dvddrive --medium /usr/share/virtualbox/VBoxGuestAdditions.iso
  • Remove Medium:
    VBoxManage storageattach "ExampleLinux86" --storagectl "IDE-Controller" --port 1 --device 0 --type dvddrive --medium none

  • Send <CTRL>+<ALT>+<DEL> via RDP: press <CTRL>+<ALT>+<END>

Install VirtualBox on Linux Ubuntu 10.04


  • Import VirtualBox apt-key:
    sudo wget -q -O- | sudo apt-key add -
  • Add VirtualBox Packet Source:
    sduo echo "deb `lsb_release -cs` contrib" >> /etc/apt/sources.list
  • Update apt:
    sudo apt-get update
  • Install VirtualBox:
    sudo apt-get install virtualbox-4.1 dkms

    Usergroup „vboxusers“ will be created by apt. VirtualBox 4.1.18 or newer will be installed.

  • Add current user to vboxusers Group:
    sudo adduser $USER vboxusers

    or create user vbox

Manage VirtualBox Extension Pack

List Extension Pack

$ VBoxManage list extpacks
Extension Packs: 2
Pack no. 0:   VNC
Version:      4.3.36
Revision:     105129
Description:  VNC plugin module
VRDE Module:  VBoxVNC
Usable:       true
Why unusable:

Pack no. 1:   Oracle VM VirtualBox Extension Pack
Version:      4.3.36
Revision:     105129
Description:  USB 2.0 Host Controller, Host Webcam, VirtualBox RDP, PXE ROM with E1000 support.
VRDE Module:  VBoxVRDP
Usable:       true
Why unusable:

Install VirtualBox Extension Pack / RDP

  • Check your VirtualBox Version
    VBoxManage --version
  • Download Extension Pack for your VirtualBox Version:
  • Install Extension Pack:
    sudo VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-4.3.36-105129.vbox-extpack
    Successfully installed "Oracle VM VirtualBox Extension Pack".


  • Enable RDP for your VM:
    VBoxManage modifyvm "ExampleLinux86" --vrde on

Uninstall RDP / VRDP

sudo VBoxManage extpack uninstall "Oracle VM VirtualBox Extension Pack"
Successfully uninstalled "Oracle VM VirtualBox Extension Pack".

Uninstall VNC Extension Pack

sudo VBoxManage extpack uninstall VNC
Successfully uninstalled "VNC".

Install phpVirtualbox

Install vboxtool

Provides effective control of virtual machines of VirtualBox on a Linux headless server like autostart and more:

Download VBoxGuestAdditions ISO


  1. Add non-free Package Repository
  2. sudo wget -q -O- | sudo apt-key add -
  3. sudo apt-get install virtualbox-guest-additions-iso
  4. VBoxGuestAdditions.iso will be installed to /usr/share/virtualbox/VBoxGuestAdditions.iso
  5. Attach ISO to VM
  6. Install GuestAdditions in VM

Download ISO

Create VM

Linux Guest OS 32-Bit

  • Create new VM:
    VBoxManage createvm --name "ExampleLinux86" --register
  • Set OS Type:
    VBoxManage modifyvm "ExampleLinux86" --ostype Linux26

    See VBoxManage list ostypes for available ostypes.

  • Some settings:
    VBoxManage modifyvm "ExampleLinux86" --memory 512 --acpi on
    VBoxManage modifyvm "ExampleLinux86" --boot1 dvd
    VBoxManage modifyvm "ExampleLinux86" --nic1 bridged --bridgeadapter1 eth0
  • Add Storage (IDE or SATA) Controller:
    VBoxManage storagectl "ExampleLinux86" --name "IDE-Controller" --add ide
  • Create Virtual Disk:
    cd ~/VirtualBox\ VMs/ExampleLinux86/ && VBoxManage createhd --filename disk1.vdi --size 10000
  • Attach Virtual Disk:
    VBoxManage storageattach "ExampleLinux86" --storagectl "IDE-Controller" --port 0 --device 0 --type hdd --medium disk1.vdi
  • Attach ISO as virtual DVD Drive:
    VBoxManage storageattach "ExampleLinux86" --storagectl "IDE-Controller" --port 1 --device 0 --type dvddrive --medium /home/example/linux.iso

Optimise VM Performance

  • Use SATA Storage Controoller instead of IDE for your Virtual Disk
  • Windows Guest: Defrag your Harddisk.

Move VMware VMDK to VirtualBox

Convert VMDK to RAW

Download Qemu for Windows (Qemu 1.0.1 or newer):

Convert VMware Virtual Disk (VMDK) to RAW Disk Image:

c:\example_vm>qemu-img.exe convert disk1.vmdk disk1.raw

Beware: Raw Disk Image will be as large as the virtual Partition inside VMDK !

Convert RAW to VDI

Download and install VirtualBox for Windows (VirtualBox 4.1.18 or newer):

c:\example_vm>"C:\Program Files\Oracle\VirtualBox\vboxmanage.exe" convertfromraw disk1.bin disk1.vdi --format VDI
pc/virtualbox.txt · Zuletzt geändert: 2016/09/19 00:26 von pixeldoc