FreeBSD On XenServer

Update (20131106): Please see FreeBSD 10 On CloudStack + XenServer Blog post instead.

UPDATE (20131015): Major changes have gone into FreeBSD 10 including fixes for the xenbusb_nop_confighook_cb. BETA2 onwards would support XenServer out of the box. The ISOs are available at

Pretty excited to have FreeBSD 10.0-CURRENT running under XenServer 6.1 in HVM mode using the XENHVM configs.

Follow the instructions in to workaround the ‘xenbusb_nop_confighook_cb’ issue on boot-up. UPDATE (20131015):This is now fixed with r256423

VM General Settings Screen

The steps in a nutshell:

  1. Download a very recent CURRENT snapshot ISO from
  2. Create a new ‘other‘ VM using Citrix XenCenter UI from the snapshot ISO
  3. Build and install the XENHVM kernel Update (20130927): Latest FreeBSD 10 Current has XENHVM merged into the GENERIC kernel and works well with the fully open source XenServer 6.2 release. When FreeBSD 10 is officially released, it should work out of the box
  4. Fix up ‘rc.conf‘ and ‘fstab‘ to use the Xen virtual devices
  5. Install the Xen tools from ports
  6. Shutdown the VM
  7. Destroy the CDROM VBD device
  8. VM Start

It would be nice if Citrix were to officially support stock FreeBSD installation at some point. Their NetScaler product is actually based on FreeBSD. In the meantime, thanks to the FreeBSD Xen community on making the OS work on EC2 and thus XenServer. Update (20130927): Most of the recent updates to FreeBSD -CURRENT to support Xen has been contributed by Citrix.

shanu@fbsd1:~ % uname -a
FreeBSD fbsd1 10.0-CURRENT FreeBSD 10.0-CURRENT #1: Sat Jun  8 20:43:11 IST 2013     root@fbsd1:/usr/obj/usr/src/sys/XENHVM  amd64
shanu@fbsd1:~ % pkg info | grep -i xen
xe-guest-utilities-6.0.2 FreeBSD VM tools for Citrix XenServer and XCP
xen-tools-4.1.3_3 Xen tools within FreeBSD domU
shanu@fbsd1:~ % /usr/local/bin/xen-detect
Running in HVM context on Xen v4.1.



By Shanker Balan

Shanker Balan is a devops and infrastructure freelancer with over 14 years of industry experience in large scale Internet systems. He is available for both short term and long term projects on contract. Please use the Contact Form for any enquiry.

Leave a comment

Your email address will not be published. Required fields are marked *