Add a new section explaining how to install and configure VirtualBox in FreeBSD. VirtualBox has recently been added to the Ports tree and supports FreeBSD as a host OS.
Reviewed by: keramida, rene, trhodes, danger, daichi, Daniel Seuffert <DS at praxisvermittlung24 dot de>
This commit is contained in:
parent
654766db00
commit
d88c151105
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=34536
1 changed files with 109 additions and 5 deletions
|
@ -963,12 +963,116 @@ xenbr1 8000.feffffffffff no vif0.1
|
||||||
<sect1 id="virtualization-host">
|
<sect1 id="virtualization-host">
|
||||||
<title>FreeBSD as a Host OS</title>
|
<title>FreeBSD as a Host OS</title>
|
||||||
|
|
||||||
<para>FreeBSD is not officially supported by any virtualization
|
<para>For a number of years, &os; was not officially supported as a host
|
||||||
package as a host operating system at this time, but many people
|
OS by any of the available virtualization solutions. Some people were
|
||||||
use older versions of <application>VMware</application> in this capacity.
|
using older and mostly obsolete versions of
|
||||||
Work is also ongoing in getting <application>&xen;</application> to
|
<application>VMware</application> (like <filename
|
||||||
work as a host environment on FreeBSD.</para>
|
role="package">emulators/vmware3</filename>), which utilized the
|
||||||
|
&linux; binary compatibility layer. Shortly after the release of
|
||||||
|
&os; 7.2, the Open Source Edition (<acronym>OSE</acronym>) of
|
||||||
|
&sun;'s <application>VirtualBox</application> appeared in the
|
||||||
|
Ports Collection as a native &os; program.</para>
|
||||||
|
|
||||||
|
<para><application>VirtualBox</application> is an actively developed,
|
||||||
|
complete virtualization package, that is available for most operating
|
||||||
|
systems including &windows;, &macos;, &linux; and &os;. It is equally
|
||||||
|
capable at running &windows; or &unix;-type guests. It comes in two
|
||||||
|
flavors, an open source and a proprietary edition. From the user's
|
||||||
|
point of view, perhaps the most important limitation of the
|
||||||
|
<acronym>OSE</acronym> is the lack of USB support. Other differences
|
||||||
|
may be found in the <quote>Editions</quote> page of the
|
||||||
|
<application>VirtualBox</application> wiki, at <ulink
|
||||||
|
url="http://www.virtualbox.org/wiki/Editions"></ulink>.
|
||||||
|
Currently, only the OSE is available for &os;.</para>
|
||||||
|
|
||||||
|
<sect2 id="virtualization-virtualbox-install">
|
||||||
|
<title>Installing VirtualBox</title>
|
||||||
|
|
||||||
|
<para><application>VirtualBox</application> is available as a &os; port
|
||||||
|
in <filename role="package">emulators/virtualbox</filename>, and
|
||||||
|
may be installed using the following commands:</para>
|
||||||
|
|
||||||
|
<screen>&prompt.root; <userinput>cd /usr/ports/emulators/virtualbox</userinput>
|
||||||
|
&prompt.root; <userinput>make install clean</userinput></screen>
|
||||||
|
|
||||||
|
<para>One useful option in the configuration dialog is the
|
||||||
|
<literal>GuestAdditions</literal> suite of programs. These provide a
|
||||||
|
number of useful features in guest operating systems, like mouse
|
||||||
|
pointer integration (allowing the mouse to be shared between host
|
||||||
|
and guest without the need to press a special keyboard shortcut to
|
||||||
|
switch) and faster video rendering, especially in &windows; guests.
|
||||||
|
The guest additions are available in the <guimenu>Devices</guimenu>
|
||||||
|
menu, after the installation of the guest OS is finished.</para>
|
||||||
|
|
||||||
|
<para>A few configuration changes are needed before
|
||||||
|
<application>VirtualBox</application> is started for the first time.
|
||||||
|
The port installs a kernel module in <filename
|
||||||
|
class="directory">/boot/modules</filename> which must be loaded
|
||||||
|
into the running kernel:</para>
|
||||||
|
|
||||||
|
<screen>&prompt.root; <userinput>kldload vboxdrv</userinput></screen>
|
||||||
|
|
||||||
|
<para>To ensure the module always gets loaded after a reboot, add the
|
||||||
|
following line to <filename>/boot/loader.conf</filename>:</para>
|
||||||
|
|
||||||
|
<programlisting>vboxdrv_load="YES"</programlisting>
|
||||||
|
|
||||||
|
<para><application>VirtualBox</application> also requires the
|
||||||
|
<filename class="directory">proc</filename> file system to be
|
||||||
|
mounted:</para>
|
||||||
|
|
||||||
|
<screen>&prompt.root; <userinput>mount -t procfs proc /proc</userinput></screen>
|
||||||
|
|
||||||
|
<para>To allow this setting to persist reboots, the following line
|
||||||
|
is needed in <filename>/etc/fstab</filename>:</para>
|
||||||
|
|
||||||
|
<programlisting>proc /proc procfs rw 0 0</programlisting>
|
||||||
|
|
||||||
|
<note>
|
||||||
|
<para>If an error message similar to the following is observed
|
||||||
|
when <application>VirtualBox</application> is run from
|
||||||
|
the terminal:</para>
|
||||||
|
|
||||||
|
<screen>VirtualBox: supR3HardenedExecDir: couldn't read "", errno=2 cchLink=-1</screen>
|
||||||
|
|
||||||
|
<para>The most likely culprit will be the <filename
|
||||||
|
class="directory">proc</filename> file system. Please use the
|
||||||
|
<command>mount</command> command to check whether it is mounted
|
||||||
|
properly.</para>
|
||||||
|
</note>
|
||||||
|
|
||||||
|
<para>The <groupname>vboxusers</groupname> group is created during
|
||||||
|
the installation of <application>VirtualBox</application>.
|
||||||
|
All users that need access to <application>VirtualBox</application>
|
||||||
|
will have to be added as members of this group.
|
||||||
|
The <command>pw</command> command may be used to add new
|
||||||
|
members:</para>
|
||||||
|
|
||||||
|
<screen>&prompt.root; <userinput>pw groupmod vboxusers -m <replaceable>yourusername</replaceable></userinput></screen>
|
||||||
|
|
||||||
|
<para>To launch <application>VirtualBox</application>, either select
|
||||||
|
the <guimenuitem>Sun VirtualBox</guimenuitem> item from your
|
||||||
|
graphic environment's menu, or type the following in a
|
||||||
|
terminal:</para>
|
||||||
|
|
||||||
|
<screen>&prompt.user; <userinput>VirtualBox</userinput></screen>
|
||||||
|
|
||||||
|
<para>For more information on configuring and using
|
||||||
|
<application>VirtualBox</application>, please visit the official
|
||||||
|
website at <ulink url="http://www.virtualbox.org"></ulink>.
|
||||||
|
As the &os; port is very recent, it is under heavy development.
|
||||||
|
For the latest information and troubleshooting instructions, please
|
||||||
|
visit the relevant page in the &os; wiki, at <ulink
|
||||||
|
url="http://wiki.freebsd.org/VirtualBox"></ulink>.</para>
|
||||||
|
</sect2>
|
||||||
|
|
||||||
|
<sect2 id="virtualization-other">
|
||||||
|
<title>Other Virtualization Options</title>
|
||||||
|
|
||||||
|
<para>There is ongoing work in getting <application>&xen;</application>
|
||||||
|
to work as a host environment on &os;. An experimental version of
|
||||||
|
this will appear in &os; 8.0.</para>
|
||||||
|
</sect2>
|
||||||
</sect1>
|
</sect1>
|
||||||
|
|
||||||
</chapter>
|
</chapter>
|
||||||
|
|
Loading…
Reference in a new issue