VirtualBox

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

Last change on this file since 83189 was 82350, checked in by vboxsync, 5 years ago

manual: integrate 6.1 drop #10 with minimal manual adjustments (frontmatter for preface and eliminated trailing whitespace)

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