Está en la página 1de 38

Chapter 8.

VBoxManage
Table of Contents
Introducton
Commands overvew
VBoxManage st
VBoxManage showvmnfo
VBoxManage regstervm / unregstervm
VBoxManage createvm
VBoxManage modfyvm
Genera settngs
Networkng settngs
Sera port, audo, cpboard, remote desktop and USB settngs
Remote machne settngs
Teeportng settngs
VBoxManage conevm
VBoxManage mport
VBoxManage export
VBoxManage startvm
VBoxManage controvm
VBoxManage dscardstate
VBoxManage adoptstate
VBoxManage snapshot
VBoxManage cosemedum
VBoxManage storageattach
VBoxManage storagect
VBoxManage bandwdthct
VBoxManage showhdnfo
VBoxManage createhd
VBoxManage modfyhd
VBoxManage conehd
VBoxManage convertfromraw
VBoxManage getextradata/setextradata
VBoxManage setproperty
VBoxManage usbter add/modfy/remove
VBoxManage sharedfoder add/remove
VBoxManage guestproperty
VBoxManage guestcontro
VBoxManage debugvm
VBoxManage metrcs
VBoxManage hostonyf
VBoxManage dhcpserver
VBoxManage extpack
lntroduction
As brey mentoned n the secton caed "Aternatve front-ends", VBoxManage s the command-ne
nterface to VrtuaBox. Wth t, you can competey contro VrtuaBox from the command ne of your host
operatng system. VBoxManage supports a the features that the graphca user nterface gves you access
to, but t supports a ot more than that. It exposes reay a the features of the vrtuazaton engne, even
those that cannot (yet) be accessed from the GUI.
You w need to use the command ne f you want to
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
1 de 38 11-04-2012 15.59
use a dherent user nterface than the man GUI (for exampe, VBoxSDL or the VBoxHeadess server);
contro some of the more advanced and expermenta conguraton settngs for a VM.
There are two man thngs to keep n mnd when usng vBoxhahage: Frst, vBoxhahage must aways be used wth
a specc "subcommand", such as "st" or "createvm" or "startvm". A the subcommands that vBoxhahage
supports are descrbed n deta n Chapter 8, V8oxManage.
Second, most of these subcommands requre that you specfy a partcuar vrtua machne after the
subcommand. There are two ways you can do ths:
You can specfy the VM name, as t s shown n the VrtuaBox GUI. Note that f that name contans
spaces, then you must encose the entre name n doube quotes (as t s aways requred wth
command ne arguments that contan spaces).
For exampe:
vBoxhahage s1aJ1vm "W1hdows XP"
You can specfy the UUID, whch s the nterna unque denter that VrtuaBox uses to refer to the
vrtua machne. Assumng that the aforementoned VM caed "Wndows XP" has the UUID shown
beow, the foowng command has the same ehect as the prevous:
vBoxhahage s1aJ1vm 670e746d-abea-4ba6-ad02-2a3b043810a5
You can type vBoxhahage 1s1 vms to have a currenty regstered VMs sted wth a ther settngs, ncudng
ther respectve names and UUIDs.
Some typca exampes of how to contro VrtuaBox from the command ne are sted beow:
To create a new vrtua machne from the command ne and mmedatey regster t wth VrtuaBox,
use vBoxhahage cJea1evm wth the --Jeg1s1eJ opton,
|35|
ke ths:
$ vBoxhahage cJea1evm --hame "SbSE 10.2" --Jeg1s1eJ
v1J1uaBox Commahd L1he hahagemeh1 Th1eJ1ace veJs1oh 4.1.12
{C) 2005-2012 0Jace CoJpoJa11oh
A J1gh1s JeseJved.
v1J1ua mach1he `SbSE 10.2` 1s cJea1ed.
bbT0. c891c351-8ec6-4102-a048-5714d25288e5
Se111hgs 11e. `/home/useJhame/.v1J1uaBox/hach1hes/SbSE 10.2/SbSE 10.2.xm`
As can be seen from the above output, a new vrtua machne has been created wth a new UUID and
a new XML settngs e.
To show the conguraton of a partcuar VM, use vBoxhahage showvm1h1o; see the secton caed
"VBoxManage showvmnfo" for detas and an exampe.
To change settngs whe a VM s powered oh, use vBoxhahage mod11yvm, e.g. as foows:
vBoxhahage mod11yvm "W1hdows XP" --memoJy "512hB"
For detas, see the secton caed "VBoxManage modfyvm".
To change the storage conguraton (e.g. to add a storage controer and then a vrtua dsk), use
vBoxhahage s1oJagec1 and vBoxhahage s1oJagea11ach; see the secton caed "VBoxManage storagect" and
the secton caed "VBoxManage storageattach" for detas.
To contro VM operaton, use one of the foowng:
To start a VM that s currenty powered oh, use vBoxhahage s1aJ1vm; see the secton caed
"VBoxManage startvm" for detas.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
2 de 38 11-04-2012 15.59
To pause or save a VM that s currenty runnng or change some of ts settngs, use vBoxhahage
coh1Jovm; see the secton caed "VBoxManage controvm" for detas.
Commands overview
When runnng VBoxManage wthout parameters or when suppyng an nvad command ne, the beow
syntax dagram w be shown. Note that the output w be sghty dherent dependng on the host
patform; when n doubt, check the output of vBoxhahage for the commands avaabe on your partcuar host.
bsage.
vBoxhahage |-v]--veJs1oh] pJ1h1 veJs1oh humbeJ ahd ex11
vBoxhahage |-q]--hoogo] ... suppJess 1he ogo
vBoxhahage 1s1 |--ohg]-] vms]Juhh1hgvms]os1ypes]hos1dvds]hos11opp1es]
bJ1dged11s]dhcpseJveJs]hos11h1o]
hos1cpu1ds]hddbackehds]hdds]dvds]1opp1es]
usbhos1]usb111eJs]sys1empJopeJ11es]ex1packs
vBoxhahage showvm1h1o <uu1d>]<hame> |--de1a1s]
|--mach1heJeadabe]
vBoxhahage showvm1h1o <uu1d>]<hame> --og <1dx>
vBoxhahage Jeg1s1eJvm <11ehame>
vBoxhahage uhJeg1s1eJvm <uu1d>]<hame> |--dee1e]
vBoxhahage cJea1evm --hame <hame>
|--os1ype <os1ype>]
|--Jeg1s1eJ]
|--base1odeJ <pa1h>]
|--uu1d <uu1d>]
vBoxhahage mod11yvm <uu1d]hame>
|--hame <hame>]
|--os1ype <os1ype>]
|--memoJy <memoJys1ze 1h hB>]
|--page1us1oh oh]o11]
|--vJam <vJams1ze 1h hB>]
|--acp1 oh]o11]
|--1oap1c oh]o11]
|--pae oh]o11]
|--hpe1 oh]o11]
|--hwv1J1ex oh]o11]
|--hwv1J1exexc oh]o11]
|--hes1edpag1hg oh]o11]
|--aJgepages oh]o11]
|--v1xvp1d oh]o11]
|--syh1hcpu oh]o11]
|--cpu1dse1 <ea1> <eax> <ebx> <ecx> <edx>]
|--cpu1dJemove <ea1>]
|--cpu1dJemovea]
|--haJdwaJeuu1d <uu1d>]
|--cpus <humbeJ>]
|--cpuho1pug oh]o11]
|--pugcpu <1d>]
|--uhpugcpu <1d>]
|--cpuexecu11ohcap <1-100>]
|--J1cuseu1c oh]o11]
|--moh11oJcouh1 <humbeJ>]
|--acceeJa1e3d oh]o11]
|--11JmwaJe b1os]e11]e1132]e1164]
|--ch1pse1 1ch9]p11x3]
|--b1osogo1ade1h oh]o11]
|--b1osogo1adeou1 oh]o11]
|--b1osogod1spay11me <msec>]
|--b1osogo1magepa1h <1magepa1h>]
|--b1osboo1mehu d1sabed]mehuohy]messageahdmehu]
|--b1ossys1em11meo11se1 <msec>]
|--b1ospxedebug oh]o11]
|--boo1<1-4> hohe]1oppy]dvd]d1sk]he1>]
|--h1c<1-h> hohe]hu]ha1]bJ1dged]1h1he1]
geheJ1c]
|--h1c1ype<1-h> Am79C970A]Am79C973]
|--cabecohhec1ed<1-h> oh]o11]
|--h1c1Jace<1-h> oh]o11]
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
3 de 38 11-04-2012 15.59
|--h1c1Jace11e<1-h> <11ehame>]
|--h1cpJopeJ1y<1-h> hame=|vaue]]
|--h1cspeed<1-h> <kbps>]
|--h1cboo1pJ1o<1-h> <pJ1oJ11y>]
|--h1cpJom1sc<1-h> dehy]aow-vms]aow-a]
|--h1cbahdw1d1hgJoup<1-h> hohe]<hame>]
|--bJ1dgeadap1eJ<1-h> hohe]<dev1cehame>]
|--1h1he1<1-h> <he1woJk hame>]
|--ha1he1<1-h> <he1woJk>]de1au1]
|--h1cgeheJ1cdJv<1-h> <dJ1veJ>
|--ha1se111hgs<1-h> |<m1u>],|<sockshd>],
|<sockJcv>],|<1cpshd>],
|<1cpJcv>]]
|--ha1p1<1-h> |<Juehame>],1cp]udp,|<hos11p>],
<hos1poJ1>,|<gues11p>],<gues1poJ1>]
|--ha1p1<1-h> dee1e <Juehame>]
|--ha1111ppJe11x<1-h> <pJe11x>]
|--ha1111p11e<1-h> <11e>]
|--ha1111pseJveJ<1-h> <1p>]
|--ha1b1hd1p<1-h> <1p>
|--ha1dhspassdoma1h<1-h> oh]o11]
|--ha1dhspJoxy<1-h> oh]o11]
|--ha1dhshos1JesoveJ<1-h> oh]o11]
|--ha1a1asmode<1-h> de1au1]|og],|pJoxyohy],
|samepoJ1s]]
|--macaddJess<1-h> au1o]<mac>]
|--mouse ps2]usb]usb1abe1
|--keyboaJd ps2]usb
|--uaJ1<1-h> o11]<T/0 base> <TR0>]
|--uaJ1mode<1-h> d1scohhec1ed]
seJveJ <p1pe>]
c1eh1 <p1pe>]
11e <11e>]
<dev1cehame>]
|--gues1memoJybaooh <baoohs1ze 1h hB>]
|--gues1s1a11s11cs1h1eJva <secohds>]
|--aud1o hohe]hu]dsouhd]soaud1o]oss]
oss]coJeaud1o]
|--aud1ocoh1JoeJ ac97]hda]sb16]
|--c1pboaJd d1sabed]hos11ogues1]gues11ohos1]
b1d1Jec11oha]
|--vJde oh]o11]
|--vJdeex1pack de1au1]<hame>
|--vJdepJopeJ1y <hame=|vaue]>]
|--vJdepoJ1 <hos1poJ1>]
|--vJdeaddJess <hos11p>]
|--vJdeau1h1ype hu]ex1eJha]gues1]
|--vJdeau1h1bJaJy de1au1]<hame>
|--vJdemu11coh oh]o11]
|--vJdeJeusecoh oh]o11]
|--vJdev1deochahhe oh]o11]
|--vJdev1deochahhequa11y <peJceh1>]
|--usb oh]o11]
|--usbehc1 oh]o11]
|--shapsho11odeJ de1au1]<pa1h>]
|--1eepoJ1eJ oh]o11]
|--1eepoJ1eJpoJ1 <poJ1>]
|--1eepoJ1eJaddJess <addJess]emp1y>
|--1eepoJ1eJpasswoJd <passwoJd>]
|--1eepoJ1eJpasswoJd11e <11e>]s1d1h]
vBoxhahage cohevm <uu1d>]<hame>
|--shapsho1 <uu1d>]<hame>]
|--mode mach1he]mach1heahdch1dJeh]a]
|--op11ohs 1hk]keepamacs]keepha1macs]
keepd1skhames]
|--hame <hame>]
|--base1odeJ <base1odeJ>]
|--uu1d <uu1d>]
|--Jeg1s1eJ]
vBoxhahage 1mpoJ1 <ov1/ova>
|--dJy-Juh]-h]
|--op11ohs keepamacs]keepha1macs]
|moJe op11ohs]
{Juh w11h -h 1o have op11ohs d1spayed
1oJ a paJ11cuaJ 0vF)
vBoxhahage expoJ1 <mach1hes> --ou1pu1]-o <ov1/ova>
|--egacy09]
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
4 de 38 11-04-2012 15.59
|--mah11es1]
|--vsys <humbeJ o1 v1J1ua sys1em>]
|--pJoduc1 <pJoduc1 hame>]
|--pJoduc1uJ <pJoduc1 uJ>]
|--vehdoJ <vehdoJ hame>]
|--vehdoJuJ <vehdoJ uJ>]
|--veJs1oh <veJs1oh 1h1o>]
|--eua <1cehse 1ex1>]
|--eua11e <11ehame>]
vBoxhahage s1aJ1vm <uu1d>]<hame>...
|--1ype gu1]sd]headess]
vBoxhahage coh1Jovm <uu1d>]<hame>
pause]Jesume]Jese1]poweJo11]saves1a1e]
acp1poweJbu11oh]acp1seepbu11oh]
keyboaJdpu1scahcode <hex> |<hex> ...]]
se11hks1a1e<1-h> oh]o11 ]
h1c<1-h> hu]ha1]bJ1dged]1h1he1]geheJ1c
|<dev1cehame>] ]
h1c1Jace<1-h> oh]o11
h1c1Jace11e<1-h> <11ehame>
h1cpJopeJ1y<1-h> hame=|vaue]
ha1p1<1-h> |<Juehame>],1cp]udp,|<hos11p>],
<hos1poJ1>,|<gues11p>],<gues1poJ1>
ha1p1<1-h> dee1e <Juehame>
gues1memoJybaooh <baoohs1ze 1h hB>]
gues1s1a11s11cs1h1eJva <secohds>]
usba11ach <uu1d>]<addJess> ]
usbde1ach <uu1d>]<addJess> ]
vJde oh]o11 ]
vJdepoJ1 <poJ1> ]
vJdepJopeJ1y <hame=|vaue]> ]
vJdev1deochahhequa11y <peJceh1>
se1v1deomodeh1h1 <xJes> <yJes> <bpp> |d1spay] ]
scJeehsho1phg <11e> |d1spay] ]
se1cJedeh11as <useJhame> <passwoJd> <doma1h>
|--aowocaogoh <yes]ho>] ]
1eepoJ1 --hos1 <hame> --poJ1 <poJ1>
|--maxdowh11me <msec>] |--passwoJd passwoJd]
pugcpu <1d>
uhpugcpu <1d>
cpuexecu11ohcap <1-100>
vBoxhahage d1scaJds1a1e <uu1d>]<hame>
vBoxhahage adop1s1a1e <uu1d>]<hame> <s1a1e_11e>
vBoxhahage shapsho1 <uu1d>]<hame>
1ake <hame> |--descJ1p11oh <desc>] |--pause] ]
dee1e <uu1d>]<hame> ]
Jes1oJe <uu1d>]<hame> ]
Jes1oJecuJJeh1 ]
ed11 <uu1d>]<hame>]--cuJJeh1
|--hame <hame>]
|--descJ1p11oh <desc>] ]
1s1 |--de1a1s]--mach1heJeadabe]
showvm1h1o <uu1d>]<hame>
vBoxhahage cosemed1um d1sk]dvd]1oppy <uu1d>]<11ehame>
|--dee1e]
vBoxhahage s1oJagea11ach <uu1d]vmhame>
--s1oJagec1 <hame>
|--poJ1 <humbeJ>]
|--dev1ce <humbeJ>]
|--1ype dvddJ1ve]hdd]1dd]
|--med1um hohe]emp1ydJ1ve]
<uu1d>]<11ehame>]hos1.<dJ1ve>]1scs1]
|--m1ype hoJma]wJ11e1hJough]1mmu1abe]shaJeabe]
Jeadohy]mu11a11ach]
|--commeh1 <1ex1>]
|--se1uu1d <uu1d>]
|--se1paJeh1uu1d <uu1d>]
|--pass1hJough oh]o11]
|--1empeec1 oh]o11]
|--hohJo1a11oha oh]o11]
|--bahdw1d1hgJoup <hame>]
|--1oJceuhmouh1]
|--seJveJ <hame>]<1p>]
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
5 de 38 11-04-2012 15.59
|--1aJge1 <1aJge1>]
|--1poJ1 <poJ1>]
|--uh <uh>]
|--ehcodeduh <uh>]
|--useJhame <useJhame>]
|--passwoJd <passwoJd>]
|--1h1he1]
vBoxhahage s1oJagec1 <uu1d]vmhame>
--hame <hame>
|--add 1de]sa1a]scs1]1oppy]sas]
|--coh1JoeJ LSTLog1c]LSTLog1cSAS]BusLog1c]
Th1eAhCT]PTTX3]PTTX4]TCh6]T82078]
|--sa1a1deemua11oh<1-4> <1-30>]
|--sa1apoJ1couh1 <1-30>]
|--hos11ocache oh]o11]
|--boo1abe oh]o11]
|--Jemove]
vBoxhahage bahdw1d1hc1 <uu1d]vmhame>
--hame <hame>
|--add d1sk]he1woJk]
|--1m11 <megaby1es peJ secohd>
|--dee1e]
vBoxhahage showhd1h1o <uu1d>]<11ehame>
vBoxhahage cJea1ehd --11ehame <11ehame>
--s1ze <megaby1es>]--s1zeby1e <by1es>
|--1oJma1 v0T]vh0K]vh0] {de1au1. v0T)
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
vBoxhahage mod11yhd <uu1d>]<11ehame>
|--1ype hoJma]wJ11e1hJough]1mmu1abe]shaJeabe]
Jeadohy]mu11a11ach]
|--au1oJese1 oh]o11]
|--compac1]
|--Jes1ze <megaby1es>]--Jes1zeby1e <by1es>]
vBoxhahage cohehd <uu1d>]<11ehame> <uu1d>]<ou1pu111e>
|--1oJma1 v0T]vh0K]vh0]RAW]<o1heJ>]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--ex1s11hg]
vBoxhahage cohveJ11JomJaw <11ehame> <ou1pu111e>
|--1oJma1 v0T]vh0K]vh0]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--uu1d <uu1d>
vBoxhahage cohveJ11JomJaw s1d1h <ou1pu111e> <by1es>
|--1oJma1 v0T]vh0K]vh0]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--uu1d <uu1d>
vBoxhahage ge1ex1Jada1a goba]<uu1d>]<hame>
<key>]ehumeJa1e
vBoxhahage se1ex1Jada1a goba]<uu1d>]<hame>
<key>
|<vaue>] {ho vaue dee1es key)
vBoxhahage se1pJopeJ1y mach1he1odeJ de1au1]<1odeJ> ]
vJdeau1h1bJaJy de1au1]<1bJaJy> ]
websJvau1h1bJaJy de1au1]hu]<1bJaJy> ]
vJdeex1pack hu]<1bJaJy> ]
ogh1s1oJycouh1 <vaue>
vBoxhahage usb111eJ add <1hdex,0-h>
--1aJge1 <uu1d>]<hame>]goba
--hame <s1J1hg>
--ac11oh 1ghoJe]hod {goba 111eJs ohy)
|--ac11ve yes]ho] {yes)
|--vehdoJ1d <XXXX>] {hu)
|--pJoduc11d <XXXX>] {hu)
|--Jev1s1oh <TTFF>] {hu)
|--mahu1ac1uJeJ <s1J1hg>] {hu)
|--pJoduc1 <s1J1hg>] {hu)
|--Jemo1e yes]ho] {hu, vh 111eJs ohy)
|--seJ1ahumbeJ <s1J1hg>] {hu)
|--masked1h1eJ1aces <XXXXXXXX>]
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
6 de 38 11-04-2012 15.59
vBoxhahage usb111eJ mod11y <1hdex,0-h>
--1aJge1 <uu1d>]<hame>]goba
|--hame <s1J1hg>]
|--ac11oh 1ghoJe]hod] {goba 111eJs ohy)
|--ac11ve yes]ho]
|--vehdoJ1d <XXXX>]""]
|--pJoduc11d <XXXX>]""]
|--Jev1s1oh <TTFF>]""]
|--mahu1ac1uJeJ <s1J1hg>]""]
|--pJoduc1 <s1J1hg>]""]
|--Jemo1e yes]ho] {hu, vh 111eJs ohy)
|--seJ1ahumbeJ <s1J1hg>]""]
|--masked1h1eJ1aces <XXXXXXXX>]
vBoxhahage usb111eJ Jemove <1hdex,0-h>
--1aJge1 <uu1d>]<hame>]goba
vBoxhahage shaJed1odeJ add <vmhame>]<uu1d>
--hame <hame> --hos1pa1h <hos1pa1h>
|--1Jahs1eh1] |--Jeadohy] |--au1omouh1]
vBoxhahage shaJed1odeJ Jemove <vmhame>]<uu1d>
--hame <hame> |--1Jahs1eh1]
vBoxhahage debugvm <uu1d>]<hame>
dumpgues1coJe --11ehame <hame> ]
1h1o <11em> |aJgs] ]
1hec1hm1 ]
og |--Jeease]--debug] <se111hgs> ...]
ogdes1 |--Jeease]--debug] <se111hgs> ...]
og1ags |--Jeease]--debug] <se111hgs> ...]
osde1ec1 ]
os1h1o ]
ge1Jeg1s1eJs |--cpu <1d>] <Jeg>]a ... ]
se1Jeg1s1eJs |--cpu <1d>] <Jeg>=<vaue> ... ]
s1a11s11cs |--Jese1] |--pa11eJh <pa11eJh>]
|--descJ1p11ohs]
vBoxhahage me1J1cs 1s1 |*]hos1]<vmhame> |<me1J1c_1s1>]]
{comma-sepaJa1ed)
vBoxhahage me1J1cs se1up
|--peJ1od <secohds>] {de1au1. 1)
|--sampes <couh1>] {de1au1. 1)
|--1s1]
|*]hos1]<vmhame> |<me1J1c_1s1>]]
vBoxhahage me1J1cs queJy |*]hos1]<vmhame> |<me1J1c_1s1>]]
vBoxhahage me1J1cs ehabe
|--1s1]
|*]hos1]<vmhame> |<me1J1c_1s1>]]
vBoxhahage me1J1cs d1sabe
|--1s1]
|*]hos1]<vmhame> |<me1J1c_1s1>]]
vBoxhahage me1J1cs coec1
|--peJ1od <secohds>] {de1au1. 1)
|--sampes <couh1>] {de1au1. 1)
|--1s1]
|--de1ach]
|*]hos1]<vmhame> |<me1J1c_1s1>]]
vBoxhahage dhcpseJveJ add]mod11y --he1hame <he1woJk_hame> ]
|--1p <1p_addJess>
--he1mask <he1woJk_mask>
--oweJ1p <oweJ_1p>
--uppeJ1p <uppeJ_1p>]
|--ehabe ] --d1sabe]
vBoxhahage dhcpseJveJ Jemove --he1hame <he1woJk_hame> ]
vBoxhahage ex1pack 1hs1a |--Jepace] <1aJba> ]
uh1hs1a |--1oJce] <hame> ]
ceahup
Each tme VBoxManage s nvoked, ony one command can be executed. However, a command mght
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
7 de 38 11-04-2012 15.59
support severa subcommands whch then can be nvoked n one snge ca. The foowng sectons provde
detaed reference nformaton on the dherent commands.
VBoxManage list
The 1s1 command gves reevant nformaton about your system and nformaton about VrtuaBox's
current settngs.
The foowng subcommands are avaabe wth vBoxhahage 1s1:
vms sts a vrtua machnes currenty regstered wth VrtuaBox. By defaut ths dspays a compact
st wth each VM's name and UUID; f you aso specfy --ohg or -, ths w be a detaed st as wth
the showvm1h1o command (see beow).
Juhh1hgvms sts a currenty runnng vrtua machnes by ther unque denters (UUIDs) n the same
format as wth vms.
os1ypes sts a guest operatng systems presenty known to VrtuaBox, aong wth the denters used
to refer to them wth the mod11yvm command.
hos1dvds, hos11opp1es, respectvey, st DVD, oppy, brdged networkng and host-ony networkng
nterfaces on the host, aong wth the name used to access them from wthn VrtuaBox.
bJ1dged11s, hos1ohy11s and dhcpseJveJs, respectvey, st brdged network nterfaces, host-ony network
nterfaces and DHCP servers currenty avaabe on the host. Pease see Chapter 6, Virtual networking
for detas on these.
hos11h1o dspays nformaton about the host system, such as CPUs, memory sze and operatng
system verson.
hos1cpu1ds dumps the CPUID parameters for the host CPUs. Ths can be used for a more ne graned
anays of the host's vrtuazaton capabtes.
hddbackehds sts a known vrtua dsk back-ends of VrtuaBox. For each such format (such as VDI,
VMDK or RAW), ths sts the back-end's capabtes and conguraton.
hdds, dvds and 1opp1es a gve you nformaton about vrtua dsk mages currenty n use by
VrtuaBox, ncudng a ther settngs, the unque denters (UUIDs) assocated wth them by
VrtuaBox and a es assocated wth them. Ths s the command-ne equvaent of the Vrtua
Meda Manager; see the secton caed "The Vrtua Meda Manager".
usbhos1 suppes nformaton about USB devces attached to the host, notaby nformaton usefu for
constructng USB ters and whether they are currenty n use by the host.
usb111eJs sts a goba USB ters regstered wth VrtuaBox -- that s, ters for devces whch are
accessbe to a vrtua machnes -- and dspays the ter parameters.
sys1empJopeJ11es dspays some goba VrtuaBox settngs, such as mnmum and maxmum guest RAM
and vrtua hard dsk sze, foder settngs and the current authentcaton brary n use.
ex1packs dspays a VrtuaBox extenson packs currenty nstaed; see the secton caed "Instang
VrtuaBox and extenson packs" and the secton caed "VBoxManage extpack" for more nformaton.
VBoxManage showvminfo
The showvm1h1o command shows nformaton about a partcuar vrtua machne. Ths s the same nformaton
as vBoxhahage 1s1 vms --ohg woud show for a vrtua machnes.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
8 de 38 11-04-2012 15.59
You w get nformaton smar to the foowng:
$ vBoxhahage showvm1h1o "W1hdows XP"
v1J1uaBox Commahd L1he hahagemeh1 Th1eJ1ace veJs1oh 4.1.12
{C) 2005-2012 0Jace CoJpoJa11oh
A J1gh1s JeseJved.
hame. W1hdows XP
Cues1 0S. 01heJ/bhkhowh
bbT0. 1b13464d-57c6-4d49-92a9-a5cc3816b7e7
Coh11g 11e. /home/useJhame/.v1J1uaBox/hach1hes/W1hdows XP/W1hdows XP.xm
hemoJy s1ze. 512hB
vRAh s1ze. 12hB
humbeJ o1 CPbs. 2
Syh1he11c Cpu. o11
Boo1 mehu mode. message ahd mehu
Boo1 0ev1ce {1). 0v0
Boo1 0ev1ce {2). haJd01sk
Boo1 0ev1ce {3). ho1 Ass1ghed
Boo1 0ev1ce {4). ho1 Ass1ghed
ACPT. oh
T0APTC. oh
PAE. oh
T1me o11se1. 0 ms
haJdw. v1J1.ex1. oh
haJdw. v1J1.ex1 excus1ve. oh
hes1ed Pag1hg. oh
vT-x vPT0. o11
S1a1e. poweJed o11 {s1hce 2009-10-20T14.52.19.000000000)
hoh11oJ couh1. 1
30 AcceeJa11oh. o11
20 v1deo AcceeJa11oh. o11
TeepoJ1eJ Ehabed. o11
TeepoJ1eJ PoJ1. 0
TeepoJ1eJ AddJess.
TeepoJ1eJ PasswoJd.
S1oJage Coh1JoeJ {0). T0E Coh1JoeJ
S1oJage Coh1JoeJ Type {0). PTTX4
S1oJage Coh1JoeJ {1). Foppy Coh1JoeJ 1
S1oJage Coh1JoeJ Type {1). T82078
T0E Coh1JoeJ {0, 0). /home/useJ/w1hdows.vd1 {bbT0. 4616e53a-4557-460a-9b95-68b0117d744b)
T0E Coh1JoeJ {0, 1). /home/useJ/opehbsd-cd46.1so {bbT0. 4335e162-59d3-4512-91d5-b63e94eebe0b)
Foppy Coh1JoeJ 1 {0, 0). /home/useJ/1oppy.1mg {bbT0. 62ac6ccb-d136-4212-972e-221836368137)
hTC 1. d1sabed
hTC 2. d1sabed
hTC 3. d1sabed
hTC 4. d1sabed
hTC 5. d1sabed
hTC 6. d1sabed
hTC 7. d1sabed
hTC 8. d1sabed
bART 1. d1sabed
bART 2. d1sabed
Aud1o. d1sabed {0J1veJ. bhkhowh)
C1pboaJd hode. B1d1Jec11oha
vR0E. d1sabed
bSB. d1sabed
bSB 0ev1ce F11eJs.
<hohe>
ShaJed 1odeJs.
<hohe>
S1a11s11cs upda1e. d1sabed
VBoxManage registervm } unregistervm
The Jeg1s1eJvm command aows you to mport a vrtua machne denton n an XML e nto VrtuaBox. The
machne must not conct wth one aready regstered n VrtuaBox and t may not have any hard or
removabe dsks attached. It s advsabe to pace the denton e n the machnes foder before
regsterng t.
Note
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
9 de 38 11-04-2012 15.59
When creatng a new vrtua machne wth vBoxhahage cJea1evm (see beow), you can drecty
specfy the --Jeg1s1eJ opton to avod havng to regster t separatey.
The uhJeg1s1eJvm command unregsters a vrtua machne. If --dee1e s aso speced, the foowng es w
automatcay be deeted as we:
a hard dsk mage es, ncudng dherencng es, whch are used by the machne and not shared
wth other machnes;
1.
saved state es that the machne created, f any (one f the machne was n "saved" state and one
for each onne snapshot);
2.
the machne XML e and ts backups; 3.
the machne og es, f any; 4.
the machne drectory, f t s empty after havng deeted a the above. 5.
VBoxManage createvm
Ths command creates a new XML vrtua machne denton e.
The --hame <hame> parameter s requred and must specfy the name of the machne. Snce ths name s used
by defaut as the e name of the settngs e (wth the extenson .xm) and the machne foder (a subfoder
of the .v1J1uaBox/hach1hes foder), t must conform to your host operatng system's requrements for e
name speccatons. If the VM s ater renamed, the e and foder names w change automatcay.
However, f the --base1odeJ <pa1h> opton s used, the machne foder w be named <pa1h>. In ths case, the
names of the e and the foder w not change f the vrtua machne s renamed.
By defaut, ths command ony creates the XML e wthout automatcay regsterng the VM wth your
VrtuaBox nstaaton. To regster the VM nstanty, use the optona --Jeg1s1eJ opton, or run vBoxhahage
Jeg1s1eJvm separatey afterwards.
VBoxManage modifyvm
Ths command changes the propertes of a regstered vrtua machne whch s not runnng. Most of the
propertes that ths command makes avaabe correspond to the VM settngs that VrtuaBox graphca user
nterface dspays n each VM's "Settngs" daog; these were descrbed n Chapter 3, Conhguring virtual
machines. Some of the more advanced settngs, however, are ony avaabe through the vBoxhahage
nterface.
These commands requre that the machne s powered oh (nether runnng nor n "saved" state). Some
machne settngs can aso be changed whe a machne s runnng; those settngs w then have a
correspondng subcommand wth the vBoxhahage coh1Jovm subcommand (see the secton caed
"VBoxManage controvm").
General settings
The foowng genera settngs are avaabe through vBoxhahage mod11yvm:
--hame <hame>: Ths changes the VM's name and possby renames the nterna vrtua machne es, as
descrbed wth vBoxhahage cJea1evm above.
--os1ype <os1ype>: Ths speces what guest operatng system s supposed to run n the VM. To earn
about the varous denters that can be used here, use vBoxhahage 1s1 os1ypes.
--memoJy <memoJys1ze>: Ths sets the amount of RAM, n MB, that the vrtua machne shoud aocate for
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
10 de 38 11-04-2012 15.59
tsef from the host. See the remarks n the secton caed "Creatng your rst vrtua machne" for
more nformaton.
--vJam <vJams1ze>: Ths sets the amount of RAM that the vrtua graphcs card shoud have. See the
secton caed "Dspay settngs" for detas.
--acp1 oh]o11; --1oap1c oh]o11: These two determne whether the VM shoud have ACPI and I/O APIC
support, respectvey; see the secton caed ""Motherboard" tab" for detas.
--haJdwaJeuu1d <uu1d>: The UUID presented to the guest va memory tabes (DMI/SMBIOS), hardware
and guest propertes. By defaut ths s the same as the VM uud. Usefu when conng a VM.
Teeportng takes care of ths automatcay.
--cpus <cpucouh1>: Ths sets the number of vrtua CPUs for the vrtua machne (see the secton caed
""Processor" tab"). If CPU hot-puggng s enabed (see beow), ths then sets the maximum number
of vrtua CPUs that can be pugged nto the vrtua machnes.
--J1cuseu1c oh]o11: Ths opton ets the rea-tme cock (RTC) operate n UTC tme (see the secton
caed ""Motherboard" tab").
--cpuho1pug oh]o11: Ths enabes CPU hot-puggng. When enabed, vrtua CPUs can be added to and
removed from a vrtua machne whe t s runnng. See the secton caed "CPU hot-puggng" for
more nformaton.
--pugcpu]uhpugcpu <1d>: If CPU hot-puggng s enabed (see above), ths adds a vrtua CPU to the
vrtua machnes (or removes one). <1d> speces the ndex of the vrtua CPU to be added or removed
and must be a number from 0 to the maxmum no. of CPUs congured wth the --cpus opton. CPU 0
can never be removed.
--cpuexecu11ohcap <1-100>: Ths settng contros how much cpu tme a vrtua CPU can use. A vaue of 50
mpes a snge vrtua CPU can use up to 50% of a snge host CPU.
--syh1hcpu oh]o11: Ths settng determnes whether VrtuaBox w expose a synthetc CPU to the guest
to aow ve mgraton between host systems that dher sgncanty.
--pae oh]o11: Ths enabes/dsabes PAE (see the secton caed ""Processor" tab").
--hpe1 oh]o11: Ths enabes/dsabes a Hgh Precson Event Tmer (HPET) whch can repace the egacy
system tmers. Ths s turned oh by defaut. Note that Wndows supports a HPET ony from Vsta
onwards.
--hwv1J1ex oh]o11: Ths enabes or dsabes the use of hardware vrtuazaton extensons (Inte VT-x or
AMD-V) n the processor of your host system; see the secton caed "Hardware vs. software
vrtuazaton".
--hwv1J1exexc oh]o11: Ths speces whether VrtuaBox w make excusve use of the hardware
vrtuazaton extensons (Inte VT-x or AMD-V) n the processor of your host system; see the secton
caed "Hardware vs. software vrtuazaton". If you wsh to smutaneousy share these extensons
wth other hypervsors, then you must dsabe ths settng. Dong so has negatve performance
mpcatons.
--hes1edpag1hg oh]o11: If hardware vrtuazaton s enabed, ths addtona settng enabes or dsabes
the use of the nested pagng feature n the processor of your host system; see the secton caed
"Hardware vs. software vrtuazaton".
--aJgepages oh]o11: If hardware vrtuazaton and nested pagng are enabed, for Inte VT-x ony, an
addtona performance mprovement of up to 5% can be obtaned by enabng ths settng. Ths
causes the hypervsor to use arge pages to reduce TLB use and overhead.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
11 de 38 11-04-2012 15.59
--v1xvp1d oh]o11: If hardware vrtuazaton s enabed, for Inte VT-x ony, ths addtona settng
enabes or dsabes the use of the tagged TLB (VPID) feature n the processor of your host system;
see the secton caed "Hardware vs. software vrtuazaton".
--acceeJa1e3d oh]o11: Ths enabes, f the Guest Addtons are nstaed, whether hardware 3D
acceeraton shoud be avaabe; see the secton caed "Hardware 3D acceeraton (OpenGL and
Drect3D 8/9)".
You can nuence the BIOS ogo that s dspayed when a vrtua machne starts up wth a number of
settngs. Per defaut, a VrtuaBox ogo s dspayed.
Wth --b1osogo1ade1h oh]o11 and --b1osogo1adeou1 oh]o11, you can determne whether the ogo shoud
fade n and out, respectvey.
Wth --b1osogod1spay11me <msec> you can set how ong the ogo shoud be vsbe, n mseconds.
Wth --b1osogo1magepa1h <1magepa1h> you can, f you are so ncned, repace the mage that s shown,
wth your own ogo. The mage must be an uncompressed 256 coor BMP e.
--b1osboo1mehu d1sabed]mehuohy]messageahdmehu: Ths speces whether the BIOS aows the user to seect
a temporary boot devce. mehuohy suppresses the message, but the user can st press F12 to seect a
temporary boot devce.
--boo1<1-4> hohe]1oppy]dvd]d1sk]he1: Ths speces the boot order for the vrtua machne. There are
four "sots", whch the VM w try to access from 1 to 4, and for each of whch you can set a devce
that the VM shoud attempt to boot from.
--shapsho11odeJ de1au1]<pa1h>: Ths aows you to specfy the foder n whch snapshots w be kept for
a vrtua machne.
--11JmwaJe e11]b1os: Speces whch rmware s used to boot partcuar vrtua machne: EFI or BIOS.
Use EFI ony f your fuy understand what you're dong.
--gues1memoJybaooh <s1ze> sets the defaut sze of the guest memory baoon, that s, memory
aocated by the VrtuaBox Guest Addtons from the guest operatng system and returned to the
hypervsor for re-use by other vrtua machnes. <sze> must be speced n megabytes. The defaut
sze s 0 megabytes. For detas, see the secton caed "Memory baoonng".
Networking settings
The foowng networkng settngs are avaabe through vBoxhahage mod11yvm. Wth a these settngs, the
decma number drecty foowng the opton name ("1-N" n the st beow) speces the vrtua network
adapter whose settngs shoud be changed.
--h1c<1-h> hohe]hu]ha1]bJ1dged]1h1he1]hos1ohy]geheJ1c : Wth ths, you can set, for each of the VM's
vrtua network cards, what type of networkng shoud be avaabe. They can be not present (hohe),
not connected to the host (hu), use network address transaton (ha1), brdged networkng (bJ1dged)
or communcate wth other vrtua machnes usng nterna networkng (1h1he1), host-ony networkng
(hos1ohy), or access rarey used sub-modes (geheJ1c). These optons correspond to the modes whch
are descrbed n deta n the secton caed "Introducton to networkng modes".
--h1c1ype<1-h> Am79C970A]Am79C973]82540Eh]82543CC]82545Eh]v1J11o: Ths aows you, for each of the VM's
vrtua network cards, to specfy whch networkng hardware VrtuaBox presents to the guest; see
the secton caed "Vrtua networkng hardware".
--cabecohhec1ed<1-h> oh]o11: Ths aows you to temporary dsconnect a vrtua network nterface, as f
a network cabe had been pued from a rea network card. Ths mght be usefu for resettng certan
software components n the VM.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
12 de 38 11-04-2012 15.59
Wth the "nctrace" optons, you can optonay trace network tramc by dumpng t to a e, for
debuggng purposes.
Wth --h1c1Jace<1-h> oh]o11, you can enabe network tracng for a partcuar vrtua network card.
If enabed, you must specfy wth --h1c1Jace11e<1-h> <11ehame> what e the trace shoud be ogged to.
--bJ1dgeadap1eJ<1-h> hohe]<dev1cehame>: If brdged networkng has been enabed for a vrtua network
card (see the --h1c opton above; otherwse ths settng has no ehect), use ths opton to specfy
whch host nterface the gven vrtua network nterface w use. For detas, pease see the secton
caed "Brdged networkng".
--hos1ohyadap1eJ<1-h> hohe]<dev1cehame>: If host-ony networkng has been enabed for a vrtua network
card (see the --nc opton above; otherwse ths settng has no ehect), use ths opton to specfy
whch host-ony networkng nterface the gven vrtua network nterface w use. For detas, pease
see the secton caed "Host-ony networkng".
--1h1he1<1-h> he1woJk: If nterna networkng has been enabed for a vrtua network card (see the --h1c
opton above; otherwse ths settng has no ehect), use ths opton to specfy the name of the nterna
network (see the secton caed "Interna networkng").
--macaddJess<1-h> au1o]<mac>: Wth ths opton you can set the MAC address of the vrtua network card.
Normay, each vrtua network card s assgned a random address by VrtuaBox at VM creaton.
--h1cgeheJ1cdJv<1-h> <backehd dJ1veJ>: If generc networkng has been enabed for a vrtua network card
(see the --h1c opton above; otherwse ths settng has no ehect), ths mode aows you to access
rarey used networkng sub-modes, such as VDE network or UDP Tunne.
--h1cpJopeJ1y<1-h> <paJamhame>="paJamvaue": Ths opton, n combnaton wth "ncgenercdrv" aows you
to pass parameters to rarey-used network backends.
Those parameters are backend engne-specc, and are dherent between UDP Tunne and the VDE
backend drvers. For exampe, pease see the secton caed "UDP Tunne networkng".
NAT Networking settings.
The foowng NAT networkng settngs are avaabe through vBoxhahage mod11yvm. Wth a these settngs, the
decma number drecty foowng the opton name ("1-N" n the st beow) speces the vrtua network
adapter whose settngs shoud be changed.
--ha1p1<1-h> |<hame>],1cp]udp,|<hos11p>],<hos1poJ1>,|<gues11p>], <gues1poJ1>: Ths opton denes a NAT
port-forwardng rue (pease see the secton caed "Congurng port forwardng wth NAT" for
detas).
--ha1p1<1-h> dee1e <hame>: Ths opton deetes a NAT port-forwardng rue (pease see the secton caed
"Congurng port forwardng wth NAT" for detas).
--ha1111ppJe11x<1-h> <pJe11x>: Ths opton denes a prex for the but-n TFTP server, .e. where the
boot e s ocated (pease see the secton caed "PXE bootng wth NAT" and the secton caed
"Congurng the boot server (next server) of a NAT network nterface" for detas).
--ha1111p11e<1-h> <boo111e>: Ths opton denes the TFT boot e (pease see the secton caed
"Congurng the boot server (next server) of a NAT network nterface" for detas).
--ha1111pseJveJ<1-h> <111pseJveJ>: Ths opton denes the TFTP server address to boot from (pease see
the secton caed "Congurng the boot server (next server) of a NAT network nterface" for detas).
--ha1dhspassdoma1h<1-h> oh]o11: Ths opton speces whether the but-n DHCP server passes the
doman name for network name resouton.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
13 de 38 11-04-2012 15.59
--ha1dhspJoxy<1-h> oh]o11: Ths opton makes the NAT engne proxy a guest DNS requests to the host's
DNS servers (pease see the secton caed "Enabng DNS proxy n NAT mode" for detas).
--ha1dhshos1JesoveJ<1-h> oh]o11: Ths opton makes the NAT engne use the host's resover mechansms
to hande DNS requests (pease see the secton caed "Enabng DNS proxy n NAT mode" for detas).
--ha1ha1se111hgs<1-h> |<m1u>],|<sockshd>],|<sockJcv>],|<1cpshd>], |<1cpJcv>]: Ths opton contros severa
NAT settngs (pease see the secton caed "Tunng TCP/IP buhers for NAT" for detas).
--ha1a1asmode<1-h> de1au1]|og],|pJoxyohy],|samepoJ1s]: Ths opton denes behavour of NAT engne
core: og - enabes oggng, proxyony - swtches of aasng mode makes NAT transparent, sameports
enforces NAT engne to send packets va the same port as they orgnated on, defaut - dsabe a
mentoned modes above . (pease see the secton caed "Congurng aasng of the NAT engne" for
detas).
Serial port, audio, clipboard, remote desktop and USB settings
The foowng other hardware settngs are avaabe through vBoxhahage mod11yvm:
--uaJ1<1-h> o11]<T/0 base> <TR0>: Wth ths opton you can congure vrtua sera ports for the VM; see
the secton caed "Sera ports" for an ntroducton.
--uaJ1mode<1-h> <aJg>: Ths settng contros how VrtuaBox connects a gven vrtua sera port
(prevousy congured wth the --uaJ1X settng, see above) to the host on whch the vrtua machne s
runnng. As descrbed n deta n the secton caed "Sera ports", for each such port, you can specfy
<aJg> as one of the foowng optons:
d1scohhec1ed: Even though the sera port s shown to the guest, t has no "other end" -- ke a
rea COM port wthout a cabe.
seJveJ <p1pehame>: On a Wndows host, ths tes VrtuaBox to create a named ppe on the host
named <p1pehame> and connect the vrtua sera devce to t. Note that Wndows requres that
the name of a named ppe begn wth \\.\p1pe\.
On a Lnux host, nstead of a named ppe, a oca doman socket s used.
c1eh1 <p1pehame>: Ths operates |ust ke seJveJ ..., except that the ppe (or oca doman socket)
s not created by VrtuaBox, but assumed to exst aready.
<dev1cehame>: If, nstead of the above, the devce name of a physca hardware sera port of the
host s speced, the vrtua sera port s connected to that hardware port. On a Wndows host,
the devce name w be a COM port such as C0h1; on a Lnux host, the devce name w ook ke
/dev/11yS0. Ths aows you to "wre" a rea sera port to a vrtua machne.
--aud1o hohe]hu]oss: Wth ths opton, you can set whether the VM shoud have audo support.
--c1pboaJd d1sabed]hos11ogues1]gues11ohos1]b1d1Jec11oha: Wth ths settng, you can seect whether the
guest operatng system's cpboard shoud be shared wth the host; see the secton caed "Genera
settngs". Ths requres that the Guest Addtons be nstaed n the vrtua machne.
--moh11oJcouh1 <couh1>: Ths enabes mut-montor support; see the secton caed "Dspay settngs".
--usb oh]o11: Ths opton enabes or dsabes the VM's vrtua USB controer; see the secton caed
"USB settngs" for detas.
--usbehc1 oh]o11: Ths opton enabes or dsabes the VM's vrtua USB 2.0 controer; see the secton
caed "USB settngs" for detas.
Remote machine settings
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
14 de 38 11-04-2012 15.59
The foowng settngs that ahect remote machne behavor are avaabe through vBoxhahage mod11yvm:
--vJde oh]o11: Wth the VrtuaBox graphca user nterface, ths enabes or dsabes the VrtuaBox
remote desktop extenson (VRDE) server. Note that f you are usng vBoxheadess (see the secton
caed "VBoxHeadess, the remote desktop server"), VRDE s enabed by defaut.
--vJdepoJ1 de1au1]<poJ1s>: A port or a range of ports the VRDE server can bnd to; "defaut" or "0"
means port 3389, the standard port for RDP. You can specfy a comma-separated st of ports or
ranges of ports. Use a dash between two port numbers to specfy a range. The VRDE server w bnd
to one of avaabe ports from the speced st. Ony one machne can use a gven port at a tme. For
exampe, the opton --vJdepoJ1 5000,5010-5012 w te the server to bnd to one of foowng ports: 5000,
5010, 5011 or 5012.
--vJdeaddJess <TP addJess>: The IP address of the host network nterface the VRDE server w bnd to. If
speced, the server w accept connectons ony on the speced host network nterface.
--vJdeau1h1ype hu]ex1eJha]gues1: Ths aows you to choose whether and how authorzaton w be
performed; see the secton caed "RDP authentcaton" for detas.
--vJdemu11coh oh]o11: Ths enabes mutpe connectons to the same VRDE server, f the server
supports ths feature; see the secton caed "Mutpe connectons to the VRDP server".
--vJdeJeusecoh oh]o11: Ths speces the VRDE server behavor when mutpe connectons are dsabed.
When ths opton s enabed, the server w aow a new cent to connect and w drop the exstng
connecton. When ths opton s dsabed (ths s the defaut settng), a new connecton w not be
accepted f there s aready a cent connected to the server.
--vJdev1deochahhe oh]o11: Ths enabes vdeo redrecton, f t s supported by the VRDE server; see the
secton caed "VRDP vdeo redrecton".
--vJdev1deochahhequa11y <peJceh1>: Sets the mage quaty for vdeo redrecton; see the secton caed
"VRDP vdeo redrecton".
Teleporting settings
Wth the foowng commands for vBoxhahage mod11yvm you can congure a machne to be a target for
teeportng. See the secton caed "Teeportng" for an ntroducton.
--1eepoJ1eJ oh]o11: Wth ths settng you turn on or oh whether a machne wats for a teeportng
request to come n on the network when t s started. If "on", when the machne s started, t does not
boot the vrtua machne as t woud normay; nstead, t then wats for a teeportng request to come
n on the port and address sted wth the next two parameters.
--1eepoJ1eJpoJ1 <poJ1>, --1eepoJ1eJaddJess <addJess>: these must be used wth --teeporter and te the
vrtua machne on whch port and address t shoud sten for a teeportng request from another
vrtua machne. <poJ1> can be any free TCP/IP port number (e.g. 6000); <addJess> can be any IP
address or hostname and speces the TCP/IP socket to bnd to. The defaut s "0.0.0.0", whch means
any address.
--1eepoJ1eJpasswoJd <passwoJd>: f ths optona argument s gven, then the teeportng request w ony
succeed f the source machne speces the same password as the one gven wth ths command.
--1eepoJ1eJpasswoJd11e <passwoJd>: f ths optona argument s gven, then the teeportng request w
ony succeed f the source machne speces the same password as the one speced n the e gve
wth ths command. Use s1d1h to read the password from stdn.
--cpu1d <ea1> <eax> <ebx> <ecx> <edx>: Advanced users can use ths command before a teeportng
operaton to restrct the vrtua CPU capabtes that VrtuaBox presents to the guest operatng
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
15 de 38 11-04-2012 15.59
system. Ths must be run on both the source and the target machnes nvoved n the teeportng and
w then modfy what the guest sees when t executes the CPbT0 machne nstructon. Ths mght hep
wth msbehavng appcatons that wrongy assume that certan CPU capabtes are present. The
meanng of the parameters s hardware dependent; pease refer to the AMD or Inte processor
manuas.
VBoxManage clonevm
Ths command creates a fu or nked copy of an exstng vrtua machne.
The cohevm subcommand takes at east the name of the vrtua machne whch shoud be coned. The
foowng addtona settngs can be used to further congure the cone VM operaton:
--shapsho1 <uu1d>]<hame>: Seect a specc snapshot where the cone operaton shoud refer to. Defaut
s referrng to the current state.
--mode mach1he]mach1heahdch1dJeh]a: Seects the conng mode of the operaton. If mach1he s seected
(the defaut), the current state of the VM wthout any snapshots s coned. In the mach1heahdch1dJeh
mode the snapshot provded by --shapsho1 and a chd snapshots are coned. If a s the seected
mode a snapshots and the current state are coned.
--op11ohs 1hk]keepamacs]keepha1macs]keepd1skhames: Aows addtona ne tunng of the cone operaton.
The rst opton denes that a nked cone shoud be created, whch s ony possbe for a machne
cone from a snapshot. The next two optons aow to dene how the MAC addresses of every vrtua
network card shoud be handed. They can ether be rentazed (the defaut), eft unchanged
(keepamacs) or eft unchanged when the network type s NAT (keepha1macs). If you add keepd1skhames a
new dsk mages are caed ke the orgna once, otherwse they are renamed.
--hame <hame>: Seect a new name for the new vrtua machne. Defaut s "Orgna Name Cone".
--base1odeJ <base1odeJ>: Seect the foder where the new vrtua machne conguraton shoud be
saved n.
--uu1d <uu1d>: Seect the UUID the new VM shoud have. Ths d has to be unque n the VrtuaBox
nstance ths cone shoud be regstered. Defaut s creatng a new UUID.
--Jeg1s1eJ: Automatcay regster the new cone n ths VrtuaBox nstaaton. If you manuay want
regster the new VM ater, see the secton caed "VBoxManage regstervm / unregstervm" for
nstructons how to do so.
VBoxManage import
Ths command mports a vrtua appance n OVF format by copyng the vrtua dsk mages and creatng
vrtua machnes n VrtuaBox. See the secton caed "Importng and exportng vrtua machnes" for an
ntroducton to appances.
The 1mpoJ1 subcommand takes at east the path name of an OVF e as nput and expects the dsk mages, f
needed, n the same drectory as the OVF e. A ot of addtona command-ne optons are supported to
contro n deta what s beng mported and modfy the mport parameters, but the detas depend on the
content of the OVF e.
It s therefore recommended to rst run the mport subcommand wth the --dJy-Juh or -h opton. Ths w
then prnt a descrpton of the appance's contents to the screen how t woud be mported nto VrtuaBox,
together wth the optona command-ne optons to nuence the mport behavor.
As an exampe, here s the screen output wth a sampe appance contanng a Wndows XP guest:
vBoxhahage 1mpoJ1 W1hdowsXp.ov1 --dJy-Juh
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
16 de 38 11-04-2012 15.59
Th1eJpJe11hg W1hdowsXp.ov1...
0K.
v1J1ua sys1em 0.
0. Sugges1ed 0S 1ype. "W1hdowsXP"
{chahge w11h "--vsys 0 --os1ype <1ype>", use "1s1 os1ypes" 1o 1s1 a)
1. Sugges1ed vh hame "W1hdows XP PJo1ess1oha_1"
{chahge w11h "--vsys 0 --vmhame <hame>")
3. humbeJ o1 CPbs. 1
{chahge w11h "--vsys 0 --cpus <h>")
4. Cues1 memoJy. 956 hB {chahge w11h "--vsys 0 --memoJy <hB>")
5. Souhd caJd {app1ahce expec1s "ehsoh1q1371", cah chahge oh 1mpoJ1)
{d1sabe w11h "--vsys 0 --uh11 5 --1ghoJe")
6. bSB coh1JoeJ
{d1sabe w11h "--vsys 0 --uh11 6 --1ghoJe")
7. he1woJk adap1eJ. oJ1g bJ1dged, coh11g 2, ex1Ja 1ype=bJ1dged
8. Foppy
{d1sabe w11h "--vsys 0 --uh11 8 --1ghoJe")
9. SCST coh1JoeJ, 1ype BusLog1c
{chahge w11h "--vsys 0 --uh11 9 --scs11ype {BusLog1c]Ls1Log1c}",
d1sabe w11h "--vsys 0 --uh11 9 --1ghoJe")
10. T0E coh1JoeJ, 1ype PTTX4
{d1sabe w11h "--vsys 0 --uh11 10 --1ghoJe")
11. haJd d1sk 1mage. souJce 1mage=W1hdowsXp.vmdk,
1aJge1 pa1h=/home/useJ/d1sks/W1hdowsXp.vmdk, coh1JoeJ=9,chahhe=0
{chahge coh1JoeJ w11h "--vsys 0 --uh11 11 --coh1JoeJ <1d>",
d1sabe w11h "--vsys 0 --uh11 11 --1ghoJe")
As you can see, the ndvdua conguraton tems are numbered, and dependng on ther type support
dherent command-ne optons. The mport subcommand can be drected to gnore many such tems wth a
--vsys X --uh11 Y --1ghoJe opton, where X s the number of the vrtua system (zero uness there are severa
vrtua system descrptons n the appance) and Y the tem number, as prnted on the screen.
In the above exampe, Item #1 speces the name of the target machne n VrtuaBox. Items #9 and #10
specfy hard dsk controers, respectvey. Item #11 descrbes a hard dsk mage; n ths case, the
addtona --coh1JoeJ opton ndcates whch tem the dsk mage shoud be connected to, wth the defaut
comng from the OVF e.
You can combne severa tems for the same vrtua system behnd the same --vsys opton. For exampe, to
mport a machne as descrbed n the OVF, but wthout the sound card and wthout the USB controer, and
wth the dsk mage connected to the IDE controer nstead of the SCSI controer, use ths:
vBoxhahage 1mpoJ1 W1hdowsXp.ov1
--vsys 0 --uh11 5 --1ghoJe --uh11 6 --1ghoJe --uh11 11 --coh1JoeJ 10
VBoxManage export
Ths command exports one or more vrtua machnes from VrtuaBox nto a vrtua appance n OVF format,
ncudng copyng ther vrtua dsk mages to compressed VMDK. See the secton caed "Importng and
exportng vrtua machnes" for an ntroducton to appances.
The expoJ1 command s smpe to use: st the machne (or the machnes) that you woud ke to export to
the same OVF e and specfy the target OVF e after an addtona --ou1pu1 or -o opton. Note that the
drectory of the target OVF e w aso receve the exported dsk mages n the compressed VMDK format
(regardess of the orgna format) and shoud have enough dsk space eft for them.
Besde a smpe export of a gven vrtua machne, you can append severa product nformaton to the
appance e. Use --pJoduc1, --pJoduc1uJ, --vehdoJ, --vehdoJuJ and --veJs1oh to specfy ths addtona
nformaton. For ega reasons you may add a cense text or the content of a cense e by usng the --eua
and --eua11e opton respectvey. As wth OVF mport, you must use the --vsys X opton to drect the
prevousy mentoned optons to the correct vrtua machne.
For vrtuazaton products whch aren't fuy compatbe wth the OVF standard 1.0 you can enabe a OVF
0.9 egacy mode wth the --egacy09 opton.
VBoxManage startvm
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
17 de 38 11-04-2012 15.59
Ths command starts a vrtua machne that s currenty n the "Powered oh" or "Saved" states.
Note
Ths s provded for backwards compatbty ony. We recommend to start vrtua machnes
drecty by runnng the respectve front-end, as you mght otherwse mss mportant error
and state nformaton that VrtuaBox may dspay on the consoe. Ths s especay
mportant for front-ends other than v1J1uaBox, our graphca user nterface, because those
cannot dspay error messages n a popup wndow. See the secton caed "VBoxHeadess,
the remote desktop server" for more nformaton.
The optona --1ype specer determnes whether the machne w be started n a wndow (GUI mode, whch
s the defaut) or whether the output shoud go through vBoxheadess, wth VRDE enabed or not; see the
secton caed "VBoxHeadess, the remote desktop server" for more nformaton. The st of types s sub|ect
to change, and t's not guaranteed that a types are accepted by any product varant.
The foowng vaues are aowed:
gu
Starts a VM showng a GUI wndow. Ths s the defaut.
headess
Starts a VM wthout a wndow for remote dspay ony.
VBoxManage controlvm
The coh1Jovm subcommand aows you to change the state of a vrtua machne that s currenty runnng.
The foowng can be speced:
vBoxhahage coh1Jovm <vm> pause temporary puts a vrtua machne on hod, wthout changng ts state
for good. The VM wndow w be panted n gray to ndcate that the VM s currenty paused. (Ths s
equvaent to seectng the "Pause" tem n the "Machne" menu of the GUI.)
Use vBoxhahage coh1Jovm <vm> Jesume to undo a prevous pause command. (Ths s equvaent to seectng
the "Resume" tem n the "Machne" menu of the GUI.)
vBoxhahage coh1Jovm <vm> Jese1 has the same ehect on a vrtua machne as pressng the "Reset" button
on a rea computer: a cod reboot of the vrtua machne, whch w restart and boot the guest
operatng system agan mmedatey. The state of the VM s not saved beforehand, and data may be
ost. (Ths s equvaent to seectng the "Reset" tem n the "Machne" menu of the GUI.)
vBoxhahage coh1Jovm <vm> poweJo11 has the same ehect on a vrtua machne as pung the power cabe
on a rea computer. Agan, the state of the VM s not saved beforehand, and data may be ost. (Ths s
equvaent to seectng the "Cose" tem n the "Machne" menu of the GUI or pressng the wndow's
cose button, and then seectng "Power oh the machne" n the daog.)
After ths, the VM's state w be "Powered oh". From there, t can be started agan; see the secton
caed "VBoxManage startvm".
vBoxhahage coh1Jovm <vm> saves1a1e w save the current state of the VM to dsk and then stop the VM.
(Ths s equvaent to seectng the "Cose" tem n the "Machne" menu of the GUI or pressng the
wndow's cose button, and then seectng "Save the machne state" n the daog.)
After ths, the VM's state w be "Saved". From there, t can be started agan; see the secton caed
"VBoxManage startvm".
vBoxhahage coh1Jovm <vm> 1eepoJ1 --hos1hame <hame> --poJ1 <poJ1> |--passwoJd <passwoJd>] makes the
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
18 de 38 11-04-2012 15.59
machne the source of a teeportng operaton and ntates a teeport to the gven target. See the
secton caed "Teeportng" for an ntroducton. If the optona password s speced, t must match
the password that was gven to the mod11yvm command for the target machne; see the secton caed
"Teeportng settngs" for detas.
A few extra optons are avaabe wth coh1Jovm that do not drecty ahect the VM's runnng state:
The se11hks1a1e<1-h> operaton connects or dsconnects vrtua network cabes from ther network
nterfaces.
h1c<1-h> hu]ha1]bJ1dged]1h1he1]hos1ohy]geheJ1c: Wth ths, you can set, for each of the VM's vrtua
network cards, what type of networkng shoud be avaabe. They can be not connected to the host
(hu), use network address transaton (ha1), brdged networkng (bJ1dged) or communcate wth other
vrtua machnes usng nterna networkng (1h1he1) or host-ony networkng (hos1ohy) or access to
rarey used sub-modes (geheJ1c). These optons correspond to the modes whch are descrbed n deta
n the secton caed "Introducton to networkng modes".
usba11ach and usbde11ach make host USB devces vsbe to the vrtua machne on the y, wthout the
need for creatng ters rst. The USB devces can be speced by UUID (unque denter) or by
address on the host system.
You can use vBoxhahage 1s1 usbhos1 to ocate ths nformaton.
vJde oh]o11 ets you enabe or dsabe the VRDE server, f t s nstaed.
vJdepoJ1 de1au1]<poJ1s> changes the port or a range of ports that the VRDE server can bnd to;
"defaut" or "0" means port 3389, the standard port for RDP. For detas, see the descrpton for the
--vJdepoJ1 opton n the secton caed "Sera port, audo, cpboard, remote desktop and USB
settngs".
se1v1deomodeh1h1 requests that the guest system change to a partcuar vdeo mode. Ths requres that
the Guest Addtons be nstaed, and w not work for a guest systems.
scJeehsho1phg takes a screenshot of the guest dspay and saves t n PNG format.
The se1cJedeh11as operaton s used for remote ogons n Wndows guests. For detas, pease refer to
the secton caed "Automated guest ogons".
The gues1memoJybaooh operaton changes the sze of the guest memory baoon, that s, memory
aocated by the VrtuaBox Guest Addtons from the guest operatng system and returned to the
hypervsor for re-use by other vrtua machnes. Ths must be speced n megabytes. For detas, see
the secton caed "Memory baoonng".
The cpuexecu11ohcap <1-100>: Ths operaton contros how much cpu tme a vrtua CPU can use. A vaue
of 50 mpes a snge vrtua CPU can use up to 50% of a snge host CPU.
VBoxManage discardstate
Ths command dscards the saved state of a vrtua machne whch s not currenty runnng, whch w
cause ts operatng system to restart next tme you start t. Ths s the equvaent of pung out the power
cabe on a physca machne, and shoud be avoded f possbe.
VBoxManage adoptstate
If you have a saved state e (.sav) that s seperate from the VM conguraton, you can use ths command
to "adopt" the e. Ths w change the VM to saved state and when you start t, VrtuaBox w attempt to
restore t from the saved state e you ndcated. Ths command shoud ony be used n speca setups.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
19 de 38 11-04-2012 15.59
VBoxManage snapshot
Ths command s used to contro snapshots from the command ne. A snapshot conssts of a compete
copy of the vrtua machne settngs, coped at the tme when the snapshot was taken, and optonay a
vrtua machne saved state e f the snapshot was taken whe the machne was runnng. After a snapshot
has been taken, VrtuaBox creates dherencng hard dsk for each norma hard dsk assocated wth the
machne so that when a snapshot s restored, the contents of the vrtua machne's vrtua hard dsks can
be qucky reset by smpy droppng the pre-exstng dherencng es.
The 1ake operaton takes a snapshot of the current state of the vrtua machne. You must suppy a name for
the snapshot and can optonay suppy a descrpton. The new snapshot s nserted nto the snapshots tree
as a chd of the current snapshot and then becomes the new current snapshot.
The dee1e operaton deetes a snapshot (speced by name or by UUID). Ths can take a whe to nsh
snce the dherencng mages assocated wth the snapshot mght need to be merged wth ther chd
dherencng mages.
The Jes1oJe operaton w restore the gven snapshot (speced by name or by UUID) by resettng the vrtua
machne's settngs and current state to that of the snapshot. The prevous current state of the machne w
be ost. After ths, the gven snapshot becomes the new "current" snapshot so that subsequent snapshots
are nserted under the snapshot from whch was restored.
The Jes1oJecuJJeh1 operaton s a shortcut to restore the current snapshot (.e. the snapshot from whch the
current state s derved). Ths subcommand s equvaent to usng the "restore" subcommand wth the
name or UUID of the current snapshot, except that t avods the extra step of determnng that name or
UUID.
Wth the ed11 operaton, you can change the name or descrpton of an exstng snapshot.
Wth the showvm1h1o operaton, you can vew the vrtua machne settngs that were stored wth an exstng
snapshot.
VBoxManage closemedium
Ths commands removes a hard dsk, DVD or oppy mage from a VrtuaBox meda regstry.
|36|
Optonay, you can request that the mage be deeted. You w get approprate dagnostcs that the
deeton faed, however the mage w become unregstered n any case.
VBoxManage storageattach
Ths command attaches/modes/removes a storage medum connected to a storage controer that was
prevousy added wth the s1oJagec1 command (see the prevous secton). The syntax s as foows:
vBoxhahage s1oJagea11ach <uu1d]vmhame>
--s1oJagec1 <hame>
|--poJ1 <humbeJ>]
|--dev1ce <humbeJ>]
|--1ype dvddJ1ve]hdd]1dd]
|--med1um hohe]emp1ydJ1ve]
<uu1d>]<11ehame>]hos1.<dJ1ve>]1scs1]
|--m1ype hoJma]wJ11e1hJough]1mmu1abe]shaJeabe]
|--commeh1 <1ex1>]
|--se1uu1d <uu1d>]
|--se1paJeh1uu1d <uu1d>]
|--pass1hJough oh]o11]
|--1empeec1 oh]o11]
|--bahdw1d1hgJoup hame]hohe]
|--1oJceuhmouh1]
|--seJveJ <hame>]<1p>]
|--1aJge1 <1aJge1>]
|--1poJ1 <poJ1>]
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
20 de 38 11-04-2012 15.59
|--uh <uh>]
|--ehcodeduh <uh>]
|--useJhame <useJhame>]
|--passwoJd <passwoJd>]
|--1h1he1]
A number of parameters are commony requred; the ones at the end of the st are requred ony for SCSI
targets (see beow).
The common parameters are:
uud|vmname
The VM UUID or VM Name. Mandatory.
storagect
Name of the storage controer. Mandatory. The st of the storage controers currenty attached to a
VM can be obtaned wth vBoxhahage showvm1h1o; see the secton caed "VBoxManage showvmnfo".
port
The number of the storage controer's port whch s to be moded. Mandatory, uness the storage
controer has ony a snge port.
devce
The number of the port's devce whch s to be moded. Mandatory, uness the storage controer
has ony a snge devce per port.
type
Dene the type of the drve to whch the medum s beng attached/detached/moded. Ths
argument can ony be omtted f the type of medum can be determned from ether the medum
gven wth the --med1um argument or from a prevous medum attachment.
medum
Speces what s to be attached. The foowng vaues are supported:
"none": Any exstng devce shoud be removed from the gven sot.
"emptydrve": For a vrtua DVD or oppy drve ony, ths makes the devce sot behaves ke a
removeabe drve nto whch no meda has been nserted.
If a UUID s speced, t must be the UUID of a storage medum that s aready known to
VrtuaBox (e.g. because t has been attached to another vrtua machne). See the secton
caed "VBoxManage st" for how to st known meda. Ths medum s then attached to the
gven devce sot.
If a ename s speced, t must be the fu path of an exstng dsk mage (ISO, RAW, VDI,
VMDK or other), whch s then attached to the gven devce sot.
"host:<drve>": For a vrtua DVD or oppy drve ony, ths connects the gven devce sot to
the speced DVD or oppy drve on the host computer.
"scs": For vrtua hard dsks ony, ths aows for specfyng an SCSI target. In ths case, more
parameters must be gven; see beow.
Some of the above changes, n partcuar for removeabe meda (oppes and CDs/DVDs), can be
ehected whe a VM s runnng. Others (devce changes or changes n hard dsk devce sots) requre
the VM to be powered oh.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
21 de 38 11-04-2012 15.59
mtype
Denes how ths medum behaves wth respect to snapshots and wrte operatons. See the secton
caed "Speca mage wrte modes" for detas.
comment
Any descrpton that you want to have stored wth ths medum (optona; for exampe, for an SCSI
target, "Bg storage server downstars"). Ths s purey descrptve and not needed for the medum to
functon correcty.
setuud, setparentuud
Modes the UUID or parent UUID of a medum before attachng t to a VM. Ths s an expert opton.
Inapproprate use can make the medum unusabe or ead to broken VM conguratons f any other
VM s referrng to the same meda aready. The most frequenty used varant s --se1uu1d "", whch
assgns a new (random) UUID to an mage. Ths s usefu to resove the dupcate UUID errors f one
dupcated an mage usng e copy uttes.
passthrough
For a vrtua DVD drve ony, you can enabe DVD wrtng support (currenty expermenta; see the
secton caed "CD/DVD support").
tempe|ect
For a vrtua DVD drve ony, you can congure the behavor for guest-trggered medum e|ect. If ths
s set to "on", the e|ect has ony temporary ehects. If the VM s powered oh and restarted the
orgnay congured medum w be st n the drve.
bandwdthgroup
Sets the bandwdth group to use for the gven devce; see the secton caed "Lmtng bandwdth for
dsk mages".
forceunmount
For a vrtua DVD or oppy drve ony, ths forcby unmounts the DVD/CD/Foppy or mounts a new
DVD/CD/Foppy even f the prevous one s ocked down by the guest for readng. Agan, see the
secton caed "CD/DVD support" for detas.
When "scs" s used wth the --med1um parameter for SCSI support -- see the secton caed "SCSI servers"
--, addtona parameters must or can be used:
server
The host name or IP address of the SCSI target; requred.
target
Target name strng. Ths s determned by the SCSI target and used to dentfy the storage resource;
requred.
tport
TCP/IP port number of the SCSI servce on the target (optona).
un
Logca Unt Number of the target resource (optona). Often, ths vaue s zero.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
22 de 38 11-04-2012 15.59
username, password
Username and password for target authentcaton, f requred (optona).
Note
Currenty, username and password are stored wthout encrypton (.e. n cear text)
n the XML machne conguraton e.
ntnet
If speced, connect to the SCSI target va Interna Networkng. Ths needs further conguraton
whch s descrbed n the secton caed "Access SCSI targets va Interna Networkng".
VBoxManage storagectl
Ths command attaches/modes/removes a storage controer. After ths, vrtua meda can be attached to
the controer wth the s1oJagea11ach command (see the next secton).
The syntax s as foows:
vBoxhahage s1oJagec1 <uu1d]vmhame>
--hame <hame>
|--add <1de/sa1a/scs1/1oppy>]
|--coh1JoeJ <Ls1Log1c]LSTLog1cSAS]BusLog1c]
Th1eAhc1]PTTX3]PTTX4]TCh6]T82078>]
|--sa1a1deemua11oh<1-4> <1-30>]
|--sa1apoJ1couh1 <1-30>]
|--hos11ocache oh]o11]
|--boo1abe oh]o11]
|--Jemove]
where the parameters mean:
uud|vmname
The VM UUID or VM Name. Mandatory.
name
Name of the storage controer. Mandatory.
add
Dene the type of the system bus to whch the storage controer must be connected.
controer
Aows to choose the type of chpset beng emuated for the gven storage controer.
satadeemuaton
Ths speces whch SATA ports shoud operate n IDE emuaton mode. As expaned n the secton
caed "Hard dsk controers: IDE, SATA (AHCI), SCSI, SAS", by defaut, ths s the case for SATA ports
1-4; wth ths command, you can map four IDE channes to any of the 30 supported SATA ports.
sataportcount
Ths determnes how many ports the SATA controer shoud support.
hostocache
Congures the use of the host I/O cache for a dsk mages attached to ths storage controer. For
detas, pease see the secton caed "Host I/O cachng".
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
23 de 38 11-04-2012 15.59
bootabe
Seects whether ths controer s bootabe.
remove
Removes the storage controer from the VM cong.
VBoxManage bandwidthctl
Ths command creates/deetes/modes bandwdth groups of the gven vrtua machne:
vBoxhahage bahdw1d1hc1 <uu1d]vmhame>
--hame <hame>
|--add d1sk
|--dee1e]
|--1m11 hB/s]
See the secton caed "Lmtng bandwdth for dsk mages" for an ntroducton to bandwdth mts. The
parameters mean:
uud|vmname
The VM UUID or VM Name. Mandatory.
name
Name of the bandwdth group. Mandatory.
add
Creates a new bandwdth group wth the gven type.
deete
Deetes a bandwdth group f t sn't used anymore.
mt
Sets the mt for the gven group to the speced amount. Can be changed whe the VM s runnng.
VBoxManage showhdinfo
Ths command shows nformaton about a vrtua hard dsk mage, notaby ts sze, ts sze on dsk, ts type
and the vrtua machnes whch use t.
Note
For compatbty wth earer versons of VrtuaBox, the "showvdnfo" command s aso
supported and mapped nternay to the "showhdnfo" command.
The dsk mage must be speced ether by ts UUID (f the medum s regstered) or by ts ename.
Regstered mages can be sted by vBoxhahage 1s1 hdds (see the secton caed "VBoxManage st" for more
nformaton). A ename must be speced as vad path, ether as an absoute path or as a reatve path
startng from the current drectory.
VBoxManage createhd
Ths command creates a new vrtua hard dsk mage. The syntax s as foows:
vBoxhahage cJea1ehd --11ehame <11ehame>
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
24 de 38 11-04-2012 15.59
--s1ze <megaby1es>
|--1oJma1 v0T]vh0K]vh0] {de1au1. v0T)
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
where the parameters mean:
ename
Aows to choose a e name. Mandatory.
sze
Aows to dene the mage capacty, n 1 MB unts. Mandatory.
format
Aows to choose a e format for the output e dherent from the e format of the nput e.
varant
Aows to choose a e format varant for the output e. It s a comma-separated st of varant ags.
Not a combnatons are supported, and specfyng nconsstent ags w resut n an error message.
Note
For compatbty wth earer versons of VrtuaBox, the "createvd" command s aso
supported and mapped nternay to the "createhd" command.
VBoxManage modifyhd
Wth the mod11yhd command, you can change the characterstcs of a dsk mage after t has been created:
vBoxhahage mod11yhd <uu1d>]<11ehame>
|--1ype hoJma]wJ11e1hJough]1mmu1abe]shaJeabe]
Jeadohy]mu11a11ach]
|--au1oJese1 oh]o11]
|--compac1]
|--Jes1ze <megaby1es>]--Jes1zeby1e <by1es>]
Note
Despte the "hd" n the subcommand name, the command works wth a dsk mages, not
ony hard dsks. For compatbty wth earer versons of VrtuaBox, the "modfyvd"
command s aso supported and mapped nternay to the "modfyhd" command.
The dsk mage to modfy must be speced ether by ts UUID (f the medum s regstered) or by ts
ename. Regstered mages can be sted by vBoxhahage 1s1 hdds (see the secton caed "VBoxManage st"
for more nformaton). A ename must be speced as vad path, ether as an absoute path or as a
reatve path startng from the current drectory.
The foowng optons are avaabe:
Wth the --1ype argument, you can change the type of an exstng mage between the norma,
mmutabe, wrte-through and other modes; see the secton caed "Speca mage wrte modes" for
detas.
For mmutabe (dherencng) hard dsks ony, the --au1oJese1 oh]o11 opton determnes whether the
dsk s automatcay reset on every VM startup (agan, see the secton caed "Speca mage wrte
modes"). The defaut s "on".
Wth the --compac1 opton, can be used to compact dsk mages, .e. remove bocks that ony contans
zeroes. Ths w shrnk a dynamcay aocated mage agan; t w reduce the physical sze of the
mage wthout ahectng the ogca sze of the vrtua dsk. Compacton works both for base mages
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
25 de 38 11-04-2012 15.59
and for dh mages created as part of a snapshot.
For ths operaton to be ehectve, t s requred that free space n the guest system rst be zeroed out
usng a sutabe software too. For Wndows guests, you can use the sdee1e too provded by
Mcrosoft. Execute sdee1e -c n the guest to zero the free dsk space before compressng the vrtua
dsk mage. For Lnux, use the zeJo1Jee utty whch supports ext2/ext3 esystems.
Pease note that compactng s currenty ony avaabe for VDI mages. A smar ehect can be
acheved by zerong out free bocks and then conng the dsk to any other dynamcay aocated
format. You can use ths workaround unt compactng s aso supported for dsk formats other than
VDI.
The --Jes1ze opton aows you to change the capacty of an exstng mage; ths ad|usts the logical
sze of a vrtua dsk wthout ahectng the physca sze much.
|37|
Ths currenty works ony for
expandng the capacty of VDI and VHD formats, and ony for the dynamcay aocated varants. For
exampe, f you orgnay created a 10G dsk whch s now fu, you can use the --Jes1ze 15360
command to add 5 GByte more space to the vrtua dsk wthout havng to create a new mage and
copy a data from wthn a vrtua machne.
VBoxManage clonehd
Ths command dupcates a regstered vrtua hard dsk mage to a new mage e wth a new unque
denter (UUID). The new mage can be transferred to another host system or mported nto VrtuaBox
agan usng the Vrtua Meda Manager; see the secton caed "The Vrtua Meda Manager" and the secton
caed "Conng dsk mages". The syntax s as foows:
vBoxhahage cohehd <uu1d>]<11ehame> <ou1pu111e>
|--1oJma1 v0T]vh0K]vh0]RAW]<o1heJ>]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--ex1s11hg]
The dsk mage to cone as we as the target mage must be descrbed ether by ts UUIDs (f the medums
are regstered) or by ts ename. Regstered mages can be sted by vBoxhahage 1s1 hdds (see the secton
caed "VBoxManage st" for more nformaton). A ename must be speced as vad path, ether as an
absoute path or as a reatve path startng from the current drectory.
The foowng optons are avaabe:
format
Aow to choose a e format for the output e dherent from the e format of the nput e.
varant
Aow to choose a e format varant for the output e. It s a comma-separated st of varant ags.
Not a combnatons are supported, and specfyng nconsstent ags w resut n an error message.
exstng
Perform the cone operaton to an aready exstng destnaton medum. Ony the porton of the
source medum whch ts nto the destnaton medum s coped. Ths means f the destnaton
medum s smaer than the source ony a part of t s coped, and f the destnaton medum s arger
than the source the remanng part of the destnaton medum s unchanged.
Note
For compatbty wth earer versons of VrtuaBox, the "conevd" command s aso
supported and mapped nternay to the "conehd" command.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
26 de 38 11-04-2012 15.59
VBoxManage convertfromraw
Ths command converts a raw dsk mage to a VrtuaBox Dsk Image (VDI) e. The syntax s as foows:
vBoxhahage cohveJ11JomJaw <11ehame> <ou1pu111e>
|--1oJma1 v0T]vh0K]vh0]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--uu1d <uu1d>]
vBoxhahage cohveJ11JomJaw s1d1h <ou1pu111e> <by1es>
|--1oJma1 v0T]vh0K]vh0]
|--vaJ1ah1 S1ahdaJd,F1xed,Sp112C,S1Jeam,ESX]
|--uu1d <uu1d>]
where the parameters mean:
format
Seect the dsk mage format to create. Defaut s VDI.
varant
Aow to choose a e format varant for the output e. It s a comma-separated st of varant ags.
Not a combnatons are supported, and specfyng nconsstent ags w resut n an error message.
uud
Aow to specy the UUID of the output e.
The second form forces VBoxManage to read the content for the dsk mage from standard nput (usefu for
usng that command n a ppe).
Note
For compatbty wth earer versons of VrtuaBox, the "convertdd" command s aso
supported and mapped nternay to the "convertfromraw" command.
VBoxManage getextradata}setextradata
These commands et you attach and retreve strng data to a vrtua machne or to a VrtuaBox
conguraton (by specfyng goba nstead of a vrtua machne name). You must specfy a key (as a text
strng) to assocate the data wth, whch you can ater use to retreve t. For exampe:
vBoxhahage se1ex1Jada1a FedoJa5 1hs1ada1e 2006.01.01
vBoxhahage se1ex1Jada1a SbSE10 1hs1ada1e 2006.02.02
woud assocate the strng "2006.01.01" wth the key nstadate for the vrtua machne Fedora5, and
"2006.02.02" on the machne SUSE10. You coud retreve the nformaton as foows:
vBoxhahage ge1ex1Jada1a FedoJa5 1hs1ada1e
whch woud return
v1J1uaBox Commahd L1he hahagemeh1 Th1eJ1ace veJs1oh 4.1.12
{C) 2005-2012 0Jace CoJpoJa11oh
A J1gh1s JeseJved.
vaue. 2006.01.01
To remove a key, the se1ex1Jada1a command must be run wthout specfyng data (ony the key), for
exampe:
vBoxhahage se1ex1Jada1a FedoJa5 1hs1ada1e
VBoxManage setproperty
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
27 de 38 11-04-2012 15.59
Ths command s used to change goba settngs whch ahect the entre VrtuaBox nstaaton. Some of
these correspond to the settngs n the "Goba settngs" daog n the graphca user nterface. The
foowng propertes are avaabe:
machnefoder
Ths speces the defaut foder n whch vrtua machne dentons are kept; see the secton caed
"Where VrtuaBox stores ts es" for detas.
vrdeauthbrary
Ths speces whch brary to use when "externa" authentcaton has been seected for a partcuar
vrtua machne; see the secton caed "RDP authentcaton" for detas.
websrvauthbrary
Ths speces whch brary the web servce uses to authentcate users. For detas about the
VrtuaBox web servce, pease refer to the separate VrtuaBox SDK reference (see Chapter 11,
Virtual8ox programming interfaces).
vrdebrary
Ths speces whch brary mpements the VrtuaBox Remote Desktop Extenson.
hwvrtexenabed
Ths seects whether or not hardware vrtuazaton support s enabed by defaut.
VBoxManage usblter add}modify}remove
The usb111eJ commands are used for workng wth USB ters n vrtua machnes, or goba ters whch
ahect the whoe VrtuaBox setup. Goba ters are apped before machne-specc ters, and may be
used to prevent devces from beng captured by any vrtua machne. Goba ters are aways apped n a
partcuar order, and ony the rst ter whch ts a devce s apped. So for exampe, f the rst goba ter
says to hod (make avaabe) a partcuar Kngston memory stck devce and the second to gnore a
Kngston devces, that memory stck w be avaabe to any machne wth an approprate ter, but no
other Kngston devce w.
When creatng a USB ter usng usb111eJ add, you must suppy three or four mandatory parameters. The
ndex speces the poston n the st at whch the ter shoud be paced. If there s aready a ter at that
poston, then t and the foowng ones w be shfted back one pace. Otherwse the new ter w be
added onto the end of the st. The 1aJge1 parameter seects the vrtua machne that the ter shoud be
attached to or use "goba" to appy t to a vrtua machnes. hame s a name for the new ter and for goba
ters, ac11oh says whether to aow machnes access to devces that t the ter descrpton ("hod") or not
to gve them access ("gnore"). In addton, you shoud specfy parameters to ter by. You can nd the
parameters for devces attached to your system usng vBoxhahage 1s1 usbhos1. Fnay, you can specfy
whether the ter shoud be actve, and for oca ters, whether they are for oca devces, remote (over an
RDP connecton) or ether.
When you modfy a USB ter usng usb111eJ mod11y, you must specfy the ter by ndex (see the output of
vBoxhahage 1s1 usb111eJs to nd goba ter ndexes and that of vBoxhahage showvm1h1o to nd ndexes for
ndvdua machnes) and by target, whch s ether a vrtua machne or "goba". The propertes whch can
be changed are the same as for usb111eJ add. To remove a ter, use usb111eJ Jemove and specfy the ndex
and the target.
VBoxManage sharedfolder add}remove
Ths command aows you to share foders on the host computer wth guest operatng systems. For ths, the
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
28 de 38 11-04-2012 15.59
guest systems must have a verson of the VrtuaBox Guest Addtons nstaed whch supports ths
functonaty.
Shared foders are descrbed n deta n the secton caed "Shared foders".
VBoxManage guestproperty
The "guestproperty" commands aow you to get or set propertes of a runnng vrtua machne. Pease see
the secton caed "Guest propertes" for an ntroducton. As expaned there, guest propertes are arbtrary
key/vaue strng pars whch can be wrtten to and read from by ether the guest or the host, so they can be
used as a ow-voume communcaton channe for strngs, provded that a guest s runnng and has the
Guest Addtons nstaed. In addton, a number of vaues whose keys begn wth "/VrtuaBox/" are
automatcay set and mantaned by the Guest Addtons.
The foowng subcommands are avaabe (where <vm>, n each case, can ether be a VM name or a VM
UUID, as wth the other VBoxManage commands):
ehumeJa1e <vm> |--pa11eJhs <pa11eJh>]: Ths sts a the guest propertes that are avaabe for the gven
VM, ncudng the vaue. Ths st w be very mted f the guest's servce process cannot be
contacted, e.g. because the VM s not runnng or the Guest Addtons are not nstaed.
If --pa11eJhs <pa11eJh> s speced, t acts as a ter to ony st propertes that match the gven pattern.
The pattern can contan the foowng wdcard characters:
* (astersk): represents any number of characters; for exampe, "/v1J1uaBox*" woud match a
propertes begnnng wth "/VrtuaBox".
? (queston mark): represents a snge arbtrary character; for exampe, "1o?" woud match both
"foo" and "for".
] (ppe symbo): can be used to specfy mutpe aternatve patterns; for exampe, "s*]1*"
woud match anythng startng wth ether "s" or "t".
ge1 <vm>: Ths retreves the vaue of a snge property ony. If the property cannot be found (e.g.
because the guest s not runnng), ths w prnt
ho vaue se1!
se1 <vm> <pJopeJ1y> |<vaue> |--1ags <1ags>]]: Ths aows you to set a guest property by specfyng the
key and vaue. If <vaue> s omtted, the property s deeted. Wth --1ags you can optonay specfy
addtona behavor (you can combne severa by separatng them wth commas):
TRAhSTEhT: the vaue w not be stored wth the VM data when the VM exts;
TRAhSRESET: the vaue w be deeted as soon as the VM restarts and/or exts;
R00hLYCbEST: the vaue can ony be changed by the host, but the guest can ony read t;
R00hLYh0ST: reversey, the vaue can ony be changed by the guest, but the host can ony read t;
REA00hLY: a combnaton of the two, the vaue cannot be changed at a.
wa11 <vm> <pa11eJh> --11meou1 <11meou1>: Ths wats for a partcuar vaue descrbed by "pattern" to
change or to be deeted or created. The pattern rues are the same as for the "enumerate"
subcommand above.
VBoxManage guestcontrol
The "guestcontro" commands aow you to contro certan thngs nsde a guest from the host. Pease see
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
29 de 38 11-04-2012 15.59
the secton caed "Guest contro" for an ntroducton.
Generay, the syntax s as foows:
vBoxhahage gues1coh1Jo <commahd>
The foowng subcommands are avaabe (where <vm>, n each case, can ether be a VM name or a VM
UUID, as wth the other VBoxManage commands):
execu1e, whch aows for executng a program/scrpt (process) whch aready s nstaed and runnabe
on the guest. Ths command ony works whe a VM s up and runnng and has the foowng syntax:
vBoxhahage gues1coh1Jo <vmhame>]<uu1d> exec|u1e]
--1mage <pa1h 1o pJogJam>
--useJhame <hame> |--passwoJd <passwoJd>]
|--dos2uh1x]
|--ehv1Johmeh1 "<hAhE>=<vALbE> |<hAhE>=<vALbE>]"]
|--11meou1 <msec>] |--uh1x2dos] |--veJbose]
|--wa11-ex11] |--wa11-s1dou1] |--wa11-s1deJJ]
-- ||<aJgumeh11>] ... |<aJgumeh1h>]]
where the parameters mean:
uud|vmname
The VM UUID or VM name. Mandatory.
--mage "<path to program>"
Absoute path and process name of process to execute n the guest, e.g. C.\W1hdows\Sys1em32
\cac.exe
--username <name>
Name of the user the process shoud run under. Ths user must exst on the guest OS.
--password <password>
Password of the user account speced wth --useJhame. If not gven, an empty password s
assumed.
--dos2unx
--envronment "<NAME>=<VALUE>"
One or more envronment varabes to be set or unset.
By defaut, the new process n the guest w be created wth the standard envronment of the
guest OS. Ths opton aows for modfyng that envronment. To set/modfy a varabe, a par of
hAhE=vALbE must be speced; to unset a certan varabe, the name wth no vaue must set, e.g.
hAhE=.
Arguments contanng spaces must be encosed n quotaton marks. More than one --ehv1Johmeh1
at a tme can be speced to keep the command ne tdy.
--tmeout <msec>
Vaue (n mseconds) that speces the tme how ong the started process s aowed to run
and how ong VBoxManage wats for gettng output from that process. If no tmeout s
speced, VBoxManage w wat forever unt the started process ends or an error occured.
--unx2dos
--verbose
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
30 de 38 11-04-2012 15.59
Tes VBoxManage to be more verbose.
--wat-ext
Wats unt the process ends and outputs ts ext code aong wth the ext reason/ags.
--wat-stdout
Wats unt the process ends and outputs ts ext code aong wth the ext reason/ags. Whe
watng VBoxManage retreves the process output coected from stdout.
--wat-stderr
Wats unt the process ends and outputs ts ext code aong wth the ext reason/ags. Whe
watng VBoxManage retreves the process output coected from stderr.
|-- |<argument1s>| ... |<argumentNs>||
One or more arguments to pass to the process beng executed.
Arguments contanng spaces must be encosed n quotaton marks.
Note
On Wndows there are certan mtatons for graphca appcatons; pease see
Chapter 14, lnown limitations for more nformaton.
Exampes:
vBoxhahage --hoogo gues1coh1Jo "hy vh" execu1e --1mage "/b1h/s"
--useJhame 1oo --passwoJd baJ --wa11-ex11 --wa11-s1dou1 -- - /usJ
vBoxhahage --hoogo gues1coh1Jo "hy vh" execu1e --1mage "c.\\w1hdows\\sys1em32\\1pcoh11g.exe"
--useJhame 1oo --passwoJd baJ --wa11-ex11 --wa11-s1dou1
Note that the doube backsashes n the second exampe are ony requred on Unx hosts.
Note
For certan commands a user name of an exstng user account on the guest must
be speced; anonymous executons are not supported for securty reasons. A user
account password, however, s optona and depends on the guest's OS securty
pocy or rues. If no password s speced for a gven user name, an empty
password w be used. On certan OSes ke Wndows the securty pocy may needs
to be ad|usted n order to aow user accounts wth an empty password set. Aso,
goba doman rues mght appy and therefore cannot be changed.
Startng at VrtuaBox 4.1.2 guest process executon by defaut s mted to serve up to 5 guest
processes at a tme. If a new guest process gets started whch woud exceed ths mt, the odest not
runnng guest process w be dscarded n order to be abe to run that new process. Aso, retrevng
output from ths od guest process w not be possbe anymore then. If a 5 guest processes are st
actve and runnng, startng a new guest process w resut n an approprate error message.
To rase or ower the guest process executon mt, ether the guest property /v1J1uaBox/Cues1Add
/vBoxSeJv1ce/--coh1Jo-pJocs-max-kep1 or VBoxServce' command ne by specfyng --coh1Jo-pJocs-
max-kep1 needs to be moded. A restart of the guest OS s requred afterwards. To serve unmted
guest processes, a vaue of 0 needs to be set (not recommended).
copy1o, whch aows copyng es from the host to the guest (ony wth nstaed Guest Addtons 4.0
and ater).
vBoxhahage gues1coh1Jo <vmhame>]<uu1d> copy1o]cp
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
31 de 38 11-04-2012 15.59
<souJce oh hos1> <des11ha11oh oh gues1>
--useJhame <hame> |--passwoJd <passwoJd>]
|--dJyJuh] |--1oow] |--JecuJs1ve] |--veJbose]
where the parameters mean:
uud|vmname
The VM UUID or VM name. Mandatory.
source on host
Absoute path of source e(s) on host to copy over to the guest, e.g. C.\W1hdows\Sys1em32
\cac.exe. Ths aso can be a wdcard expresson, e.g. C.\W1hdows\Sys1em32\*.d
destnaton on guest
Absoute destnaton path on the guest, e.g. C.\Temp
--username <name>
Name of the user the copy process shoud run under. Ths user must exst on the guest OS.
--password <password>
Password of the user account speced wth --useJhame. If not gven, an empty password s
assumed.
--dryrun
Tes VBoxManage to ony perform a dry run nstead of reay copyng es to the guest.
--foow
Enabes foowng symnks on the host's source.
--recursve
Recursvey copes es/drectores of the speced source.
--verbose
Tes VBoxManage to be more verbose.
--ags <ags>
Addtona ags to set. Ths s not used at the moment.
cJea1ed1Jec1oJy, whch aows copyng es from the host to the guest (ony wth nstaed Guest
Addtons 4.0 and ater).
vBoxhahage gues1coh1Jo <vmhame>]<uu1d> cJea1ed1J|ec1oJy]]mkd1J]md
<d1Jec1oJy 1o cJea1e oh gues1>
|--useJhame "<hame>"] |--passwoJd "<passwoJd>"]
|--paJeh1s] |--mode <mode>] |--veJbose]
where the parameters mean:
uud|vmname
The VM UUID or VM name. Mandatory.
drectory to create on guest
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
32 de 38 11-04-2012 15.59
Absoute path of drectory/drectores to create on guest, e.g. 0.\Foo\BaJ. Parent drectores need
to exst (e.g. n ths exampe 0.\Foo) when swtch --paJeh1s s omtted. The speced user must
have approprate rghts to create the speced drectory.
--username <name>
Name of the user the copy process shoud run under. Ths user must exst on the guest OS.
--password <password>
Password of the user account speced wth --useJhame. If not gven, an empty password s
assumed.
--parents
Aso creates not yet exstng parent drectores of the speced drectory, e.g. f the drectory
0.\Foo of 0.\Foo\BaJ does not exst yet t w be created. Wthout specfyng --paJeh1 the acton
woud have faed.
--mode <mode>
Sets the permsson mode of the speced drectory. Ony octa modes (e.g. 0755) are supported
rght now.
--verbose
Tes VBoxManage to be more verbose.
s1a1, whch dspays e or e system status on the guest.
vBoxhahage gues1coh1Jo <vmhame>]<uu1d> s1a1
<11e eemeh1{s) 1o check oh gues1>
|--useJhame "<hame>"] |--passwoJd "<passwoJd>"]
|--veJbose]
where the parameters mean:
uud|vmname
The VM UUID or VM name. Mandatory.
e eement(s) to check on guest
Absoute path of drectory/drectores to check on guest, e.g. /home/1oo/a.ou1. The speced user
must have approprate rghts to access the gven e eement(s).
--username <name>
Name of the user the copy process shoud run under. Ths user must exst on the guest OS.
--password <password>
Password of the user account speced wth --useJhame. If not gven, an empty password s
assumed.
--verbose
Tes VBoxManage to be more verbose.
upda1eadd111ohs, whch aows for updatng an aready nstaed Guest Addtons verson on the guest
(ony aready nstaed Guest Addtons 4.0 and ater).
vBoxhahage gues1coh1Jo <vmhame>]<uu1d> upda1eadd111ohs
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
33 de 38 11-04-2012 15.59
|--souJce "<gues1 add111ohs .TS0 11e 1o use>"] |--veJbose]
where the parameters mean:
uud|vmname
The VM UUID or VM name. Mandatory.
--source "<guest addtons .ISO e to use>"
Fu path to an aternatve VrtuaBox Guest Addtons .ISO e to use for the Guest Addtons
update.
--verbose
Tes VBoxManage to be more verbose.
VBoxManage debugvm
The "debugvm" commands are for experts who want to tnker wth the exact detas of vrtua machne
executon. Lke the VM debugger descrbed n the secton caed "The but-n VM debugger", these
commands are ony usefu f you are very famar wth the detas of the PC archtecture and how to debug
software.
The subcommands of "debugvm" a operate on a runnng vrtua machne. The foowng are avaabe:
Wth dumpgues1coJe --11ehame <hame>, you can create a system dump of the runnng VM, whch w be
wrtten nto the gven e. Ths e w have the standard ELF core format (wth custom sectons); see
the secton caed "VM core format".
Ths corresponds to the wJ11ecoJe command n the debugger.
The 1h1o command s used to dspay nfo tems reatng to the VMM, devce emuatons and
assocated drvers. Ths command takes one or two arguments: the name of the nfo tem, optonay
foowed by a strng contanng arguments specc to the nfo tem. The hep nfo tem provdes a
stnng of the avaabe tems and hnts about any optona arguments.
Ths corresponds to the 1h1o command n the debugger.
The 1hec1hm1 command causes a non-maskabe nterrupt (NMI) n the guest, whch mght be usefu
for certan debuggng scenaros. What happens exacty s dependent on the guest operatng system,
but an NMI can crash the whoe guest operatng system. Do not use uness you know what you're
dong.
The osde1ec1 command makes the VMM's debugger facty (re-)detecton the guest operaton system.
Ths corresponds to the de1ec1 command n the debugger.
The os1h1o command s used to dspay nfo about the operatng system (OS) detected by the VMM's
debugger facty.
The ge1Jeg1s1eJs command s used to dspay CPU and devce regsters. The command takes a st of
regsters, each havng one of the foowng forms:
Jeg1s1eJ-se1.Jeg1s1eJ-hame.sub-11ed
Jeg1s1eJ-se1.Jeg1s1eJ-hame
cpu-Jeg1s1eJ-hame.sub-11ed
cpu-Jeg1s1eJ-hame
a
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
34 de 38 11-04-2012 15.59
The a form w cause a regsters to be shown (no sub-eds). The regsters names are
case-nsenstve. When requestng a CPU regster the regster set can be omtted, t w be seected
usng the vaue of the --cpu opton (defautng to 0).
The se1Jeg1s1eJs command s used to change CPU and devce regsters. The command takes a st of
regster assgnments, each havng one of the foowng forms:
Jeg1s1eJ-se1.Jeg1s1eJ-hame.sub-11ed=vaue
Jeg1s1eJ-se1.Jeg1s1eJ-hame=vaue
cpu-Jeg1s1eJ-hame.sub-11ed=vaue
cpu-Jeg1s1eJ-hame=vaue
The vaue format shoud be n the same stye as what ge1Jeg1s1eJs dspays, wth the excepton that
both octa and decma can be used nstead of hexadecma. The regster namng and the defaut CPU
regster set are handed the same way as wth the ge1Jeg1s1eJs command.
The s1a11s11cs command can be used to dspay VMM statstcs on the command ne. The --Jese1
opton w reset statstcs. The ahected statstcs can be tered wth the --pa11eJh opton, whch
accepts DOS/NT-stye wdcards (? and *).
VBoxManage metrics
Ths command supports montorng the usage of system resources. Resources are represented by varous
metrcs assocated wth the host system or a partcuar VM. For exampe, the host system has a
CPb/Load/bseJ metrc that shows the percentage of tme CPUs spend executng n user mode over a specc
sampng perod.
Metrc data s coected and retaned nternay; t may be retreved at any tme wth the vBoxhahage me1J1cs
queJy subcommand. The data s avaabe as ong as the background vBoxSvC process s ave. That process
termnates shorty after a VMs and frontends have been cosed.
By defaut no metrcs are coected at a. Metrcs coecton does not start unt vBoxhahage me1J1cs se1up s
nvoked wth a proper sampng nterva and the number of metrcs to be retaned. The nterva s measured
n seconds. For exampe, to enabe coectng the host processor and memory usage metrcs every second
and keepng the 5 most current sampes, the foowng command can be used:
vBoxhahage me1J1cs se1up --peJ1od 1 --sampes 5 hos1 CPb/Load,RAh/bsage
Metrc coecton can ony be enabed for started VMs. Coected data and coecton settngs for a partcuar
VM w dsappear as soon as t shuts down. Use vBoxhahage me1J1cs 1s1 subcommand to see whch metrcs
are currenty avaabe. You can aso use --1s1 opton wth any subcommand that modes metrc settngs
to nd out whch metrcs were ahected.
Note that the vBoxhahage me1J1cs se1up subcommand dscards a sampes that may have been prevousy
coected for the speced set of ob|ects and metrcs.
To enabe or dsabe metrcs coecton wthout dscardng the data vBoxhahage me1J1cs ehabe and vBoxhahage
me1J1cs d1sabe subcommands can be used. Note that these subcommands expect metrcs, not submetrcs,
ke CPb/Load or RAh/bsage as parameters. In other words enabng CPb/Load/bseJ whe dsabng CPb/Load/KeJhe s
not supported.
The host and VMs have dherent sets of assocated metrcs. Avaabe metrcs can be sted wth vBoxhahage
me1J1cs 1s1 subcommand.
A compete metrc name may ncude an aggregate functon. The name has the foowng form:
Ca1egoJy/he1J1c|/Subhe1J1c]|.aggJega1e]. For exampe, RAh/bsage/FJee.m1h stands for the mnmum amount of
avaabe memory over a retaned data f apped to the host ob|ect.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
35 de 38 11-04-2012 15.59
Subcommands may appy to a ob|ects and metrcs or can be mted to one ob|ect or/and a st of metrcs.
If no ob|ects or metrcs are gven n the parameters, the subcommands w appy to a avaabe metrcs of
a ob|ects. You may use an astersk ("*") to expcty specfy that the command shoud be apped to a
ob|ects or metrcs. Use "host" as the ob|ect name to mt the scope of the command to host-reated
metrcs. To mt the scope to a subset of metrcs, use a metrc st wth names separated by commas.
For exampe, to query metrc data on the CPU tme spent n user and kerne modes by the vrtua machne
named "test", you can use the foowng command:
vBoxhahage me1J1cs queJy 1es1 CPb/Load/bseJ,CPb/Load/KeJhe
The foowng st summarzes the avaabe subcommands:
st
Ths subcommand shows the parameters of the currenty exstng metrcs. Note that VM-specc
metrcs are ony avaabe when a partcuar VM s runnng.
setup
Ths subcommand sets the nterva between takng two sampes of metrc data and the number of
sampes retaned nternay. The retaned data s avaabe for dspayng wth the queJy subcommand.
The --1s1 opton shows whch metrcs have been moded as the resut of the command executon.
enabe
Ths subcommand "resumes" data coecton after t has been stopped wth d1sabe subcommand.
Note that specfyng submetrcs as parameters w not enabe underyng metrcs. Use --1s1 to nd
out f the command dd what was expected.
dsabe
Ths subcommand "suspends" data coecton wthout ahectng coecton parameters or coected
data. Note that specfyng submetrcs as parameters w not dsabe underyng metrcs. Use --1s1 to
nd out f the command dd what was expected.
query
Ths subcommand retreves and dspays the currenty retaned metrc data.
Note
The queJy subcommand does not remove or "ush" retaned data. If you query often
enough you w see how od sampes are graduay beng "phased out" by new
sampes.
coect
Ths subcommand sets the nterva between takng two sampes of metrc data and the number of
sampes retaned nternay. The coected data s dspayed perodcay unt Ctr-C s pressed uness
the --de1ach opton s speced. Wth the --de1ach opton, ths subcommand operates the same way as
se1up does. The --1s1 opton shows whch metrcs match the speced ter.
VBoxManage hostonlyif
Wth "hostonyf" you can change the IP conguraton of a host-ony network nterface. For a descrpton of
host-ony networkng, pease refer to the secton caed "Host-ony networkng". Each host-ony nterface s
dented by a name and can ether use the nterna DHCP server or a manua IP conguraton (both IP4
and IP6).
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
36 de 38 11-04-2012 15.59
VBoxManage dhcpserver
The "dhcpserver" commands aow you to contro the DHCP server that s but nto VrtuaBox. You may nd
ths usefu when usng nterna or host-ony networkng. (Theoretcay, you can enabe t for a brdged
network as we, but that w key cause concts wth other DHCP servers n your physca network.)
Use the foowng command ne optons:
If you use nterna networkng for a vrtua network adapter of a vrtua machne, use vBoxhahage
dhcpseJveJ add --he1hame <he1woJk_hame>, where <he1woJk_hame> s the same network name you used wth
vBoxhahage mod11yvm <vmhame> --1h1he1<X> <he1woJk_hame>.
If you use host-ony networkng for a vrtua network adapter of a vrtua machne, use vBoxhahage
dhcpseJveJ add --11hame <hos1ohy_11_hame> nstead, where <hos1ohy_11_hame> s the same host-ony
nterface name you used wth vBoxhahage mod11yvm <vmhame> --hos1ohyadap1eJ<X> <hos1ohy_11_hame>.
Aternatvey, you can aso use the --netname opton as wth nterna networks f you know the
host-ony network's name; you can see the names wth vBoxhahage 1s1 hos1ohy11s (see the secton
caed "VBoxManage st" above).
The foowng addtona parameters are requred when rst addng a DHCP server:
Wth --1p, specfy the IP address of the DHCP server tsef.
Wth --he1mask, specfy the netmask of the network.
Wth --oweJ1p and --uppeJ1p, you can specfy the owest and hghest IP address, respectvey, that the
DHCP server w hand out to cents.
Fnay, you must specfy --ehabe or the DHCP server w be created n the dsabed state, dong nothng.
After ths, VrtuaBox w automatcay start the DHCP server for gven nterna or host-ony network as
soon as the rst vrtua machne whch uses that network s started.
Reversey, use vBoxhahage dhcpseJveJ Jemove wth the gven --he1hame <he1woJk_hame> or --11hame <hos1ohy_11_hame>
to remove the DHCP server agan for the gven nterna or host-ony network.
To modfy the settngs of a DHCP server created earer wth vBoxhahage dhcpseJveJ add, you can use vBoxhahage
dhcpseJveJ mod11y for a gven network or host-ony nterface name.
VBoxManage extpack
The "extpack" command aows you to add or remove VrtuaBox extenson packs, as descrbed n the
secton caed "Instang VrtuaBox and extenson packs".
To add a new extenson pack, use vBoxhahage ex1pack 1hs1a <1aJba>. Ths command w fa f an oder
verson of the same extenson pack s aready nstaed. The optona --Jepace parameter can be used
to unnsta the od package before the new package s nstaed.
To remove a prevousy nstaed extenson pack, use vBoxhahage ex1pack uh1hs1a <hame>. You can use
vBoxhahage 1s1 ex1packs to show the names of the extenson packs whch are currenty nstaed; pease
see the secton caed "VBoxManage st" aso. The optona --1oJce parameter can be used to
overrde the refusa of an extenson pack to be unnstaed.
The vBoxhahage ex1pack ceahup command can be used to remove temporary es and drectores that
may have been eft behnd f a prevous nsta or unnsta command faed.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
37 de 38 11-04-2012 15.59
|35|
For detas, see the secton caed "VBoxManage createvm".
|36|
Before VrtuaBox 4.0, t was necessary to ca VBoxManage openmedum before a medum coud be
attached to a vrtua machne; that ca "regstered" the medum wth the goba VrtuaBox meda regstry.
Wth VrtuaBox 4.0 ths s no onger necessary; meda are added to meda regstres automatcay. The
"cosemedum" ca has been retaned, however, to aow for expcty removng a medum from a regstry.
|37|
Image reszng was added wth VrtuaBox 4.0.
Chapter 8. VoxManage http.//www.vIrtuaIbox.org/manuaI/ch08.htmI
38 de 38 11-04-2012 15.59

También podría gustarte