User Tools

Site Tools


software:virtualbox:shell_commands

CLI VirtualBox management

List virtual machines

|Vboxmanage
vboxmanage list vms

Avaliable commands

  • vms - Lists all VMs
  • runningvms - Lists only running VMs
  • ostypes, hostdvds, hostfloppies, bridgesifs, hostonlyifs, dhcpservers, hostinfo, hostcpuids, hddbackends, hdds, dvds, floppies, usbhost, usbfilters, systemproperties, extpacks

Start a virtual machine in headless mode (that's why you are typing theese commands)

|Vboxmanage
vboxmanage startvm "VM name" --type headless

Avaliable types

  • gui - Starts a VM in a GUI window (Default)
  • headless - Starts a VM for remote access
  • sdl - Starts a VM with a minimal GUI and limited features
  • separate - Starts a VM with detachable UI (Headless VM with GUI in separate process)

Change state of the running virtual machine

|Vboxmanage
vboxmanage controlvm "VM Name" savestate

Avaliable commands

  • pause - Puts a VM on hold
  • resume - Resumes the paused VM
  • reset - Same as pressing a Reset button
  • poweroff - Same as pressing the power off button
  • savestate - This will save the state of a VM and then stop it.

Start a program in Windows guest from Linux host

VBoxManage --nologo guestcontrol "VM Name" run --exe "C:\\windows\\notepad.exe" --username jdoe --password Pa$$w0rd --wait-stdout
software/virtualbox/shell_commands.txt · Last modified: 2017/08/10 11:00 (external edit)