VirtualBox

source: vbox/trunk/doc/manual/en_US/user_VBoxManage.xml@ 43986

Last change on this file since 43986 was 43973, checked in by vboxsync, 12 years ago

Mods to user manual reflecting mods in 4.2.x 6417

File size: 155.2 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
4<chapter id="vboxmanage">
5 <title>VBoxManage</title>
6
7 <sect1>
8 <title>Introduction</title>
9
10 <para>As briefly mentioned in <xref linkend="frontends" />, VBoxManage is
11 the command-line interface to VirtualBox. With it, you can completely
12 control VirtualBox from the command line of your host operating system.
13 VBoxManage supports all the features that the graphical user interface
14 gives you access to, but it supports a lot more than that. It exposes
15 really all the features of the virtualization engine, even those that
16 cannot (yet) be accessed from the GUI.</para>
17
18 <para>You will need to use the command line if you want to</para>
19
20 <para><itemizedlist>
21 <listitem>
22 <para>use a different user interface than the main GUI (for example,
23 VBoxSDL or the VBoxHeadless server);</para>
24 </listitem>
25
26 <listitem>
27 <para>control some of the more advanced and experimental
28 configuration settings for a VM.</para>
29 </listitem>
30 </itemizedlist></para>
31
32 <para>There are two main things to keep in mind when using
33 <computeroutput>VBoxManage</computeroutput>: First,
34 <computeroutput>VBoxManage</computeroutput> must always be used with a
35 specific "subcommand", such as "list" or "createvm" or "startvm". All the
36 subcommands that <computeroutput>VBoxManage</computeroutput> supports are
37 described in detail in <xref linkend="vboxmanage" />.</para>
38
39 <para>Second, most of these subcommands require that you specify a
40 particular virtual machine after the subcommand. There are two ways you
41 can do this:</para>
42
43 <itemizedlist>
44 <listitem>
45 <para>You can specify the VM name, as it is shown in the VirtualBox
46 GUI. Note that if that name contains spaces, then you must enclose the
47 entire name in double quotes (as it is always required with command
48 line arguments that contain spaces).</para>
49
50 <para>For example:<screen>VBoxManage startvm "Windows XP"</screen></para>
51 </listitem>
52
53 <listitem>
54 <para>You can specify the UUID, which is the internal unique
55 identifier that VirtualBox uses to refer to the virtual machine.
56 Assuming that the aforementioned VM called "Windows XP" has the UUID
57 shown below, the following command has the same effect as the
58 previous:<screen>VBoxManage startvm 670e746d-abea-4ba6-ad02-2a3b043810a5</screen></para>
59 </listitem>
60 </itemizedlist>
61
62 <para>You can type <computeroutput>VBoxManage list vms</computeroutput> to
63 have all currently registered VMs listed with all their settings,
64 including their respective names and UUIDs.</para>
65
66 <para>Some typical examples of how to control VirtualBox from the command
67 line are listed below:</para>
68
69 <itemizedlist>
70 <listitem>
71 <para>To create a new virtual machine from the command line and
72 immediately register it with VirtualBox, use
73 <computeroutput>VBoxManage createvm</computeroutput> with the
74 <computeroutput>--register</computeroutput> option,<footnote>
75 <para>For details, see <xref
76 linkend="vboxmanage-createvm" />.</para>
77 </footnote> like this:</para>
78
79 <screen>$ VBoxManage createvm --name "SUSE 10.2" --register
80VirtualBox Command Line Management Interface Version $VBOX_VERSION_MAJOR.$VBOX_VERSION_MINOR.$VBOX_VERSION_BUILD
81(C) 2005-$VBOX_C_YEAR $VBOX_VENDOR
82All rights reserved.
83
84Virtual machine 'SUSE 10.2' is created.
85UUID: c89fc351-8ec6-4f02-a048-57f4d25288e5
86Settings file: '/home/username/.VirtualBox/Machines/SUSE 10.2/SUSE 10.2.xml'
87</screen>
88
89 <para>As can be seen from the above output, a new virtual machine has
90 been created with a new UUID and a new XML settings file.</para>
91 </listitem>
92
93 <listitem>
94 <para>To show the configuration of a particular VM, use
95 <computeroutput>VBoxManage showvminfo</computeroutput>; see <xref
96 linkend="vboxmanage-showvminfo" /> for details and an example.</para>
97 </listitem>
98
99 <listitem>
100 <para>To change settings while a VM is powered off, use
101 <computeroutput>VBoxManage modifyvm</computeroutput>, e.g. as
102 follows:<screen>VBoxManage modifyvm "Windows XP" --memory "512MB"</screen></para>
103
104 <para>For details, see <xref linkend="vboxmanage-modifyvm" />.</para>
105 </listitem>
106
107 <listitem>
108 <para>To change the storage configuration (e.g. to add a storage
109 controller and then a virtual disk), use <computeroutput>VBoxManage
110 storagectl</computeroutput> and <computeroutput>VBoxManage
111 storageattach</computeroutput>; see <xref
112 linkend="vboxmanage-storagectl" /> and <xref
113 linkend="vboxmanage-storageattach" /> for details.</para>
114 </listitem>
115
116 <listitem>
117 <para>To control VM operation, use one of the following:<itemizedlist>
118 <listitem>
119 <para>To start a VM that is currently powered off, use
120 <computeroutput>VBoxManage startvm</computeroutput>; see <xref
121 linkend="vboxmanage-startvm" /> for details.</para>
122 </listitem>
123
124 <listitem>
125 <para>To pause or save a VM that is currently running or change
126 some of its settings, use <computeroutput>VBoxManage
127 controlvm</computeroutput>; see <xref
128 linkend="vboxmanage-controlvm" /> for details.</para>
129 </listitem>
130 </itemizedlist></para>
131 </listitem>
132 </itemizedlist>
133 </sect1>
134
135 <sect1>
136 <title>Commands overview</title>
137
138 <para>When running VBoxManage without parameters or when supplying an
139 invalid command line, the below syntax diagram will be shown. Note that
140 the output will be slightly different depending on the host platform; when
141 in doubt, check the output of <computeroutput>VBoxManage</computeroutput>
142 for the commands available on your particular host.</para>
143
144 <screen>$VBOX_MANAGE_OUTPUT</screen>
145
146 <para>Each time VBoxManage is invoked, only one command can be executed.
147 However, a command might support several subcommands which then can be
148 invoked in one single call. The following sections provide detailed
149 reference information on the different commands.</para>
150 </sect1>
151
152 <sect1 id="vboxmanage-general">
153 <title>General options</title>
154 <para>
155 <itemizedlist>
156 <listitem>
157 <para><computeroutput>--version</computeroutput>: show the version of
158 this tool and exit.</para>
159 </listitem>
160 <listitem>
161 <para><computeroutput>--nologo</computeroutput>: suppress the output
162 of the logo information (useful for scripts)</para>
163 </listitem>
164 <listitem>
165 <para><computeroutput>--settingspw</computeroutput>: specifiy a settings
166 password</para>
167 </listitem>
168 <listitem>
169 <para><computeroutput>--settingspwfile</computeroutput>: specify a file
170 containing the settings password.</para>
171 </listitem>
172 </itemizedlist>
173 The settings password is used for certain settings which need to be
174 stored encrypted for security reasons. At the moment, the only encrypted
175 setting is the iSCSI initiator secret (see
176 <xref linkend="vboxmanage-storageattach" /> for details). As long as no
177 settings password is specified, this information is stored in
178 <emphasis role="bold">plain text</emphasis>. After using the
179 <computeroutput>--settingspw|--settingspwfile</computeroutput> option
180 once, it must be always used, otherwise the encrypted setting cannot
181 be unencrypted.
182 </para>
183 </sect1>
184
185 <sect1 id="vboxmanage-list">
186 <title>VBoxManage list</title>
187
188 <para>The <computeroutput>list</computeroutput> command gives relevant
189 information about your system and information about VirtualBox's current
190 settings.</para>
191
192 <para>The following subcommands are available with
193 <computeroutput>VBoxManage list</computeroutput>: <itemizedlist>
194 <listitem>
195 <para><computeroutput>vms</computeroutput> lists all virtual
196 machines currently registered with VirtualBox. By default this
197 displays a compact list with each VM's name and UUID; if you also
198 specify <computeroutput>--long</computeroutput> or
199 <computeroutput>-l</computeroutput>, this will be a detailed list as
200 with the <computeroutput>showvminfo</computeroutput> command (see
201 below).</para>
202 </listitem>
203
204 <listitem>
205 <para><computeroutput>runningvms</computeroutput> lists all
206 currently running virtual machines by their unique identifiers
207 (UUIDs) in the same format as with
208 <computeroutput>vms</computeroutput>.</para>
209 </listitem>
210
211 <listitem>
212 <para><computeroutput>ostypes</computeroutput> lists all guest
213 operating systems presently known to VirtualBox, along with the
214 identifiers used to refer to them with the
215 <computeroutput>modifyvm</computeroutput> command.</para>
216 </listitem>
217
218 <listitem>
219 <para><computeroutput>hostdvds</computeroutput>,
220 <computeroutput>hostfloppies</computeroutput>, respectively, list
221 DVD, floppy, bridged networking and host-only networking interfaces
222 on the host, along with the name used to access them from within
223 VirtualBox.</para>
224 </listitem>
225
226 <listitem>
227 <para><computeroutput>bridgedifs</computeroutput>,
228 <computeroutput>hostonlyifs</computeroutput> and
229 <computeroutput>dhcpservers</computeroutput>, respectively, list
230 bridged network interfaces, host-only network interfaces and DHCP
231 servers currently available on the host. Please see <xref
232 linkend="networkingdetails" /> for details on these.</para>
233 </listitem>
234
235 <listitem>
236 <para><computeroutput>hostinfo</computeroutput> displays information
237 about the host system, such as CPUs, memory size and operating
238 system version.</para>
239 </listitem>
240
241 <listitem>
242 <para><computeroutput>hostcpuids</computeroutput> dumps the CPUID
243 parameters for the host CPUs. This can be used for a more fine
244 grained analyis of the host's virtualization capabilities.</para>
245 </listitem>
246
247 <listitem>
248 <para><computeroutput>hddbackends</computeroutput> lists all known
249 virtual disk back-ends of VirtualBox. For each such format (such as
250 VDI, VMDK or RAW), this lists the back-end's capabilities and
251 configuration.</para>
252 </listitem>
253
254 <listitem>
255 <para><computeroutput>hdds</computeroutput>,
256 <computeroutput>dvds</computeroutput> and
257 <computeroutput>floppies</computeroutput> all give you information
258 about virtual disk images currently in use by VirtualBox, including
259 all their settings, the unique identifiers (UUIDs) associated with
260 them by VirtualBox and all files associated with them. This is the
261 command-line equivalent of the Virtual Media Manager; see <xref
262 linkend="vdis" />.</para>
263 </listitem>
264
265 <listitem>
266 <para><computeroutput>usbhost</computeroutput> supplies information
267 about USB devices attached to the host, notably information useful
268 for constructing USB filters and whether they are currently in use
269 by the host.</para>
270 </listitem>
271
272 <listitem>
273 <para><computeroutput>usbfilters</computeroutput> lists all global
274 USB filters registered with VirtualBox -- that is, filters for
275 devices which are accessible to all virtual machines -- and displays
276 the filter parameters.</para>
277 </listitem>
278
279 <listitem>
280 <para><computeroutput>systemproperties</computeroutput> displays
281 some global VirtualBox settings, such as minimum and maximum guest
282 RAM and virtual hard disk size, folder settings and the current
283 authentication library in use.</para>
284 </listitem>
285
286 <listitem>
287 <para><computeroutput>extpacks</computeroutput> displays all
288 VirtualBox extension packs currently installed; see <xref
289 linkend="intro-installing" /> and <xref
290 linkend="vboxmanage-extpack" /> for more information.</para>
291 </listitem>
292 </itemizedlist></para>
293 </sect1>
294
295 <sect1 id="vboxmanage-showvminfo">
296 <title>VBoxManage showvminfo</title>
297
298 <para>The <computeroutput>showvminfo</computeroutput> command shows
299 information about a particular virtual machine. This is the same
300 information as <computeroutput>VBoxManage list vms --long</computeroutput>
301 would show for all virtual machines.</para>
302
303 <para>You will get information similar to the following:</para>
304
305 <para><screen>$ VBoxManage showvminfo "Windows XP"
306VirtualBox Command Line Management Interface Version $VBOX_VERSION_MAJOR.$VBOX_VERSION_MINOR.$VBOX_VERSION_BUILD
307(C) 2005-$VBOX_C_YEAR $VBOX_VENDOR
308All rights reserved.
309
310Name: Windows XP
311Guest OS: Other/Unknown
312UUID: 1bf3464d-57c6-4d49-92a9-a5cc3816b7e7
313Config file: /home/username/.VirtualBox/Machines/Windows XP/Windows XP.xml
314Memory size: 512MB
315VRAM size: 12MB
316Number of CPUs: 2
317Synthetic Cpu: off
318Boot menu mode: message and menu
319Boot Device (1): DVD
320Boot Device (2): HardDisk
321Boot Device (3): Not Assigned
322Boot Device (4): Not Assigned
323ACPI: on
324IOAPIC: on
325PAE: on
326Time offset: 0 ms
327Hardw. virt.ext: on
328Hardw. virt.ext exclusive: on
329Nested Paging: on
330VT-x VPID: off
331State: powered off (since 2009-10-20T14:52:19.000000000)
332Monitor count: 1
3333D Acceleration: off
3342D Video Acceleration: off
335Teleporter Enabled: off
336Teleporter Port: 0
337Teleporter Address:
338Teleporter Password:
339Storage Controller (0): IDE Controller
340Storage Controller Type (0): PIIX4
341Storage Controller (1): Floppy Controller 1
342Storage Controller Type (1): I82078
343IDE Controller (0, 0): /home/user/windows.vdi (UUID: 46f6e53a-4557-460a-9b95-68b0f17d744b)
344IDE Controller (0, 1): /home/user/openbsd-cd46.iso (UUID: 4335e162-59d3-4512-91d5-b63e94eebe0b)
345Floppy Controller 1 (0, 0): /home/user/floppy.img (UUID: 62ac6ccb-df36-42f2-972e-22f836368137)
346NIC 1: disabled
347NIC 2: disabled
348NIC 3: disabled
349NIC 4: disabled
350NIC 5: disabled
351NIC 6: disabled
352NIC 7: disabled
353NIC 8: disabled
354UART 1: disabled
355UART 2: disabled
356Audio: disabled (Driver: Unknown)
357Clipboard Mode: Bidirectional
358VRDE: disabled
359USB: disabled
360
361USB Device Filters:
362&lt;none&gt;
363
364Shared folders:
365&lt;none&gt;
366
367Statistics update: disabled
368</screen></para>
369 </sect1>
370
371 <sect1 id="vboxmanage-registervm">
372 <title>VBoxManage registervm / unregistervm</title>
373
374 <para>The <computeroutput>registervm</computeroutput> command allows you
375 to import a virtual machine definition in an XML file into VirtualBox. The
376 machine must not conflict with one already registered in VirtualBox and it
377 may not have any hard or removable disks attached. It is advisable to
378 place the definition file in the machines folder before registering
379 it.<note>
380 <para>When creating a new virtual machine with
381 <computeroutput>VBoxManage createvm</computeroutput> (see below), you
382 can directly specify the <computeroutput>--register</computeroutput>
383 option to avoid having to register it separately.</para>
384 </note></para>
385
386 <para>The <computeroutput>unregistervm</computeroutput> command
387 unregisters a virtual machine. If
388 <computeroutput>--delete</computeroutput> is also specified, the following
389 files will automatically be deleted as well:<orderedlist>
390 <listitem>
391 <para>all hard disk image files, including differencing files, which
392 are used by the machine and not shared with other machines;</para>
393 </listitem>
394
395 <listitem>
396 <para>saved state files that the machine created, if any (one if the
397 machine was in "saved" state and one for each online
398 snapshot);</para>
399 </listitem>
400
401 <listitem>
402 <para>the machine XML file and its backups;</para>
403 </listitem>
404
405 <listitem>
406 <para>the machine log files, if any;</para>
407 </listitem>
408
409 <listitem>
410 <para>the machine directory, if it is empty after having deleted all
411 the above.</para>
412 </listitem>
413 </orderedlist></para>
414 </sect1>
415
416 <sect1>
417 <title id="vboxmanage-createvm">VBoxManage createvm</title>
418
419 <para>This command creates a new XML virtual machine definition
420 file.</para>
421
422 <para>The <computeroutput>--name &lt;name&gt;</computeroutput> parameter
423 is required and must specify the name of the machine. Since this name is
424 used by default as the file name of the settings file (with the extension
425 <computeroutput>.xml</computeroutput>) and the machine folder (a subfolder
426 of the <computeroutput>.VirtualBox/Machines</computeroutput> folder), it
427 must conform to your host operating system's requirements for file name
428 specifications. If the VM is later renamed, the file and folder names will
429 change automatically.</para>
430
431 <para>However, if the <computeroutput>--basefolder
432 &lt;path&gt;</computeroutput> option is used, the machine folder will be
433 named <computeroutput>&lt;path&gt;</computeroutput>. In this case, the
434 names of the file and the folder will not change if the virtual machine is
435 renamed.</para>
436
437 <para>By default, this command only creates the XML file without
438 automatically registering the VM with your VirtualBox installation. To
439 register the VM instantly, use the optional
440 <computeroutput>--register</computeroutput> option, or run
441 <computeroutput>VBoxManage registervm</computeroutput> separately
442 afterwards.</para>
443 </sect1>
444
445 <sect1 id="vboxmanage-modifyvm">
446 <title>VBoxManage modifyvm</title>
447
448 <para>This command changes the properties of a registered virtual machine
449 which is not running. Most of the properties that this command makes
450 available correspond to the VM settings that VirtualBox graphical user
451 interface displays in each VM's "Settings" dialog; these were described in
452 <xref linkend="BasicConcepts" />. Some of the more advanced settings,
453 however, are only available through the
454 <computeroutput>VBoxManage</computeroutput> interface.</para>
455
456 <para>These commands require that the machine is powered off (neither
457 running nor in "saved" state). Some machine settings can also be changed
458 while a machine is running; those settings will then have a corresponding
459 subcommand with the <computeroutput>VBoxManage controlvm</computeroutput>
460 subcommand (see <xref linkend="vboxmanage-controlvm" />).</para>
461
462 <sect2>
463 <title>General settings</title>
464
465 <para>The following general settings are available through
466 <computeroutput>VBoxManage modifyvm</computeroutput>:<itemizedlist>
467 <listitem>
468 <para><computeroutput>--name &lt;name&gt;</computeroutput>: This
469 changes the VM's name and possibly renames the internal virtual
470 machine files, as described with <computeroutput>VBoxManage
471 createvm</computeroutput> above.</para>
472 </listitem>
473
474 <listitem>
475 <para><computeroutput>--ostype &lt;ostype&gt;</computeroutput>:
476 This specifies what guest operating system is supposed to run in
477 the VM. To learn about the various identifiers that can be used
478 here, use <computeroutput>VBoxManage list
479 ostypes</computeroutput>.</para>
480 </listitem>
481
482 <listitem>
483 <para><computeroutput>--memory
484 &lt;memorysize&gt;</computeroutput>: This sets the amount of RAM,
485 in MB, that the virtual machine should allocate for itself from
486 the host. See the remarks in <xref linkend="gui-createvm" /> for
487 more information.</para>
488 </listitem>
489
490 <listitem>
491 <para><computeroutput>--vram &lt;vramsize&gt;</computeroutput>:
492 This sets the amount of RAM that the virtual graphics card should
493 have. See <xref linkend="settings-display" /> for details.</para>
494 </listitem>
495
496 <listitem>
497 <para><computeroutput>--acpi on|off</computeroutput>;
498 <computeroutput>--ioapic on|off</computeroutput>: These two
499 determine whether the VM should have ACPI and I/O APIC support,
500 respectively; see <xref linkend="settings-motherboard" /> for
501 details.</para>
502 </listitem>
503
504 <listitem>
505 <para><computeroutput>--hardwareuuid
506 &lt;uuid&gt;</computeroutput>: The UUID presented to the guest via
507 memory tables (DMI/SMBIOS), hardware and guest properties. By
508 default this is the same as the VM uuid. Useful when cloning a VM.
509 Teleporting takes care of this automatically.</para>
510 </listitem>
511
512 <listitem>
513 <para><computeroutput>--cpus &lt;cpucount&gt;</computeroutput>:
514 This sets the number of virtual CPUs for the virtual machine (see
515 <xref linkend="settings-processor" />). If CPU hot-plugging is
516 enabled (see below), this then sets the
517 <emphasis>maximum</emphasis> number of virtual CPUs that can be
518 plugged into the virtual machines.</para>
519 </listitem>
520
521 <listitem>
522 <para><computeroutput>--rtcuseutc on|off</computeroutput>: This
523 option lets the real-time clock (RTC) operate in UTC time (see
524 <xref linkend="settings-motherboard" />).</para>
525 </listitem>
526
527 <listitem>
528 <para><computeroutput>--cpuhotplug on|off</computeroutput>: This
529 enables CPU hot-plugging. When enabled, virtual CPUs can be added
530 to and removed from a virtual machine while it is running. See
531 <xref linkend="cpuhotplug" /> for more information.</para>
532 </listitem>
533
534 <listitem>
535 <para><computeroutput>--plugcpu|unplugcpu
536 &lt;id&gt;</computeroutput>: If CPU hot-plugging is enabled (see
537 above), this adds a virtual CPU to the virtual machines (or
538 removes one). <computeroutput>&lt;id&gt;</computeroutput>
539 specifies the index of the virtual CPU to be added or removed and
540 must be a number from 0 to the maximum no. of CPUs configured with
541 the <computeroutput>--cpus</computeroutput> option. CPU 0 can
542 never be removed.</para>
543 </listitem>
544
545 <listitem>
546 <para><computeroutput>--cpuexecutioncap
547 &lt;1-100&gt;</computeroutput>: This setting controls how much cpu
548 time a virtual CPU can use. A value of 50 implies a single virtual
549 CPU can use up to 50% of a single host CPU.</para>
550 </listitem>
551
552 <listitem>
553 <para><computeroutput>--synthcpu on|off</computeroutput>: This
554 setting determines whether VirtualBox will expose a synthetic CPU
555 to the guest to allow live migration between host systems that
556 differ significantly.</para>
557 </listitem>
558
559 <listitem>
560 <para><computeroutput>--pae on|off</computeroutput>: This
561 enables/disables PAE (see <xref
562 linkend="settings-processor" />).</para>
563 </listitem>
564
565 <listitem>
566 <para><computeroutput>--hpet on|off</computeroutput>: This
567 enables/disables a High Precision Event Timer (HPET) which can
568 replace the legacy system timers. This is turned off by default.
569 Note that Windows supports a HPET only from Vista onwards.</para>
570 </listitem>
571
572 <listitem>
573 <para><computeroutput>--hwvirtex on|off</computeroutput>: This
574 enables or disables the use of hardware virtualization extensions
575 (Intel VT-x or AMD-V) in the processor of your host system; see
576 <xref linkend="hwvirt" />.</para>
577 </listitem>
578
579 <listitem>
580 <para><computeroutput>--hwvirtexexcl on|off</computeroutput>: This
581 specifies whether VirtualBox will make exclusive use of the
582 hardware virtualization extensions (Intel VT-x or AMD-V) in the
583 processor of your host system; see <xref linkend="hwvirt" />. If
584 you wish to simultaneously share these extensions with other
585 hypervisors, then you must disable this setting. Doing so has
586 negative performance implications.</para>
587 </listitem>
588
589 <listitem>
590 <para><computeroutput>--nestedpaging on|off</computeroutput>: If
591 hardware virtualization is enabled, this additional setting
592 enables or disables the use of the nested paging feature in the
593 processor of your host system; see <xref
594 linkend="hwvirt" />.</para>
595 </listitem>
596
597 <listitem>
598 <para><computeroutput>--largepages on|off</computeroutput>: If
599 hardware virtualization <emphasis>and</emphasis> nested paging are
600 enabled, for Intel VT-x only, an additional performance
601 improvement of up to 5% can be obtained by enabling this setting.
602 This causes the hypervisor to use large pages to reduce TLB use
603 and overhead.</para>
604 </listitem>
605
606 <listitem>
607 <para><computeroutput>--vtxvpid on|off</computeroutput>: If
608 hardware virtualization is enabled, for Intel VT-x only, this
609 additional setting enables or disables the use of the tagged TLB
610 (VPID) feature in the processor of your host system; see <xref
611 linkend="hwvirt" />.</para>
612 </listitem>
613
614 <listitem>
615 <para><computeroutput>--accelerate3d on|off</computeroutput>: This
616 enables, if the Guest Additions are installed, whether hardware 3D
617 acceleration should be available; see <xref
618 linkend="guestadd-3d" />.</para>
619 </listitem>
620
621 <listitem>
622 <para>You can influence the BIOS logo that is displayed when a
623 virtual machine starts up with a number of settings. Per default,
624 a VirtualBox logo is displayed.</para>
625
626 <para>With <computeroutput>--bioslogofadein
627 on|off</computeroutput> and <computeroutput>--bioslogofadeout
628 on|off</computeroutput>, you can determine whether the logo should
629 fade in and out, respectively.</para>
630
631 <para>With <computeroutput>--bioslogodisplaytime
632 &lt;msec&gt;</computeroutput> you can set how long the logo should
633 be visible, in milliseconds.</para>
634
635 <para>With <computeroutput>--bioslogoimagepath
636 &lt;imagepath&gt;</computeroutput> you can, if you are so
637 inclined, replace the image that is shown, with your own logo. The
638 image must be an uncompressed 256 color BMP file.</para>
639 </listitem>
640
641 <listitem>
642 <para><computeroutput>--biosbootmenu
643 disabled|menuonly|messageandmenu</computeroutput>: This specifies
644 whether the BIOS allows the user to select a temporary boot
645 device. <computeroutput>menuonly</computeroutput> suppresses the
646 message, but the user can still press F12 to select a temporary
647 boot device.</para>
648 </listitem>
649
650 <listitem>
651 <para><computeroutput>--nicbootprio&lt;1-N&gt;
652 &lt;priority&gt;</computeroutput>: This specifies the order in which
653 NICs are tried for booting over the network (using PXE). The
654 priority is an integer in the 0 to 4 range. Priority 1 is the
655 highest, priority 4 is low. Priority 0, which is the default unless
656 otherwise specified, is the lowest.
657 </para>
658 <para> Note that this option only has effect when the Intel PXE boot
659 ROM is used.
660 </para>
661 </listitem>
662
663 <listitem>
664 <para><computeroutput>--boot&lt;1-4&gt;
665 none|floppy|dvd|disk|net</computeroutput>: This specifies the boot
666 order for the virtual machine. There are four "slots", which the
667 VM will try to access from 1 to 4, and for each of which you can
668 set a device that the VM should attempt to boot from.</para>
669 </listitem>
670
671 <listitem>
672 <para><computeroutput>--snapshotfolder
673 default|&lt;path&gt;</computeroutput>: This allows you to specify
674 the folder in which snapshots will be kept for a virtual
675 machine.</para>
676 </listitem>
677
678 <listitem>
679 <para><computeroutput>--firmware efi|bios</computeroutput>:
680 Specifies which firmware is used to boot particular virtual
681 machine: EFI or BIOS. Use EFI only if your fully understand what
682 you're doing.</para>
683 </listitem>
684
685
686 <listitem>
687 <para><computeroutput>--guestmemoryballoon
688 &lt;size&gt;</computeroutput> sets the default size of the guest
689 memory balloon, that is, memory allocated by the VirtualBox Guest
690 Additions from the guest operating system and returned to the
691 hypervisor for re-use by other virtual machines. &lt;size&gt; must
692 be specified in megabytes. The default size is 0 megabytes. For
693 details, see <xref linkend="guestadd-balloon" />.</para>
694 </listitem>
695
696 <listitem>
697 <para><computeroutput>--lptmode
698 &lt;Device&gt; </computeroutput>
699 Specifies the Device Name of the lpt/parallel port that
700 the Parallel Port feature will be using. Use this BEFORE --lpt. This feature is Host specific and unrelated to Guest OS.</para>
701 </listitem>
702
703 <listitem>
704 <para><computeroutput>--lpt
705 &lt;IOAddress IRQNumber&gt; </computeroutput>
706 Specifies the I/O address of the lpt/parallel port and the IRQ number that
707 the Parallel Port feature will be using. Use this AFTER --lptmod. This feature is Host specific and unrelated to Guest OS.</para>
708 </listitem>
709 </itemizedlist></para>
710 </sect2>
711
712 <sect2>
713 <title>Networking settings</title>
714
715 <para>The following networking settings are available through
716 <computeroutput>VBoxManage modifyvm</computeroutput>. With all these
717 settings, the decimal number directly following the option name ("1-N"
718 in the list below) specifies the virtual network adapter whose settings
719 should be changed.<itemizedlist>
720 <listitem>
721 <para><computeroutput>--nic&lt;1-N&gt;
722 none|null|nat|bridged|intnet|hostonly|generic
723 </computeroutput>: With
724 this, you can set, for each of the VM's virtual network cards,
725 what type of networking should be available. They can be not
726 present (<computeroutput>none</computeroutput>), not connected to
727 the host (<computeroutput>null</computeroutput>), use network
728 address translation (<computeroutput>nat</computeroutput>),
729 bridged networking (<computeroutput>bridged</computeroutput>) or
730 communicate with other virtual machines using internal networking
731 (<computeroutput>intnet</computeroutput>), host-only networking
732 (<computeroutput>hostonly</computeroutput>), or access rarely used
733 sub-modes (<computeroutput>generic</computeroutput>).
734 These options correspond
735 to the modes which are described in detail in <xref
736 linkend="networkingmodes" />.</para>
737 </listitem>
738
739 <listitem>
740 <para><computeroutput>--nictype&lt;1-N&gt;
741 Am79C970A|Am79C973|82540EM|82543GC|82545EM|virtio</computeroutput>:
742 This allows you, for each of the VM's virtual network cards, to
743 specify which networking hardware VirtualBox presents to the
744 guest; see <xref linkend="nichardware" />.</para>
745 </listitem>
746
747 <listitem>
748 <para><computeroutput>--cableconnected&lt;1-N&gt;
749 on|off</computeroutput>: This allows you to temporarily disconnect
750 a virtual network interface, as if a network cable had been pulled
751 from a real network card. This might be useful for resetting
752 certain software components in the VM.</para>
753 </listitem>
754
755 <listitem>
756 <para>With the "nictrace" options, you can optionally trace
757 network traffic by dumping it to a file, for debugging
758 purposes.</para>
759
760 <para>With <computeroutput>--nictrace&lt;1-N&gt;
761 on|off</computeroutput>, you can enable network tracing for a
762 particular virtual network card.</para>
763
764 <para>If enabled, you must specify with
765 <computeroutput>--nictracefile&lt;1-N&gt;
766 &lt;filename&gt;</computeroutput> what file the trace should be
767 logged to.</para>
768 </listitem>
769
770 <listitem>
771 <para><computeroutput>--bridgeadapter&lt;1-N&gt;
772 none|&lt;devicename&gt;</computeroutput>: If bridged networking
773 has been enabled for a virtual network card (see the
774 <computeroutput>--nic</computeroutput> option above; otherwise
775 this setting has no effect), use this option to specify which host
776 interface the given virtual network interface will use. For
777 details, please see <xref linkend="network_bridged" />.</para>
778 </listitem>
779
780 <listitem>
781 <para><computeroutput>--hostonlyadapter&lt;1-N&gt;
782 none|&lt;devicename&gt;</computeroutput>: If host-only networking
783 has been enabled for a virtual network card (see the --nic option
784 above; otherwise this setting has no effect), use this option to
785 specify which host-only networking interface the given virtual
786 network interface will use. For details, please see <xref
787 linkend="network_hostonly" />.</para>
788 </listitem>
789
790 <listitem>
791 <para><computeroutput>--intnet&lt;1-N&gt;
792 network</computeroutput>: If internal networking has been enabled
793 for a virtual network card (see the
794 <computeroutput>--nic</computeroutput> option above; otherwise
795 this setting has no effect), use this option to specify the name
796 of the internal network (see <xref
797 linkend="network_internal" />).</para>
798 </listitem>
799
800 <listitem>
801 <para><computeroutput>--macaddress&lt;1-N&gt;
802 auto|&lt;mac&gt;</computeroutput>: With this option you can set
803 the MAC address of the virtual network card. Normally, each
804 virtual network card is assigned a random address by VirtualBox at
805 VM creation.</para>
806 </listitem>
807
808 <listitem>
809 <para><computeroutput>--nicgenericdrv&lt;1-N&gt;
810 &lt;backend driver&gt;</computeroutput>: If generic networking has been
811 enabled for a virtual network card (see the
812 <computeroutput>--nic</computeroutput> option above; otherwise
813 this setting has no effect), this mode allows you to access
814 rarely used networking sub-modes, such as VDE network or UDP Tunnel.
815 </para>
816 </listitem>
817
818 <listitem>
819 <para><computeroutput>--nicproperty&lt;1-N&gt;
820 &lt;paramname&gt;="paramvalue"</computeroutput>:
821 This option, in combination with "nicgenericdrv" allows you to
822 pass parameters to rarely-used network backends.</para><para>
823 Those parameters are backend engine-specific, and are different
824 between UDP Tunnel and the VDE backend drivers. For example,
825 please see <xref linkend="network_udp_tunnel" />.
826 </para>
827 </listitem>
828 </itemizedlist></para>
829
830 <sect3>
831 <title>NAT Networking settings.</title>
832
833 <para>The following NAT networking settings are available through
834 <computeroutput>VBoxManage modifyvm</computeroutput>. With all these
835 settings, the decimal number directly following the option name ("1-N"
836 in the list below) specifies the virtual network adapter whose
837 settings should be changed.<itemizedlist>
838 <listitem>
839 <para><computeroutput>--natpf&lt;1-N&gt;
840 [&lt;name&gt;],tcp|udp,[&lt;hostip&gt;],&lt;hostport&gt;,[&lt;guestip&gt;],
841 &lt;guestport&gt;</computeroutput>: This option defines a NAT
842 port-forwarding rule (please see <xref linkend="natforward" />
843 for details).</para>
844 </listitem>
845
846 <listitem>
847 <para><computeroutput>--natpf&lt;1-N&gt; delete
848 &lt;name&gt;</computeroutput>: This option deletes a NAT
849 port-forwarding rule (please see <xref linkend="natforward" />
850 for details).</para>
851 </listitem>
852
853 <listitem>
854 <para><computeroutput>--nattftpprefix&lt;1-N&gt;
855 &lt;prefix&gt;</computeroutput>: This option defines a prefix
856 for the built-in TFTP server, i.e. where the boot file is
857 located (please see <xref linkend="nat-tftp" /> and <xref
858 linkend="nat-adv-tftp" /> for details).</para>
859 </listitem>
860
861 <listitem>
862 <para><computeroutput>--nattftpfile&lt;1-N&gt;
863 &lt;bootfile&gt;</computeroutput>: This option defines the TFT
864 boot file (please see <xref linkend="nat-adv-tftp" /> for
865 details).</para>
866 </listitem>
867
868 <listitem>
869 <para><computeroutput>--nattftpserver&lt;1-N&gt;
870 &lt;tftpserver&gt;</computeroutput>: This option defines the
871 TFTP server address to boot from (please see <xref
872 linkend="nat-adv-tftp" /> for details).</para>
873 </listitem>
874
875 <listitem>
876 <para><computeroutput>--natdnspassdomain&lt;1-N&gt;
877 on|off</computeroutput>: This option specifies whether the
878 built-in DHCP server passes the domain name for network name
879 resolution.</para>
880 </listitem>
881
882 <listitem>
883 <para><computeroutput>--natdnsproxy&lt;1-N&gt;
884 on|off</computeroutput>: This option makes the NAT engine proxy
885 all guest DNS requests to the host's DNS servers (please see
886 <xref linkend="nat-adv-dns" /> for details).</para>
887 </listitem>
888
889 <listitem>
890 <para><computeroutput>--natdnshostresolver&lt;1-N&gt;
891 on|off</computeroutput>: This option makes the NAT engine use
892 the host's resolver mechanisms to handle DNS requests (please
893 see <xref linkend="nat-adv-dns" /> for details).</para>
894 </listitem>
895
896 <listitem>
897 <para><computeroutput>--natnatsettings&lt;1-N&gt;
898 [&lt;mtu&gt;],[&lt;socksnd&gt;],[&lt;sockrcv&gt;],[&lt;tcpsnd&gt;],
899 [&lt;tcprcv&gt;]</computeroutput>: This option controls several
900 NAT settings (please see <xref linkend="nat-adv-settings" /> for
901 details).</para>
902 </listitem>
903
904 <listitem>
905 <para><computeroutput>--nataliasmode&lt;1-N&gt;
906 default|[log],[proxyonly],[sameports]</computeroutput>: This
907 option defines behaviour of NAT engine core: log - enables
908 logging, proxyonly - switches of aliasing mode makes NAT
909 transparent, sameports enforces NAT engine to send packets via
910 the same port as they originated on, default - disable all
911 mentioned modes above . (please see <xref
912 linkend="nat-adv-alias" /> for details).</para>
913 </listitem>
914 </itemizedlist></para>
915 </sect3>
916 </sect2>
917
918 <sect2 id="vboxmanage-modifyvm-other">
919 <title>Serial port, audio, clipboard, remote desktop and USB
920 settings</title>
921
922 <para>The following other hardware settings are available through
923 <computeroutput>VBoxManage modifyvm</computeroutput>:<itemizedlist>
924 <listitem>
925 <para><computeroutput>--uart&lt;1-N&gt; off|&lt;I/O base&gt;
926 &lt;IRQ&gt;</computeroutput>: With this option you can configure
927 virtual serial ports for the VM; see <xref
928 linkend="serialports" /> for an introduction.</para>
929 </listitem>
930
931 <listitem>
932 <para><computeroutput>--uartmode&lt;1-N&gt;
933 &lt;arg&gt;</computeroutput>: This setting controls how VirtualBox
934 connects a given virtual serial port (previously configured with
935 the <computeroutput>--uartX</computeroutput> setting, see above)
936 to the host on which the virtual machine is running. As described
937 in detail in <xref linkend="serialports" />, for each such port,
938 you can specify <computeroutput>&lt;arg&gt;</computeroutput> as
939 one of the following options:<itemizedlist>
940 <listitem>
941 <para><computeroutput>disconnected</computeroutput>: Even
942 though the serial port is shown to the guest, it has no
943 "other end" -- like a real COM port without a cable.</para>
944 </listitem>
945
946 <listitem>
947 <para><computeroutput>server
948 &lt;pipename&gt;</computeroutput>: On a Windows host, this
949 tells VirtualBox to create a named pipe on the host named
950 <computeroutput>&lt;pipename&gt;</computeroutput> and
951 connect the virtual serial device to it. Note that Windows
952 requires that the name of a named pipe begin with
953 <computeroutput>\\.\pipe\</computeroutput>.</para>
954
955 <para>On a Linux host, instead of a named pipe, a local
956 domain socket is used.</para>
957 </listitem>
958
959 <listitem>
960 <para><computeroutput>client
961 &lt;pipename&gt;</computeroutput>: This operates just like
962 <computeroutput>server ...</computeroutput>, except that the
963 pipe (or local domain socket) is not created by VirtualBox,
964 but assumed to exist already.</para>
965 </listitem>
966
967 <listitem>
968 <para><computeroutput>&lt;devicename&gt;</computeroutput>:
969 If, instead of the above, the device name of a physical
970 hardware serial port of the host is specified, the virtual
971 serial port is connected to that hardware port. On a Windows
972 host, the device name will be a COM port such as
973 <computeroutput>COM1</computeroutput>; on a Linux host, the
974 device name will look like
975 <computeroutput>/dev/ttyS0</computeroutput>. This allows you
976 to "wire" a real serial port to a virtual machine.</para>
977 </listitem>
978 </itemizedlist></para>
979 </listitem>
980
981 <listitem>
982 <para><computeroutput>--audio none|null|oss</computeroutput>: With
983 this option, you can set whether the VM should have audio
984 support.</para>
985 </listitem>
986
987 <listitem>
988 <para><computeroutput>--clipboard
989 disabled|hosttoguest|guesttohost|bidirectional</computeroutput>:
990 With this setting, you can select whether the guest operating
991 system's clipboard should be shared with the host; see <xref
992 linkend="generalsettings" />. This requires that the Guest
993 Additions be installed in the virtual machine.</para>
994 </listitem>
995
996 <listitem>
997 <para><computeroutput>--monitorcount
998 &lt;count&gt;</computeroutput>: This enables multi-monitor
999 support; see <xref linkend="settings-display" />.</para>
1000 </listitem>
1001
1002 <listitem>
1003 <para><computeroutput>--usb on|off</computeroutput>: This option
1004 enables or disables the VM's virtual USB controller; see <xref
1005 linkend="settings-usb" /> for details.</para>
1006 </listitem>
1007
1008 <listitem>
1009 <para><computeroutput>--usbehci on|off</computeroutput>: This
1010 option enables or disables the VM's virtual USB 2.0 controller;
1011 see <xref linkend="settings-usb" /> for details.</para>
1012 </listitem>
1013 </itemizedlist></para>
1014 </sect2>
1015
1016 <sect2>
1017 <title>Remote machine settings</title>
1018
1019 <para>The following settings that affect remote machine behavior are
1020 available through <computeroutput>VBoxManage
1021 modifyvm</computeroutput>:<itemizedlist>
1022 <listitem>
1023 <para><computeroutput>--vrde on|off</computeroutput>: With the
1024 VirtualBox graphical user interface, this enables or disables the
1025 VirtualBox remote desktop extension (VRDE) server. Note that if
1026 you are using <computeroutput>VBoxHeadless</computeroutput> (see
1027 <xref linkend="vboxheadless" />), VRDE is enabled by
1028 default.</para>
1029 </listitem>
1030
1031 <listitem>
1032 <para><computeroutput>--vrdeport
1033 default|&lt;ports&gt;</computeroutput>: A port or a range of ports
1034 the VRDE server can bind to; "default" or "0" means port 3389, the
1035 standard port for RDP. You can specify a comma-separated list of
1036 ports or ranges of ports. Use a dash between two port numbers to
1037 specify a range. The VRDE server will bind to <emphasis
1038 role="bold">one</emphasis> of available ports from the specified
1039 list. Only one machine can use a given port at a time. For
1040 example, the option <computeroutput> --vrdeport
1041 5000,5010-5012</computeroutput> will tell the server to bind to
1042 one of following ports: 5000, 5010, 5011 or 5012.</para>
1043 </listitem>
1044
1045 <listitem>
1046 <para><computeroutput>--vrdeaddress &lt;IP
1047 address&gt;</computeroutput>: The IP address of the host network
1048 interface the VRDE server will bind to. If specified, the server
1049 will accept connections only on the specified host network
1050 interface.</para>
1051 </listitem>
1052
1053 <listitem>
1054 <para><computeroutput>--vrdeauthtype
1055 null|external|guest</computeroutput>: This allows you to choose
1056 whether and how authorization will be performed; see <xref
1057 linkend="vbox-auth" /> for details.</para>
1058 </listitem>
1059
1060 <listitem>
1061 <para><computeroutput>--vrdemulticon on|off</computeroutput>: This
1062 enables multiple connections to the same VRDE server, if the
1063 server supports this feature; see <xref lang=""
1064 linkend="vrde-multiconnection" />.</para>
1065 </listitem>
1066
1067 <listitem>
1068 <para><computeroutput>--vrdereusecon on|off</computeroutput>: This
1069 specifies the VRDE server behavior when multiple connections are
1070 disabled. When this option is enabled, the server will allow a new
1071 client to connect and will drop the existing connection. When this
1072 option is disabled (this is the default setting), a new connection
1073 will not be accepted if there is already a client connected to the
1074 server.</para>
1075 </listitem>
1076
1077 <listitem>
1078 <para><computeroutput>--vrdevideochannel on|off</computeroutput>:
1079 This enables video redirection, if it is supported by the VRDE
1080 server; see <xref lang="" linkend="vrde-videochannel" />.</para>
1081 </listitem>
1082
1083 <listitem>
1084 <para><computeroutput>--vrdevideochannelquality
1085 &lt;percent&gt;</computeroutput>: Sets the image quality for video
1086 redirection; see <xref lang=""
1087 linkend="vrde-videochannel" />.</para>
1088 </listitem>
1089 </itemizedlist></para>
1090 </sect2>
1091
1092 <sect2 id="vboxmanage-modifyvm-teleport">
1093 <title>Teleporting settings</title>
1094
1095 <para>With the following commands for <computeroutput>VBoxManage
1096 modifyvm</computeroutput> you can configure a machine to be a target for
1097 teleporting. See <xref linkend="teleporting" /> for an
1098 introduction.<itemizedlist>
1099 <listitem>
1100 <para><computeroutput>--teleporter on|off</computeroutput>: With
1101 this setting you turn on or off whether a machine waits for a
1102 teleporting request to come in on the network when it is started.
1103 If "on", when the machine is started, it does not boot the virtual
1104 machine as it would normally; instead, it then waits for a
1105 teleporting request to come in on the port and address listed with
1106 the next two parameters.</para>
1107 </listitem>
1108
1109 <listitem>
1110 <para><computeroutput>--teleporterport
1111 &lt;port&gt;</computeroutput>, <computeroutput>--teleporteraddress
1112 &lt;address&gt;</computeroutput>: these must be used with
1113 --teleporter and tell the virtual machine on which port and
1114 address it should listen for a teleporting request from another
1115 virtual machine. <computeroutput>&lt;port&gt;</computeroutput> can
1116 be any free TCP/IP port number (e.g. 6000);
1117 <computeroutput>&lt;address&gt;</computeroutput> can be any IP
1118 address or hostname and specifies the TCP/IP socket to bind to.
1119 The default is "0.0.0.0", which means any address.</para>
1120 </listitem>
1121
1122 <listitem>
1123 <para><computeroutput>--teleporterpassword
1124 &lt;password&gt;</computeroutput>: if this optional argument is
1125 given, then the teleporting request will only succeed if the
1126 source machine specifies the same password as the one given with
1127 this command.</para>
1128 </listitem>
1129
1130 <listitem>
1131 <para><computeroutput>--teleporterpasswordfile
1132 &lt;password&gt;</computeroutput>: if this optional argument is
1133 given, then the teleporting request will only succeed if the
1134 source machine specifies the same password as the one specified
1135 in the file give with this command. Use <computeroutput>stdin</computeroutput>
1136 to read the password from stdin.</para>
1137 </listitem>
1138
1139 <listitem>
1140 <para><computeroutput>--cpuid &lt;leaf&gt; &lt;eax&gt; &lt;ebx&gt;
1141 &lt;ecx&gt; &lt;edx&gt;</computeroutput>: Advanced users can use
1142 this command before a teleporting operation to restrict the
1143 virtual CPU capabilities that VirtualBox presents to the guest
1144 operating system. This must be run on both the source and the
1145 target machines involved in the teleporting and will then modify
1146 what the guest sees when it executes the
1147 <computeroutput>CPUID</computeroutput> machine instruction. This
1148 might help with misbehaving applications that wrongly assume that
1149 certain CPU capabilities are present. The meaning of the
1150 parameters is hardware dependent; please refer to the AMD or Intel
1151 processor manuals.</para>
1152 </listitem>
1153 </itemizedlist></para>
1154 </sect2>
1155 </sect1>
1156
1157 <sect1 id="vboxmanage-clonevm">
1158 <title>VBoxManage clonevm</title>
1159
1160 <para>This command creates a full or linked copy of an existing virtual
1161 machine.</para>
1162
1163 <para>The <computeroutput>clonevm</computeroutput> subcommand takes at
1164 least the name of the virtual machine which should be cloned. The following
1165 additional settings can be used to further configure the clone VM
1166 operation:</para>
1167
1168 <itemizedlist>
1169 <listitem>
1170 <para><computeroutput>--snapshot &lt;uuid&gt;|&lt;name&gt;</computeroutput>:
1171 Select a specific snapshot where the clone operation should refer
1172 to. Default is referring to the current state.</para>
1173 </listitem>
1174 <listitem>
1175 <para><computeroutput>--mode machine|machineandchildren|all</computeroutput>:
1176 Selects the cloning mode of the operation. If
1177 <computeroutput>machine</computeroutput> is selected (the default),
1178 the current state of the VM without any snapshots is cloned. In the
1179 <computeroutput>machineandchildren</computeroutput> mode the snapshot
1180 provided by <computeroutput>--snapshot</computeroutput> and all
1181 child snapshots are cloned. If <computeroutput>all</computeroutput>
1182 is the selected mode all snapshots and the current state are cloned.
1183 </para>
1184 </listitem>
1185 <listitem>
1186 <para><computeroutput>--options link|keepallmacs|keepnatmacs|keepdisknames</computeroutput>:
1187 Allows additional fine tuning of the clone operation. The first
1188 option defines that a linked clone should be created, which is
1189 only possible for a machine clone from a snapshot. The next two
1190 options allow to define how the MAC addresses of every virtual
1191 network card should be handled. They can either be reinitialized
1192 (the default), left unchanged
1193 (<computeroutput>keepallmacs</computeroutput>) or left unchanged
1194 when the network type is NAT
1195 (<computeroutput>keepnatmacs</computeroutput>). If you add
1196 <computeroutput>keepdisknames</computeroutput> all new disk images
1197 are called like the original once, otherwise they are
1198 renamed.</para>
1199 </listitem>
1200 <listitem>
1201 <para><computeroutput>--name &lt;name&gt;</computeroutput>: Select a
1202 new name for the new virtual machine. Default is "Original Name
1203 Clone".</para>
1204 </listitem>
1205 <listitem>
1206 <para><computeroutput>--basefolder &lt;basefolder&gt;</computeroutput>:
1207 Select the folder where the new virtual machine configuration should
1208 be saved in.</para>
1209 </listitem>
1210 <listitem>
1211 <para><computeroutput>--uuid &lt;uuid&gt;</computeroutput>:
1212 Select the UUID the new VM should have. This id has to be unique in
1213 the VirtualBox instance this clone should be registered. Default is
1214 creating a new UUID.</para>
1215 </listitem>
1216 <listitem>
1217 <para><computeroutput>--register</computeroutput>:
1218 Automatically register the new clone in this VirtualBox
1219 installation. If you manually want register the new VM later, see
1220 <xref linkend="vboxmanage-registervm" /> for instructions how to do
1221 so.</para>
1222 </listitem>
1223 </itemizedlist>
1224 </sect1>
1225
1226 <sect1 id="vboxmanage-import">
1227 <title>VBoxManage import</title>
1228
1229 <para>This command imports a virtual appliance in OVF format by copying
1230 the virtual disk images and creating virtual machines in VirtualBox. See
1231 <xref linkend="ovf" /> for an introduction to appliances.</para>
1232
1233 <para>The <computeroutput>import</computeroutput> subcommand takes at
1234 least the path name of an OVF file as input and expects the disk images,
1235 if needed, in the same directory as the OVF file. A lot of additional
1236 command-line options are supported to control in detail what is being
1237 imported and modify the import parameters, but the details depend on the
1238 content of the OVF file.</para>
1239
1240 <para>It is therefore recommended to first run the import subcommand with
1241 the <computeroutput>--dry-run</computeroutput> or
1242 <computeroutput>-n</computeroutput> option. This will then print a
1243 description of the appliance's contents to the screen how it would be
1244 imported into VirtualBox, together with the optional command-line options
1245 to influence the import behavior.</para>
1246
1247 <para>As an example, here is the screen output with a sample appliance
1248 containing a Windows XP guest:<screen>VBoxManage import WindowsXp.ovf --dry-run
1249Interpreting WindowsXp.ovf...
1250OK.
1251Virtual system 0:
1252 0: Suggested OS type: "WindowsXP"
1253 (change with "--vsys 0 --ostype &lt;type&gt;"; use "list ostypes" to list all)
1254 1: Suggested VM name "Windows XP Professional_1"
1255 (change with "--vsys 0 --vmname &lt;name&gt;")
1256 3: Number of CPUs: 1
1257 (change with "--vsys 0 --cpus &lt;n&gt;")
1258 4: Guest memory: 956 MB (change with "--vsys 0 --memory &lt;MB&gt;")
1259 5: Sound card (appliance expects "ensoniq1371", can change on import)
1260 (disable with "--vsys 0 --unit 5 --ignore")
1261 6: USB controller
1262 (disable with "--vsys 0 --unit 6 --ignore")
1263 7: Network adapter: orig bridged, config 2, extra type=bridged
1264 8: Floppy
1265 (disable with "--vsys 0 --unit 8 --ignore")
1266 9: SCSI controller, type BusLogic
1267 (change with "--vsys 0 --unit 9 --scsitype {BusLogic|LsiLogic}";
1268 disable with "--vsys 0 --unit 9 --ignore")
126910: IDE controller, type PIIX4
1270 (disable with "--vsys 0 --unit 10 --ignore")
127111: Hard disk image: source image=WindowsXp.vmdk,
1272 target path=/home/user/disks/WindowsXp.vmdk, controller=9;channel=0
1273 (change controller with "--vsys 0 --unit 11 --controller &lt;id&gt;";
1274 disable with "--vsys 0 --unit 11 --ignore")</screen></para>
1275
1276 <para>As you can see, the individual configuration items are numbered, and
1277 depending on their type support different command-line options. The import
1278 subcommand can be directed to ignore many such items with a
1279 <computeroutput>--vsys X --unit Y --ignore</computeroutput> option, where
1280 X is the number of the virtual system (zero unless there are several
1281 virtual system descriptions in the appliance) and Y the item number, as
1282 printed on the screen.</para>
1283
1284 <para>In the above example, Item #1 specifies the name of the target
1285 machine in VirtualBox. Items #9 and #10 specify hard disk controllers,
1286 respectively. Item #11 describes a hard disk image; in this case, the
1287 additional <computeroutput>--controller</computeroutput> option indicates
1288 which item the disk image should be connected to, with the default coming
1289 from the OVF file.</para>
1290
1291 <para>You can combine several items for the same virtual system behind the
1292 same <computeroutput>--vsys</computeroutput> option. For example, to
1293 import a machine as described in the OVF, but without the sound card and
1294 without the USB controller, and with the disk image connected to the IDE
1295 controller instead of the SCSI controller, use this:<screen>VBoxManage import WindowsXp.ovf
1296 --vsys 0 --unit 5 --ignore --unit 6 --ignore --unit 11 --controller 10</screen></para>
1297 </sect1>
1298
1299 <sect1 id="vboxmanage-export">
1300 <title>VBoxManage export</title>
1301
1302 <para>This command exports one or more virtual machines from VirtualBox
1303 into a virtual appliance in OVF format, including copying their virtual
1304 disk images to compressed VMDK. See <xref linkend="ovf" /> for an
1305 introduction to appliances.</para>
1306
1307 <para>The <computeroutput>export</computeroutput> command is simple to
1308 use: list the machine (or the machines) that you would like to export to
1309 the same OVF file and specify the target OVF file after an additional
1310 <computeroutput>--output</computeroutput> or
1311 <computeroutput>-o</computeroutput> option. Note that the directory of the
1312 target OVF file will also receive the exported disk images in the
1313 compressed VMDK format (regardless of the original format) and should have
1314 enough disk space left for them.</para>
1315
1316 <para>Beside a simple export of a given virtual machine, you can append
1317 several product information to the appliance file. Use
1318 <computeroutput>--product</computeroutput>,
1319 <computeroutput>--producturl</computeroutput>,
1320 <computeroutput>--vendor</computeroutput>,
1321 <computeroutput>--vendorurl</computeroutput> and
1322 <computeroutput>--version</computeroutput> to specify this additional
1323 information. For legal reasons you may add a license text or the content
1324 of a license file by using the <computeroutput>--eula</computeroutput> and
1325 <computeroutput>--eulafile</computeroutput> option respectively. As with
1326 OVF import, you must use the <computeroutput>--vsys X</computeroutput>
1327 option to direct the previously mentioned options to the correct virtual
1328 machine.</para>
1329
1330 <para>For virtualization products which aren't fully compatible with the
1331 OVF standard 1.0 you can enable a OVF 0.9 legacy mode with the
1332 <computeroutput>--legacy09</computeroutput> option.</para>
1333 </sect1>
1334
1335 <sect1 id="vboxmanage-startvm">
1336 <title>VBoxManage startvm</title>
1337
1338 <para>This command starts a virtual machine that is currently in the
1339 "Powered off" or "Saved" states.</para>
1340
1341 <note>
1342 <para>This is provided for backwards compatibility only. We recommend to
1343 start virtual machines directly by running the respective front-end, as
1344 you might otherwise miss important error and state information that
1345 VirtualBox may display on the console. This is especially important for
1346 front-ends other than <computeroutput>VirtualBox</computeroutput>, our
1347 graphical user interface, because those cannot display error messages in
1348 a popup window. See <xref linkend="vboxheadless" /> for more
1349 information.</para>
1350 </note>
1351
1352 <para>The optional <computeroutput>--type</computeroutput> specifier
1353 determines whether the machine will be started in a window (GUI mode,
1354 which is the default) or whether the output should go through
1355 <computeroutput>VBoxHeadless</computeroutput>, with VRDE enabled or not;
1356 see <xref linkend="vboxheadless" /> for more information. The list of
1357 types is subject to change, and it's not guaranteed that all types are
1358 accepted by any product variant.</para>
1359
1360 <para>The following values are allowed:</para>
1361
1362 <glosslist>
1363 <glossentry>
1364 <glossterm>gui</glossterm>
1365
1366 <glossdef>
1367 <para>Starts a VM showing a GUI window. This is the default.</para>
1368 </glossdef>
1369 </glossentry>
1370
1371 <glossentry>
1372 <glossterm>headless</glossterm>
1373
1374 <glossdef>
1375 <para>Starts a VM without a window for remote display only.</para>
1376 </glossdef>
1377 </glossentry>
1378 </glosslist>
1379 </sect1>
1380
1381 <sect1 id="vboxmanage-controlvm">
1382 <title>VBoxManage controlvm</title>
1383
1384 <para>The <computeroutput>controlvm</computeroutput> subcommand allows you
1385 to change the state of a virtual machine that is currently running. The
1386 following can be specified:</para>
1387
1388 <para><itemizedlist>
1389 <listitem>
1390 <para><computeroutput>VBoxManage controlvm &lt;vm&gt;
1391 pause</computeroutput> temporarily puts a virtual machine on hold,
1392 without changing its state for good. The VM window will be painted
1393 in gray to indicate that the VM is currently paused. (This is
1394 equivalent to selecting the "Pause" item in the "Machine" menu of
1395 the GUI.)</para>
1396 </listitem>
1397
1398 <listitem>
1399 <para>Use <computeroutput>VBoxManage controlvm &lt;vm&gt;
1400 resume</computeroutput> to undo a previous
1401 <computeroutput>pause</computeroutput> command. (This is equivalent
1402 to selecting the "Resume" item in the "Machine" menu of the
1403 GUI.)</para>
1404 </listitem>
1405
1406 <listitem>
1407 <para><computeroutput>VBoxManage controlvm &lt;vm&gt;
1408 reset</computeroutput> has the same effect on a virtual machine as
1409 pressing the "Reset" button on a real computer: a cold reboot of the
1410 virtual machine, which will restart and boot the guest operating
1411 system again immediately. The state of the VM is not saved
1412 beforehand, and data may be lost. (This is equivalent to selecting
1413 the "Reset" item in the "Machine" menu of the GUI.)</para>
1414 </listitem>
1415
1416 <listitem>
1417 <para><computeroutput>VBoxManage controlvm &lt;vm&gt;
1418 poweroff</computeroutput> has the same effect on a virtual machine
1419 as pulling the power cable on a real computer. Again, the state of
1420 the VM is not saved beforehand, and data may be lost. (This is
1421 equivalent to selecting the "Close" item in the "Machine" menu of
1422 the GUI or pressing the window's close button, and then selecting
1423 "Power off the machine" in the dialog.)</para>
1424
1425 <para>After this, the VM's state will be "Powered off". From there,
1426 it can be started again; see <xref
1427 linkend="vboxmanage-startvm" />.</para>
1428 </listitem>
1429
1430 <listitem>
1431 <para><computeroutput>VBoxManage controlvm &lt;vm&gt;
1432 savestate</computeroutput> will save the current state of the VM to
1433 disk and then stop the VM. (This is equivalent to selecting the
1434 "Close" item in the "Machine" menu of the GUI or pressing the
1435 window's close button, and then selecting "Save the machine state"
1436 in the dialog.)</para>
1437
1438 <para>After this, the VM's state will be "Saved". From there, it can
1439 be started again; see <xref linkend="vboxmanage-startvm" />.</para>
1440 </listitem>
1441
1442 <listitem>
1443 <para><computeroutput>VBoxManage controlvm &lt;vm&gt; teleport
1444 --hostname &lt;name&gt; --port &lt;port&gt; [--passwordfile
1445 &lt;file&gt; | --password &lt;password&gt;]</computeroutput> makes
1446 the machine the source of a teleporting operation and initiates a
1447 teleport to the given target. See <xref linkend="teleporting" /> for
1448 an introduction. If the optional password is specified, it must match
1449 the password that was given to the
1450 <computeroutput>modifyvm</computeroutput> command for the target
1451 machine; see <xref linkend="vboxmanage-modifyvm-teleport" /> for
1452 details.</para>
1453 </listitem>
1454 </itemizedlist></para>
1455
1456 <para>A few extra options are available with
1457 <computeroutput>controlvm</computeroutput> that do not directly affect the
1458 VM's running state:</para>
1459
1460 <itemizedlist>
1461 <listitem>
1462 <para>The <computeroutput>setlinkstate&lt;1-N&gt;</computeroutput>
1463 operation connects or disconnects virtual network cables from their
1464 network interfaces.</para>
1465 </listitem>
1466
1467 <listitem>
1468 <para><computeroutput>nic&lt;1-N&gt;
1469 null|nat|bridged|intnet|hostonly|generic</computeroutput>: With this, you can
1470 set, for each of the VM's virtual network cards, what type of
1471 networking should be available. They can be not connected to the host
1472 (<computeroutput>null</computeroutput>), use network address
1473 translation (<computeroutput>nat</computeroutput>), bridged networking
1474 (<computeroutput>bridged</computeroutput>) or communicate with other
1475 virtual machines using internal networking
1476 (<computeroutput>intnet</computeroutput>) or host-only networking
1477 (<computeroutput>hostonly</computeroutput>) or access to rarely used
1478 sub-modes
1479 (<computeroutput>generic</computeroutput>). These options correspond
1480 to the modes which are described in detail in <xref
1481 linkend="networkingmodes" />.</para>
1482 </listitem>
1483
1484 <listitem>
1485 <para><computeroutput>usbattach</computeroutput> and
1486 <computeroutput>usbdettach</computeroutput> make host USB devices
1487 visible to the virtual machine on the fly, without the need for
1488 creating filters first. The USB devices can be specified by UUID
1489 (unique identifier) or by address on the host system.</para>
1490
1491 <para>You can use <computeroutput>VBoxManage list
1492 usbhost</computeroutput> to locate this information.</para>
1493 </listitem>
1494
1495 <listitem>
1496 <para><computeroutput>vrde on|off</computeroutput> lets you enable or
1497 disable the VRDE server, if it is installed.</para>
1498 </listitem>
1499
1500 <listitem>
1501 <para><computeroutput>vrdeport default|&lt;ports&gt;</computeroutput>
1502 changes the port or a range of ports that the VRDE server can bind to;
1503 "default" or "0" means port 3389, the standard port for RDP. For
1504 details, see the description for the
1505 <computeroutput>--vrdeport</computeroutput> option in <xref
1506 linkend="vboxmanage-modifyvm-other" />.</para>
1507 </listitem>
1508
1509 <listitem>
1510 <para><computeroutput>setvideomodehint</computeroutput> requests that
1511 the guest system change to a particular video mode. This requires that
1512 the Guest Additions be installed, and will not work for all guest
1513 systems.</para>
1514 </listitem>
1515
1516 <listitem>
1517 <para><computeroutput>screenshotpng</computeroutput> takes a screenshot
1518 of the guest display and saves it in PNG format.</para>
1519 </listitem>
1520
1521 <listitem>
1522 <para>The <computeroutput>setcredentials</computeroutput> operation is
1523 used for remote logons in Windows guests. For details, please refer to
1524 <xref linkend="autologon" />.</para>
1525 </listitem>
1526
1527 <listitem>
1528 <para>The <computeroutput>guestmemoryballoon</computeroutput>
1529 operation changes the size of the guest memory balloon, that is,
1530 memory allocated by the VirtualBox Guest Additions from the guest
1531 operating system and returned to the hypervisor for re-use by other
1532 virtual machines. This must be specified in megabytes. For details,
1533 see <xref linkend="guestadd-balloon" />.</para>
1534 </listitem>
1535
1536 <listitem>
1537 <para>The <computeroutput>cpuexecutioncap
1538 &lt;1-100&gt;</computeroutput>: This operation controls how much cpu
1539 time a virtual CPU can use. A value of 50 implies a single virtual CPU
1540 can use up to 50% of a single host CPU.</para>
1541 </listitem>
1542 </itemizedlist>
1543 </sect1>
1544
1545 <sect1>
1546 <title>VBoxManage discardstate</title>
1547
1548 <para>This command discards the saved state of a virtual machine which is
1549 not currently running, which will cause its operating system to restart
1550 next time you start it. This is the equivalent of pulling out the power
1551 cable on a physical machine, and should be avoided if possible.</para>
1552 </sect1>
1553
1554 <sect1>
1555 <title>VBoxManage adoptstate</title>
1556
1557 <para>If you have a saved state file (<computeroutput>.sav</computeroutput>)
1558 that is seperate from the VM configuration, you can use this command to
1559 "adopt" the file. This will change the VM to saved state and when you
1560 start it, VirtualBox will attempt to restore it from the saved state file
1561 you indicated. This command should only be used in special setups.</para>
1562 </sect1>
1563
1564 <sect1>
1565 <title>VBoxManage snapshot</title>
1566
1567 <para>This command is used to control snapshots from the command line. A
1568 snapshot consists of a complete copy of the virtual machine settings,
1569 copied at the time when the snapshot was taken, and optionally a virtual
1570 machine saved state file if the snapshot was taken while the machine was
1571 running. After a snapshot has been taken, VirtualBox creates differencing
1572 hard disk for each normal hard disk associated with the machine so that
1573 when a snapshot is restored, the contents of the virtual machine's virtual
1574 hard disks can be quickly reset by simply dropping the pre-existing
1575 differencing files.</para>
1576
1577 <para>The <computeroutput>take</computeroutput> operation takes a snapshot
1578 of the current state of the virtual machine. You must supply a name for
1579 the snapshot and can optionally supply a description. The new snapshot is
1580 inserted into the snapshots tree as a child of the current snapshot and
1581 then becomes the new current snapshot.</para>
1582
1583 <para>The <computeroutput>delete</computeroutput> operation deletes a
1584 snapshot (specified by name or by UUID). This can take a while to finish
1585 since the differencing images associated with the snapshot might need to
1586 be merged with their child differencing images.</para>
1587
1588 <para>The <computeroutput>restore</computeroutput> operation will restore
1589 the given snapshot (specified by name or by UUID) by resetting the virtual
1590 machine's settings and current state to that of the snapshot. The previous
1591 current state of the machine will be lost. After this, the given snapshot
1592 becomes the new "current" snapshot so that subsequent snapshots are
1593 inserted under the snapshot from which was restored.</para>
1594
1595 <para>The <computeroutput>restorecurrent</computeroutput> operation is a
1596 shortcut to restore the current snapshot (i.e. the snapshot from which the
1597 current state is derived). This subcommand is equivalent to using the
1598 "restore" subcommand with the name or UUID of the current snapshot, except
1599 that it avoids the extra step of determining that name or UUID.</para>
1600
1601 <para>With the <computeroutput>edit</computeroutput> operation, you can
1602 change the name or description of an existing snapshot.</para>
1603
1604 <para>With the <computeroutput>showvminfo</computeroutput> operation, you
1605 can view the virtual machine settings that were stored with an existing
1606 snapshot.</para>
1607 </sect1>
1608
1609 <sect1 id="vboxmanage-closemedium">
1610 <title>VBoxManage closemedium</title>
1611
1612 <para>This commands removes a hard disk, DVD or floppy image from a
1613 VirtualBox media registry.<footnote>
1614 <para>Before VirtualBox 4.0, it was necessary to call VBoxManage
1615 openmedium before a medium could be attached to a virtual machine;
1616 that call "registered" the medium with the global VirtualBox media
1617 registry. With VirtualBox 4.0 this is no longer necessary; media are
1618 added to media registries automatically. The "closemedium" call has
1619 been retained, however, to allow for explicitly removing a medium from
1620 a registry.</para>
1621 </footnote></para>
1622
1623 <para>Optionally, you can request that the image be deleted. You will get
1624 appropriate diagnostics that the deletion failed, however the image will
1625 become unregistered in any case.</para>
1626 </sect1>
1627
1628 <sect1>
1629 <title id="vboxmanage-storageattach">VBoxManage storageattach</title>
1630
1631 <para>This command attaches/modifies/removes a storage medium connected to
1632 a storage controller that was previously added with the
1633 <computeroutput>storagectl</computeroutput> command (see the previous
1634 section). The syntax is as follows:</para>
1635
1636 <screen>VBoxManage storageattach &lt;uuid|vmname&gt;
1637 --storagectl &lt;name&gt;
1638 [--port &lt;number&gt;]
1639 [--device &lt;number&gt;]
1640 [--type dvddrive|hdd|fdd]
1641 [--medium none|emptydrive|
1642 &lt;uuid&gt;|&lt;filename&gt;|host:&lt;drive&gt;|iscsi]
1643 [--mtype normal|writethrough|immutable|shareable]
1644 [--comment &lt;text&gt;]
1645 [--setuuid &lt;uuid&gt;]
1646 [--setparentuuid &lt;uuid&gt;]
1647 [--passthrough on|off]
1648 [--tempeject on|off]
1649 [--nonrotational on|off]
1650 [--discard on|off]
1651 [--bandwidthgroup name|none]
1652 [--forceunmount]
1653 [--server &lt;name&gt;|&lt;ip&gt;]
1654 [--target &lt;target&gt;]
1655 [--tport &lt;port&gt;]
1656 [--lun &lt;lun&gt;]
1657 [--encodedlun &lt;lun&gt;]
1658 [--username &lt;username&gt;]
1659 [--password &lt;password&gt;]
1660 [--initiator &lt;initiator&gt;]
1661 [--intnet]
1662</screen>
1663
1664 <para>A number of parameters are commonly required; the ones at the end of
1665 the list are required only for iSCSI targets (see below).</para>
1666
1667 <para>The common parameters are:<glosslist>
1668 <glossentry>
1669 <glossterm>uuid|vmname</glossterm>
1670
1671 <glossdef>
1672 <para>The VM UUID or VM Name. Mandatory.</para>
1673 </glossdef>
1674 </glossentry>
1675
1676 <glossentry>
1677 <glossterm>storagectl</glossterm>
1678
1679 <glossdef>
1680 <para>Name of the storage controller. Mandatory. The list of the
1681 storage controllers currently attached to a VM can be obtained
1682 with <computeroutput>VBoxManage showvminfo</computeroutput>; see
1683 <xref linkend="vboxmanage-showvminfo" />.</para>
1684 </glossdef>
1685 </glossentry>
1686
1687 <glossentry>
1688 <glossterm>port</glossterm>
1689
1690 <glossdef>
1691 <para>The number of the storage controller's port which is to be
1692 modified. Mandatory, unless the storage controller has only a
1693 single port.</para>
1694 </glossdef>
1695 </glossentry>
1696
1697 <glossentry>
1698 <glossterm>device</glossterm>
1699
1700 <glossdef>
1701 <para>The number of the port's device which is to be modified.
1702 Mandatory, unless the storage controller has only a single device
1703 per port.</para>
1704 </glossdef>
1705 </glossentry>
1706
1707 <glossentry>
1708 <glossterm>type</glossterm>
1709
1710 <glossdef>
1711 <para>Define the type of the drive to which the medium is being
1712 attached/detached/modified. This argument can only be omitted if
1713 the type of medium can be determined from either the medium given
1714 with the <computeroutput>--medium</computeroutput> argument or
1715 from a previous medium attachment.</para>
1716 </glossdef>
1717 </glossentry>
1718
1719 <glossentry>
1720 <glossterm>medium</glossterm>
1721
1722 <glossdef>
1723 <para>Specifies what is to be attached. The following values are
1724 supported:<itemizedlist>
1725 <listitem>
1726 <para>"none": Any existing device should be removed from the
1727 given slot.</para>
1728 </listitem>
1729
1730 <listitem>
1731 <para>"emptydrive": For a virtual DVD or floppy drive only,
1732 this makes the device slot behaves like a removeable drive
1733 into which no media has been inserted.</para>
1734 </listitem>
1735
1736 <listitem>
1737 <para>If a UUID is specified, it must be the UUID of a
1738 storage medium that is already known to VirtualBox (e.g.
1739 because it has been attached to another virtual machine).
1740 See <xref linkend="vboxmanage-list" /> for how to list known
1741 media. This medium is then attached to the given device
1742 slot.</para>
1743 </listitem>
1744
1745 <listitem>
1746 <para>If a filename is specified, it must be the full path
1747 of an existing disk image (ISO, RAW, VDI, VMDK or other),
1748 which is then attached to the given device slot.</para>
1749 </listitem>
1750
1751 <listitem>
1752 <para>"host:&lt;drive&gt;": For a virtual DVD or floppy
1753 drive only, this connects the given device slot to the
1754 specified DVD or floppy drive on the host computer.</para>
1755 </listitem>
1756
1757 <listitem>
1758 <para>"iscsi": For virtual hard disks only, this allows for
1759 specifying an iSCSI target. In this case, more parameters
1760 must be given; see below.</para>
1761 </listitem>
1762 </itemizedlist></para>
1763
1764 <para>Some of the above changes, in particular for removeable
1765 media (floppies and CDs/DVDs), can be effected while a VM is
1766 running. Others (device changes or changes in hard disk device
1767 slots) require the VM to be powered off.</para>
1768 </glossdef>
1769 </glossentry>
1770
1771 <glossentry>
1772 <glossterm>mtype</glossterm>
1773
1774 <glossdef>
1775 <para>Defines how this medium behaves with respect to snapshots
1776 and write operations. See <xref linkend="hdimagewrites" /> for
1777 details.</para>
1778 </glossdef>
1779 </glossentry>
1780
1781 <glossentry>
1782 <glossterm>comment</glossterm>
1783
1784 <glossdef>
1785 <para>Any description that you want to have stored with this
1786 medium (optional; for example, for an iSCSI target, "Big storage
1787 server downstairs"). This is purely descriptive and not needed for
1788 the medium to function correctly.</para>
1789 </glossdef>
1790 </glossentry>
1791
1792 <glossentry>
1793 <glossterm>setuuid, setparentuuid</glossterm>
1794
1795 <glossdef>
1796 <para>Modifies the UUID or parent UUID of a medium before
1797 attaching it to a VM. This is an expert option. Inappropriate use
1798 can make the medium unusable or lead to broken VM configurations
1799 if any other VM is referring to the same media already. The most
1800 frequently used variant is <code>--setuuid ""</code>, which assigns
1801 a new (random) UUID to an image. This is useful to resolve the
1802 duplicate UUID errors if one duplicated an image using file copy
1803 utilities.</para>
1804 </glossdef>
1805 </glossentry>
1806
1807 <glossentry>
1808 <glossterm>passthrough</glossterm>
1809
1810 <glossdef>
1811 <para>For a virtual DVD drive only, you can enable DVD writing
1812 support (currently experimental; see <xref
1813 linkend="storage-cds" />).</para>
1814 </glossdef>
1815 </glossentry>
1816
1817 <glossentry>
1818 <glossterm>tempeject</glossterm>
1819
1820 <glossdef>
1821 <para>For a virtual DVD drive only, you can configure the behavior
1822 for guest-triggered medium eject. If this is set to "on", the eject
1823 has only temporary effects. If the VM is powered off and restarted
1824 the originally configured medium will be still in the drive.</para>
1825 </glossdef>
1826 </glossentry>
1827
1828 <glossentry>
1829 <glossterm>nonrotational</glossterm>
1830
1831 <glossdef>
1832 <para>This switch allows to enable the non-rotational flag for virtual
1833 hard disks. Some guests (i.e. Windows 7+) treat such disks like SSDs
1834 and don't perform disk fragmentation on such media.
1835 </para>
1836 </glossdef>
1837 </glossentry>
1838
1839 <glossentry>
1840 <glossterm>bandwidthgroup</glossterm>
1841
1842 <glossdef>
1843 <para>Sets the bandwidth group to use for the given device; see
1844 <xref linkend="storage-bandwidth-limit" />.</para>
1845 </glossdef>
1846 </glossentry>
1847
1848 <glossentry>
1849 <glossterm>forceunmount</glossterm>
1850
1851 <glossdef>
1852 <para>For a virtual DVD or floppy drive only, this forcibly
1853 unmounts the DVD/CD/Floppy or mounts a new DVD/CD/Floppy even if
1854 the previous one is locked down by the guest for reading. Again,
1855 see <xref linkend="storage-cds" /> for details.</para>
1856 </glossdef>
1857 </glossentry>
1858 </glosslist></para>
1859
1860 <para>When "iscsi" is used with the
1861 <computeroutput>--medium</computeroutput> parameter for iSCSI support --
1862 see <xref linkend="storage-iscsi" /> --, additional parameters must or can
1863 be used:<glosslist>
1864 <glossentry>
1865 <glossterm>server</glossterm>
1866
1867 <glossdef>
1868 <para>The host name or IP address of the iSCSI target;
1869 required.</para>
1870 </glossdef>
1871 </glossentry>
1872
1873 <glossentry>
1874 <glossterm>target</glossterm>
1875
1876 <glossdef>
1877 <para>Target name string. This is determined by the iSCSI target
1878 and used to identify the storage resource; required.</para>
1879 </glossdef>
1880 </glossentry>
1881
1882 <glossentry>
1883 <glossterm>tport</glossterm>
1884
1885 <glossdef>
1886 <para>TCP/IP port number of the iSCSI service on the target
1887 (optional).</para>
1888 </glossdef>
1889 </glossentry>
1890
1891 <glossentry>
1892 <glossterm>lun</glossterm>
1893
1894 <glossdef>
1895 <para>Logical Unit Number of the target resource (optional).
1896 Often, this value is zero.</para>
1897 </glossdef>
1898 </glossentry>
1899
1900 <glossentry>
1901 <glossterm>username, password</glossterm>
1902
1903 <glossdef>
1904 <para>Username and password (initiator secret) for target
1905 authentication, if required (optional).<note>
1906 <para>Username and password are stored without
1907 encryption (i.e. in clear text) in the XML machine
1908 configuration file if no settings password is provided.
1909 When a settings password was specified the first time,
1910 the password is stored encrypted.</para>
1911 </note></para>
1912 </glossdef>
1913 </glossentry>
1914
1915 <glossentry>
1916 <glossterm>intnet</glossterm>
1917
1918 <glossdef>
1919 <para>If specified, connect to the iSCSI target via Internal
1920 Networking. This needs further configuration which is described in
1921 <xref linkend="iscsi-intnet" />.</para>
1922 </glossdef>
1923 </glossentry>
1924 </glosslist></para>
1925 </sect1>
1926
1927 <sect1 id="vboxmanage-storagectl">
1928 <title>VBoxManage storagectl</title>
1929
1930 <para>This command attaches/modifies/removes a storage controller. After
1931 this, virtual media can be attached to the controller with the
1932 <computeroutput>storageattach</computeroutput> command (see the next
1933 section).</para>
1934
1935 <para>The syntax is as follows:</para>
1936
1937 <screen>VBoxManage storagectl &lt;uuid|vmname&gt;
1938 --name &lt;name&gt;
1939 [--add &lt;ide/sata/scsi/floppy&gt;]
1940 [--controller &lt;LsiLogic|LSILogicSAS|BusLogic|
1941 IntelAhci|PIIX3|PIIX4|ICH6|I82078&gt;]
1942 [--sataportcount &lt;1-30&gt;]
1943 [--hostiocache on|off]
1944 [--bootable on|off]
1945 [--remove]</screen>
1946
1947 <para>where the parameters mean: <glosslist>
1948 <glossentry>
1949 <glossterm>uuid|vmname</glossterm>
1950
1951 <glossdef>
1952 <para>The VM UUID or VM Name. Mandatory.</para>
1953 </glossdef>
1954 </glossentry>
1955
1956 <glossentry>
1957 <glossterm>name</glossterm>
1958
1959 <glossdef>
1960 <para>Name of the storage controller. Mandatory.</para>
1961 </glossdef>
1962 </glossentry>
1963
1964 <glossentry>
1965 <glossterm>add</glossterm>
1966
1967 <glossdef>
1968 <para>Define the type of the system bus to which the storage
1969 controller must be connected.</para>
1970 </glossdef>
1971 </glossentry>
1972
1973 <glossentry>
1974 <glossterm>controller</glossterm>
1975
1976 <glossdef>
1977 <para>Allows to choose the type of chipset being emulated for the
1978 given storage controller.</para>
1979 </glossdef>
1980 </glossentry>
1981
1982 <glossentry>
1983 <glossterm>sataportcount</glossterm>
1984
1985 <glossdef>
1986 <para>This determines how many ports the SATA controller should
1987 support.</para>
1988 </glossdef>
1989 </glossentry>
1990
1991 <glossentry>
1992 <glossterm>hostiocache</glossterm>
1993
1994 <glossdef>
1995 <para>Configures the use of the host I/O cache for all disk images
1996 attached to this storage controller. For details, please see <xref
1997 linkend="iocaching" />.</para>
1998 </glossdef>
1999 </glossentry>
2000
2001 <glossentry>
2002 <glossterm>bootable</glossterm>
2003
2004 <glossdef>
2005 <para>Selects whether this controller is bootable.</para>
2006 </glossdef>
2007 </glossentry>
2008
2009 <glossentry>
2010 <glossterm>remove</glossterm>
2011
2012 <glossdef>
2013 <para>Removes the storage controller from the VM config.</para>
2014 </glossdef>
2015 </glossentry>
2016 </glosslist></para>
2017 </sect1>
2018
2019 <sect1>
2020 <title>VBoxManage bandwidthctl</title>
2021
2022 <para>This command creates/deletes/modifies/shows bandwidth groups of the given
2023 virtual machine:<screen>VBoxManage bandwidthctl &lt;uuid|vmname&gt;
2024 add &lt;name&gt; --type disk|network --limit &lt;megabytes per second&gt;[k|m|g|K|M|G] |
2025 set &lt;name&gt; --limit &lt;megabytes per second&gt;[k|m|g|K|M|G] |
2026 remove &lt;name&gt; |
2027 list [--machinereadable]</screen></para>
2028
2029 <para>The following subcommands are available:<itemizedlist>
2030 <listitem>
2031 <para><computeroutput>add</computeroutput>, creates a new bandwidth
2032 group of given type.</para>
2033 </listitem>
2034 <listitem>
2035 <para><computeroutput>set</computeroutput>, modifies the limit for an
2036 existing bandwidth group.</para>
2037 </listitem>
2038 <listitem>
2039 <para><computeroutput>remove</computeroutput>, destroys a bandwidth
2040 group.</para>
2041 </listitem>
2042 <listitem>
2043 <para><computeroutput>list</computeroutput>, shows all bandwidth groups
2044 defined for the given VM.</para>
2045 </listitem>
2046 </itemizedlist>
2047 </para>
2048 <para>The parameters mean:<glosslist>
2049 <glossentry>
2050 <glossterm>uuid|vmname</glossterm>
2051
2052 <glossdef>
2053 <para>The VM UUID or VM Name. Mandatory.</para>
2054 </glossdef>
2055 </glossentry>
2056
2057 <glossentry>
2058 <glossterm>name</glossterm>
2059
2060 <glossdef>
2061 <para>Name of the bandwidth group. Mandatory.</para>
2062 </glossdef>
2063 </glossentry>
2064
2065 <glossentry>
2066 <glossterm>type</glossterm>
2067
2068 <glossdef>
2069 <para>Type of the bandwidth group. Mandatory. Two types are
2070 supported: <computeroutput>disk</computeroutput> and
2071 <computeroutput>network</computeroutput>. See
2072 <xref linkend="storage-bandwidth-limit" /> or
2073 <xref linkend="network_bandwidth_limit" /> for a description of a
2074 particular type.</para>
2075 </glossdef>
2076 </glossentry>
2077
2078 <glossentry>
2079 <glossterm>limit</glossterm>
2080
2081 <glossdef>
2082 <para>Specifies the limit for the given group. Can be changed
2083 while the VM is running. The default unit is megabytes per
2084 second. The unit can be changed by specifying one of the
2085 following suffixes: <computeroutput>k</computeroutput> for kilobits/s, <computeroutput>m</computeroutput> for megabits/s, <computeroutput>g</computeroutput> for gigabits/s, <computeroutput>K</computeroutput> for kilobytes/s, <computeroutput>M</computeroutput> for megabytes/s, <computeroutput>G</computeroutput> for gigabytes/s.</para>
2086 </glossdef>
2087 </glossentry>
2088 </glosslist>
2089 <note>
2090 <para>The network bandwidth limits apply only to the traffic being sent by
2091 virtual machines. The traffic being received by VMs is unlimited.</para>
2092 </note>
2093 <note>
2094 <para>To remove a bandwidth group it must not be referenced by any disks
2095 or adapters in running VM.</para>
2096 </note>
2097 </para>
2098 </sect1>
2099
2100 <sect1>
2101 <title>VBoxManage showhdinfo</title>
2102
2103 <para>This command shows information about a virtual hard disk image,
2104 notably its size, its size on disk, its type and the virtual machines
2105 which use it.<note>
2106 <para>For compatibility with earlier versions of VirtualBox, the
2107 "showvdiinfo" command is also supported and mapped internally to the
2108 "showhdinfo" command.</para>
2109 </note></para>
2110 <para>The disk image must be specified either by its UUID (if the medium
2111 is registered) or by its filename. Registered images can be listed by
2112 <computeroutput>VBoxManage list hdds</computeroutput> (see <xref linkend="vboxmanage-list" />
2113 for more information). A filename must be specified as valid path, either
2114 as an absolute path or as a relative path starting from the current
2115 directory.</para>
2116 </sect1>
2117
2118 <sect1 id="vboxmanage-createvdi">
2119 <title>VBoxManage createhd</title>
2120
2121 <para>This command creates a new virtual hard disk image. The syntax is as
2122 follows:</para>
2123
2124 <screen>VBoxManage createhd --filename &lt;filename&gt;
2125 --size &lt;megabytes&gt;
2126 [--format VDI|VMDK|VHD] (default: VDI)
2127 [--variant Standard,Fixed,Split2G,Stream,ESX]</screen>
2128
2129 <para>where the parameters mean:<glosslist>
2130 <glossentry>
2131 <glossterm>filename</glossterm>
2132
2133 <glossdef>
2134 <para>Allows to choose a file name. Mandatory.</para>
2135 </glossdef>
2136 </glossentry>
2137
2138 <glossentry>
2139 <glossterm>size</glossterm>
2140
2141 <glossdef>
2142 <para>Allows to define the image capacity, in 1 MiB units.
2143 Mandatory.</para>
2144 </glossdef>
2145 </glossentry>
2146
2147 <glossentry>
2148 <glossterm>format</glossterm>
2149
2150 <glossdef>
2151 <para>Allows to choose a file format for the output file different
2152 from the file format of the input file.</para>
2153 </glossdef>
2154 </glossentry>
2155
2156 <glossentry>
2157 <glossterm>variant</glossterm>
2158
2159 <glossdef>
2160 <para>Allows to choose a file format variant for the output file.
2161 It is a comma-separated list of variant flags. Not all
2162 combinations are supported, and specifying inconsistent flags will
2163 result in an error message.</para>
2164 </glossdef>
2165 </glossentry>
2166 </glosslist> <note>
2167 <para>For compatibility with earlier versions of VirtualBox, the
2168 "createvdi" command is also supported and mapped internally to the
2169 "createhd" command.</para>
2170 </note></para>
2171 </sect1>
2172
2173 <sect1 id="vboxmanage-modifyvdi">
2174 <title>VBoxManage modifyhd</title>
2175
2176 <para>With the <computeroutput>modifyhd</computeroutput> command, you can
2177 change the characteristics of a disk image after it has been
2178 created:<screen>VBoxManage modifyhd &lt;uuid&gt;|&lt;filename&gt;
2179 [--type normal|writethrough|immutable|shareable|
2180 readonly|multiattach]
2181 [--autoreset on|off]
2182 [--compact]
2183 [--resize &lt;megabytes&gt;|--resizebyte &lt;bytes&gt;]</screen><note>
2184 <para>Despite the "hd" in the subcommand name, the command works with
2185 all disk images, not only hard disks. For compatibility with earlier
2186 versions of VirtualBox, the "modifyvdi" command is also supported and
2187 mapped internally to the "modifyhd" command.</para>
2188 </note></para>
2189
2190 <para>The disk image to modify must be specified either by its UUID
2191 (if the medium is registered) or by its filename. Registered images
2192 can be listed by <computeroutput>VBoxManage list hdds</computeroutput>
2193 (see <xref linkend="vboxmanage-list" /> for more information).
2194 A filename must be specified as valid path, either as an absolute path
2195 or as a relative path starting from the current directory.</para>
2196 <para>The following options are available:<itemizedlist>
2197 <listitem>
2198 <para>With the <computeroutput>--type</computeroutput> argument, you
2199 can change the type of an existing image between the normal,
2200 immutable, write-through and other modes; see <xref
2201 linkend="hdimagewrites" /> for details.</para>
2202 </listitem>
2203
2204 <listitem>
2205 <para>For immutable (differencing) hard disks only, the
2206 <computeroutput>--autoreset on|off</computeroutput> option
2207 determines whether the disk is automatically reset on every VM
2208 startup (again, see <xref linkend="hdimagewrites" />). The default
2209 is "on".</para>
2210 </listitem>
2211
2212 <listitem>
2213 <para>With the <computeroutput>--compact</computeroutput> option,
2214 can be used to compact disk images, i.e. remove blocks that only
2215 contains zeroes. This will shrink a dynamically allocated image
2216 again; it will reduce the <emphasis>physical</emphasis> size of the
2217 image without affecting the logical size of the virtual disk.
2218 Compaction works both for base images and for diff images created as
2219 part of a snapshot.</para>
2220
2221 <para>For this operation to be effective, it is required that free
2222 space in the guest system first be zeroed out using a suitable
2223 software tool. For Windows guests, you can use the
2224 <computeroutput>sdelete</computeroutput> tool provided by Microsoft.
2225 Execute <computeroutput>sdelete -z</computeroutput> in the guest to
2226 zero the free disk space before compressing the virtual disk
2227 image. For Linux, use the <code>zerofree</code> utility which
2228 supports ext2/ext3 filesystems.</para>
2229
2230 <para>Please note that compacting is currently only available for
2231 VDI images. A similar effect can be achieved by zeroing out free
2232 blocks and then cloning the disk to any other dynamically allocated
2233 format. You can use this workaround until compacting is also
2234 supported for disk formats other than VDI.</para>
2235 </listitem>
2236
2237 <listitem>
2238 <para>The <computeroutput>--resize x</computeroutput> option (where x
2239 is the desired new total space in <emphasis role="bold">megabytes</emphasis>)
2240 allows you to change the capacity of an existing image; this adjusts the
2241 <emphasis>logical</emphasis> size of a virtual disk without affecting
2242 the physical size much.<footnote>
2243 <para>Image resizing was added with VirtualBox 4.0.</para>
2244 </footnote> This currently works only for VDI and VHD formats, and only
2245 for the dynamically allocated variants, and can only be used to expand
2246 (not shrink) the capacity.
2247 For example, if you originally created a 10G disk which is now full,
2248 you can use the <computeroutput>--resize 15360</computeroutput>
2249 command to change the capacity to 15G (15,360MB) without having to create a new
2250 image and copy all data from within a virtual machine. Note however that
2251 this only changes the drive capacity; you will typically next need to use
2252 a partition management tool inside the guest to adjust the main partition
2253 to fill the drive.</para><para>The <computeroutput>--resizebyte x</computeroutput>
2254 option does almost the same thing, except that x is expressed in bytes
2255 instead of megabytes.</para>
2256 </listitem>
2257 </itemizedlist></para>
2258 </sect1>
2259
2260 <sect1 id="vboxmanage-clonevdi">
2261 <title>VBoxManage clonehd</title>
2262
2263 <para>This command duplicates a registered virtual hard disk image to a
2264 new image file with a new unique identifier (UUID). The new image can be
2265 transferred to another host system or imported into VirtualBox again using
2266 the Virtual Media Manager; see <xref linkend="vdis" /> and <xref
2267 linkend="cloningvdis" />. The syntax is as follows:</para>
2268
2269 <screen>VBoxManage clonehd &lt;uuid&gt;|&lt;filename&gt; &lt;outputfile&gt;
2270 [--format VDI|VMDK|VHD|RAW|&lt;other&gt;]
2271 [--variant Standard,Fixed,Split2G,Stream,ESX]
2272 [--existing]</screen>
2273
2274 <para>The disk image to clone as well as the target image must be described
2275 either by its UUIDs (if the mediums are registered) or by its filename.
2276 Registered images can be listed by <computeroutput>VBoxManage list hdds</computeroutput>
2277 (see <xref linkend="vboxmanage-list" /> for more information).
2278 A filename must be specified as valid path, either as an absolute path or
2279 as a relative path starting from the current directory.</para>
2280 <para>The following options are available:<glosslist>
2281 <glossentry>
2282 <glossterm>format</glossterm>
2283
2284 <glossdef>
2285 <para>Allow to choose a file format for the output file different
2286 from the file format of the input file.</para>
2287 </glossdef>
2288 </glossentry>
2289
2290 <glossentry>
2291 <glossterm>variant</glossterm>
2292
2293 <glossdef>
2294 <para>Allow to choose a file format variant for the output file.
2295 It is a comma-separated list of variant flags. Not all
2296 combinations are supported, and specifying inconsistent flags will
2297 result in an error message.</para>
2298 </glossdef>
2299 </glossentry>
2300
2301 <glossentry>
2302 <glossterm>existing</glossterm>
2303
2304 <glossdef>
2305 <para>Perform the clone operation to an already existing
2306 destination medium. Only the portion of the source medium which
2307 fits into the destination medium is copied. This means if the
2308 destination medium is smaller than the source only a part of it is
2309 copied, and if the destination medium is larger than the source
2310 the remaining part of the destination medium is unchanged.</para>
2311 </glossdef>
2312 </glossentry>
2313 </glosslist> <note>
2314 <para>For compatibility with earlier versions of VirtualBox, the
2315 "clonevdi" command is also supported and mapped internally to the
2316 "clonehd" command.</para>
2317 </note></para>
2318 </sect1>
2319
2320 <sect1>
2321 <title>VBoxManage convertfromraw</title>
2322
2323 <para>This command converts a raw disk image to a VirtualBox Disk Image
2324 (VDI) file. The syntax is as follows:</para>
2325
2326 <screen>VBoxManage convertfromraw &lt;filename&gt; &lt;outputfile&gt;
2327 [--format VDI|VMDK|VHD]
2328 [--variant Standard,Fixed,Split2G,Stream,ESX]
2329 [--uuid &lt;uuid&gt;]
2330VBoxManage convertfromraw stdin &lt;outputfile&gt; &lt;bytes&gt;
2331 [--format VDI|VMDK|VHD]
2332 [--variant Standard,Fixed,Split2G,Stream,ESX]
2333 [--uuid &lt;uuid&gt;]</screen>
2334
2335 <para>where the parameters mean:<glosslist>
2336 <glossentry>
2337 <glossterm>bytes</glossterm>
2338
2339 <glossdef>
2340 <para>The size of the image file, in bytes, provided through
2341 stdin.</para>
2342 </glossdef>
2343 </glossentry>
2344
2345 <glossentry>
2346 <glossterm>format</glossterm>
2347
2348 <glossdef>
2349 <para>Select the disk image format to create. Default is
2350 VDI.</para>
2351 </glossdef>
2352 </glossentry>
2353
2354 <glossentry>
2355 <glossterm>variant</glossterm>
2356
2357 <glossdef>
2358 <para>Allow to choose a file format variant for the output file.
2359 It is a comma-separated list of variant flags. Not all
2360 combinations are supported, and specifying inconsistent flags will
2361 result in an error message.</para>
2362 </glossdef>
2363 </glossentry>
2364
2365 <glossentry>
2366 <glossterm>uuid</glossterm>
2367
2368 <glossdef>
2369 <para>Allow to specifiy the UUID of the output file.</para>
2370 </glossdef>
2371 </glossentry>
2372 </glosslist> The second form forces VBoxManage to read the content for
2373 the disk image from standard input (useful for using that command in a
2374 pipe).</para>
2375
2376 <para><note>
2377 <para>For compatibility with earlier versions of VirtualBox, the
2378 "convertdd" command is also supported and mapped internally to the
2379 "convertfromraw" command.</para>
2380 </note></para>
2381 </sect1>
2382
2383 <sect1>
2384 <title>VBoxManage getextradata/setextradata</title>
2385
2386 <para>These commands let you attach and retrieve string data to a virtual
2387 machine or to a VirtualBox configuration (by specifying
2388 <computeroutput>global</computeroutput> instead of a virtual machine
2389 name). You must specify a key (as a text string) to associate the data
2390 with, which you can later use to retrieve it. For example:</para>
2391
2392 <screen>VBoxManage setextradata Fedora5 installdate 2006.01.01
2393VBoxManage setextradata SUSE10 installdate 2006.02.02</screen>
2394
2395 <para>would associate the string "2006.01.01" with the key installdate for
2396 the virtual machine Fedora5, and "2006.02.02" on the machine SUSE10. You
2397 could retrieve the information as follows:</para>
2398
2399 <screen>VBoxManage getextradata Fedora5 installdate</screen>
2400
2401 <para>which would return</para>
2402
2403 <screen>VirtualBox Command Line Management Interface Version $VBOX_VERSION_MAJOR.$VBOX_VERSION_MINOR.$VBOX_VERSION_BUILD
2404(C) 2005-$VBOX_C_YEAR $VBOX_VENDOR
2405All rights reserved.
2406
2407Value: 2006.01.01</screen>
2408 <para>To remove a key, the <computeroutput>setextradata</computeroutput>
2409 command must be run without specifying data (only the key), for example:
2410 </para>
2411
2412 <screen>VBoxManage setextradata Fedora5 installdate</screen>
2413
2414 </sect1>
2415
2416 <sect1 id="vboxmanage-setproperty">
2417 <title>VBoxManage setproperty</title>
2418
2419 <para>This command is used to change global settings which affect the
2420 entire VirtualBox installation. Some of these correspond to the settings
2421 in the "Global settings" dialog in the graphical user interface. The
2422 following properties are available:<glosslist>
2423 <glossentry>
2424 <glossterm>machinefolder</glossterm>
2425
2426 <glossdef>
2427 <para>This specifies the default folder in which virtual machine
2428 definitions are kept; see <xref linkend="vboxconfigdata" /> for
2429 details.</para>
2430 </glossdef>
2431 </glossentry>
2432
2433 <glossentry>
2434 <glossterm>vrdeauthlibrary</glossterm>
2435
2436 <glossdef>
2437 <para>This specifies which library to use when "external"
2438 authentication has been selected for a particular virtual machine;
2439 see <xref linkend="vbox-auth" /> for details.</para>
2440 </glossdef>
2441 </glossentry>
2442
2443 <glossentry>
2444 <glossterm>websrvauthlibrary</glossterm>
2445
2446 <glossdef>
2447 <para>This specifies which library the web service uses to
2448 authenticate users. For details about the VirtualBox web service,
2449 please refer to the separate VirtualBox SDK reference (see <xref
2450 linkend="VirtualBoxAPI" />).</para>
2451 </glossdef>
2452 </glossentry>
2453
2454 <glossentry>
2455 <glossterm>vrdelibrary</glossterm>
2456
2457 <glossdef>
2458 <para>This specifies which library implements the VirtualBox
2459 Remote Desktop Extension.</para>
2460 </glossdef>
2461 </glossentry>
2462
2463 <glossentry>
2464 <glossterm>hwvirtexenabled</glossterm>
2465
2466 <glossdef>
2467 <para>This selects whether or not hardware virtualization support
2468 is enabled by default.</para>
2469 </glossdef>
2470 </glossentry>
2471 </glosslist></para>
2472 </sect1>
2473
2474 <sect1>
2475 <title>VBoxManage usbfilter add/modify/remove</title>
2476
2477 <para>The <computeroutput>usbfilter</computeroutput> commands are used for
2478 working with USB filters in virtual machines, or global filters which
2479 affect the whole VirtualBox setup. Global filters are applied before
2480 machine-specific filters, and may be used to prevent devices from being
2481 captured by any virtual machine. Global filters are always applied in a
2482 particular order, and only the first filter which fits a device is
2483 applied. So for example, if the first global filter says to hold (make
2484 available) a particular Kingston memory stick device and the second to
2485 ignore all Kingston devices, that memory stick will be available to any
2486 machine with an appropriate filter, but no other Kingston device
2487 will.</para>
2488
2489 <para>When creating a USB filter using <computeroutput>usbfilter
2490 add</computeroutput>, you must supply three or four mandatory parameters.
2491 The index specifies the position in the list at which the filter should be
2492 placed. If there is already a filter at that position, then it and the
2493 following ones will be shifted back one place. Otherwise the new filter
2494 will be added onto the end of the list. The
2495 <computeroutput>target</computeroutput> parameter selects the virtual
2496 machine that the filter should be attached to or use "global" to apply it
2497 to all virtual machines. <computeroutput>name</computeroutput> is a name
2498 for the new filter and for global filters,
2499 <computeroutput>action</computeroutput> says whether to allow machines
2500 access to devices that fit the filter description ("hold") or not to give
2501 them access ("ignore"). In addition, you should specify parameters to
2502 filter by. You can find the parameters for devices attached to your system
2503 using <computeroutput>VBoxManage list usbhost</computeroutput>. Finally,
2504 you can specify whether the filter should be active, and for local
2505 filters, whether they are for local devices, remote (over an RDP
2506 connection) or either.</para>
2507
2508 <para>When you modify a USB filter using <computeroutput>usbfilter
2509 modify</computeroutput>, you must specify the filter by index (see the
2510 output of <computeroutput>VBoxManage list usbfilters</computeroutput> to
2511 find global filter indexes and that of <computeroutput>VBoxManage
2512 showvminfo</computeroutput> to find indexes for individual machines) and
2513 by target, which is either a virtual machine or "global". The properties
2514 which can be changed are the same as for <computeroutput>usbfilter
2515 add</computeroutput>. To remove a filter, use <computeroutput>usbfilter
2516 remove</computeroutput> and specify the index and the target.</para>
2517 </sect1>
2518
2519 <sect1 id="vboxmanage-sharedfolder">
2520 <title>VBoxManage sharedfolder add/remove</title>
2521
2522 <para>This command allows you to share folders on the host computer with
2523 guest operating systems. For this, the guest systems must have a version
2524 of the VirtualBox Guest Additions installed which supports this
2525 functionality.</para>
2526
2527 <para>Shared folders are described in detail in <xref
2528 linkend="sharedfolders" />.</para>
2529 </sect1>
2530
2531 <sect1 id="vboxmanage-guestproperty">
2532 <title>VBoxManage guestproperty</title>
2533
2534 <para>The "guestproperty" commands allow you to get or set properties of a
2535 running virtual machine. Please see <xref linkend="guestadd-guestprops" />
2536 for an introduction. As explained there, guest properties are arbitrary
2537 key/value string pairs which can be written to and read from by either the
2538 guest or the host, so they can be used as a low-volume communication
2539 channel for strings, provided that a guest is running and has the Guest
2540 Additions installed. In addition, a number of values whose keys begin with
2541 "/VirtualBox/" are automatically set and maintained by the Guest
2542 Additions.</para>
2543
2544 <para>The following subcommands are available (where
2545 <computeroutput>&lt;vm&gt;</computeroutput>, in each case, can either be a
2546 VM name or a VM UUID, as with the other VBoxManage commands):<itemizedlist>
2547 <listitem>
2548 <para><computeroutput>enumerate &lt;vm&gt; [--patterns
2549 &lt;pattern&gt;]</computeroutput>: This lists all the guest
2550 properties that are available for the given VM, including the value.
2551 This list will be very limited if the guest's service process cannot
2552 be contacted, e.g. because the VM is not running or the Guest
2553 Additions are not installed.</para>
2554
2555 <para>If <computeroutput>--patterns &lt;pattern&gt;</computeroutput>
2556 is specified, it acts as a filter to only list properties that match
2557 the given pattern. The pattern can contain the following wildcard
2558 characters:<itemizedlist>
2559 <listitem>
2560 <para><computeroutput>*</computeroutput> (asterisk):
2561 represents any number of characters; for example,
2562 "<computeroutput>/VirtualBox*</computeroutput>" would match
2563 all properties beginning with "/VirtualBox".</para>
2564 </listitem>
2565
2566 <listitem>
2567 <para><computeroutput>?</computeroutput> (question mark):
2568 represents a single arbitrary character; for example,
2569 "<computeroutput>fo?</computeroutput>" would match both "foo"
2570 and "for".</para>
2571 </listitem>
2572
2573 <listitem>
2574 <para><computeroutput>|</computeroutput> (pipe symbol): can be
2575 used to specify multiple alternative patterns; for example,
2576 "<computeroutput>s*|t*</computeroutput>" would match anything
2577 starting with either "s" or "t".</para>
2578 </listitem>
2579 </itemizedlist></para>
2580 </listitem>
2581
2582 <listitem>
2583 <para><computeroutput>get &lt;vm&gt;</computeroutput>: This
2584 retrieves the value of a single property only. If the property
2585 cannot be found (e.g. because the guest is not running), this will
2586 print <screen>No value set!</screen></para>
2587 </listitem>
2588
2589 <listitem>
2590 <para><computeroutput>set &lt;vm&gt; &lt;property&gt; [&lt;value&gt;
2591 [--flags &lt;flags&gt;]]</computeroutput>: This allows you to set a
2592 guest property by specifying the key and value. If
2593 <computeroutput>&lt;value&gt;</computeroutput> is omitted, the
2594 property is deleted. With <computeroutput>--flags</computeroutput>
2595 you can optionally specify additional behavior (you can combine
2596 several by separating them with commas):<itemizedlist>
2597 <listitem>
2598 <para><computeroutput>TRANSIENT</computeroutput>: the value
2599 will not be stored with the VM data when the VM exits;</para>
2600 </listitem>
2601
2602 <listitem>
2603 <para><computeroutput>TRANSRESET</computeroutput>: the value
2604 will be deleted as soon as the VM restarts and/or exits;</para>
2605 </listitem>
2606
2607 <listitem>
2608 <para><computeroutput>RDONLYGUEST</computeroutput>: the value
2609 can only be changed by the host, but the guest can only read
2610 it;</para>
2611 </listitem>
2612
2613 <listitem>
2614 <para><computeroutput>RDONLYHOST</computeroutput>: reversely,
2615 the value can only be changed by the guest, but the host can
2616 only read it;</para>
2617 </listitem>
2618
2619 <listitem>
2620 <para><computeroutput>READONLY</computeroutput>: a combination
2621 of the two, the value cannot be changed at all.</para>
2622 </listitem>
2623 </itemizedlist></para>
2624 </listitem>
2625
2626 <listitem>
2627 <para><computeroutput>wait &lt;vm&gt; &lt;pattern&gt; --timeout
2628 &lt;timeout&gt;</computeroutput>: This waits for a particular value
2629 described by "pattern" to change or to be deleted or created. The
2630 pattern rules are the same as for the "enumerate" subcommand
2631 above.</para>
2632 </listitem>
2633 </itemizedlist></para>
2634 </sect1>
2635
2636 <sect1 id="vboxmanage-guestcontrol">
2637 <title>VBoxManage guestcontrol</title>
2638
2639 <para>The "guestcontrol" commands allow you to control certain things
2640 inside a guest from the host. Please see <xref
2641 linkend="guestadd-guestcontrol" /> for an introduction.</para>
2642
2643 <para>Generally, the syntax is as follows:</para>
2644
2645 <screen>VBoxManage guestcontrol &lt;command&gt;</screen>
2646
2647 <para>The following subcommands are available (where
2648 <computeroutput>&lt;vm&gt;</computeroutput>, in each case, can either be a
2649 VM name or a VM UUID, as with the other VBoxManage commands):<itemizedlist>
2650 <listitem>
2651 <para><computeroutput>execute</computeroutput>, which allows for
2652 executing a program/script (process) which already is installed and
2653 runnable on the guest. This command only works while a VM is up and
2654 running and has the following syntax:</para>
2655
2656 <screen>VBoxManage guestcontrol &lt;vmname&gt;|&lt;uuid&gt; exec[ute]
2657 --image &lt;path to program&gt; --username &lt;name&gt;
2658 [--passwordfile &lt;file&gt; | --password &lt;password&gt;]
2659 [--environment "&lt;NAME&gt;=&lt;VALUE&gt; [&lt;NAME&gt;=&lt;VALUE&gt;]"]
2660 [--verbose] [--timeout &lt;msec&gt;]
2661 [--wait-exit] [--wait-stdout] [--wait-stderr]
2662 [--dos2unix] [--unix2dos]
2663 -- [[&lt;argument1&gt;] ... [&lt;argumentN&gt;]]</screen>
2664
2665 <para>where the parameters mean: <glosslist>
2666 <glossentry>
2667 <glossterm>uuid|vmname</glossterm>
2668
2669 <glossdef>
2670 <para>The VM UUID or VM name. Mandatory.</para>
2671 </glossdef>
2672 </glossentry>
2673
2674 <glossentry>
2675 <glossterm>--image "&lt;path to program&gt;"</glossterm>
2676
2677 <glossdef>
2678 <para>Absolute path and process name of process to execute
2679 in the guest, e.g.
2680 <computeroutput>C:\Windows\System32\calc.exe</computeroutput></para>
2681 </glossdef>
2682 </glossentry>
2683
2684 <glossentry>
2685 <glossterm>--username &lt;name&gt;</glossterm>
2686
2687 <glossdef>
2688 <para>Name of the user the process should run under. This
2689 user must exist on the guest OS.</para>
2690 </glossdef>
2691 </glossentry>
2692
2693 <glossentry>
2694 <glossterm>--passwordfile &lt;file&gt;</glossterm>
2695
2696 <glossdef>
2697 <para>Password of the user account specified to be read from
2698 the given file. If not given, an empty password is
2699 assumed.</para>
2700 </glossdef>
2701 </glossentry>
2702
2703 <glossentry>
2704 <glossterm>--password &lt;password&gt;</glossterm>
2705
2706 <glossdef>
2707 <para>Password of the user account specified with
2708 <computeroutput>--username</computeroutput>. If not given,
2709 an empty password is assumed.</para>
2710 </glossdef>
2711 </glossentry>
2712
2713 <glossentry>
2714 <glossterm>--dos2unix</glossterm>
2715
2716 <glossdef>
2717 Converts output from DOS/Windows guests to UNIX-compatible
2718 line endings (CR + LF -> LF). Not implemented yet.
2719 </glossdef>
2720 </glossentry>
2721
2722 <glossentry>
2723 <glossterm>--environment
2724 "&lt;NAME&gt;=&lt;VALUE&gt;"</glossterm>
2725
2726 <glossdef>
2727 <para>One or more environment variables to be set or
2728 unset.</para>
2729
2730 <para>By default, the new process in the guest will be
2731 created with the standard environment of the guest OS. This
2732 option allows for modifying that environment. To set/modify
2733 a variable, a pair of
2734 <computeroutput>NAME=VALUE</computeroutput> must be
2735 specified; to unset a certain variable, the name with no
2736 value must set, e.g.
2737 <computeroutput>NAME=</computeroutput>.</para>
2738
2739 <para>Arguments containing spaces must be enclosed in
2740 quotation marks. More than one
2741 <computeroutput>--environment</computeroutput> at a time can
2742 be specified to keep the command line tidy.</para>
2743 </glossdef>
2744 </glossentry>
2745
2746 <glossentry>
2747 <glossterm>--timeout &lt;msec&gt;</glossterm>
2748
2749 <glossdef>
2750 <para>Value (in milliseconds) that specifies the time how
2751 long the started process is allowed to run and how long
2752 VBoxManage waits for getting output from that process. If no
2753 timeout is specified, VBoxManage will wait forever until the
2754 started process ends or an error occured.</para>
2755 </glossdef>
2756 </glossentry>
2757
2758 <glossentry>
2759 <glossterm>--unix2dos</glossterm>
2760
2761 <glossdef>
2762 Converts output from a UNIX/Linux guests to DOS-/Windows-compatible
2763 line endings (LF -> CR + LF). Not implemented yet.
2764 </glossdef>
2765 </glossentry>
2766
2767 <glossentry>
2768 <glossterm>--verbose</glossterm>
2769
2770 <glossdef>
2771 <para>Tells VBoxManage to be more verbose.</para>
2772 </glossdef>
2773 </glossentry>
2774
2775 <glossentry>
2776 <glossterm>--wait-exit</glossterm>
2777
2778 <glossdef>
2779 <para>Waits until the process ends and outputs its
2780 exit code along with the exit reason/flags.</para>
2781 </glossdef>
2782 </glossentry>
2783
2784 <glossentry>
2785 <glossterm>--wait-stdout</glossterm>
2786
2787 <glossdef>
2788 <para>Waits until the process ends and outputs its
2789 exit code along with the exit reason/flags. While waiting
2790 VBoxManage retrieves the process output collected from stdout.</para>
2791 </glossdef>
2792 </glossentry>
2793
2794 <glossentry>
2795 <glossterm>--wait-stderr</glossterm>
2796
2797 <glossdef>
2798 <para>Waits until the process ends and outputs its
2799 exit code along with the exit reason/flags. While waiting
2800 VBoxManage retrieves the process output collected from stderr.</para>
2801 </glossdef>
2802 </glossentry>
2803
2804 <glossentry>
2805 <glossterm>[-- [&lt;argument1s&gt;] ... [&lt;argumentNs&gt;]]</glossterm>
2806
2807 <glossdef>
2808 <para>One or more arguments to pass to the process being
2809 executed.</para>
2810 <para>Arguments containing spaces must be enclosed in
2811 quotation marks.</para>
2812 </glossdef>
2813 </glossentry>
2814
2815 </glosslist></para>
2816
2817 <para><note>
2818 <para>On Windows there are certain limitations for graphical
2819 applications; please see <xref linkend="KnownIssues" /> for more
2820 information.</para>
2821 </note> Examples: <screen>VBoxManage --nologo guestcontrol "My VM" execute --image "/bin/ls"
2822 --username foo --passwordfile bar.txt --wait-exit --wait-stdout -- -l /usr</screen> <screen>VBoxManage --nologo guestcontrol "My VM" execute --image "c:\\windows\\system32\\ipconfig.exe"
2823 --username foo --passwordfile bar.txt --wait-exit --wait-stdout</screen> Note that
2824 the double backslashes in the second example are only required on
2825 Unix hosts.</para>
2826
2827 <para><note>
2828 <para>For certain commands a user name of an existing user account on the guest
2829 must be specified; anonymous executions are not supported for security reasons. A
2830 user account password, however, is optional and depends on the guest's OS security
2831 policy or rules. If no password is specified for a given user name, an empty password
2832 will be used. On certain OSes like Windows the security policy may needs to be adjusted
2833 in order to allow user accounts with an empty password set. Also, global domain rules might
2834 apply and therefore cannot be changed.</para>
2835 </note></para>
2836
2837 <para>Starting at VirtualBox 4.1.2 guest process execution by default is limited
2838 to serve up to 5 guest processes at a time. If a new guest process gets started
2839 which would exceed this limit, the oldest not running guest process will be discarded
2840 in order to be able to run that new process. Also, retrieving output from this
2841 old guest process will not be possible anymore then. If all 5 guest processes
2842 are still active and running, starting a new guest process will result in an
2843 appropriate error message.</para>
2844
2845 <para>To raise or lower the guest process execution limit, either the guest
2846 property <computeroutput>/VirtualBox/GuestAdd/VBoxService/--control-procs-max-kept</computeroutput>
2847 or VBoxService' command line by specifying <computeroutput>--control-procs-max-kept</computeroutput>
2848 needs to be modified. A restart of the guest OS is required afterwards. To serve unlimited
2849 guest processes, a value of <computeroutput>0</computeroutput> needs to be set (not recommended).</para>
2850 </listitem>
2851
2852 <listitem>
2853 <para><computeroutput>copyto</computeroutput>, which allows copying
2854 files from the host to the guest (only with installed Guest
2855 Additions 4.0 and later).</para>
2856
2857 <screen>VBoxManage guestcontrol &lt;vmname&gt;|&lt;uuid&gt; copyto|cp
2858 &lt;guest source&gt; &lt;host dest&gt; --username &lt;name&gt;
2859 [--passwordfile &lt;file&gt; | --password &lt;password&gt;]
2860 [--dryrun] [--follow] [--recursive] [--verbose]</screen>
2861
2862 <para>where the parameters mean: <glosslist>
2863 <glossentry>
2864 <glossterm>uuid|vmname</glossterm>
2865
2866 <glossdef>
2867 <para>The VM UUID or VM name. Mandatory.</para>
2868 </glossdef>
2869 </glossentry>
2870
2871 <glossentry>
2872 <glossterm>source on host</glossterm>
2873
2874 <glossdef>
2875 <para>Absolute path of source file(s) on host to copy over
2876 to the guest, e.g.
2877 <computeroutput>C:\Windows\System32\calc.exe</computeroutput>.
2878 This also can be a wildcard expression, e.g.
2879 <computeroutput>C:\Windows\System32\*.dll</computeroutput></para>
2880 </glossdef>
2881 </glossentry>
2882
2883 <glossentry>
2884 <glossterm>destination on guest</glossterm>
2885
2886 <glossdef>
2887 <para>Absolute destination path on the guest, e.g.
2888 <computeroutput>C:\Temp</computeroutput></para>
2889 </glossdef>
2890 </glossentry>
2891
2892 <glossentry>
2893 <glossterm>--username &lt;name&gt;</glossterm>
2894
2895 <glossdef>
2896 <para>Name of the user the copy process should run under.
2897 This user must exist on the guest OS.</para>
2898 </glossdef>
2899 </glossentry>
2900
2901 <glossentry>
2902 <glossterm>--passwordfile &lt;file&gt;</glossterm>
2903
2904 <glossdef>
2905 <para>Password of the user account specified to be read from
2906 the given file. If not given, an empty password is
2907 assumed.</para>
2908 </glossdef>
2909 </glossentry>
2910
2911 <glossentry>
2912 <glossterm>--password &lt;password&gt;</glossterm>
2913
2914 <glossdef>
2915 <para>Password of the user account specified with
2916 <computeroutput>--username</computeroutput>. If not given,
2917 an empty password is assumed.</para>
2918 </glossdef>
2919 </glossentry>
2920
2921 <glossentry>
2922 <glossterm>--dryrun</glossterm>
2923
2924 <glossdef>
2925 <para>Tells VBoxManage to only perform a dry run instead of
2926 really copying files to the guest.</para>
2927 </glossdef>
2928 </glossentry>
2929
2930 <glossentry>
2931 <glossterm>--follow</glossterm>
2932
2933 <glossdef>
2934 <para>Enables following symlinks on the host's
2935 source.</para>
2936 </glossdef>
2937 </glossentry>
2938
2939 <glossentry>
2940 <glossterm>--recursive</glossterm>
2941
2942 <glossdef>
2943 <para>Recursively copies files/directories of the specified
2944 source.</para>
2945 </glossdef>
2946 </glossentry>
2947
2948 <glossentry>
2949 <glossterm>--verbose</glossterm>
2950
2951 <glossdef>
2952 <para>Tells VBoxManage to be more verbose.</para>
2953 </glossdef>
2954 </glossentry>
2955
2956 <glossentry>
2957 <glossterm>--flags &lt;flags&gt;</glossterm>
2958
2959 <glossdef>
2960 <para>Additional flags to set. This is not used at the
2961 moment.</para>
2962 </glossdef>
2963 </glossentry>
2964 </glosslist></para>
2965 </listitem>
2966
2967 <listitem>
2968 <para><computeroutput>copyfrom</computeroutput>, which allows copying
2969 files from the guest to the host (only with installed Guest
2970 Additions 4.0 and later). It has the same parameters as
2971 <computeroutput>copyto</computeroutput> above.</para>
2972 </listitem>
2973
2974 <listitem>
2975 <para><computeroutput>createdirectory</computeroutput>, which allows
2976 copying files from the host to the guest (only with installed Guest
2977 Additions 4.0 and later).</para>
2978
2979 <screen>VBoxManage guestcontrol &lt;vmname&gt;|&lt;uuid&gt; createdir[ectory]|mkdir|md
2980 &lt;guest directory&gt;... --username &lt;name&gt;
2981 [--passwordfile &lt;file&gt; | --password &lt;password&gt;]
2982 [--parents] [--mode &lt;mode&gt;] [--verbose]</screen>
2983
2984 <para>where the parameters mean: <glosslist>
2985 <glossentry>
2986 <glossterm>uuid|vmname</glossterm>
2987
2988 <glossdef>
2989 <para>The VM UUID or VM name. Mandatory.</para>
2990 </glossdef>
2991 </glossentry>
2992
2993 <glossentry>
2994 <glossterm>directory to create on guest</glossterm>
2995
2996 <glossdef>
2997 <para>Absolute path of directory/directories to create on
2998 guest, e.g. <computeroutput>D:\Foo\Bar</computeroutput>.
2999 Parent directories need to exist (e.g. in this example
3000 <computeroutput>D:\Foo</computeroutput>) when switch
3001 <computeroutput>--parents</computeroutput> is omitted. The
3002 specified user must have appropriate rights to create the
3003 specified directory.</para>
3004 </glossdef>
3005 </glossentry>
3006
3007 <glossentry>
3008 <glossterm>--username &lt;name&gt;</glossterm>
3009
3010 <glossdef>
3011 <para>Name of the user the copy process should run under.
3012 This user must exist on the guest OS.</para>
3013 </glossdef>
3014 </glossentry>
3015
3016 <glossentry>
3017 <glossterm>--passwordfile &lt;file&gt;</glossterm>
3018
3019 <glossdef>
3020 <para>Password of the user account specified to be read from
3021 the given file. If not given, an empty password is
3022 assumed.</para>
3023 </glossdef>
3024 </glossentry>
3025
3026 <glossentry>
3027 <glossterm>--password &lt;password&gt;</glossterm>
3028
3029 <glossdef>
3030 <para>Password of the user account specified with
3031 <computeroutput>--username</computeroutput>. If not given,
3032 an empty password is assumed.</para>
3033 </glossdef>
3034 </glossentry>
3035
3036 <glossentry>
3037 <glossterm>--parents</glossterm>
3038
3039 <glossdef>
3040 <para>Also creates not yet existing parent directories of
3041 the specified directory, e.g. if the directory
3042 <computeroutput>D:\Foo</computeroutput> of
3043 <computeroutput>D:\Foo\Bar</computeroutput> does not exist
3044 yet it will be created. Without specifying
3045 <computeroutput>--parent</computeroutput> the action would
3046 have failed.</para>
3047 </glossdef>
3048 </glossentry>
3049
3050 <glossentry>
3051 <glossterm>--mode &lt;mode&gt;</glossterm>
3052
3053 <glossdef>
3054 <para>Sets the permission mode of the specified directory.
3055 Only octal modes (e.g.
3056 <computeroutput>0755</computeroutput>) are supported right
3057 now.</para>
3058 </glossdef>
3059 </glossentry>
3060
3061 <glossentry>
3062 <glossterm>--verbose</glossterm>
3063
3064 <glossdef>
3065 <para>Tells VBoxManage to be more verbose.</para>
3066 </glossdef>
3067 </glossentry>
3068 </glosslist></para>
3069 </listitem>
3070
3071 <listitem>
3072 <para><computeroutput>stat</computeroutput>, which displays file
3073 or file system status on the guest.</para>
3074
3075 <screen>VBoxManage guestcontrol &lt;vmname&gt;|&lt;uuid&gt; stat
3076 &lt;file&gt;... --username &lt;name&gt;
3077 [--passwordfile &lt;file&gt; | --password &lt;password&gt;]
3078 [--verbose]</screen>
3079
3080 <para>where the parameters mean: <glosslist>
3081 <glossentry>
3082 <glossterm>uuid|vmname</glossterm>
3083
3084 <glossdef>
3085 <para>The VM UUID or VM name. Mandatory.</para>
3086 </glossdef>
3087 </glossentry>
3088
3089 <glossentry>
3090 <glossterm>file element(s) to check on guest</glossterm>
3091
3092 <glossdef>
3093 <para>Absolute path of directory/directories to check on
3094 guest, e.g. <computeroutput>/home/foo/a.out</computeroutput>.
3095 The specified user must have appropriate rights to access
3096 the given file element(s).</para>
3097 </glossdef>
3098 </glossentry>
3099
3100 <glossentry>
3101 <glossterm>--username &lt;name&gt;</glossterm>
3102
3103 <glossdef>
3104 <para>Name of the user the copy process should run under.
3105 This user must exist on the guest OS.</para>
3106 </glossdef>
3107 </glossentry>
3108
3109 <glossentry>
3110 <glossterm>--passwordfile &lt;file&gt;</glossterm>
3111
3112 <glossdef>
3113 <para>Password of the user account specified to be read from
3114 the given file. If not given, an empty password is
3115 assumed.</para>
3116 </glossdef>
3117 </glossentry>
3118
3119 <glossentry>
3120 <glossterm>--password &lt;password&gt;</glossterm>
3121
3122 <glossdef>
3123 <para>Password of the user account specified with
3124 <computeroutput>--username</computeroutput>. If not given,
3125 an empty password is assumed.</para>
3126 </glossdef>
3127 </glossentry>
3128
3129 <glossentry>
3130 <glossterm>--verbose</glossterm>
3131
3132 <glossdef>
3133 <para>Tells VBoxManage to be more verbose.</para>
3134 </glossdef>
3135 </glossentry>
3136 </glosslist></para>
3137 </listitem>
3138
3139 <listitem>
3140 <para><computeroutput>updateadditions</computeroutput>, which allows
3141 for updating an already installed Guest Additions version on the
3142 guest (only already installed Guest Additions 4.0 and later).</para>
3143
3144 <screen>VBoxManage guestcontrol &lt;vmname&gt;|&lt;uuid&gt; updateadditions
3145 [--source "&lt;guest additions .ISO file to use&gt;"] [--verbose]
3146 [--wait-start]</screen>
3147
3148 <para>where the parameters mean: <glosslist>
3149 <glossentry>
3150 <glossterm>uuid|vmname</glossterm>
3151
3152 <glossdef>
3153 <para>The VM UUID or VM name. Mandatory.</para>
3154 </glossdef>
3155 </glossentry>
3156
3157 <glossentry>
3158 <glossterm>--source "&lt;guest additions .ISO file to
3159 use&gt;"</glossterm>
3160
3161 <glossdef>
3162 <para>Full path to an alternative VirtualBox Guest Additions
3163 .ISO file to use for the Guest Additions update.</para>
3164 </glossdef>
3165 </glossentry>
3166
3167 <glossentry>
3168 <glossterm>--verbose</glossterm>
3169
3170 <glossdef>
3171 <para>Tells VBoxManage to be more verbose.</para>
3172 </glossdef>
3173 </glossentry>
3174
3175 <glossentry>
3176 <glossterm>--wait-start</glossterm>
3177 <glossdef>
3178 <para>Starts the regular updating process and waits until the
3179 actual Guest Additions update inside the guest was started.
3180 This can be necessary due to needed interaction with the
3181 guest OS during the installation phase.</para>
3182 <para>When omitting this flag VBoxManage will wait for the
3183 whole Guest Additions update to complete.</para>
3184 </glossdef>
3185 </glossentry>
3186 </glosslist></para>
3187 </listitem>
3188 </itemizedlist></para>
3189 </sect1>
3190
3191 <sect1 id="vboxmanage-debugvm">
3192 <title>VBoxManage debugvm</title>
3193
3194 <para>The "debugvm" commands are for experts who want to tinker with the
3195 exact details of virtual machine execution. Like the VM debugger described
3196 in <xref linkend="ts_debugger" />, these commands are only useful if you are
3197 very familiar with the details of the PC architecture and how to debug
3198 software.</para>
3199
3200 <para>The subcommands of "debugvm" all operate on a running virtual
3201 machine. The following are available:<itemizedlist>
3202 <listitem>
3203 <para>With <computeroutput>dumpguestcore --filename
3204 &lt;name&gt;</computeroutput>, you can create a system dump of the
3205 running VM, which will be written into the given file. This file
3206 will have the standard ELF core format (with custom sections); see
3207 <xref linkend="ts_guest-core-format" />.</para>
3208
3209 <para>This corresponds to the
3210 <computeroutput>writecore</computeroutput> command in the debugger.
3211 </para>
3212 </listitem>
3213
3214 <listitem>
3215 <para>The <computeroutput>info</computeroutput> command is used to
3216 display info items relating to the VMM, device emulations and
3217 associated drivers. This command takes one or two arguments: the
3218 name of the info item, optionally followed by a string containing
3219 arguments specific to the info item.
3220 The <computeroutput>help</computeroutput> info item provides a
3221 listning of the available items and hints about any optional
3222 arguments.</para>
3223
3224 <para>This corresponds to the <computeroutput>info</computeroutput>
3225 command in the debugger.</para>
3226 </listitem>
3227
3228 <listitem>
3229 <para>The <computeroutput>injectnmi</computeroutput> command causes
3230 a non-maskable interrupt (NMI) in the guest, which might be useful
3231 for certain debugging scenarios. What happens exactly is dependent
3232 on the guest operating system, but an NMI can crash the whole guest
3233 operating system. Do not use unless you know what you're
3234 doing.</para>
3235 </listitem>
3236
3237 <listitem>
3238 <para>The <computeroutput>osdetect</computeroutput> command makes the
3239 VMM's debugger facility (re-)detection the guest operation
3240 system.</para>
3241
3242 <para>This corresponds to the <computeroutput>detect</computeroutput>
3243 command in the debugger.</para>
3244 </listitem>
3245
3246 <listitem>
3247 <para>The <computeroutput>osinfo</computeroutput> command is used to
3248 display info about the operating system (OS) detected by the VMM's
3249 debugger facility.</para>
3250 </listitem>
3251
3252 <listitem>
3253 <para>The <computeroutput>getregisters</computeroutput> command is
3254 used to display CPU and device registers. The command takes a list
3255 of registers, each having one of the following forms:
3256 <itemizedlist>
3257 <listitem><computeroutput>register-set.register-name.sub-field</computeroutput></listitem>
3258 <listitem><computeroutput>register-set.register-name</computeroutput></listitem>
3259 <listitem><computeroutput>cpu-register-name.sub-field</computeroutput></listitem>
3260 <listitem><computeroutput>cpu-register-name</computeroutput></listitem>
3261 <listitem><computeroutput>all</computeroutput></listitem>
3262 </itemizedlist>
3263 The <computeroutput>all</computeroutput> form will cause all
3264 registers to be shown (no sub-fields). The registers names are
3265 case-insensitive. When requesting a CPU register the register set
3266 can be omitted, it will be selected using the value of the
3267 <computeroutput>--cpu</computeroutput> option (defaulting to 0).
3268 </para>
3269 </listitem>
3270
3271 <listitem>
3272 <para>The <computeroutput>setregisters</computeroutput> command is
3273 used to change CPU and device registers. The command takes a list
3274 of register assignments, each having one of the following forms:
3275 <itemizedlist>
3276 <listitem><computeroutput>register-set.register-name.sub-field=value</computeroutput></listitem>
3277 <listitem><computeroutput>register-set.register-name=value</computeroutput></listitem>
3278 <listitem><computeroutput>cpu-register-name.sub-field=value</computeroutput></listitem>
3279 <listitem><computeroutput>cpu-register-name=value</computeroutput></listitem>
3280 </itemizedlist>
3281 The value format should be in the same style as what
3282 <computeroutput>getregisters</computeroutput> displays, with the
3283 exception that both octal and decimal can be used instead of
3284 hexadecimal. The register naming and the default CPU register set
3285 are handled the same way as with the
3286 <computeroutput>getregisters</computeroutput> command.</para>
3287 </listitem>
3288
3289 <listitem>
3290 <para>The <computeroutput>statistics</computeroutput> command can be
3291 used to display VMM statistics on the command line. The
3292 <computeroutput>--reset</computeroutput> option will reset
3293 statistics. The affected statistics can be filtered with the
3294 <computeroutput>--pattern</computeroutput> option, which accepts
3295 DOS/NT-style wildcards (<computeroutput>?</computeroutput> and
3296 <computeroutput>*</computeroutput>).</para>
3297 </listitem>
3298 </itemizedlist></para>
3299 </sect1>
3300
3301 <sect1>
3302 <title id="metrics">VBoxManage metrics</title>
3303
3304 <para>This command supports monitoring the usage of system resources.
3305 Resources are represented by various metrics associated with the host
3306 system or a particular VM. For example, the host system has a
3307 <computeroutput>CPU/Load/User</computeroutput> metric that shows the
3308 percentage of time CPUs spend executing in user mode over a specific
3309 sampling period.</para>
3310
3311 <para>Metric data is collected and retained internally; it may be
3312 retrieved at any time with the <computeroutput>VBoxManage metrics
3313 query</computeroutput> subcommand. The data is available as long as the
3314 background <computeroutput>VBoxSVC</computeroutput> process is alive. That
3315 process terminates shortly after all VMs and frontends have been
3316 closed.</para>
3317
3318 <para>By default no metrics are collected at all. Metrics collection does
3319 not start until <computeroutput>VBoxManage metrics setup</computeroutput>
3320 is invoked with a proper sampling interval and the number of metrics to be
3321 retained. The interval is measured in seconds. For example, to enable
3322 collecting the host processor and memory usage metrics every second and
3323 keeping the 5 most current samples, the following command can be
3324 used:</para>
3325
3326 <screen>VBoxManage metrics setup --period 1 --samples 5 host CPU/Load,RAM/Usage</screen>
3327
3328 <para>Metric collection can only be enabled for started VMs. Collected
3329 data and collection settings for a particular VM will disappear as soon as
3330 it shuts down. Use <computeroutput>VBoxManage metrics list
3331 </computeroutput> subcommand to see which metrics are currently available.
3332 You can also use <computeroutput>--list</computeroutput> option with any
3333 subcommand that modifies metric settings to find out which metrics were
3334 affected.</para>
3335
3336 <para>Note that the <computeroutput>VBoxManage metrics
3337 setup</computeroutput> subcommand discards all samples that may have been
3338 previously collected for the specified set of objects and metrics.</para>
3339
3340 <para>To enable or disable metrics collection without discarding the data
3341 <computeroutput>VBoxManage metrics enable</computeroutput> and
3342 <computeroutput>VBoxManage metrics disable</computeroutput> subcommands
3343 can be used. Note that these subcommands expect metrics, not submetrics,
3344 like <code>CPU/Load</code> or <code>RAM/Usage</code> as parameters. In
3345 other words enabling <code>CPU/Load/User</code> while disabling
3346 <code>CPU/Load/Kernel</code> is not supported.</para>
3347
3348 <para>The host and VMs have different sets of associated metrics.
3349 Available metrics can be listed with <computeroutput>VBoxManage metrics
3350 list</computeroutput> subcommand.</para>
3351
3352 <para>A complete metric name may include an aggregate function. The name
3353 has the following form:
3354 <computeroutput>Category/Metric[/SubMetric][:aggregate]</computeroutput>.
3355 For example, <computeroutput>RAM/Usage/Free:min</computeroutput> stands
3356 for the minimum amount of available memory over all retained data if
3357 applied to the host object.</para>
3358
3359 <para>Subcommands may apply to all objects and metrics or can be limited
3360 to one object or/and a list of metrics. If no objects or metrics are given
3361 in the parameters, the subcommands will apply to all available metrics of
3362 all objects. You may use an asterisk
3363 ("<computeroutput>*</computeroutput>") to explicitly specify that the
3364 command should be applied to all objects or metrics. Use "host" as the
3365 object name to limit the scope of the command to host-related metrics. To
3366 limit the scope to a subset of metrics, use a metric list with names
3367 separated by commas.</para>
3368
3369 <para>For example, to query metric data on the CPU time spent in user and
3370 kernel modes by the virtual machine named "test", you can use the
3371 following command:</para>
3372
3373 <screen>VBoxManage metrics query test CPU/Load/User,CPU/Load/Kernel</screen>
3374
3375 <para>The following list summarizes the available subcommands:</para>
3376
3377 <glosslist>
3378 <glossentry>
3379 <glossterm>list</glossterm>
3380
3381 <glossdef>
3382 <para>This subcommand shows the parameters of the currently existing
3383 metrics. Note that VM-specific metrics are only available when a
3384 particular VM is running.</para>
3385 </glossdef>
3386 </glossentry>
3387
3388 <glossentry>
3389 <glossterm>setup</glossterm>
3390
3391 <glossdef>
3392 <para>This subcommand sets the interval between taking two samples
3393 of metric data and the number of samples retained internally. The
3394 retained data is available for displaying with the
3395 <code>query</code> subcommand. The <computeroutput>--list
3396 </computeroutput> option shows which metrics have been modified as
3397 the result of the command execution.</para>
3398 </glossdef>
3399 </glossentry>
3400
3401 <glossentry>
3402 <glossterm>enable</glossterm>
3403
3404 <glossdef>
3405 <para>This subcommand "resumes" data collection after it has been
3406 stopped with <code>disable</code> subcommand. Note that specifying
3407 submetrics as parameters will not enable underlying metrics. Use
3408 <computeroutput>--list</computeroutput> to find out if the command
3409 did what was expected.</para>
3410 </glossdef>
3411 </glossentry>
3412
3413 <glossentry>
3414 <glossterm>disable</glossterm>
3415
3416 <glossdef>
3417 <para>This subcommand "suspends" data collection without affecting
3418 collection parameters or collected data. Note that specifying
3419 submetrics as parameters will not disable underlying metrics. Use
3420 <computeroutput>--list</computeroutput> to find out if the command
3421 did what was expected.</para>
3422 </glossdef>
3423 </glossentry>
3424
3425 <glossentry>
3426 <glossterm>query</glossterm>
3427
3428 <glossdef>
3429 <para>This subcommand retrieves and displays the currently retained
3430 metric data.<note>
3431 <para>The <code>query</code> subcommand does not remove or
3432 "flush" retained data. If you query often enough you will see
3433 how old samples are gradually being "phased out" by new
3434 samples.</para>
3435 </note></para>
3436 </glossdef>
3437 </glossentry>
3438
3439 <glossentry>
3440 <glossterm>collect</glossterm>
3441
3442 <glossdef>
3443 <para>This subcommand sets the interval between taking two samples
3444 of metric data and the number of samples retained internally. The
3445 collected data is displayed periodically until Ctrl-C is pressed
3446 unless the <computeroutput>--detach</computeroutput> option is
3447 specified. With the <computeroutput>--detach</computeroutput>
3448 option, this subcommand operates the same way as <code>setup</code>
3449 does. The <computeroutput>--list</computeroutput> option shows which
3450 metrics match the specified filter.</para>
3451 </glossdef>
3452 </glossentry>
3453 </glosslist>
3454 </sect1>
3455
3456 <sect1>
3457 <title>VBoxManage hostonlyif</title>
3458
3459 <para>With "hostonlyif" you can change the IP configuration of a host-only
3460 network interface. For a description of host-only networking, please
3461 refer to <xref linkend="network_hostonly" />. Each host-only interface is
3462 identified by a name and can either use the internal DHCP server or a
3463 manual IP configuration (both IP4 and IP6).</para>
3464 </sect1>
3465
3466 <sect1 id="vboxmanage-dhcpserver">
3467 <title>VBoxManage dhcpserver</title>
3468
3469 <para>The "dhcpserver" commands allow you to control the DHCP server that
3470 is built into VirtualBox. You may find this useful when using internal or
3471 host-only networking. (Theoretically, you can enable it for a bridged
3472 network as well, but that will likely cause conflicts with other DHCP
3473 servers in your physical network.)</para>
3474
3475 <para>Use the following command line options:<itemizedlist>
3476 <listitem>
3477 <para>If you use internal networking for a virtual network adapter
3478 of a virtual machine, use <computeroutput>VBoxManage dhcpserver add
3479 --netname &lt;network_name&gt;</computeroutput>, where
3480 <computeroutput>&lt;network_name&gt;</computeroutput> is the same
3481 network name you used with <computeroutput>VBoxManage modifyvm
3482 &lt;vmname&gt; --intnet&lt;X&gt;
3483 &lt;network_name&gt;</computeroutput>.</para>
3484 </listitem>
3485
3486 <listitem>
3487 <para>If you use host-only networking for a virtual network adapter
3488 of a virtual machine, use <computeroutput>VBoxManage dhcpserver add
3489 --ifname &lt;hostonly_if_name&gt;</computeroutput> instead, where
3490 <computeroutput>&lt;hostonly_if_name&gt;</computeroutput> is the
3491 same host-only interface name you used with
3492 <computeroutput>VBoxManage modifyvm &lt;vmname&gt;
3493 --hostonlyadapter&lt;X&gt;
3494 &lt;hostonly_if_name&gt;</computeroutput>.</para>
3495
3496 <para>Alternatively, you can also use the --netname option as with
3497 internal networks if you know the host-only network's name; you can
3498 see the names with <computeroutput>VBoxManage list
3499 hostonlyifs</computeroutput> (see <xref linkend="vboxmanage-list" />
3500 above).</para>
3501 </listitem>
3502 </itemizedlist></para>
3503
3504 <para>The following additional parameters are required when first adding a
3505 DHCP server:<itemizedlist>
3506 <listitem>
3507 <para>With <computeroutput>--ip</computeroutput>, specify the IP
3508 address of the DHCP server itself.</para>
3509 </listitem>
3510
3511 <listitem>
3512 <para>With <computeroutput>--netmask</computeroutput>, specify the
3513 netmask of the network.</para>
3514 </listitem>
3515
3516 <listitem>
3517 <para>With <computeroutput>--lowerip</computeroutput> and
3518 <computeroutput>--upperip</computeroutput>, you can specify the
3519 lowest and highest IP address, respectively, that the DHCP server
3520 will hand out to clients.</para>
3521 </listitem>
3522 </itemizedlist></para>
3523
3524 <para>Finally, you must specify <computeroutput>--enable</computeroutput>
3525 or the DHCP server will be created in the disabled state, doing
3526 nothing.</para>
3527
3528 <para>After this, VirtualBox will automatically start the DHCP server for
3529 given internal or host-only network as soon as the first virtual machine
3530 which uses that network is started.</para>
3531
3532 <para>Reversely, use <computeroutput>VBoxManage dhcpserver
3533 remove</computeroutput> with the given <computeroutput>--netname
3534 &lt;network_name&gt;</computeroutput> or <computeroutput>--ifname
3535 &lt;hostonly_if_name&gt;</computeroutput> to remove the DHCP server again
3536 for the given internal or host-only network.</para>
3537
3538 <para>To modify the settings of a DHCP server created earlier with
3539 <computeroutput>VBoxManage dhcpserver add</computeroutput>, you can use
3540 <computeroutput>VBoxManage dhcpserver modify</computeroutput> for a given
3541 network or host-only interface name.</para>
3542 </sect1>
3543
3544 <sect1 id="vboxmanage-extpack">
3545 <title>VBoxManage extpack</title>
3546
3547 <para>The "extpack" command allows you to add or remove VirtualBox
3548 extension packs, as described in <xref
3549 linkend="intro-installing" />.<itemizedlist>
3550 <listitem>
3551 <para>To add a new extension pack, use <computeroutput>VBoxManage
3552 extpack install &lt;tarball&gt;</computeroutput>. This command
3553 will fail if an older version of the same extension pack is already
3554 installed. The optional <computeroutput>--replace</computeroutput>
3555 parameter can be used to uninstall the old package before the new
3556 package is installed.</para>
3557 </listitem>
3558
3559 <listitem>
3560 <para>To remove a previously installed extension pack, use
3561 <computeroutput>VBoxManage extpack uninstall
3562 &lt;name&gt;</computeroutput>. You can use
3563 <computeroutput>VBoxManage list extpacks</computeroutput> to show
3564 the names of the extension packs which are currently installed;
3565 please see <xref linkend="vboxmanage-list" /> also. The optional
3566 <computeroutput>--force</computeroutput> parameter can be used to
3567 override the refusal of an extension pack to be uninstalled.</para>
3568 </listitem>
3569
3570 <listitem>
3571 <para>The <computeroutput>VBoxManage extpack
3572 cleanup</computeroutput> command can be used to remove temporary
3573 files and directories that may have been left behind if a previous
3574 install or uninstall command failed.</para>
3575 </listitem>
3576 </itemizedlist></para>
3577 <para>The following commands show examples how to list extension packs and
3578 remove one:<screen>
3579$ VBoxManage list extpacks
3580Extension Packs: 1
3581Pack no. 0: Oracle VM VirtualBox Extension Pack
3582Version: 4.1.12
3583Revision: 77218
3584Edition:
3585Description: USB 2.0 Host Controller, VirtualBox RDP, PXE ROM with E1000 support.
3586VRDE Module: VBoxVRDP
3587Usable: true
3588Why unusable:
3589$ VBoxManage extpack uninstall "Oracle VM VirtualBox Extension Pack"
35900%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
3591Successfully uninstalled "Oracle VM VirtualBox Extension Pack".</screen></para>
3592 </sect1>
3593</chapter>
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette