Click here to Skip to main content
13,589,560 members
Click here to Skip to main content
Add your own
alternative version

Tagged as


Posted 27 Jul 2014
Licenced CPOL

Virtualbox Guest Additions for FreeBSD Guest

, 27 Jul 2014
Rate this:
Please Sign up or sign in to vote.
Virtualbox Guest Additions for FreeBSD Guest

I had to test something on FreeBSD. I was not sure how the test would turn out. Virtual machines help a lot in this regard. Virtualbox is one of the best tools available that helps in creating virtual machines. I can easily create virtual machines on Virtualbox and test to my heart’s content. Back-ups are possible. Throwing away the virtual machine too would cost nothing (apart from the time one invested in creating the virtual machine).

I installed FreeBSD on Virtualbox and everything went fine. I installed XFCE 4.10 on it. But most of the features that make Virtualbox a pleasure to work with need Virtualbox Guest Additions to be installed on the guest OS. This includes sharing the clipboard, mouse pointer integration, shared folders, full screen/scale-mode, etc. Installing Guest Additions is a trivial step in the Windows guests and on most Linux distributions. It is however a different story with FreeBSD. It is still simple but one needs to go through the FreeBSD’s unparalleled documentation.

The FreeBSD Wiki and FreeBSD Handbook have clear details of how to install Virtualbox Guest Additions to the FreeBSD guest. The gist is:

  • First, install the emulators/virtualbox-ose-additions package or port in the FreeBSD guest. This will install the port:
    cd /usr/ports/emulators/virtualbox-ose-additions && make install clean

The above process needs the port to be installed on the system. Each port has complete data needed for compiling and installing the application. However, the source code is not downloaded when you install the ports collection. The Makefile in the port will fetch and compile the source code and then install. This may not be suitable for all. About ports:

Each port’s Makefile automatically fetches the application source code, either from a local disk, CD-ROM or via ftp, unpacks it on your system, applies the patches, and compiles. If all went well, a simple make install will install the application and register it with the package system.

I did not have the ports tree with me and did not want to compile. I decided to install the virtualbox-ose-additions binary package. Luckily, it existed and did not have to go through the process of compiling everything. I did the following:

pkg_add -r  virtualbox-ose-additions

That was it. Done.

Add these lines to /etc/rc.conf:


That is all. There is nothing more to it. Everything now works as expected.

Edit: for FreeBSD 10.0

When I installed Xorg packages on the FreeBSD guest, I ran the Xorg -configure command too. After that, I installed the guest additions package. But the FULL SCREEN mode did not work. That is when I re-ran the Xorg -configure. The vboxvideo driver was recognized and file was generated at some temp location. I copied this file as /etc/X11/xorg.conf. Everything works now.

Filed under: CodeProject, FreeBSD, Virtualbox
Tagged: FreeBSD, Virtualbox, Virtualbox Guest Additions


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Software Developer HCL Technologies
India India
My name is M Sreekant. We South Indians have long names. My name, when completely expanded, is Mohan Sreekant Iyer. I like to be called "msiyer" due to economical considerations. You know what I mean Wink | ;)

I am a robot, a DNA replicator, made of chemical compounds. I try very hard to override nature's programming. A robot that knows, is a robot that seeks to know more.

I believe, any system or structure can be dissected by he who is curious enough. One day mankind will find loopholes in the laws of Physics that govern the cosmos, probably with my help. That will be the greatest day in my life or afterlife.

You may also be interested in...

Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Cookies | Terms of Use | Mobile
Web04-2016 | 2.8.180615.1 | Last Updated 28 Jul 2014
Article Copyright 2014 by msiyer
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid