VirtualBox

source: vbox/trunk/doc/manual/en_US/user_Installation.xml@ 64216

Last change on this file since 64216 was 64216, checked in by vboxsync, 8 years ago

8530: Documentation: improve automated instructions for building kernel modules: further refine the description of how to build kernel modules in the manual, and add back some information about networking which was removed in the last change: the user should not be told unnecessary details, but some details are useful to know.

File size: 39.6 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
3"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd">
4<chapter id="installation">
5 <title>Installation details</title>
6
7 <para>As installation of VirtualBox varies depending on your host operating
8 system, we provide installation instructions in four separate chapters for
9 Windows, Mac OS X, Linux and Solaris, respectively.</para>
10
11 <sect1 id="installation_windows">
12 <title>Installing on Windows hosts</title>
13
14 <sect2>
15 <title>Prerequisites</title>
16
17 <para>For the various versions of Windows that we support as host
18 operating systems, please refer to <xref
19 linkend="hostossupport" />.</para>
20
21 <para>In addition, Windows Installer 1.1 or higher must be present on
22 your system. This should be the case if you have all recent Windows
23 updates installed.</para>
24 </sect2>
25
26 <sect2>
27 <title>Performing the installation</title>
28
29 <para>The VirtualBox installation can be started <itemizedlist>
30 <listitem>
31 <para>either by double-clicking on its executable file (contains
32 both 32- and 64-bit architectures)</para>
33 </listitem>
34
35 <listitem>
36 <para>or by entering <screen>VirtualBox.exe -extract</screen></para>
37
38 <para>on the command line. This will extract both installers into
39 a temporary directory in which you'll then find the usual .MSI
40 files. Then you can do a <screen>msiexec /i VirtualBox-&lt;version&gt;-MultiArch_&lt;x86|amd64&gt;.msi</screen>
41 to perform the installation.</para>
42 </listitem>
43 </itemizedlist></para>
44
45 <para>In either case, this will display the installation welcome dialog
46 and allow you to choose where to install VirtualBox to and which
47 components to install. In addition to the VirtualBox application, the
48 following components are available:<glosslist>
49 <glossentry>
50 <glossterm>USB support</glossterm>
51
52 <glossdef>
53 <para>This package contains special drivers for your Windows
54 host that VirtualBox requires to fully support USB devices
55 inside your virtual machines.</para>
56 </glossdef>
57 </glossentry>
58
59 <glossentry>
60 <glossterm>Networking</glossterm>
61
62 <glossdef>
63 <para>This package contains extra networking drivers for your
64 Windows host that VirtualBox needs to support Bridged Networking
65 (to make your VM's virtual network cards accessible from other
66 machines on your physical network).</para>
67 </glossdef>
68 </glossentry>
69
70 <glossentry>
71 <glossterm>Python Support</glossterm>
72
73 <glossdef>
74 <para>This package contains Python scripting support for the
75 VirtualBox API (see <xref linkend="VirtualBoxAPI" />). For this
76 to work, an already working Windows Python installation on the
77 system is required.
78 <note><para>Python version &ge; 2.6 is required. Since VirtualBox 5.1 Python 3 is also supported.</para></note>
79 <footnote>
80 <para>See, for example, <ulink
81 url="http://www.python.org/download/windows/">http://www.python.org/download/windows/</ulink>.</para>
82 </footnote></para>
83 </glossdef>
84 </glossentry>
85 </glosslist></para>
86
87 <para>Depending on your Windows configuration, you may see warnings
88 about "unsigned drivers" or similar. Please select "Continue" on these
89 warnings as otherwise VirtualBox might not function correctly after
90 installation.</para>
91
92 <para>The installer will create a "VirtualBox" group in the Windows
93 "Start" menu which allows you to launch the application and access its
94 documentation.</para>
95
96 <para>With standard settings, VirtualBox will be installed for all users
97 on the local system. In case this is not wanted, you have to invoke the
98 installer by first extracting it by using <screen>VirtualBox.exe -extract</screen>
99 and then do as follows: <screen>VirtualBox.exe -msiparams ALLUSERS=2</screen>
100 or <screen>msiexec /i VirtualBox-&lt;version&gt;-MultiArch_&lt;x86|amd64&gt;.msi ALLUSERS=2</screen>
101 on the extracted .MSI files. This will install VirtualBox only for the
102 current user.</para>
103
104 <para>If you do not want to install all features of VirtualBox, you can
105 set the optional <computeroutput>ADDLOCAL</computeroutput> parameter to
106 explicitly name the features to be installed. The following features are
107 available: <glosslist>
108 <glossentry>
109 <glossterm>VBoxApplication</glossterm>
110
111 <glossdef>
112 <para>Main binaries of VirtualBox.<note>
113 <para>This feature must not be absent since it contains the
114 minimum set of files to have working VirtualBox
115 installation.</para>
116 </note></para>
117 </glossdef>
118 </glossentry>
119
120 <glossentry>
121 <glossterm>VBoxUSB</glossterm>
122
123 <glossdef>
124 <para>USB support.</para>
125 </glossdef>
126 </glossentry>
127
128 <glossentry>
129 <glossterm>VBoxNetwork</glossterm>
130
131 <glossdef>
132 <para>All networking support; includes the VBoxNetworkFlt and
133 VBoxNetworkAdp features (see below).</para>
134 </glossdef>
135 </glossentry>
136
137 <glossentry>
138 <glossterm>VBoxNetworkFlt</glossterm>
139
140 <glossdef>
141 <para>Bridged networking support.</para>
142 </glossdef>
143 </glossentry>
144
145 <glossentry>
146 <glossterm>VBoxNetworkAdp</glossterm>
147
148 <glossdef>
149 <para>Host-only networking support.</para>
150 </glossdef>
151 </glossentry>
152
153 <glossentry>
154 <glossterm>VBoxPython</glossterm>
155
156 <glossdef>
157 <para>Python support.
158 <note><para>Python version &ge; 2.6 is required. Since VirtualBox 5.1 Python 3 is also supported.</para></note>
159 </para>
160 </glossdef>
161 </glossentry>
162 </glosslist>For example, to only install USB support along with the
163 main binaries, do a: <screen>VirtualBox.exe -msiparams ADDLOCAL=VBoxApplication,VBoxUSB</screen>
164 or <screen>msiexec /i VirtualBox-&lt;version&gt;-MultiArch_&lt;x86|amd64&gt;.msi ADDLOCAL=VBoxApplication,VBoxUSB</screen></para>
165
166 <para>
167 The user is able to choose between NDIS5 and NDIS6 host network filters drivers during
168 the installation. This is realized via a command line parameter
169 <computeroutput>NETWORKTYPE</computeroutput>.
170 The NDIS6 driver is default for Windows Vista and later. For older Windows versions,
171 the installer will automatically select the NDIS5 driver and this cannot be changed.
172 For Windows Vista and later the user can force to install the (legacy) NDIS5 host
173 network filter driver using <computeroutput>NETWORKTYPE=NDIS5</computeroutput>. For
174 example, to install the NDIS5 driver on Windows 7, do
175 <screen>VirtualBox.exe -msiparams NETWORKTYPE=NDIS5</screen>
176 or
177 <screen>msiexec /i VirtualBox-&lt;version&gt;-MultiArch_&lt;x86|amd64&gt;.msi NETWORKTYPE=NDIS5</screen>
178 </para>
179
180
181 </sect2>
182
183 <sect2>
184 <title>Uninstallation</title>
185
186 <para>As VirtualBox uses the standard Microsoft Windows installer,
187 VirtualBox can be safely uninstalled at any time by choosing the program
188 entry in the "Add/Remove Programs" applet in the Windows Control
189 Panel.</para>
190 </sect2>
191
192 <sect2>
193 <title>Unattended installation</title>
194
195 <para>Unattended installations can be performed using the standard MSI
196 support.</para>
197
198 </sect2>
199
200 <sect2>
201 <title>Public properties</title>
202
203 <para>The following public properties can be specified via MSI API,
204 <screen>VirtualBox.exe -msiparams NAME=VALUE [...]</screen>
205 or
206 <screen>msiexec /i VirtualBox-&lt;version&gt;-MultiArch_&lt;x86|amd64&gt;.msi NAME=VALUE [...]</screen>
207 to control additional behavior and/or features of the Windows host installer:
208 <glosslist>
209 <glossentry>
210 <glossterm>VBOX_INSTALLDESKTOPSHORTCUT</glossterm>
211
212 <glossdef>
213 <para>Specifies whether or not a VirtualBox icon on the desktop
214 should be created.</para>
215
216 <para>Set to <computeroutput>1</computeroutput> to enable,
217 <computeroutput>0</computeroutput> to disable. Default is 1.</para>
218 </glossdef>
219 </glossentry>
220
221 <glossentry>
222 <glossterm>VBOX_INSTALLQUICKLAUNCHSHORTCUT</glossterm>
223
224 <glossdef>
225 <para>Specifies whether or not a VirtualBox icon in the Quick Launch
226 Bar should be created.</para>
227
228 <para>Set to <computeroutput>1</computeroutput> to enable,
229 <computeroutput>0</computeroutput> to disable. Default is 1.</para>
230 </glossdef>
231 </glossentry>
232
233 <glossentry>
234 <glossterm>VBOX_REGISTERFILEEXTENSIONS</glossterm>
235
236 <glossdef>
237 <para>Specifies whether or not the file extensions .vbox,
238 .vbox-extpack, .ovf, .ova, .vdi, .vmdk, .vhd and .vdd should be
239 associated with VirtualBox. Files of these types then will be opened
240 with VirtualBox.</para>
241
242 <para>Set to <computeroutput>1</computeroutput> to enable,
243 <computeroutput>0</computeroutput> to disable. Default is 1.</para>
244 </glossdef>
245 </glossentry>
246
247 <glossentry>
248 <glossterm>VBOX_START</glossterm>
249
250 <glossdef>
251 <para>Specifies whether or not VirtualBox should be started right after
252 successful installation.</para>
253
254 <para>Set to <computeroutput>1</computeroutput> to enable,
255 <computeroutput>0</computeroutput> to disable. Default is 1.</para>
256 </glossdef>
257 </glossentry>
258 </glosslist>
259 </para>
260
261 </sect2>
262 </sect1>
263
264 <sect1>
265 <title>Installing on Mac OS X hosts</title>
266
267 <sect2>
268 <title>Performing the installation</title>
269
270 <para>For Mac OS X hosts, VirtualBox ships in a disk image
271 (<computeroutput>dmg</computeroutput>) file. Perform the following
272 steps: <orderedlist>
273 <listitem>
274 <para>Double-click on that file to have its contents
275 mounted.</para>
276 </listitem>
277
278 <listitem>
279 <para>A window will open telling you to double click on the
280 <computeroutput>VirtualBox.mpkg</computeroutput> installer file
281 displayed in that window.</para>
282 </listitem>
283
284 <listitem>
285 <para>This will start the installer, which will allow you to
286 select where to install VirtualBox to.</para>
287 </listitem>
288 </orderedlist></para>
289
290 <para>After installation, you can find a VirtualBox icon in the
291 "Applications" folder in the Finder.</para>
292 </sect2>
293
294 <sect2>
295 <title>Uninstallation</title>
296
297 <para>To uninstall VirtualBox, open the disk image (dmg) file again and
298 double-click on the uninstall icon contained therein.</para>
299 </sect2>
300
301 <sect2>
302 <title>Unattended installation</title>
303
304 <para>To perform a non-interactive installation of VirtualBox you can
305 use the command line version of the installer application.</para>
306
307 <para>Mount the disk image (dmg) file as described in the normal
308 installation or use the following command line:</para>
309
310 <screen>hdiutil attach /path/to/VirtualBox-xyz.dmg</screen>
311
312 <para>Then open a terminal session and execute:</para>
313
314 <screen>sudo installer -pkg /Volumes/VirtualBox/VirtualBox.pkg -target /Volumes/Macintosh\ HD</screen>
315 </sect2>
316 </sect1>
317
318 <sect1 id="install-linux-host">
319 <title>Installing on Linux hosts</title>
320
321 <sect2>
322 <title>Prerequisites</title>
323
324 <para>For the various versions of Linux that we support as host
325 operating systems, please refer to <xref
326 linkend="hostossupport" />.</para>
327
328 <para>You will need to install the following packages on your Linux
329 system before starting the installation (some systems will do this for
330 you automatically when you install VirtualBox):</para>
331
332 <itemizedlist>
333 <listitem>
334 <para>Qt 4.8.0 or higher;</para>
335 </listitem>
336
337 <listitem>
338 <para>SDL 1.2.7 or higher (this graphics library is typically called
339 <computeroutput>libsdl</computeroutput> or similar).</para>
340 </listitem>
341 </itemizedlist>
342
343 <note>
344 <para>To be precise, these packages are only required if you want to
345 run the VirtualBox graphical user interfaces. In particular,
346 <computeroutput>VirtualBox</computeroutput>, the graphical VirtualBox
347 manager, requires both Qt and SDL;
348 <computeroutput>VBoxSDL</computeroutput>, our simplified GUI, requires
349 only SDL. By contrast, if you only want to run
350 <computeroutput>VBoxHeadless</computeroutput>, neither Qt nor SDL are
351 required.</para>
352 </note>
353 </sect2>
354
355 <sect2 id="externalkernelmodules">
356 <title>The VirtualBox driver modules</title>
357
358 <para>In order to run other operating systems in virtual machines
359 alongside your main operating system, VirtualBox needs to integrate
360 very tightly into the system. To do this it installs a "driver"
361 module called <computeroutput>vboxdrv</computeroutput> which does
362 a lot of that work into the system kernel, which is the part of
363 the operating system which controls your processor and physical
364 hardware. Without this kernel module, you can still use the
365 VirtualBox manager to configure virtual machines, but they will not
366 start. It also installs network drivers called
367 <computeroutput>vboxnetflt</computeroutput> and
368 <computeroutput>vboxnetadp</computeroutput> which let virtual machines
369 make more use of your computer's network capabilities and are needed
370 for any virtual machine networking beyond the basic "NAT" mode.</para>
371
372 <para>Since distributing driver modules separately from the kernel
373 is not something which Linux supports well, we create the modules
374 on the system where they will be used. This usually means first
375 installing software packages from the distribution which are needed
376 for the "build" process. Normally, these will be the GNU compiler
377 (GCC), GNU Make (make) and packages containing "header files" for
378 your kernel - and making sure that all system updates are
379 installed and that the system is running the most up-to-date
380 kernel included in the distribution. <emphasis>The running kernel
381 and the header files must be updated to matching versions.</emphasis>
382 We will give some instructions for common distributions. For most
383 of them you will want to start by finding the version name of your
384 kernel using the command
385 <computeroutput>uname -r</computeroutput> in a terminal. They
386 assume that you have not changed too much from the original
387 installation, particularly not installed a different kernel type.
388 If you have then you will need to determine yourself what to set
389 up.</para>
390
391 <itemizedlist>
392 <listitem>
393 <para>With Debian and Ubuntu-based distributions, you
394 must install the right version of the
395 <computeroutput>linux-headers</computeroutput>, usually
396 whichever of <computeroutput>linux-headers-generic
397 </computeroutput>, <computeroutput>linux-headers-amd64
398 </computeroutput>, <computeroutput>linux-headers-i686
399 </computeroutput> or <computeroutput>linux-headers-i686-pae
400 </computeroutput> best matches the kernel version name;
401 and if it exists the <computeroutput>linux-kbuild
402 </computeroutput>
403 package. Basic Ubuntu releases should have the right
404 packages installed by default.</para>
405 </listitem>
406
407 <listitem>
408 <para>On Fedora, Redhat, Oracle Linux and many other
409 RPM-based systems, the kernel version sometimes has
410 a code of letters or a word close to the end of the
411 version name, for example "uek" for the Oracle
412 Enterprise kernel or "default" or "desktop" for the
413 standard SUSE kernels. In this case the package name is
414 <computeroutput>kernel-uek-devel</computeroutput> or
415 equivalent. If there is no such code, it is usually
416 <computeroutput>kernel-devel</computeroutput>.</para>
417 </listitem>
418
419 <listitem>
420 <para>On older SUSE and openSUSE Linux, you must install
421 the <computeroutput>kernel-source</computeroutput>
422 and <computeroutput>kernel-syms</computeroutput>
423 packages.</para>
424 </listitem>
425 </itemizedlist>
426
427 <para>If you suspect that something has gone wrong with module installation,
428 check that your system is set up as described above and try running (as root)
429 the following command:</para>
430
431 <screen>rcvboxdrv setup</screen>
432 </sect2>
433
434 <sect2>
435 <title>Performing the installation</title>
436
437 <para>VirtualBox is available in a number of package formats native to
438 various common Linux distributions (see <xref linkend="hostossupport" />
439 for details). In addition, there is an alternative generic installer
440 (.run) which should work on most Linux distributions. The generic
441 installer packages are built on EL5 systems and thus require reasonable
442 old versions of glibc (version 2.5) and other system libraries.</para>
443
444 <sect3>
445 <title>Installing VirtualBox from a Debian/Ubuntu package</title>
446
447 <para>First, download the appropriate package for your distribution.
448 The following examples assume that you are installing to a 32-bit
449 Ubuntu Wily system. Use <computeroutput>dpkg</computeroutput> to
450 install the Debian package:</para>
451
452 <screen>sudo dpkg -i virtualbox-5.0_@VBOX_VERSION_STRING@_Ubuntu_wily_i386.deb</screen>
453
454 <para>The installer will also try to build kernel modules suitable for
455 the current running kernel. If the build process is not successful you
456 will be shown a
457 warning and the package will be left unconfigured. Please have a look
458 at <computeroutput>/var/log/vbox-install.log</computeroutput> to find
459 out why the compilation failed. You may have to install the
460 appropriate Linux kernel headers (see <xref
461 linkend="externalkernelmodules" />). After correcting any problems, do
462 <screen>sudo rcvboxdrv setup</screen>This will start a
463 second attempt to build the module.</para>
464
465 <para>If a suitable kernel module was found in the package or the
466 module was successfully built, the installation script will attempt to
467 load that module. If this fails, please see <xref
468 linkend="ts_linux-kernelmodule-fails-to-load" /> for further
469 information.</para>
470
471 <para>Once VirtualBox has been successfully installed and configured,
472 you can start it by selecting "VirtualBox" in your start menu or from
473 the command line (see <xref linkend="startingvboxonlinux" />).</para>
474 </sect3>
475
476 <sect3>
477 <title>Using the alternative generic installer (VirtualBox.run)</title>
478
479 <para>The alternative generic installer performs the following steps:</para>
480
481 <itemizedlist>
482 <listitem>
483 <para>It unpacks the application files to the target directory,
484 <screen>/opt/VirtualBox/</screen> which cannot be changed.</para>
485 </listitem>
486
487 <listitem>
488 <para>It builds the VirtualBox kernel modules
489 (<computeroutput>vboxdrv</computeroutput>,
490 <computeroutput>vboxnetflt</computeroutput> and
491 <computeroutput>vboxnetadp</computeroutput>) and installs
492 them.</para>
493 </listitem>
494
495 <listitem>
496 <para>It creates
497 <computeroutput>/sbin/rcvboxdrv</computeroutput>, an init
498 script to start the VirtualBox kernel module.</para>
499 </listitem>
500
501 <listitem>
502 <para>It creates a new system group called
503 <computeroutput>vboxusers</computeroutput>.</para>
504 </listitem>
505
506 <listitem>
507 <para>It creates symbolic links in
508 <computeroutput>/usr/bin</computeroutput> to the a shell script
509 (<computeroutput>/opt/VirtualBox/VBox</computeroutput>) which does
510 some sanity checks and dispatches to the actual executables,
511 <computeroutput>VirtualBox</computeroutput>,
512 <computeroutput>VBoxSDL</computeroutput>,
513 <computeroutput>VBoxVRDP</computeroutput>,
514 <computeroutput>VBoxHeadless</computeroutput> and
515 <computeroutput>VBoxManage</computeroutput></para>
516 </listitem>
517
518 <listitem>
519 <para>It creates
520 <computeroutput>/etc/udev/rules.d/60-vboxdrv.rules</computeroutput>,
521 a description file for udev, if that is present, which makes the
522 USB devices accessible to all users in the
523 <computeroutput>vboxusers</computeroutput> group.</para>
524 </listitem>
525
526 <listitem>
527 <para>It writes the installation directory to
528 <computeroutput>/etc/vbox/vbox.cfg</computeroutput>.</para>
529 </listitem>
530 </itemizedlist>
531
532 <para>The installer must be executed as root with either
533 <computeroutput>install</computeroutput> or
534 <computeroutput>uninstall</computeroutput> as the first
535 parameter.</para>
536
537 <screen>sudo ./VirtualBox.run install</screen>
538
539 <para>Or if you do not have the "sudo" command available, run the
540 following as root instead:<screen>./VirtualBox.run install</screen></para>
541
542 <para>After that you need to put every user which should be able to
543 access USB devices from VirtualBox guests in the group
544 <computeroutput>vboxusers</computeroutput>, either through the GUI
545 user management tools or by running the following command as
546 root:</para>
547
548 <screen>sudo usermod -a -G vboxusers username</screen>
549
550 <para><note>
551 <para>The <computeroutput>usermod</computeroutput> command of some
552 older Linux distributions does not support the
553 <computeroutput>-a</computeroutput> option (which adds the user to
554 the given group without affecting membership of other groups). In
555 this case, find out the current group memberships with the
556 <computeroutput>groups</computeroutput> command and add all these
557 groups in a comma-separated list to the command line after the
558 <computeroutput>-G</computeroutput> option, e.g. like this:
559 <computeroutput>usermod -G group1,group2,vboxusers
560 username</computeroutput>.</para>
561 </note></para>
562 </sect3>
563
564 <sect3>
565 <title>Performing a manual installation</title>
566
567 <para>If, for any reason, you cannot use the shell script installer
568 described previously, you can also perform a manual installation.
569 Invoke the installer like this:</para>
570
571 <screen>./VirtualBox.run --keep --noexec</screen>
572
573 <para>This will unpack all the files needed for installation in the
574 directory <computeroutput>install</computeroutput> under the current
575 directory. The VirtualBox application files are contained in
576 <computeroutput>VirtualBox.tar.bz2</computeroutput> which you can
577 unpack to any directory on your system. For example:</para>
578
579 <screen>sudo mkdir /opt/VirtualBox
580sudo tar jxf ./install/VirtualBox.tar.bz2 -C /opt/VirtualBox</screen>
581
582 <para>or as root:<screen>mkdir /opt/VirtualBox
583tar jxf ./install/VirtualBox.tar.bz2 -C /opt/VirtualBox</screen></para>
584
585 <para>The sources for VirtualBox's kernel module are provided in the
586 <computeroutput>src</computeroutput> directory. To build the module,
587 change to the directory and issue</para>
588
589 <screen>make</screen>
590
591 <para>If everything builds correctly, issue the following command to
592 install the module to the appropriate module directory:</para>
593
594 <screen>sudo make install</screen>
595
596 <para>In case you do not have sudo, switch the user account to root
597 and perform<screen>make install</screen></para>
598
599 <para>The VirtualBox kernel module needs a device node to operate. The
600 above make command will tell you how to create the device node,
601 depending on your Linux system. The procedure is slightly different
602 for a classical Linux setup with a
603 <computeroutput>/dev</computeroutput> directory, a system with the now
604 deprecated <computeroutput>devfs</computeroutput> and a modern Linux
605 system with <computeroutput>udev</computeroutput>.</para>
606
607 <para>On certain Linux distributions, you might experience
608 difficulties building the module. You will have to analyze the error
609 messages from the build system to diagnose the cause of the problems.
610 In general, make sure that the correct Linux kernel sources are used
611 for the build process.</para>
612
613 <para>Note that the <computeroutput>/dev/vboxdrv</computeroutput>
614 kernel module device node must be owned by root:root and must be
615 read/writable only for the user.</para>
616
617 <para>Next, you will have to install the system initialization script
618 for the kernel module:<screen>cp /opt/VirtualBox/vboxdrv.sh /sbin/rcvboxdrv</screen>(assuming
619 you installed VirtualBox to the
620 <computeroutput>/opt/VirtualBox</computeroutput> directory) and
621 activate the initialization script using the right method for your
622 distribution. You should create VirtualBox's configuration
623 file:<screen>mkdir /etc/vbox
624echo INSTALL_DIR=/opt/VirtualBox &gt; /etc/vbox/vbox.cfg</screen>and, for
625 convenience, create the following symbolic links:</para>
626
627 <screen>ln -sf /opt/VirtualBox/VBox.sh /usr/bin/VirtualBox
628ln -sf /opt/VirtualBox/VBox.sh /usr/bin/VBoxManage
629ln -sf /opt/VirtualBox/VBox.sh /usr/bin/VBoxHeadless
630ln -sf /opt/VirtualBox/VBox.sh /usr/bin/VBoxSDL</screen>
631 </sect3>
632
633 <sect3>
634 <title>Updating and uninstalling VirtualBox</title>
635
636 <para>Before updating or uninstalling VirtualBox, you must terminate
637 any virtual machines which are currently running and exit the
638 VirtualBox or VBoxSVC applications. To update VirtualBox, simply run
639 the installer of the updated version. To uninstall VirtualBox, invoke
640 the installer like this: <screen>sudo ./VirtualBox.run uninstall</screen>
641 or as root<screen>./VirtualBox.run uninstall</screen>. Starting with
642 version 2.2.2, you can uninstall the .run package by invoking <screen>/opt/VirtualBox/uninstall.sh</screen>To
643 manually uninstall VirtualBox, simply undo the steps in the manual
644 installation in reverse order.</para>
645 </sect3>
646
647 <sect3>
648 <title>Automatic installation of Debian packages</title>
649
650 <para>The Debian packages will request some user feedback when
651 installed for the first time. The debconf system is used to perform
652 this task. To prevent any user interaction during installation,
653 default values can be defined. A file
654 <computeroutput>vboxconf</computeroutput> can contain the following
655 debconf settings: <screen>virtualbox virtualbox/module-compilation-allowed boolean true
656virtualbox virtualbox/delete-old-modules boolean true</screen>The first line
657 allows compilation of the vboxdrv kernel module if no module was found
658 for the current kernel. The second line allows the package to delete
659 any old vboxdrv kernel modules compiled by previous
660 installations.</para>
661
662 <para>These default settings can be applied with <screen>debconf-set-selections vboxconf</screen>
663 prior to the installation of the VirtualBox Debian package.</para>
664
665 <para>In addition there are some common configuration options that can
666 be set prior to the installation, described in <xref
667 linkend="linux_install_opts" />.</para>
668 </sect3>
669
670 <sect3>
671 <title>Automatic installation of .rpm packages</title>
672
673 <para>The .rpm format does not provide a configuration system
674 comparable to the debconf system. See <xref
675 linkend="linux_install_opts" /> for how to set some common
676 installation options provided by VirtualBox.</para>
677 </sect3>
678
679 <sect3 id="linux_install_opts">
680 <title>Automatic installation options</title>
681
682 <para>To configure the installation process of our .deb and .rpm
683 packages, you can create a response file named
684 <computeroutput>/etc/default/virtualbox</computeroutput>. The
685 automatic generation of the udev rule can be prevented by the
686 following setting: <screen>INSTALL_NO_UDEV=1</screen> The creation of
687 the group vboxusers can be prevented by <screen>INSTALL_NO_GROUP=1</screen>
688 If the line <screen>INSTALL_NO_VBOXDRV=1</screen> is specified, the
689 package installer will not try to build the
690 <computeroutput>vboxdrv</computeroutput> kernel module if no module
691 fitting the current kernel was found.</para>
692 </sect3>
693 </sect2>
694
695 <sect2>
696 <title>The vboxusers group</title>
697
698 <para>The Linux installers create the system user group
699 <computeroutput>vboxusers</computeroutput> during installation. Any
700 system user who is going to use USB devices from VirtualBox guests must
701 be a member of that group. A user can be made a member of the group
702 <computeroutput>vboxusers</computeroutput> through the GUI user/group
703 management or at the command line with</para>
704
705 <screen>sudo usermod -a -G vboxusers username</screen>
706 </sect2>
707
708 <sect2 id="startingvboxonlinux">
709 <title>Starting VirtualBox on Linux</title>
710
711 <para>The easiest way to start a VirtualBox program is by running the
712 program of your choice (<computeroutput>VirtualBox</computeroutput>,
713 <computeroutput>VBoxManage</computeroutput>,
714 <computeroutput>VBoxSDL</computeroutput> or
715 <computeroutput>VBoxHeadless</computeroutput>) from a terminal. These
716 are symbolic links to <computeroutput>VBox.sh</computeroutput> that
717 start the required program for you.</para>
718
719 <para>The following detailed instructions should only be of interest if
720 you wish to execute VirtualBox without installing it first. You should
721 start by compiling the <computeroutput>vboxdrv</computeroutput> kernel
722 module (see above) and inserting it into the Linux kernel. VirtualBox
723 consists of a service daemon (<computeroutput>VBoxSVC</computeroutput>)
724 and several application programs. The daemon is automatically started if
725 necessary. All VirtualBox applications will communicate with the daemon
726 through Unix local domain sockets. There can be multiple daemon
727 instances under different user accounts and applications can only
728 communicate with the daemon running under the user account as the
729 application. The local domain socket resides in a subdirectory of your
730 system's directory for temporary files called
731 <computeroutput>.vbox-&lt;username&gt;-ipc</computeroutput>. In case of
732 communication problems or server startup problems, you may try to remove
733 this directory.</para>
734
735 <para>All VirtualBox applications
736 (<computeroutput>VirtualBox</computeroutput>,
737 <computeroutput>VBoxSDL</computeroutput>,
738 <computeroutput>VBoxManage</computeroutput> and
739 <computeroutput>VBoxHeadless</computeroutput>) require the VirtualBox
740 directory to be in the library path:</para>
741
742 <screen>LD_LIBRARY_PATH=. ./VBoxManage showvminfo "Windows XP"</screen>
743 </sect2>
744 </sect1>
745
746 <sect1 id="install-solaris-host">
747 <title>Installing on Solaris hosts</title>
748
749 <para>For the specific versions of Solaris that we support as host
750 operating systems, please refer to <xref
751 linkend="hostossupport" />.</para>
752
753 <para>If you have a previously installed instance of VirtualBox on your
754 Solaris host, please uninstall it first before installing a new instance.
755 Refer to <xref linkend="uninstall-solaris-host" /> for uninstall
756 instructions.</para>
757
758 <sect2>
759 <title>Performing the installation</title>
760
761 <para>VirtualBox is available as a standard Solaris package. Download
762 the VirtualBox SunOS package which includes the 64-bit
763 versions of VirtualBox. <emphasis>The installation must be performed as
764 root and from the global zone</emphasis> as the VirtualBox installer
765 loads kernel drivers which cannot be done from non-global zones. To
766 verify which zone you are currently in, execute the
767 <computeroutput>zonename</computeroutput> command. Execute the following
768 commands:</para>
769
770 <screen>gunzip -cd VirtualBox-@[email protected] | tar xvf -</screen>
771
772 <para>Starting with VirtualBox 3.1 the VirtualBox kernel package is no
773 longer a separate package and has been integrated into the main package.
774 Install the VirtualBox package using:</para>
775
776 <screen>pkgadd -d VirtualBox-@[email protected]</screen>
777
778 <para>The installer will then prompt you to enter the package you wish
779 to install. Choose "1" or "all" and proceed. Next the installer will ask
780 you if you want to allow the postinstall script to be executed. Choose
781 "y" and proceed as it is essential to execute this script which installs
782 the VirtualBox kernel module. Following this confirmation the installer
783 will install VirtualBox and execute the postinstall setup script.</para>
784
785 <para>Once the postinstall script has been executed your installation is
786 now complete. You may now safely delete the uncompressed package and
787 <computeroutput>autoresponse</computeroutput> files from your system.
788 VirtualBox would be installed in
789 <computeroutput>/opt/VirtualBox</computeroutput>.</para>
790
791 <note>
792 <para>If you need to use VirtualBox from non-global zones, please read
793 <xref linkend="solaris-zones" />.</para>
794 </note>
795 </sect2>
796
797 <sect2>
798 <title>The vboxuser group</title>
799
800 <para>Starting with VirtualBox 4.1, the installer creates the system
801 user group <computeroutput>vboxuser</computeroutput> during installation
802 for Solaris hosts that support the USB features required by VirtualBox.
803 Any system user who is going to use USB devices from VirtualBox guests
804 must be a member of this group. A user can be made a member of this
805 group through the GUI user/group management or at the command line by
806 executing as root:</para>
807
808 <screen>usermod -G vboxuser username</screen>
809
810 <para>Note that adding an active user to that group will require that
811 user to log out and back in again. This should be done manually after
812 successful installation of the package.</para>
813 </sect2>
814
815 <sect2>
816 <title>Starting VirtualBox on Solaris</title>
817
818 <para>The easiest way to start a VirtualBox program is by running the
819 program of your choice (<computeroutput>VirtualBox</computeroutput>,
820 <computeroutput>VBoxManage</computeroutput>,
821 <computeroutput>VBoxSDL</computeroutput> or
822 <computeroutput>VBoxHeadless</computeroutput>) from a terminal. These
823 are symbolic links to <computeroutput>VBox.sh</computeroutput> that
824 start the required program for you.</para>
825
826 <para>Alternatively, you can directly invoke the required programs from
827 <computeroutput>/opt/VirtualBox</computeroutput>. Using the links
828 provided is easier as you do not have to type the full path.</para>
829
830 <para>You can configure some elements of the
831 <computeroutput>VirtualBox</computeroutput> Qt GUI such as fonts and
832 colours by executing <computeroutput>VBoxQtconfig</computeroutput> from
833 the terminal.</para>
834 </sect2>
835
836 <sect2 id="uninstall-solaris-host">
837 <title>Uninstallation</title>
838
839 <para>Uninstallation of VirtualBox on Solaris requires root permissions.
840 To perform the uninstallation, start a root terminal session and
841 execute:</para>
842
843 <screen>pkgrm SUNWvbox</screen>
844
845 <para>After confirmation, this will remove VirtualBox from your
846 system.</para>
847
848 <para>If you are uninstalling VirtualBox version 3.0 or lower, you need
849 to remove the VirtualBox kernel interface package, execute:</para>
850
851 <para><screen>pkgrm SUNWvboxkern</screen></para>
852 </sect2>
853
854 <sect2>
855 <title>Unattended installation</title>
856
857 <para>To perform a non-interactive installation of VirtualBox we have
858 provided a response file named
859 <computeroutput>autoresponse</computeroutput> that the installer will
860 use for responses to inputs rather than ask them from you.</para>
861
862 <para>Extract the tar.gz package as described in the normal
863 installation. Then open a root terminal session and execute:</para>
864
865 <screen>pkgadd -d VirtualBox-@VBOX_VERSION_STRING@-SunOS-x86 -n -a autoresponse SUNWvbox</screen>
866
867 <para>To perform a non-interactive uninstallation, open a root terminal
868 session and execute:</para>
869
870 <screen>pkgrm -n -a /opt/VirtualBox/autoresponse SUNWvbox</screen>
871 </sect2>
872
873 <sect2 id="solaris-zones">
874 <title>Configuring a zone for running VirtualBox</title>
875
876 <para>Assuming that VirtualBox has already been installed into your
877 zone, you need to give the zone access to VirtualBox's device node. This
878 is done by performing the following steps. Start a root terminal and
879 execute:</para>
880
881 <screen>zonecfg -z vboxzone</screen>
882
883 <para>Replace "vboxzone" with the name of the zone in which you intend
884 to run VirtualBox.</para>
885
886 <para>Inside the <computeroutput>zonecfg</computeroutput> prompt add the
887 <computeroutput>device</computeroutput> resource and
888 <computeroutput>match</computeroutput> properties to the zone. Here's
889 how it can be done:</para>
890
891 <screen>zonecfg:vboxzone&gt;add device
892zonecfg:vboxzone:device&gt;set match=/dev/vboxdrv
893zonecfg:vboxzone:device&gt;end
894zonecfg:vboxzone&gt;add device
895zonecfg:vboxzone:device&gt;set match=/dev/vboxdrvu
896zonecfg:vboxzone:device&gt;end
897zonecfg:vboxzone&gt;exit</screen>
898
899 <para>If you are running VirtualBox 2.2.0 or above on Solaris 11 or
900 above, you may add a device for <computeroutput>/dev/vboxusbmon</computeroutput>
901 too, similar to what was shown above. This does not apply to Solaris 10
902 hosts due to lack of USB support.</para>
903
904 <para>If you are not using sparse root zones, you will need to loopback
905 mount <computeroutput>/opt/VirtualBox</computeroutput> from the global zone
906 (specified below using the <computeroutput>dir</computeroutput> attribute) into
907 the non-global zone at the same path (specified using the
908 <computeroutput>special</computeroutput> attribute). For example:</para>
909
910 <screen>zonecfg:vboxzone&gt;add fs
911zonecfg:vboxzone:device&gt;set dir=/opt/VirtualBox
912zonecfg:vboxzone:device&gt;set special=/opt/VirtualBox
913zonecfg:vboxzone:device&gt;set type=lofs
914zonecfg:vboxzone:device&gt;end
915zonecfg:vboxzone&gt;exit</screen>
916
917 <para>Next reboot the zone using <computeroutput>zoneadm</computeroutput>
918 and you should be able to run VirtualBox from within the configured zone.</para>
919 </sect2>
920 </sect1>
921</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