Virtualization: VirtualBox

Configuration

by ross at 20:03:31 on July 27, 2017

Install

Just run

# pkg install virtualbox-ose

Or install it from sources:

# cd /usr/ports/emulators/virtualbox-ose
# make install clean
# rehash

Options for virtualbox-ose:

  • If you need GUI check QT and X11
  • Check GUESTADDITIONS
  • If you need headless mode check VNC

You must have sources of your system available in /usr/src. After upgrading system don't forget to rebuild VirtualBox kernel module: portupgrade -f virtualbox-ose-kmod.

Add to /boot/loader.conf:

vboxdrv_load="YES"
# kldload vboxdrv

Add yourself to vboxusers group:

# pw groupmod vboxusers -m youruserhere

To the system section of your /etc/devfs.rules append the line for vboxnetctl device (create the file if it does not exist):

[system=10]
add path 'vboxnetctl' mode 0660 group vboxusers

Append to /etc/rc.conf:

devfs_system_ruleset="system"
vboxnet_enable="YES"

Run:

# service devfs restat
# service vboxnet start

GUI

Using VirtualBox via GUI is very simple, I won't descibe it here. Just run VirtualBox command or find it in the applications menu of your DE.

Comments