VirtualBox

source: vbox/trunk/doc/manual/en_US/user_GuestAdditions.xml@ 81589

Last change on this file since 81589 was 76786, checked in by vboxsync, 6 years ago

manual: integrate drop #40 with minimal manual adjustments (but everything into one book, with manually applied tweaks to turn the release notes into a pure changelog again, and eliminated trailing whitespace)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id Revision
File size: 83.1 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd"[
4<!ENTITY % all.entities SYSTEM "all-entities.ent">
5%all.entities;
6]>
7<chapter id="guestadditions">
8
9 <title>Guest Additions</title>
10
11 <para>
12 The previous chapter covered getting started with &product-name; and
13 installing operating systems in a virtual machine. For any serious
14 and interactive use, the &product-name; Guest Additions will make
15 your life much easier by providing closer integration between host
16 and guest and improving the interactive performance of guest
17 systems. This chapter describes the Guest Additions in detail.
18 </para>
19
20 <sect1 id="guestadd-intro">
21
22 <title>Introduction to Guest Additions</title>
23
24 <para>
25 As mentioned in <xref linkend="virtintro" />, the Guest Additions
26 are designed to be installed <emphasis>inside</emphasis> a virtual
27 machine after the guest operating system has been installed. They
28 consist of device drivers and system applications that optimize
29 the guest operating system for better performance and usability.
30 See <xref linkend="guestossupport" /> for details on what guest
31 operating systems are fully supported with Guest Additions by
32 &product-name;.
33 </para>
34
35 <para>
36 The &product-name; Guest Additions for all supported guest
37 operating systems are provided as a single CD-ROM image file which
38 is called <computeroutput>VBoxGuestAdditions.iso</computeroutput>.
39 This image file is located in the installation directory of
40 &product-name;. To install the Guest Additions for a particular
41 VM, you mount this ISO file in your VM as a virtual CD-ROM and
42 install from there.
43 </para>
44
45 <para>
46 The Guest Additions offer the following features:
47 </para>
48
49 <itemizedlist>
50
51 <listitem>
52 <para>
53 <emphasis role="bold">Mouse pointer integration</emphasis>. To
54 overcome the limitations for mouse support described in
55 <xref linkend="keyb_mouse_normal" />, this feature provides
56 you with seamless mouse support. You will only have one mouse
57 pointer and pressing the Host key is no longer required to
58 "free" the mouse from being captured by the guest OS. To make
59 this work, a special mouse driver is installed in the guest
60 that communicates with the "real" mouse driver on your host
61 and moves the guest mouse pointer accordingly.
62 </para>
63 </listitem>
64
65 <listitem>
66 <para>
67 <emphasis role="bold">Shared folders.</emphasis> These provide
68 an easy way to exchange files between the host and the guest.
69 Much like ordinary Windows network shares, you can tell
70 &product-name; to treat a certain host directory as a shared
71 folder, and &product-name; will make it available to the guest
72 operating system as a network share, irrespective of whether
73 guest actually has a network. See
74 <xref
75 linkend="sharedfolders" />.
76 </para>
77 </listitem>
78
79 <listitem>
80 <para>
81 <emphasis role="bold">Better video support.</emphasis> While
82 the virtual graphics card which &product-name; emulates for
83 any guest operating system provides all the basic features,
84 the custom video drivers that are installed with the Guest
85 Additions provide you with extra high and non-standard video
86 modes, as well as accelerated video performance.
87 </para>
88
89 <para>
90 In addition, with Windows, Linux, and Oracle Solaris guests,
91 you can resize the virtual machine's window if the Guest
92 Additions are installed. The video resolution in the guest
93 will be automatically adjusted, as if you had manually entered
94 an arbitrary resolution in the guest's
95 <emphasis role="bold">Display</emphasis> settings. See
96 <xref linkend="intro-resize-window" />.
97 </para>
98
99 <para>
100 If the Guest Additions are installed, 3D graphics and 2D video
101 for guest applications can be accelerated. See
102 <xref linkend="guestadd-video" />.
103 </para>
104 </listitem>
105
106 <listitem>
107 <para>
108 <emphasis role="bold">Seamless windows.</emphasis> With this
109 feature, the individual windows that are displayed on the
110 desktop of the virtual machine can be mapped on the host's
111 desktop, as if the underlying application was actually running
112 on the host. See <xref linkend="seamlesswindows" />.
113 </para>
114 </listitem>
115
116 <listitem>
117 <para>
118 <emphasis role="bold">Generic host/guest communication
119 channels.</emphasis> The Guest Additions enable you to control
120 and monitor guest execution. The "guest properties" provide a
121 generic string-based mechanism to exchange data bits between a
122 guest and a host, some of which have special meanings for
123 controlling and monitoring the guest. See
124 <xref linkend="guestadd-guestprops" />.
125 </para>
126
127 <para>
128 Additionally, applications can be started in a guest from the
129 host. See <xref linkend="guestadd-guestcontrol" />.
130 </para>
131 </listitem>
132
133 <listitem>
134 <para>
135 <emphasis role="bold">Time synchronization.</emphasis> With
136 the Guest Additions installed, &product-name; can ensure that
137 the guest's system time is better synchronized with that of
138 the host.
139 </para>
140
141 <para>
142 For various reasons, the time in the guest might run at a
143 slightly different rate than the time on the host. The host
144 could be receiving updates through NTP and its own time might
145 not run linearly. A VM could also be paused, which stops the
146 flow of time in the guest for a shorter or longer period of
147 time. When the wall clock time between the guest and host only
148 differs slightly, the time synchronization service attempts to
149 gradually and smoothly adjust the guest time in small
150 increments to either "catch up" or "lose" time. When the
151 difference is too great, for example if a VM paused for hours
152 or restored from saved state, the guest time is changed
153 immediately, without a gradual adjustment.
154 </para>
155
156 <para>
157 The Guest Additions will resynchronize the time regularly. See
158 <xref linkend="changetimesync" /> for how to configure the
159 parameters of the time synchronization mechanism.
160 </para>
161 </listitem>
162
163 <listitem>
164 <para>
165 <emphasis role="bold">Shared clipboard.</emphasis> With the
166 Guest Additions installed, the clipboard of the guest
167 operating system can optionally be shared with your host
168 operating system. See <xref linkend="generalsettings" />.
169 </para>
170 </listitem>
171
172 <listitem>
173 <para>
174 <emphasis role="bold">Automated logins.</emphasis> Also called
175 credentials passing. See <xref linkend="autologon" />.
176 </para>
177 </listitem>
178
179 </itemizedlist>
180
181 <para>
182 Each version of &product-name;, even minor releases, ship with
183 their own version of the Guest Additions. While the interfaces
184 through which the &product-name; core communicates with the Guest
185 Additions are kept stable so that Guest Additions already
186 installed in a VM should continue to work when &product-name; is
187 upgraded on the host, for best results, it is recommended to keep
188 the Guest Additions at the same version.
189 </para>
190
191 <para>
192 The Windows and Linux Guest Additions therefore check
193 automatically whether they have to be updated. If the host is
194 running a newer &product-name; version than the Guest Additions, a
195 notification with further instructions is displayed in the guest.
196 </para>
197
198 <para>
199 To disable this update check for the Guest Additions of a given
200 virtual machine, set the value of its
201 <computeroutput>/VirtualBox/GuestAdd/CheckHostVersion</computeroutput>
202 guest property to <computeroutput>0</computeroutput>. See
203 <xref
204 linkend="guestadd-guestprops" />.
205 </para>
206
207 </sect1>
208
209 <sect1 id="guestadd-install">
210
211 <title>Installing and Maintaining Guest Additions</title>
212
213 <para>
214 Guest Additions are available for virtual machines running
215 Windows, Linux, Oracle Solaris, or OS/2. The following sections
216 describe the specifics of each variant in detail.
217 </para>
218
219 <sect2 id="additions-windows">
220
221 <title>Guest Additions for Windows</title>
222
223 <para>
224 The &product-name; Windows Guest Additions are designed to be
225 installed in a virtual machine running a Windows operating
226 system. The following versions of Windows guests are supported:
227 </para>
228
229 <itemizedlist>
230
231 <listitem>
232 <para>
233 Microsoft Windows NT 4.0 (any service pack)
234 </para>
235 </listitem>
236
237 <listitem>
238 <para>
239 Microsoft Windows 2000 (any service pack)
240 </para>
241 </listitem>
242
243 <listitem>
244 <para>
245 Microsoft Windows XP (any service pack)
246 </para>
247 </listitem>
248
249 <listitem>
250 <para>
251 Microsoft Windows Server 2003 (any service pack)
252 </para>
253 </listitem>
254
255 <listitem>
256 <para>
257 Microsoft Windows Server 2008
258 </para>
259 </listitem>
260
261 <listitem>
262 <para>
263 Microsoft Windows Vista (all editions)
264 </para>
265 </listitem>
266
267 <listitem>
268 <para>
269 Microsoft Windows 7 (all editions)
270 </para>
271 </listitem>
272
273 <listitem>
274 <para>
275 Microsoft Windows 8 (all editions)
276 </para>
277 </listitem>
278
279 <listitem>
280 <para>
281 Microsoft Windows 10 RTM build 10240
282 </para>
283 </listitem>
284
285 <listitem>
286 <para>
287 Microsoft Windows Server 2012
288 </para>
289 </listitem>
290
291 </itemizedlist>
292
293 <sect3 id="mountingadditionsiso">
294
295 <title>Installing the Windows Guest Additions</title>
296
297 <para>
298 In the <emphasis role="bold">Devices</emphasis> menu in the
299 virtual machine's menu bar, &product-name; has a menu item
300 <emphasis role="bold">Insert Guest Additions CD
301 Image</emphasis>, which mounts the Guest Additions ISO file
302 inside your virtual machine. A Windows guest should then
303 automatically start the Guest Additions installer, which
304 installs the Guest Additions on your Windows guest.
305 </para>
306
307 <para>
308 For other guest operating systems, or if automatic start of
309 software on a CD is disabled, you need to do a manual start of
310 the installer.
311 </para>
312
313 <note>
314 <para>
315 For the basic Direct3D acceleration to work in a Windows
316 guest, you have to install the WDDM video driver available
317 for Windows Vista or later.
318 </para>
319
320 <para>
321 For Windows 8 and later, only the WDDM Direct3D video driver
322 is available. For basic Direct3D acceleration to work in
323 Windows XP guests, you have to install the Guest Additions
324 in Safe Mode. See <xref linkend="KnownIssues" /> for
325 details.
326 </para>
327 </note>
328
329 <para>
330 If you prefer to mount the Guest Additions manually, you can
331 perform the following steps:
332 </para>
333
334 <orderedlist>
335
336 <listitem>
337 <para>
338 Start the virtual machine in which you have installed
339 Windows.
340 </para>
341 </listitem>
342
343 <listitem>
344 <para>
345 Select <emphasis role="bold">Mount CD/DVD-ROM</emphasis>
346 from the <emphasis role="bold">Devices</emphasis> menu in
347 the virtual machine's menu bar and then
348 <emphasis role="bold">CD/DVD-ROM Image</emphasis>. This
349 displays the Virtual Media Manager, described in
350 <xref
351 linkend="vdis" />.
352 </para>
353 </listitem>
354
355 <listitem>
356 <para>
357 In the Virtual Media Manager, click
358 <emphasis role="bold">Add</emphasis> and browse your host
359 file system for the
360 <computeroutput>VBoxGuestAdditions.iso</computeroutput>
361 file.
362 </para>
363
364 <itemizedlist>
365
366 <listitem>
367 <para>
368 On a Windows host, this file is in the &product-name;
369 installation directory, usually in
370 <computeroutput>C:\Program
371 files\Oracle\VirtualBox</computeroutput>.
372 </para>
373 </listitem>
374
375 <listitem>
376 <para>
377 On Mac OS X hosts, this file is in the application
378 bundle of &product-name;. Right-click on the
379 &product-name; icon in Finder and choose
380 <emphasis role="bold">Show Package
381 Contents</emphasis>. The file is located in the
382 <computeroutput>Contents/MacOS</computeroutput>
383 folder.
384 </para>
385 </listitem>
386
387 <listitem>
388 <para>
389 On a Linux host, this file is in the
390 <computeroutput>additions</computeroutput> folder
391 where you installed &product-name;, usually
392 <computeroutput>/opt/VirtualBox/</computeroutput>.
393 </para>
394 </listitem>
395
396 <listitem>
397 <para>
398 On Oracle Solaris hosts, this file is in the
399 <computeroutput>additions</computeroutput> folder
400 where you installed &product-name;, usually
401 <computeroutput>/opt/VirtualBox</computeroutput>.
402 </para>
403 </listitem>
404
405 </itemizedlist>
406 </listitem>
407
408 <listitem>
409 <para>
410 In the Virtual Media Manager, select the ISO file and
411 click <emphasis role="bold">Select</emphasis> button. This
412 mounts the ISO file and presents it to your Windows guest
413 as a CD-ROM.
414 </para>
415 </listitem>
416
417 </orderedlist>
418
419 <para>
420 Unless you have the Autostart feature disabled in your Windows
421 guest, Windows will now autostart the &product-name; Guest
422 Additions installation program from the Additions ISO. If the
423 Autostart feature has been turned off, choose
424 <computeroutput>VBoxWindowsAdditions.exe</computeroutput> from
425 the CD/DVD drive inside the guest to start the installer.
426 </para>
427
428 <para>
429 The installer will add several device drivers to the Windows
430 driver database and then invoke the hardware detection wizard.
431 </para>
432
433 <para>
434 Depending on your configuration, it might display warnings
435 that the drivers are not digitally signed. You must confirm
436 these in order to continue the installation and properly
437 install the Additions.
438 </para>
439
440 <para>
441 After installation, reboot your guest operating system to
442 activate the Additions.
443 </para>
444
445 </sect3>
446
447 <sect3 id="additions-windows-updating">
448
449 <title>Updating the Windows Guest Additions</title>
450
451 <para>
452 Windows Guest Additions can be updated by running the
453 installation program again. This replaces the previous
454 Additions drivers with updated versions.
455 </para>
456
457 <para>
458 Alternatively, you can also open the Windows Device Manager
459 and select <emphasis role="bold">Update Driver...</emphasis>
460 for the following devices:
461 </para>
462
463 <orderedlist>
464
465 <listitem>
466 <para>
467 &product-name; Graphics Adapter
468 </para>
469 </listitem>
470
471 <listitem>
472 <para>
473 &product-name; System Device
474 </para>
475 </listitem>
476
477 </orderedlist>
478
479 <para>
480 For each, choose the option to provide your own driver, click
481 <emphasis role="bold">Have Disk</emphasis> and navigate to the
482 CD-ROM drive with the Guest Additions.
483 </para>
484
485 </sect3>
486
487 <sect3 id="additions-windows-install-unattended">
488
489 <title>Unattended Installation</title>
490
491 <para>
492 To avoid popups when performing an unattended installation of
493 the &product-name; Guest Additions, the code signing
494 certificates used to sign the drivers needs to be installed in
495 the correct certificate stores on the guest operating system.
496 Failure to do this will cause a typical Windows installation
497 to display multiple dialogs asking whether you want to install
498 a particular driver.
499 </para>
500
501 <note>
502 <para>
503 On some Windows versions, such as Windows 2000 and Windows
504 XP, the user intervention popups mentioned above are always
505 displayed, even after importing the Oracle certificates.
506 </para>
507 </note>
508
509 <para>
510 Installing the code signing certificates on a Windows guest
511 can be done automatically. Use the
512 <computeroutput>VBoxCertUtil.exe</computeroutput> utility from
513 the <computeroutput>cert</computeroutput> folder on the Guest
514 Additions installation CD.
515 </para>
516
517 <para>
518 Use the following steps:
519 </para>
520
521 <orderedlist>
522
523 <listitem>
524 <para>
525 Log in as Administrator on the guest.
526 </para>
527 </listitem>
528
529 <listitem>
530 <para>
531 Mount the &product-name; Guest Additions .ISO.
532 </para>
533 </listitem>
534
535 <listitem>
536 <para>
537 Open a command line window on the guest and change to the
538 <computeroutput>cert</computeroutput> folder on the
539 &product-name; Guest Additions CD.
540 </para>
541 </listitem>
542
543 <listitem>
544 <para>
545 Run the following command:
546 </para>
547
548<screen>VBoxCertUtil.exe add-trusted-publisher vbox*.cer --root vbox*.cer</screen>
549
550 <para>
551 This command installs the certificates to the certificate
552 store. When installing the same certificate more than
553 once, an appropriate error will be displayed.
554 </para>
555 </listitem>
556
557 </orderedlist>
558
559 <para>
560 To allow for completely unattended guest installations, you
561 can specify a command line parameter to the install launcher:
562 </para>
563
564<screen>VBoxWindowsAdditions.exe /S</screen>
565
566 <para>
567 This automatically installs the right files and drivers for
568 the corresponding platform, either 32-bit or 64-bit.
569 </para>
570
571 <note>
572 <para>
573 By default on an unattended installation on a Vista or
574 Windows 7 guest, there will be the XPDM graphics driver
575 installed. This graphics driver does not support Windows
576 Aero / Direct3D on the guest. Instead, the WDDM graphics
577 driver needs to be installed. To select this driver by
578 default, add the command line parameter
579 <computeroutput>/with_wddm</computeroutput> when invoking
580 the Windows Guest Additions installer. This is only required
581 for Vista and Windows 7.
582 </para>
583 </note>
584
585 <note>
586 <para>
587 For Windows Aero to run correctly on a guest, the guest's
588 VRAM size needs to be configured to at least 128 MB.
589 </para>
590 </note>
591
592 <para>
593 For more options regarding unattended guest installations,
594 consult the command line help by using the command:
595 </para>
596
597<screen>VBoxWindowsAdditions.exe /?</screen>
598
599 </sect3>
600
601 <sect3 id="windows-guest-file-extraction">
602
603 <title>Manual File Extraction</title>
604
605 <para>
606 If you would like to install the files and drivers manually,
607 you can extract the files from the Windows Guest Additions
608 setup as follows:
609 </para>
610
611<screen>VBoxWindowsAdditions.exe /extract</screen>
612
613 <para>
614 To explicitly extract the Windows Guest Additions for another
615 platform than the current running one, such as 64-bit files on
616 a 32-bit system, you must use the appropriate platform
617 installer. Use
618 <computeroutput>VBoxWindowsAdditions-x86.exe</computeroutput>
619 or
620 <computeroutput>VBoxWindowsAdditions-amd64.exe</computeroutput>
621 with the <computeroutput>/extract</computeroutput> parameter.
622 </para>
623
624 </sect3>
625
626 </sect2>
627
628 <sect2 id="additions-linux">
629
630 <title>Guest Additions for Linux</title>
631
632 <para>
633 Like the Windows Guest Additions, the &product-name; Guest
634 Additions for Linux are a set of device drivers and system
635 applications which may be installed in the guest operating
636 system.
637 </para>
638
639 <para>
640 The following Linux distributions are officially supported:
641 </para>
642
643 <itemizedlist>
644
645 <listitem>
646 <para>
647 Oracle Linux as of version 5, including UEK kernels
648 </para>
649 </listitem>
650
651 <listitem>
652 <para>
653 Fedora as of Fedora Core 4
654 </para>
655 </listitem>
656
657 <listitem>
658 <para>
659 Redhat Enterprise Linux as of version 3
660 </para>
661 </listitem>
662
663 <listitem>
664 <para>
665 SUSE and openSUSE Linux as of version 9
666 </para>
667 </listitem>
668
669 <listitem>
670 <para>
671 Ubuntu as of version 5.10
672 </para>
673 </listitem>
674
675 </itemizedlist>
676
677 <para>
678 Many other distributions are known to work with the Guest
679 Additions.
680 </para>
681
682 <para>
683 The version of the Linux kernel supplied by default in SUSE and
684 openSUSE 10.2, Ubuntu 6.10 (all versions) and Ubuntu 6.06
685 (server edition) contains a bug which can cause it to crash
686 during startup when it is run in a virtual machine. The Guest
687 Additions work in those distributions.
688 </para>
689
690 <para>
691 Note that some Linux distributions already come with all or part
692 of the &product-name; Guest Additions. You may choose to keep
693 the distribution's version of the Guest Additions but these are
694 often not up to date and limited in functionality, so we
695 recommend replacing them with the Guest Additions that come with
696 &product-name;. The &product-name; Linux Guest Additions
697 installer tries to detect an existing installation and replace
698 them but depending on how the distribution integrates the Guest
699 Additions, this may require some manual interaction. It is
700 highly recommended to take a snapshot of the virtual machine
701 before replacing preinstalled Guest Additions.
702 </para>
703
704 <sect3 id="additions-linux-install">
705
706 <title>Installing the Linux Guest Additions</title>
707
708 <para>
709 The &product-name; Guest Additions for Linux are provided on
710 the same virtual CD-ROM file as the Guest Additions for
711 Windows. See <xref linkend="mountingadditionsiso"/>. They also
712 come with an installation program that guides you through the
713 setup process. However, due to the significant differences
714 between Linux distributions, installation may be slightly more
715 complex when compared to Windows.
716 </para>
717
718 <para>
719 Installation generally involves the following steps:
720 </para>
721
722 <orderedlist>
723
724 <listitem>
725 <para>
726 Before installing the Guest Additions, you prepare your
727 guest system for building external kernel modules. This
728 works as described in
729 <xref linkend="externalkernelmodules" />, except that this
730 step must be performed in your Linux
731 <emphasis>guest</emphasis> instead of on a Linux host
732 system.
733 </para>
734
735 <para>
736 If you suspect that something has gone wrong, check that
737 your guest is set up correctly and run the following
738 command as root:
739 </para>
740
741<screen>rcvboxadd setup</screen>
742 </listitem>
743
744 <listitem>
745 <para>
746 Insert the
747 <computeroutput>VBoxGuestAdditions.iso</computeroutput> CD
748 file into your Linux guest's virtual CD-ROM drive, as
749 described for a Windows guest in
750 <xref linkend="mountingadditionsiso" />.
751 </para>
752 </listitem>
753
754 <listitem>
755 <para>
756 Change to the directory where your CD-ROM drive is mounted
757 and run the following command as root:
758 </para>
759
760<screen>sh ./VBoxLinuxAdditions.run</screen>
761 </listitem>
762
763 </orderedlist>
764
765 </sect3>
766
767 <sect3 id="additions-linux-graphics-mouse">
768
769 <title>Graphics and Mouse Integration</title>
770
771 <para>
772 In Linux and Oracle Solaris guests, &product-name; graphics
773 and mouse integration goes through the X Window System.
774 &product-name; can use the X.Org variant of the system, or
775 XFree86 version 4.3 which is identical to the first X.Org
776 release. During the installation process, the X.Org display
777 server will be set up to use the graphics and mouse drivers
778 which come with the Guest Additions.
779 </para>
780
781 <para>
782 After installing the Guest Additions into a fresh installation
783 of a supported Linux distribution or Oracle Solaris system,
784 many unsupported systems will work correctly too, the guest's
785 graphics mode will change to fit the size of the
786 &product-name; window on the host when it is resized. You can
787 also ask the guest system to switch to a particular resolution
788 by sending a video mode hint using the
789 <command>VBoxManage</command> tool.
790 </para>
791
792 <para>
793 Multiple guest monitors are supported in guests using the
794 X.Org server version 1.3, which is part of release 7.3 of the
795 X Window System version 11, or a later version. The layout of
796 the guest screens can be adjusted as needed using the tools
797 which come with the guest operating system.
798 </para>
799
800 <para>
801 If you want to understand more about the details of how the
802 X.Org drivers are set up, in particular if you wish to use
803 them in a setting which our installer does not handle
804 correctly, see <xref linkend="guestxorgsetup" />.
805 </para>
806
807 </sect3>
808
809 <sect3 id="additions-linux-updating">
810
811 <title>Updating the Linux Guest Additions</title>
812
813 <para>
814 The Guest Additions can simply be updated by going through the
815 installation procedure again with an updated CD-ROM image.
816 This will replace the drivers with updated versions. You
817 should reboot after updating the Guest Additions.
818 </para>
819
820 </sect3>
821
822 <sect3 id="additions-linux-uninstall">
823
824 <title>Uninstalling the Linux Guest Additions</title>
825
826 <para>
827 If you have a version of the Guest Additions installed on your
828 virtual machine and wish to remove it without installing new
829 ones, you can do so by inserting the Guest Additions CD image
830 into the virtual CD-ROM drive as described above. Then run the
831 installer for the current Guest Additions with the
832 <computeroutput>uninstall</computeroutput> parameter from the
833 path that the CD image is mounted on in the guest, as follows:
834 </para>
835
836<screen>sh ./VBoxLinuxAdditions.run uninstall</screen>
837
838 <para>
839 While this will normally work without issues, you may need to
840 do some manual cleanup of the guest in some cases, especially
841 of the XFree86Config or xorg.conf file. In particular, if the
842 Additions version installed or the guest operating system were
843 very old, or if you made your own changes to the Guest
844 Additions setup after you installed them.
845 </para>
846
847 <para>
848 You can uninstall the Additions as follows:
849 </para>
850
851<screen>/opt/VBoxGuestAdditions-<replaceable>version</replaceable>/uninstall.sh</screen>
852
853 <para>
854 Replace
855 <computeroutput>/opt/VBoxGuestAdditions-<replaceable>version</replaceable></computeroutput>
856 with the correct Guest Additions installation directory.
857 </para>
858
859 </sect3>
860
861 </sect2>
862
863 <sect2 id="additions-solaris">
864
865 <title>Guest Additions for Oracle Solaris</title>
866
867 <para>
868 Like the Windows Guest Additions, the &product-name; Guest
869 Additions for Oracle Solaris take the form of a set of device
870 drivers and system applications which may be installed in the
871 guest operating system.
872 </para>
873
874 <para>
875 The following Oracle Solaris distributions are officially
876 supported:
877 </para>
878
879 <itemizedlist>
880
881 <listitem>
882 <para>
883 Oracle Solaris 11, including Oracle Solaris 11 Express
884 </para>
885 </listitem>
886
887 <listitem>
888 <para>
889 Oracle Solaris 10 4/08 and later
890 </para>
891 </listitem>
892
893 </itemizedlist>
894
895 <para>
896 Other distributions may work if they are based on comparable
897 software releases.
898 </para>
899
900 <sect3 id="additions-solaris-install">
901
902 <title>Installing the Oracle Solaris Guest Additions</title>
903
904 <para>
905 The &product-name; Guest Additions for Oracle Solaris are
906 provided on the same ISO CD-ROM as the Additions for Windows
907 and Linux. They come with an installation program that guides
908 you through the setup process.
909 </para>
910
911 <para>
912 Installation involves the following steps:
913 </para>
914
915 <orderedlist>
916
917 <listitem>
918 <para>
919 Mount the
920 <computeroutput>VBoxGuestAdditions.iso</computeroutput>
921 file as your Oracle Solaris guest's virtual CD-ROM drive,
922 exactly the same way as described for a Windows guest in
923 <xref
924 linkend="mountingadditionsiso" />.
925 </para>
926
927 <para>
928 If the CD-ROM drive on the guest does not get mounted, as
929 seen with some versions of Oracle Solaris 10, run the
930 following command as root:
931 </para>
932
933<screen>svcadm restart volfs</screen>
934 </listitem>
935
936 <listitem>
937 <para>
938 Change to the directory where your CD-ROM drive is mounted
939 and run the following command as root:
940 </para>
941
942<screen>pkgadd -G -d ./VBoxSolarisAdditions.pkg</screen>
943 </listitem>
944
945 <listitem>
946 <para>
947 Choose <emphasis role="bold">1</emphasis> and confirm
948 installation of the Guest Additions package. After the
949 installation is complete, log out and log in to X server
950 on your guest, to activate the X11 Guest Additions.
951 </para>
952 </listitem>
953
954 </orderedlist>
955
956 </sect3>
957
958 <sect3 id="additions-solaris-uninstall">
959
960 <title>Uninstalling the Oracle Solaris Guest Additions</title>
961
962 <para>
963 The Oracle Solaris Guest Additions can be safely removed by
964 removing the package from the guest. Open a root terminal
965 session and run the following command:
966 </para>
967
968<screen>pkgrm SUNWvboxguest</screen>
969
970 </sect3>
971
972 <sect3 id="additions-solaris-updating">
973
974 <title>Updating the Oracle Solaris Guest Additions</title>
975
976 <para>
977 The Guest Additions should be updated by first uninstalling
978 the existing Guest Additions and then installing the new ones.
979 Attempting to install new Guest Additions without removing the
980 existing ones is not possible.
981 </para>
982
983 </sect3>
984
985 </sect2>
986
987 <sect2 id="additions-os2">
988
989 <title>Guest Additions for OS/2</title>
990
991 <para>
992 &product-name; also ships with a set of drivers that improve
993 running OS/2 in a virtual machine. Due to restrictions of OS/2
994 itself, this variant of the Guest Additions has a limited
995 feature set. See <xref
996 linkend="KnownIssues" /> for
997 details.
998 </para>
999
1000 <para>
1001 The OS/2 Guest Additions are provided on the same ISO CD-ROM as
1002 those for the other platforms. Mount the ISO in OS/2 as
1003 described previously. The OS/2 Guest Additions are located in
1004 the directory <computeroutput>\OS2</computeroutput>.
1005 </para>
1006
1007 <para>
1008 We do not provide an automatic installer at this time. See the
1009 <computeroutput>readme.txt</computeroutput> file in the CD-ROM
1010 directory, which describes how to install the OS/2 Guest
1011 Additions manually.
1012 </para>
1013
1014 </sect2>
1015
1016 </sect1>
1017
1018 <sect1 id="sharedfolders">
1019
1020 <title>Shared Folders</title>
1021
1022 <para>
1023 With the <emphasis>shared folders</emphasis> feature of
1024 &product-name;, you can access files of your host system from
1025 within the guest system. This is similar to how you would use
1026 network shares in Windows networks, except that shared folders do
1027 not require networking, only the Guest Additions. Shared folders
1028 are supported with Windows 2000 or later, Linux, and Oracle
1029 Solaris guests. &product-name; release 6.0 includes experimental
1030 support for Mac OS X and OS/2 guests.
1031 </para>
1032
1033 <para>
1034 Shared folders physically reside on the <emphasis>host</emphasis>
1035 and are then shared with the guest, which uses a special file
1036 system driver in the Guest Additions to talk to the host. For
1037 Windows guests, shared folders are implemented as a pseudo-network
1038 redirector. For Linux and Oracle Solaris guests, the Guest
1039 Additions provide a virtual file system.
1040 </para>
1041
1042 <para>
1043 To share a host folder with a virtual machine in &product-name;,
1044 you must specify the path of the folder and choose a
1045 <emphasis>share name</emphasis> that the guest can use to access
1046 the shared folder. This happens on the host. In the guest you can
1047 then use the share name to connect to it and access files.
1048 </para>
1049
1050 <para>
1051 There are several ways in which shared folders can be set up for a
1052 virtual machine:
1053 </para>
1054
1055 <itemizedlist>
1056
1057 <listitem>
1058 <para>
1059 In the window of a running VM, you select
1060 <emphasis role="bold">Shared Folders</emphasis> from the
1061 <emphasis role="bold">Devices</emphasis> menu, or click on the
1062 folder icon on the status bar in the bottom right corner.
1063 </para>
1064 </listitem>
1065
1066 <listitem>
1067 <para>
1068 If a VM is not currently running, you can configure shared
1069 folders in the virtual machine's
1070 <emphasis role="bold">Settings</emphasis> dialog.
1071 </para>
1072 </listitem>
1073
1074 <listitem>
1075 <para>
1076 From the command line, you can create shared folders using
1077 <command>VBoxManage</command>, as follows:
1078 </para>
1079
1080<screen>VBoxManage sharedfolder add "VM name" --name "sharename" --hostpath "C:\test"</screen>
1081
1082 <para>
1083 See <xref linkend="vboxmanage-sharedfolder" />.
1084 </para>
1085 </listitem>
1086
1087 </itemizedlist>
1088
1089 <para>
1090 There are two types of shares:
1091 </para>
1092
1093 <itemizedlist>
1094
1095 <listitem>
1096 <para>
1097 Permanent shares, that are saved with the VM settings.
1098 </para>
1099 </listitem>
1100
1101 <listitem>
1102 <para>
1103 Transient shares, that are added at runtime and disappear when
1104 the VM is powered off. These can be created using a checkbox
1105 in the VirtualBox Manager, or by using the
1106 <computeroutput>--transient</computeroutput> option of the
1107 <command>VBoxManage sharedfolder add</command> command.
1108 </para>
1109 </listitem>
1110
1111 </itemizedlist>
1112
1113 <para>
1114 Shared folders can either be read-write or read-only. This means
1115 that the guest is either allowed to both read and write, or just
1116 read files on the host. By default, shared folders are read-write.
1117 Read-only folders can be created using a checkbox in the
1118 VirtualBox Manager, or with the
1119 <computeroutput>--readonly</computeroutput> option of the
1120 <command>VBoxManage sharedfolder add</command> command.
1121 </para>
1122
1123 <para>
1124 &product-name; shared folders also support symbolic links, also
1125 called <emphasis>symlinks</emphasis>, under the following
1126 conditions:
1127 </para>
1128
1129 <itemizedlist>
1130
1131 <listitem>
1132 <para>
1133 The host operating system must support symlinks. For example,
1134 a Mac OS X, Linux, or Oracle Solaris host is required.
1135 </para>
1136 </listitem>
1137
1138 <listitem>
1139 <para>
1140 Currently only Linux and Oracle Solaris Guest Additions
1141 support symlinks.
1142 </para>
1143 </listitem>
1144
1145 <listitem>
1146 <para>
1147 For security reasons the guest OS is not allowed to create
1148 symlinks by default. If you trust the guest OS to not abuse
1149 the functionality, you can enable creation of symlinks for a
1150 shared folder as follows:
1151 </para>
1152
1153<screen>VBoxManage setextradata "VM name" VBoxInternal2/SharedFoldersEnableSymlinksCreate/<replaceable>sharename</replaceable> 1</screen>
1154 </listitem>
1155
1156 </itemizedlist>
1157
1158 <sect2 id="sf_mount_manual">
1159
1160 <title>Manual Mounting</title>
1161
1162 <para>
1163 You can mount the shared folder from inside a VM, in the same
1164 way as you would mount an ordinary network share:
1165 </para>
1166
1167 <itemizedlist>
1168
1169 <listitem>
1170 <para>
1171 In a Windows guest, shared folders are browseable and
1172 therefore visible in Windows Explorer. To attach the host's
1173 shared folder to your Windows guest, open Windows Explorer
1174 and look for the folder in <emphasis role="bold">My
1175 Networking Place</emphasis>s, <emphasis role="bold">Entire
1176 Network</emphasis>, <emphasis role="bold">&product-name;
1177 Shared Folders</emphasis>. By right-clicking on a shared
1178 folder and selecting <emphasis role="bold">Map Network
1179 Drive</emphasis> from the menu that pops up, you can assign
1180 a drive letter to that shared folder.
1181 </para>
1182
1183 <para>
1184 Alternatively, on the Windows command line, use the
1185 following command:
1186 </para>
1187
1188<screen>net use x: \\vboxsvr\sharename</screen>
1189
1190 <para>
1191 While <computeroutput>vboxsvr</computeroutput> is a fixed
1192 name, note that <computeroutput>vboxsrv</computeroutput>
1193 would also work, replace <replaceable>x:</replaceable> with
1194 the drive letter that you want to use for the share, and
1195 <replaceable>sharename</replaceable> with the share name
1196 specified with <command>VBoxManage</command>.
1197 </para>
1198 </listitem>
1199
1200 <listitem>
1201 <para>
1202 In a Linux guest, use the following command:
1203 </para>
1204
1205<screen>mount -t vboxsf [-o OPTIONS] sharename mountpoint</screen>
1206
1207 <para>
1208 To mount a shared folder during boot, add the following
1209 entry to <computeroutput>/etc/fstab</computeroutput>:
1210 </para>
1211
1212<screen>sharename mountpoint vboxsf defaults 0 0</screen>
1213 </listitem>
1214
1215 <listitem>
1216 <para>
1217 In a Oracle Solaris guest, use the following command:
1218 </para>
1219
1220<screen>mount -F vboxfs [-o OPTIONS] sharename mountpoint</screen>
1221
1222 <para>
1223 Replace <replaceable>sharename</replaceable>, use a
1224 lowercase string, with the share name specified with
1225 <command>VBoxManage</command> or the GUI. Replace
1226 <replaceable>mountpoint</replaceable> with the path where
1227 you want the share to be mounted on the guest, such as
1228 <computeroutput>/mnt/share</computeroutput>. The usual mount
1229 rules apply. For example, create this directory first if it
1230 does not exist yet.
1231 </para>
1232
1233 <para>
1234 Here is an example of mounting the shared folder for the
1235 user jack on Oracle Solaris:
1236 </para>
1237
1238<screen>$ id
1239uid=5000(jack) gid=1(other)
1240$ mkdir /export/home/jack/mount
1241$ pfexec mount -F vboxfs -o uid=5000,gid=1 jackshare /export/home/jack/mount
1242$ cd ~/mount
1243$ ls
1244sharedfile1.mp3 sharedfile2.txt
1245$</screen>
1246
1247 <para>
1248 Beyond the standard options supplied by the
1249 <command>mount</command> command, the following are
1250 available:
1251 </para>
1252
1253<screen>iocharset CHARSET</screen>
1254
1255 <para>
1256 This option sets the character set used for I/O operations.
1257 Note that on Linux guests, if the
1258 <computeroutput>iocharset</computeroutput> option is not
1259 specified, then the Guest Additions driver will attempt to
1260 use the character set specified by the CONFIG_NLS_DEFAULT
1261 kernel option. If this option is not set either, then UTF-8
1262 is used.
1263 </para>
1264
1265<screen>convertcp CHARSET</screen>
1266
1267 <para>
1268 This option specifies the character set used for the shared
1269 folder name. This is UTF-8 by default.
1270 </para>
1271
1272 <para>
1273 The generic mount options, documented in the
1274 <computeroutput>mount</computeroutput> manual page, apply
1275 also. Especially useful are the options
1276 <computeroutput>uid</computeroutput>,
1277 <computeroutput>gid</computeroutput> and
1278 <computeroutput>mode</computeroutput>, as they can allow
1279 access by normal users in read/write mode, depending on the
1280 settings, even if root has mounted the filesystem.
1281 </para>
1282 </listitem>
1283
1284 <listitem>
1285 <para>
1286 In an OS/2 guest, use the <command>VBoxControl</command>
1287 command to manage shared folders. For example:
1288 </para>
1289
1290<screen>VBoxControl sharedfolder use D: MyShareName
1291VBoxControl sharedfolder unuse D:
1292VBoxControl sharedfolder list</screen>
1293
1294 <para>
1295 As with Windows guests, shared folders can also be accessed
1296 via UNC using <computeroutput>\\VBoxSF\</computeroutput>,
1297 <computeroutput>\\VBoxSvr\</computeroutput> or
1298 <computeroutput>\\VBoxSrv\</computeroutput> as the server
1299 name and the shared folder name as
1300 <replaceable>sharename</replaceable>.
1301 </para>
1302 </listitem>
1303
1304 </itemizedlist>
1305
1306 </sect2>
1307
1308 <sect2 id="sf_mount_auto">
1309
1310 <title>Automatic Mounting</title>
1311
1312 <para>
1313 &product-name; provides the option to mount shared folders
1314 automatically. When automatic mounting is enabled for a shared
1315 folder, the Guest Additions service will mount it for you
1316 automatically. For Windows or OS/2, a preferred drive letter can
1317 also be specified. For Linux or Oracle Solaris, a mount point
1318 directory can also be specified.
1319 </para>
1320
1321 <para>
1322 If a drive letter or mount point is not specified, or is in use
1323 already, an alternative location is found by the Guest Additions
1324 service. The service searches for an alternative location
1325 depending on the guest OS, as follows:
1326 </para>
1327
1328 <itemizedlist>
1329
1330 <listitem>
1331 <para>
1332 <emphasis role="bold">Windows and OS/2 guests.</emphasis>
1333 Search for a free drive letter, starting at
1334 <computeroutput>Z:</computeroutput>. If all drive letters
1335 are assigned, the folder is not mounted.
1336 </para>
1337 </listitem>
1338
1339 <listitem>
1340 <para>
1341 <emphasis role="bold">Linux and Oracle Solaris
1342 guests.</emphasis> Folders are mounted under the
1343 <computeroutput>/media</computeroutput> directory. The
1344 folder name is normalized (no spaces, slashes or colons) and
1345 is prefixed with <computeroutput>sf_</computeroutput>.
1346 </para>
1347
1348 <para>
1349 For example, if you have a shared folder called
1350 <computeroutput>myfiles</computeroutput>, it will appear as
1351 <computeroutput>/media/sf_myfiles</computeroutput> in the
1352 guest.
1353 </para>
1354
1355 <para>
1356 The guest properties
1357 <computeroutput>/VirtualBox/GuestAdd/SharedFolders/MountDir</computeroutput>
1358 and the more generic
1359 <computeroutput>/VirtualBox/GuestAdd/SharedFolders/MountPrefix</computeroutput>
1360 can be used to override the automatic mount directory and
1361 prefix. See <xref linkend="guestadd-guestprops" />.
1362 </para>
1363 </listitem>
1364
1365 </itemizedlist>
1366
1367 <para>
1368 Access to an automatically mounted shared folder is granted to
1369 everyone in a Windows guest, including the guest user. For Linux
1370 and Oracle Solaris guests, access is restricted to members of
1371 the group <computeroutput>vboxsf</computeroutput> and the
1372 <computeroutput>root</computeroutput> user.
1373 </para>
1374
1375 </sect2>
1376
1377 </sect1>
1378
1379 <sect1 id="guestadd-dnd">
1380
1381 <title>Drag and Drop</title>
1382
1383 <para>
1384 &product-name; enables you to drag and drop content from the host
1385 to the guest, and vice versa. For this to work the latest Guest
1386 Additions must be installed on the guest.
1387 </para>
1388
1389 <para>
1390 Drag and drop transparently allows copying or opening files,
1391 directories, and even certain clipboard formats from one end to
1392 the other. For example, from the host to the guest or from the
1393 guest to the host. You then can perform drag and drop operations
1394 between the host and a VM, as it would be a native drag and drop
1395 operation on the host OS.
1396 </para>
1397
1398 <para>
1399 At the moment drag and drop is implemented for Windows-based and
1400 X-Windows-based systems, both on the host and guest side. As
1401 X-Windows supports many different drag and drop protocols only the
1402 most common one, XDND, is supported for now. Applications using
1403 other protocols, such as Motif or OffiX, will not be recognized by
1404 &product-name;.
1405 </para>
1406
1407 <para>
1408 In the context of using drag and drop, the origin of the data is
1409 called the <emphasis>source</emphasis>. That is, where the actual
1410 data comes from and is specified. The <emphasis>target</emphasis>
1411 specifies where the data from the source should go to.
1412 Transferring data from the source to the target can be done in
1413 various ways, such as copying, moving, or linking.
1414 </para>
1415
1416 <note>
1417 <para>
1418 At the moment only copying of data is supported. Moving or
1419 linking is not yet implemented.
1420 </para>
1421 </note>
1422
1423 <para>
1424 When transferring data from the host to the guest OS, the host in
1425 this case is the source, whereas the guest OS is the target.
1426 However, when transferring data from the guest OS to the host, the
1427 guest OS this time became the source and the host is the target.
1428 </para>
1429
1430 <para>
1431 For security reasons drag and drop can be configured at runtime on
1432 a per-VM basis either using the <emphasis role="bold">Drag and
1433 Drop</emphasis> menu item in the
1434 <emphasis role="bold">Devices</emphasis> menu of the virtual
1435 machine, as shown below, or the <command>VBoxManage</command>
1436 command.
1437 </para>
1438
1439 <figure id="fig-drag-drop-options">
1440 <title>Drag and Drop Menu Options</title>
1441 <mediaobject>
1442 <imageobject>
1443 <imagedata align="center" fileref="images/dnd-modes.png"
1444 width="10cm" />
1445 </imageobject>
1446 </mediaobject>
1447 </figure>
1448
1449 <para>
1450 The following drag and drop modes are available:
1451 </para>
1452
1453 <itemizedlist>
1454
1455 <listitem>
1456 <para>
1457 <emphasis role="bold">Disabled.</emphasis> Disables the drag
1458 and drop feature entirely. This is the default when creating a
1459 new VM.
1460 </para>
1461 </listitem>
1462
1463 <listitem>
1464 <para>
1465 <emphasis role="bold">Host To Guest.</emphasis> Enables drag
1466 and drop operations from the host to the guest only.
1467 </para>
1468 </listitem>
1469
1470 <listitem>
1471 <para>
1472 <emphasis role="bold">Guest To Host.</emphasis> Enables drag
1473 and drop operations from the guest to the host only.
1474 </para>
1475 </listitem>
1476
1477 <listitem>
1478 <para>
1479 <emphasis role="bold">Bidirectional.</emphasis> Enables drag
1480 and drop operations in both directions: from the host to the
1481 guest, and from the guest to the host.
1482 </para>
1483 </listitem>
1484
1485 </itemizedlist>
1486
1487 <note>
1488 <para>
1489 Drag and drop support depends on the frontend being used. At the
1490 moment, only the VirtualBox Manager frontend provides this
1491 functionality.
1492 </para>
1493 </note>
1494
1495 <para>
1496 To use the <command>VBoxManage</command> command to control the
1497 current drag and drop mode, see <xref linkend="vboxmanage" />. The
1498 <command>modifyvm</command> and <command>controlvm</command>
1499 commands enable setting of a VM's current drag and drop mode from
1500 the command line.
1501 </para>
1502
1503 <sect2 id="guestadd-dnd-formats">
1504
1505 <title>Supported Formats</title>
1506
1507 <para>
1508 As &product-name; can run on a variety of host operating systems
1509 and also supports a wide range of guests, certain data formats
1510 must be translated after transfer. This is so that the target
1511 operating system, which receiving the data, is able to handle
1512 them in an appropriate manner.
1513 </para>
1514
1515 <note>
1516 <para>
1517 When dragging files no data conversion is done in any way. For
1518 example, when transferring a file from a Linux guest to a
1519 Windows host the Linux-specific line endings are not converted
1520 to Windows line endings.
1521 </para>
1522 </note>
1523
1524 <para>
1525 The following formats are handled by the &product-name; drag and
1526 drop service:
1527 </para>
1528
1529 <itemizedlist>
1530
1531 <listitem>
1532 <para>
1533 <emphasis role="bold">Plain text:</emphasis> From
1534 applications such as text editors, internet browsers and
1535 terminal windows.
1536 </para>
1537 </listitem>
1538
1539 <listitem>
1540 <para>
1541 <emphasis role="bold">Files:</emphasis> From file managers
1542 such as Windows Explorer, Nautilus, and Finder.
1543 </para>
1544 </listitem>
1545
1546 <listitem>
1547 <para>
1548 <emphasis role="bold">Directories:</emphasis> For
1549 directories, the same formats apply as for files.
1550 </para>
1551 </listitem>
1552
1553 </itemizedlist>
1554
1555 </sect2>
1556
1557 <sect2 id="guestadd-dnd-limitations">
1558
1559 <title>Known Limitations</title>
1560
1561 <para>
1562 The following limitations are known for drag and drop:
1563 </para>
1564
1565 <para>
1566 On Windows hosts, dragging and dropping content between
1567 UAC-elevated (User Account Control) programs and
1568 non-UAC-elevated programs is not allowed. If you start
1569 &product-name; with Administrator privileges then drag and drop
1570 will not work with Windows Explorer, which runs with regular
1571 user privileges by default.
1572 </para>
1573
1574 </sect2>
1575
1576 </sect1>
1577
1578 <sect1 id="guestadd-video">
1579
1580 <title>Hardware-Accelerated Graphics</title>
1581
1582 <sect2 id="guestadd-3d">
1583
1584 <title>Hardware 3D Acceleration (OpenGL and Direct3D 8/9)</title>
1585
1586 <para>
1587 The &product-name; Guest Additions contain experimental hardware
1588 3D support for Windows, Linux, and Oracle Solaris guests.
1589 </para>
1590
1591 <para>
1592 With this feature, if an application inside your virtual machine
1593 uses 3D features through the OpenGL or Direct3D 8/9 programming
1594 interfaces, instead of emulating them in software, which would
1595 be slow, &product-name; will attempt to use your host's 3D
1596 hardware. This works for all supported host platforms, provided
1597 that your host operating system can make use of your accelerated
1598 3D hardware in the first place.
1599 </para>
1600
1601 <para>
1602 The 3D acceleration feature currently has the following
1603 preconditions:
1604 </para>
1605
1606 <itemizedlist>
1607
1608 <listitem>
1609 <para>
1610 It is only available for certain Windows, Linux, and Oracle
1611 Solaris guests. In particular:
1612 </para>
1613
1614 <itemizedlist>
1615
1616 <listitem>
1617 <para>
1618 3D acceleration with Windows guests requires Windows
1619 2000, Windows XP, Vista, or Windows 7. Apart from on
1620 Windows 2000 guests, both OpenGL and Direct3D 8/9 are
1621 supported on an experimental basis.
1622 </para>
1623 </listitem>
1624
1625 <listitem>
1626 <para>
1627 OpenGL on Linux requires kernel 2.6.27 or later, as well
1628 as X.org server version 1.5 or later. Ubuntu 10.10 and
1629 Fedora 14 have been tested and confirmed as working.
1630 </para>
1631 </listitem>
1632
1633 <listitem>
1634 <para>
1635 OpenGL on Oracle Solaris guests requires X.org server
1636 version 1.5 or later.
1637 </para>
1638 </listitem>
1639
1640 </itemizedlist>
1641 </listitem>
1642
1643 <listitem>
1644 <para>
1645 The Guest Additions must be installed.
1646 </para>
1647
1648 <note>
1649 <para>
1650 For the basic Direct3D acceleration to work in a Windows
1651 Guest, &product-name; needs to replace Windows system
1652 files in the virtual machine. As a result, the Guest
1653 Additions installation program offers Direct3D
1654 acceleration as an option that must be explicitly enabled.
1655 Also, you must install the Guest Additions in Safe Mode.
1656 This does <emphasis>not</emphasis> apply to the WDDM
1657 Direct3D video driver available for Windows Vista and
1658 later. See <xref linkend="KnownIssues" /> for details.
1659 </para>
1660 </note>
1661 </listitem>
1662
1663 <listitem>
1664 <para>
1665 Because 3D support is still experimental at this time, it is
1666 disabled by default and must be <emphasis>manually
1667 enabled</emphasis> in the VM settings. See
1668 <xref linkend="settings-display" />.
1669 </para>
1670
1671 <note>
1672 <para>
1673 Untrusted guest systems should not be allowed to use the
1674 3D acceleration features of &product-name;, just as
1675 untrusted host software should not be allowed to use 3D
1676 acceleration. Drivers for 3D hardware are generally too
1677 complex to be made properly secure and any software which
1678 is allowed to access them may be able to compromise the
1679 operating system running them. In addition, enabling 3D
1680 acceleration gives the guest direct access to a large body
1681 of additional program code in the &product-name; host
1682 process which it might conceivably be able to use to crash
1683 the virtual machine.
1684 </para>
1685 </note>
1686 </listitem>
1687
1688 </itemizedlist>
1689
1690 <para>
1691 To enable Aero theme support, the &product-name; WDDM video
1692 driver must be installed, which is available with the Guest
1693 Additions installation. The WDDM driver is not installed by
1694 default for Vista and Windows 7 guest and must be
1695 <emphasis>manually selected</emphasis> in the Guest Additions
1696 installer by clicking <emphasis role="bold">No</emphasis> in the
1697 <emphasis role="bold">Would You Like to Install Basic Direct3D
1698 Support</emphasis> dialog displayed when the Direct3D feature is
1699 selected.
1700 </para>
1701
1702 <para>
1703 The Aero theme is not enabled by default. To enable it, do the
1704 following:
1705 </para>
1706
1707 <itemizedlist>
1708
1709 <listitem>
1710 <para>
1711 <emphasis role="bold">Windows Vista guests:</emphasis>
1712 Right-click on the desktop and select
1713 <emphasis role="bold">Personalize</emphasis>, then select
1714 <emphasis role="bold">Windows Color and
1715 Appearance</emphasis> in the
1716 <emphasis role="bold">Personalization</emphasis> window. In
1717 the <emphasis role="bold">Appearance Settings</emphasis>
1718 dialog, select <emphasis role="bold">Windows Aero</emphasis>
1719 and click <emphasis role="bold">OK</emphasis>.
1720 </para>
1721 </listitem>
1722
1723 <listitem>
1724 <para>
1725 <emphasis role="bold">Windows 7 guests:</emphasis>
1726 Right-click on the desktop and select
1727 <emphasis role="bold">Personalize</emphasis>. Select any
1728 Aero theme in the
1729 <emphasis role="bold">Personalization</emphasis> window.
1730 </para>
1731 </listitem>
1732
1733 </itemizedlist>
1734
1735 <para>
1736 Technically, &product-name; implements this by installing an
1737 additional hardware 3D driver inside your guest when the Guest
1738 Additions are installed. This driver acts as a hardware 3D
1739 driver and reports to the guest operating system that the
1740 virtual hardware is capable of 3D hardware acceleration. When an
1741 application in the guest then requests hardware acceleration
1742 through the OpenGL or Direct3D programming interfaces, these are
1743 sent to the host through a special communication tunnel
1744 implemented by &product-name;, and then the
1745 <emphasis>host</emphasis> performs the requested 3D operation
1746 using the host's programming interfaces.
1747 </para>
1748
1749 </sect2>
1750
1751 <sect2 id="guestadd-2d">
1752
1753 <title>Hardware 2D Video Acceleration for Windows Guests</title>
1754
1755 <para>
1756 The &product-name; Guest Additions contain experimental hardware
1757 2D video acceleration support for Windows guests.
1758 </para>
1759
1760 <para>
1761 With this feature, if an application such as a video player
1762 inside your Windows VM uses 2D video overlays to play a movie
1763 clip, then &product-name; will attempt to use your host's video
1764 acceleration hardware instead of performing overlay stretching
1765 and color conversion in software, which would be slow. This
1766 currently works for Windows, Linux and Mac OS X host platforms,
1767 provided that your host operating system can make use of 2D
1768 video acceleration in the first place.
1769 </para>
1770
1771 <para>
1772 Hardware 2D video acceleration currently has the following
1773 preconditions:
1774 </para>
1775
1776 <itemizedlist>
1777
1778 <listitem>
1779 <para>
1780 Only available for Windows guests, running Windows XP or
1781 later.
1782 </para>
1783 </listitem>
1784
1785 <listitem>
1786 <para>
1787 Guest Additions must be installed.
1788 </para>
1789 </listitem>
1790
1791 <listitem>
1792 <para>
1793 Because 2D support is still experimental at this time, it is
1794 disabled by default and must be <emphasis>manually
1795 enabled</emphasis> in the VM settings. See
1796 <xref linkend="settings-display" />.
1797 </para>
1798 </listitem>
1799
1800 </itemizedlist>
1801
1802 <para>
1803 Technically, &product-name; implements this by exposing video
1804 overlay DirectDraw capabilities in the Guest Additions video
1805 driver. The driver sends all overlay commands to the host
1806 through a special communication tunnel implemented by
1807 &product-name;. On the host side, OpenGL is then used to
1808 implement color space transformation and scaling
1809 </para>
1810
1811 </sect2>
1812
1813 </sect1>
1814
1815 <sect1 id="seamlesswindows">
1816
1817 <title>Seamless Windows</title>
1818
1819 <para>
1820 With the <emphasis>seamless windows</emphasis> feature of
1821 &product-name;, you can have the windows that are displayed within
1822 a virtual machine appear side by side next to the windows of your
1823 host. This feature is supported for the following guest operating
1824 systems, provided that the Guest Additions are installed:
1825 </para>
1826
1827 <itemizedlist>
1828
1829 <listitem>
1830 <para>
1831 Windows guests. Support was added in &product-name; 1.5.
1832 </para>
1833 </listitem>
1834
1835 <listitem>
1836 <para>
1837 Supported Linux or Oracle Solaris guests running the X Window
1838 System. Support was added with &product-name; 1.6.
1839 </para>
1840 </listitem>
1841
1842 </itemizedlist>
1843
1844 <para>
1845 After seamless windows are enabled, &product-name; suppresses the
1846 display of the desktop background of your guest, allowing you to
1847 run the windows of your guest operating system seamlessly next to
1848 the windows of your host.
1849 </para>
1850
1851 <figure id="fig-seamless-windows">
1852 <title>Seamless Windows on a Host Desktop</title>
1853 <mediaobject>
1854 <imageobject>
1855 <imagedata align="center" fileref="images/seamless.png" width="14cm" />
1856 </imageobject>
1857 </mediaobject>
1858 </figure>
1859
1860 <para>
1861 To enable seamless mode, after starting the virtual machine, press
1862 the <emphasis role="bold">Host key + L</emphasis>. The Host key is
1863 normally the right control key. This will enlarge the size of the
1864 VM's display to the size of your host screen and mask out the
1865 guest operating system's background. To disable seamless windows
1866 and go back to the normal VM display, press the Host key + L
1867 again.
1868 </para>
1869
1870 </sect1>
1871
1872 <sect1 id="guestadd-guestprops">
1873
1874 <title>Guest Properties</title>
1875
1876 <para>
1877 &product-name; enables requests of some properties from a running
1878 guest, provided that the &product-name; Guest Additions are
1879 installed and the VM is running. This provides the following
1880 advantages:
1881 </para>
1882
1883 <itemizedlist>
1884
1885 <listitem>
1886 <para>
1887 A number of predefined VM characteristics are automatically
1888 maintained by &product-name; and can be retrieved on the host.
1889 For example, to monitor VM performance and statistics.
1890 </para>
1891 </listitem>
1892
1893 <listitem>
1894 <para>
1895 Arbitrary string data can be exchanged between guest and host.
1896 This works in both directions.
1897 </para>
1898 </listitem>
1899
1900 </itemizedlist>
1901
1902 <para>
1903 To accomplish this, &product-name; establishes a private
1904 communication channel between the &product-name; Guest Additions
1905 and the host, and software on both sides can use this channel to
1906 exchange string data for arbitrary purposes. Guest properties are
1907 simply string keys to which a value is attached. They can be set,
1908 or written to, by either the host and the guest. They can also be
1909 read from both sides.
1910 </para>
1911
1912 <para>
1913 In addition to establishing the general mechanism of reading and
1914 writing values, a set of predefined guest properties is
1915 automatically maintained by the &product-name; Guest Additions to
1916 allow for retrieving interesting guest data such as the guest's
1917 exact operating system and service pack level, the installed
1918 version of the Guest Additions, users that are currently logged
1919 into the guest OS, network statistics and more. These predefined
1920 properties are all prefixed with
1921 <computeroutput>/VirtualBox/</computeroutput> and organized into a
1922 hierarchical tree of keys.
1923 </para>
1924
1925 <para>
1926 Some of this runtime information is shown when you select
1927 <emphasis role="bold">Session Information Dialog</emphasis> from a
1928 virtual machine's <emphasis role="bold">Machine</emphasis> menu.
1929 </para>
1930
1931 <para>
1932 A more flexible way to use this channel is with the
1933 <command>VBoxManage guestproperty</command> command. See
1934 <xref linkend="vboxmanage-guestproperty" />. For example, to have
1935 <emphasis>all</emphasis> the available guest properties for a
1936 given running VM listed with their respective values, use this
1937 command:
1938 </para>
1939
1940<screen>$ VBoxManage guestproperty enumerate "Windows Vista III"
1941VirtualBox Command Line Management Interface Version <replaceable>version-number</replaceable>
1942(C) 2005-2018 Oracle Corporation
1943All rights reserved.
1944
1945Name: /VirtualBox/GuestInfo/OS/Product, value: Windows Vista Business Edition,
1946 timestamp: 1229098278843087000, flags:
1947Name: /VirtualBox/GuestInfo/OS/Release, value: 6.0.6001,
1948 timestamp: 1229098278950553000, flags:
1949Name: /VirtualBox/GuestInfo/OS/ServicePack, value: 1,
1950 timestamp: 1229098279122627000, flags:
1951Name: /VirtualBox/GuestAdd/InstallDir,
1952 value: C:/Program Files/Oracle/VirtualBox
1953 Guest Additions, timestamp: 1229098279269739000, flags:
1954Name: /VirtualBox/GuestAdd/Revision, value: 40720,
1955 timestamp: 1229098279345664000, flags:
1956Name: /VirtualBox/GuestAdd/Version, value: <replaceable>version-number</replaceable>,
1957 timestamp: 1229098279479515000, flags:
1958Name: /VirtualBox/GuestAdd/Components/VBoxControl.exe, value: <replaceable>version-number</replaceable>r40720,
1959 timestamp: 1229098279651731000, flags:
1960Name: /VirtualBox/GuestAdd/Components/VBoxHook.dll, value: <replaceable>version-number</replaceable>r40720,
1961 timestamp: 1229098279804835000, flags:
1962Name: /VirtualBox/GuestAdd/Components/VBoxDisp.dll, value: <replaceable>version-number</replaceable>r40720,
1963 timestamp: 1229098279880611000, flags:
1964Name: /VirtualBox/GuestAdd/Components/VBoxMRXNP.dll, value: <replaceable>version-number</replaceable>r40720,
1965 timestamp: 1229098279882618000, flags:
1966Name: /VirtualBox/GuestAdd/Components/VBoxService.exe, value: <replaceable>version-number</replaceable>r40720,
1967 timestamp: 1229098279883195000, flags:
1968Name: /VirtualBox/GuestAdd/Components/VBoxTray.exe, value: <replaceable>version-number</replaceable>r40720,
1969 timestamp: 1229098279885027000, flags:
1970Name: /VirtualBox/GuestAdd/Components/VBoxGuest.sys, value: <replaceable>version-number</replaceable>r40720,
1971 timestamp: 1229098279886838000, flags:
1972Name: /VirtualBox/GuestAdd/Components/VBoxMouse.sys, value: <replaceable>version-number</replaceable>r40720,
1973 timestamp: 1229098279890600000, flags:
1974Name: /VirtualBox/GuestAdd/Components/VBoxSF.sys, value: <replaceable>version-number</replaceable>r40720,
1975 timestamp: 1229098279893056000, flags:
1976Name: /VirtualBox/GuestAdd/Components/VBoxVideo.sys, value: <replaceable>version-number</replaceable>r40720,
1977 timestamp: 1229098279895767000, flags:
1978Name: /VirtualBox/GuestInfo/OS/LoggedInUsers, value: 1,
1979 timestamp: 1229099826317660000, flags:
1980Name: /VirtualBox/GuestInfo/OS/NoLoggedInUsers, value: false,
1981 timestamp: 1229098455580553000, flags:
1982Name: /VirtualBox/GuestInfo/Net/Count, value: 1,
1983 timestamp: 1229099826299785000, flags:
1984Name: /VirtualBox/HostInfo/GUI/LanguageID, value: C,
1985 timestamp: 1229098151272771000, flags:
1986Name: /VirtualBox/GuestInfo/Net/0/V4/IP, value: 192.168.2.102,
1987 timestamp: 1229099826300088000, flags:
1988Name: /VirtualBox/GuestInfo/Net/0/V4/Broadcast, value: 255.255.255.255,
1989 timestamp: 1229099826300220000, flags:
1990Name: /VirtualBox/GuestInfo/Net/0/V4/Netmask, value: 255.255.255.0,
1991 timestamp: 1229099826300350000, flags:
1992Name: /VirtualBox/GuestInfo/Net/0/Status, value: Up,
1993 timestamp: 1229099826300524000, flags:
1994Name: /VirtualBox/GuestInfo/OS/LoggedInUsersList, value: username,
1995 timestamp: 1229099826317386000, flags:</screen>
1996
1997 <para>
1998 To query the value of a single property, use the
1999 <computeroutput>get</computeroutput> subcommand as follows:
2000 </para>
2001
2002<screen>$ VBoxManage guestproperty get "Windows Vista III" "/VirtualBox/GuestInfo/OS/Product"
2003VirtualBox Command Line Management Interface Version <replaceable>version-number</replaceable>
2004(C) 2005-2018 Oracle Corporation
2005All rights reserved.
2006
2007Value: Windows Vista Business Edition</screen>
2008
2009 <para>
2010 To add or change guest properties from the guest, use the tool
2011 <computeroutput>VBoxControl</computeroutput>. This tool is
2012 included in the Guest Additions of &product-name; 2.2 or later.
2013 When started from a Linux guest, this tool requires root
2014 privileges for security reasons:
2015 </para>
2016
2017<screen>$ sudo VBoxControl guestproperty enumerate
2018VirtualBox Guest Additions Command Line Management Interface Version <replaceable>version-number</replaceable>
2019(C) 2005-2018 Oracle Corporation
2020All rights reserved.
2021
2022Name: /VirtualBox/GuestInfo/OS/Release, value: 2.6.28-18-generic,
2023 timestamp: 1265813265835667000, flags: &lt;NULL&gt;
2024Name: /VirtualBox/GuestInfo/OS/Version, value: #59-Ubuntu SMP Thu Jan 28 01:23:03 UTC 2010,
2025 timestamp: 1265813265836305000, flags: &lt;NULL&gt;
2026 ...</screen>
2027
2028 <para>
2029 For more complex needs, you can use the &product-name; programming
2030 interfaces. See <xref linkend="VirtualBoxAPI" />.
2031 </para>
2032
2033 <sect2 id="guestadd-guestprops-waits">
2034
2035 <title>Using Guest Properties to Wait on VM Events</title>
2036
2037 <para>
2038 The properties
2039 <computeroutput>/VirtualBox/HostInfo/VBoxVer</computeroutput>,
2040 <computeroutput>/VirtualBox/HostInfo/VBoxVerExt</computeroutput>
2041 or <computeroutput>/VirtualBox/HostInfo/VBoxRev</computeroutput>
2042 can be waited on to detect that the VM state was restored from
2043 saved state or snapshot:
2044 </para>
2045
2046<screen>$ VBoxControl guestproperty wait /VirtualBox/HostInfo/VBoxVer</screen>
2047
2048 <para>
2049 Similarly the
2050 <computeroutput>/VirtualBox/HostInfo/ResumeCounter</computeroutput>
2051 can be used to detect that a VM was resumed from the paused
2052 state or saved state.
2053 </para>
2054
2055 </sect2>
2056
2057 </sect1>
2058
2059 <sect1 id="guestadd-gc-file-manager">
2060
2061 <title>Guest Control File Manager</title>
2062
2063 <para>
2064 The Guest Control File Manager is a feature of the Guest Additions
2065 that enables easy copying and moving of files between a guest and
2066 the host system. Other file management operations provide support
2067 to create new folders and to rename or delete files.
2068 </para>
2069
2070 <figure id="fig-guest-control-fm">
2071 <title>Guest Control File Manager</title>
2072 <mediaobject>
2073 <imageobject>
2074 <imagedata align="center" fileref="images/guest-fm.png"
2075 width="12cm" />
2076 </imageobject>
2077 </mediaobject>
2078 </figure>
2079
2080 <para>
2081 The Guest Control File Manager works by mounting the host file
2082 system. Guest users must authenticate and create a guest session
2083 before they can transfer files.
2084 </para>
2085
2086 <sect2 id="guestadd-gc-file-manager-using">
2087
2088 <title>Using the Guest Control File Manager</title>
2089
2090 <para>
2091 The following steps describe how to use the Guest Control File
2092 Manager.
2093 </para>
2094
2095 <orderedlist>
2096
2097 <listitem>
2098 <para>
2099 Open the Guest Control File Manager.
2100 </para>
2101
2102 <para>
2103 In the guest VM, select
2104 <emphasis role="bold">Machine</emphasis>,
2105 <emphasis role="bold">File Manager</emphasis>.
2106 </para>
2107
2108 <para>
2109 The left pane shows the files on the host system.
2110 </para>
2111 </listitem>
2112
2113 <listitem>
2114 <para>
2115 Create a guest session.
2116 </para>
2117
2118 <para>
2119 At the bottom of the Guest Control File Manager, enter
2120 authentication credentials for a user on the guest system.
2121 </para>
2122
2123 <para>
2124 Click <emphasis role="bold">Create Session</emphasis>.
2125 </para>
2126
2127 <para>
2128 The contents of the guest VM file system appears in the
2129 right pane of the Guest Control File Manager.
2130 </para>
2131 </listitem>
2132
2133 <listitem>
2134 <para>
2135 Transfer files between the guest and the host system by
2136 using the move and copy file transfer icons.
2137 </para>
2138
2139 <para>
2140 You can copy and move files from a guest to the host system
2141 or from the host system to the guest.
2142 </para>
2143 </listitem>
2144
2145 <listitem>
2146 <para>
2147 Close the Guest Control File Manager.
2148 </para>
2149
2150 <para>
2151 Click <emphasis role="bold">Close</emphasis> to end the
2152 guest session.
2153 </para>
2154 </listitem>
2155
2156 </orderedlist>
2157
2158 </sect2>
2159
2160 </sect1>
2161
2162 <sect1 id="guestadd-guestcontrol">
2163
2164 <title>Guest Control of Applications</title>
2165
2166 <para>
2167 The Guest Additions enable starting of applications inside a VM
2168 from the host system.
2169 </para>
2170
2171 <para>
2172 For this to work, the application needs to be installed inside the
2173 guest. No additional software needs to be installed on the host.
2174 Additionally, text mode output to stdout and stderr can be shown
2175 on the host for further processing. There are options to specify
2176 user credentials and a timeout value, in milliseconds, to limit
2177 the time the application is able to run.
2178 </para>
2179
2180 <para>
2181 This feature can be used to automate deployment of software within
2182 the guest.
2183 </para>
2184
2185 <para>
2186 The Guest Additions for Windows allow for automatic updating. This
2187 applies for already installed Guest Additions version 4.0 or
2188 later. Also, copying files from host to the guest as well as
2189 remotely creating guest directories is available.
2190 </para>
2191
2192 <para>
2193 To use these features, use the &product-name; command line. See
2194 <xref linkend="vboxmanage-guestcontrol" />.
2195 </para>
2196
2197 </sect1>
2198
2199 <sect1 id="guestadd-memory-usage">
2200
2201 <title>Memory Overcommitment</title>
2202
2203 <para>
2204 In server environments with many VMs, the Guest Additions can be
2205 used to share physical host memory between several VMs. This
2206 reduces the total amount of memory in use by the VMs. If memory
2207 usage is the limiting factor and CPU resources are still
2208 available, this can help with running more VMs on each host.
2209 </para>
2210
2211 <sect2 id="guestadd-balloon">
2212
2213 <title>Memory Ballooning</title>
2214
2215 <para>
2216 The Guest Additions can change the amount of host memory that a
2217 VM uses, while the machine is running. Because of how this is
2218 implemented, this feature is called <emphasis>memory
2219 ballooning</emphasis>.
2220 </para>
2221
2222 <note>
2223 <itemizedlist>
2224
2225 <listitem>
2226 <para>
2227 &product-name; supports memory ballooning only on 64-bit
2228 hosts. It is not supported on Mac OS X hosts.
2229 </para>
2230 </listitem>
2231
2232 <listitem>
2233 <para>
2234 Memory ballooning does not work with large pages enabled.
2235 To turn off large pages support for a VM, run
2236 <computeroutput>VBoxManage modifyvm &lt;VM name&gt;
2237 --largepages off</computeroutput>
2238 </para>
2239 </listitem>
2240
2241 </itemizedlist>
2242 </note>
2243
2244 <para>
2245 Normally, to change the amount of memory allocated to a virtual
2246 machine, you have to shut down the virtual machine entirely and
2247 modify its settings. With memory ballooning, memory that was
2248 allocated for a virtual machine can be given to another virtual
2249 machine without having to shut the machine down.
2250 </para>
2251
2252 <para>
2253 When memory ballooning is requested, the &product-name; Guest
2254 Additions, which run inside the guest, allocate physical memory
2255 from the guest operating system on the kernel level and lock
2256 this memory down in the guest. This ensures that the guest will
2257 not use that memory any longer. No guest applications can
2258 allocate it, and the guest kernel will not use it either.
2259 &product-name; can then reuse this memory and give it to another
2260 virtual machine.
2261 </para>
2262
2263 <para>
2264 The memory made available through the ballooning mechanism is
2265 only available for reuse by &product-name;. It is
2266 <emphasis>not</emphasis> returned as free memory to the host.
2267 Requesting balloon memory from a running guest will therefore
2268 not increase the amount of free, unallocated memory on the host.
2269 Effectively, memory ballooning is therefore a memory
2270 overcommitment mechanism for multiple virtual machines while
2271 they are running. This can be useful to temporarily start
2272 another machine, or in more complicated environments, for
2273 sophisticated memory management of many virtual machines that
2274 may be running in parallel depending on how memory is used by
2275 the guests.
2276 </para>
2277
2278 <para>
2279 At this time, memory ballooning is only supported through
2280 <command>VBoxManage</command>. Use the following command to
2281 increase or decrease the size of the memory balloon within a
2282 running virtual machine that has Guest Additions installed:
2283 </para>
2284
2285<screen>VBoxManage controlvm "VM name" guestmemoryballoon n</screen>
2286
2287 <para>
2288 where <replaceable>VM name</replaceable> is the name or UUID of
2289 the virtual machine in question and <replaceable>n</replaceable>
2290 is the amount of memory to allocate from the guest in megabytes.
2291 See <xref
2292 linkend="vboxmanage-controlvm" />.
2293 </para>
2294
2295 <para>
2296 You can also set a default balloon that will automatically be
2297 requested from the VM every time after it has started up with
2298 the following command:
2299 </para>
2300
2301<screen>VBoxManage modifyvm "VM name" --guestmemoryballoon n</screen>
2302
2303 <para>
2304 By default, no balloon memory is allocated. This is a VM
2305 setting, like other <computeroutput>modifyvm</computeroutput>
2306 settings, and therefore can only be set while the machine is
2307 shut down. See <xref
2308 linkend="vboxmanage-modifyvm" />.
2309 </para>
2310
2311 </sect2>
2312
2313 <sect2 id="guestadd-pagefusion">
2314
2315 <title>Page Fusion</title>
2316
2317 <para>
2318 Whereas memory ballooning simply reduces the amount of RAM that
2319 is available to a VM, Page Fusion works differently. It avoids
2320 memory duplication between several similar running VMs.
2321 </para>
2322
2323 <para>
2324 In a server environment running several similar VMs on the same
2325 host, lots of memory pages are identical. For example, if the
2326 VMs are using identical operating systems. &product-name;'s Page
2327 Fusion technology can efficiently identify these identical
2328 memory pages and share them between multiple VMs.
2329 </para>
2330
2331 <note>
2332 <para>
2333 &product-name; supports Page Fusion only on 64-bit hosts, and
2334 it is not supported on Mac OS X hosts. Page Fusion currently
2335 works only with Windows 2000 and later guests.
2336 </para>
2337 </note>
2338
2339 <para>
2340 The more similar the VMs on a given host are, the more
2341 efficiently Page Fusion can reduce the amount of host memory
2342 that is in use. It therefore works best if all VMs on a host run
2343 identical operating systems, such as Windows XP Service Pack 2.
2344 Instead of having a complete copy of each operating system in
2345 each VM, Page Fusion identifies the identical memory pages in
2346 use by these operating systems and eliminates the duplicates,
2347 sharing host memory between several machines. This is called
2348 <emphasis>deduplication</emphasis>. If a VM tries to modify a
2349 page that has been shared with other VMs, a new page is
2350 allocated again for that VM with a copy of the shared page. This
2351 is called <emphasis>copy on write</emphasis>. All this is fully
2352 transparent to the virtual machine.
2353 </para>
2354
2355 <para>
2356 You may be familiar with this kind of memory overcommitment from
2357 other hypervisor products, which call this feature
2358 <emphasis>page sharing</emphasis> or <emphasis>same page
2359 merging</emphasis>. However, Page Fusion differs significantly
2360 from those other solutions, whose approaches have several
2361 drawbacks:
2362 </para>
2363
2364 <itemizedlist>
2365
2366 <listitem>
2367 <para>
2368 Traditional hypervisors scan <emphasis>all</emphasis> guest
2369 memory and compute checksums, also called hashes, for every
2370 single memory page. Then, they look for pages with identical
2371 hashes and compare the entire content of those pages. If two
2372 pages produce the same hash, it is very likely that the
2373 pages are identical in content. This process can take rather
2374 long, especially if the system is not idling. As a result,
2375 the additional memory only becomes available after a
2376 significant amount of time, such as hours or sometimes days.
2377 Even worse, this kind of page sharing algorithm generally
2378 consumes significant CPU resources and increases the
2379 virtualization overhead by 10 to 20%.
2380 </para>
2381
2382 <para>
2383 Page Fusion in &product-name; uses logic in the
2384 &product-name; Guest Additions to quickly identify memory
2385 cells that are most likely identical across VMs. It can
2386 therefore achieve most of the possible savings of page
2387 sharing almost immediately and with almost no overhead.
2388 </para>
2389 </listitem>
2390
2391 <listitem>
2392 <para>
2393 Page Fusion is also much less likely to be confused by
2394 identical memory that it will eliminate, just to learn
2395 seconds later that the memory will now change and having to
2396 perform a highly expensive and often service-disrupting
2397 reallocation.
2398 </para>
2399 </listitem>
2400
2401 </itemizedlist>
2402
2403 <para>
2404 At this time, Page Fusion can only be controlled with
2405 <command>VBoxManage</command>, and only while a VM is shut down.
2406 To enable Page Fusion for a VM, use the following command:
2407 </para>
2408
2409<screen>VBoxManage modifyvm "VM name" --pagefusion on</screen>
2410
2411 <para>
2412 You can observe Page Fusion operation using some metrics.
2413 <computeroutput>RAM/VMM/Shared</computeroutput> shows the total
2414 amount of fused pages, whereas the per-VM metric
2415 <computeroutput>Guest/RAM/Usage/Shared</computeroutput> will
2416 return the amount of fused memory for a given VM. See
2417 <xref
2418 linkend="vboxmanage-metrics" /> for information on
2419 how to query metrics.
2420 </para>
2421
2422 <note>
2423 <para>
2424 Enabling Page Fusion might indirectly increase the chances for
2425 malicious guests to successfully attack other VMs running on
2426 the same host. See <xref linkend="pot-insecure"/>.
2427 </para>
2428 </note>
2429
2430 </sect2>
2431
2432 </sect1>
2433
2434</chapter>
Note: See TracBrowser for help on using the repository browser.

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