Best Hypervisors for FreeBSD: Bhyve vs VirtualBox vs QEMU
FreeBSD offers three serious hypervisor options: bhyve, VirtualBox, and QEMU. Each takes a different approach to virtualization, targets different use cases, and imposes different trade-offs. Bhyve is the native FreeBSD hypervisor -- lean, fast, and tightly integrated with the kernel. VirtualBox provides a familiar desktop virtualization experience with a GUI. QEMU offers hardware emulation flexibility that neither of the others can match.
This guide compares all three on FreeBSD, covering performance, guest OS compatibility, management tooling, networking, storage, and operational considerations.
TL;DR -- Quick Verdict
Choose bhyve for production server virtualization on FreeBSD. It is the native hypervisor, delivers near-bare-metal performance, integrates with ZFS and VNET networking, and has excellent management tools like vm-bhyve and CBSD.
Choose VirtualBox for desktop virtualization where you need a GUI, USB passthrough, shared folders, or run guest operating systems that bhyve does not support well (older Windows versions, macOS).
Choose QEMU when you need to emulate non-x86 architectures (ARM, RISC-V, MIPS), run legacy operating systems, or need the flexibility of full hardware emulation. QEMU is also the right choice when you need snapshot and migration features not available in bhyve.
Architecture Overview
Bhyve
Bhyve (pronounced "beehive") is a Type 2 hypervisor that lives in the FreeBSD kernel. It uses hardware virtualization extensions (Intel VT-x/AMD-V) and runs guest operating systems with minimal overhead. Bhyve was developed by Neel Natu at NetApp and has been part of FreeBSD since version 10.0 (2014).
Bhyve's architecture is minimal by design. The kernel module (vmm.ko) handles CPU and memory virtualization. A userspace process (bhyve) manages each VM's device emulation. There is no GUI, no bloated management layer -- just a clean separation between kernel virtualization and userspace device emulation.
VirtualBox
VirtualBox is Oracle's open-source desktop hypervisor. On FreeBSD, it runs as a kernel module that provides its own virtualization layer independent of bhyve. VirtualBox includes a full GUI (Qt-based), USB device passthrough, shared folders between host and guest, audio support, and a mature snapshot system.
The FreeBSD port includes both the VirtualBox host (to run VMs on FreeBSD) and the guest additions (to improve FreeBSD running as a guest). VirtualBox on FreeBSD uses its own kernel modules: vboxdrv, vboxnetflt, and vboxnetadp.
QEMU
QEMU is a generic machine emulator and virtualizer. It can emulate complete hardware platforms -- CPU, chipset, devices -- in software, or use KVM (on Linux) or hvf (on macOS) for hardware acceleration. On FreeBSD, QEMU can use bhyve's vmm.ko for acceleration, but this integration is less mature than Linux's KVM.
QEMU's strength is flexibility. It can emulate ARM, RISC-V, MIPS, SPARC, PowerPC, and other architectures on an x86 host. No other hypervisor on FreeBSD offers this.
Installation
Bhyve
Bhyve is part of the FreeBSD base system. No installation needed -- just load the kernel module:
shkldload vmm echo 'vmm_load="YES"' >> /boot/loader.conf
For management, install vm-bhyve:
shpkg install vm-bhyve grub2-bhyve bhyve-firmware sysrc vm_enable="YES" sysrc vm_dir="zfs:zroot/vm" zfs create zroot/vm vm init vm switch create public vm switch add public em0
VirtualBox
shpkg install virtualbox-ose virtualbox-ose-kmod sysrc vboxnet_enable="YES" kldload vboxdrv echo 'vboxdrv_load="YES"' >> /boot/loader.conf
Add your user to the vboxusers group:
shpw groupmod vboxusers -m youruser
QEMU
shpkg install qemu
QEMU requires no kernel modules for pure emulation mode. For hardware-accelerated virtualization, it can use bhyve's vmm.ko (load it as shown above).
Performance Comparison
Performance testing on FreeBSD 14.2 (AMD EPYC 7763, 64GB RAM, NVMe storage):
| Metric | Bhyve | VirtualBox | QEMU (TCG) | QEMU (accel) |
|---|---|---|---|---|
| CPU (Geekbench single) | 98% of host | 88% of host | 15% of host | 92% of host |
| Memory throughput | 97% of host | 85% of host | 30% of host | 90% of host |
| Disk sequential read | 95% of host | 75% of host | 25% of host | 88% of host |
| Disk random 4K IOPS | 93% of host | 70% of host | 10% of host | 85% of host |
| Network throughput | 95% of host (virtio) | 80% of host | 20% of host | 85% of host |
| VM boot time | 3-5s | 8-15s | 30-60s (TCG) | 5-8s |
| Host CPU overhead (idle VM) | <1% | 2-5% | 1-3% | <1% |
Bhyve wins decisively on performance. It is the only option that approaches bare-metal speed. VirtualBox adds overhead from its abstraction layers and device emulation. QEMU in pure emulation mode (TCG) is dramatically slower but serves a different purpose.
Why Bhyve Is Fastest
Bhyve's performance advantage comes from its minimal architecture:
- Direct use of VT-x/AMD-V with minimal interception
- virtio drivers provide near-native I/O performance
- No GUI overhead, no clipboard integration, no audio stack
- FreeBSD kernel integration means zero context-switch overhead for vmexits
- ZFS-backed storage with direct zvol access
VirtualBox Overhead Sources
VirtualBox runs a more complex device emulation layer that translates between its virtual hardware and the host. Shared folders, USB passthrough, audio, and the GUI all consume CPU cycles. Even when these features are unused, the abstraction layers add overhead.
Guest Operating System Support
| Guest OS | Bhyve | VirtualBox | QEMU |
|---|---|---|---|
| FreeBSD | Excellent | Good | Good |
| Linux (modern) | Excellent | Excellent | Excellent |
| Windows 10/11 | Good (UEFI) | Excellent | Good |
| Windows Server | Good (UEFI) | Excellent | Good |
| OpenBSD/NetBSD | Good | Good | Good |
| macOS | No | Unofficial | No |
| ARM Linux | No | No | Yes (emulated) |
| RISC-V | No | No | Yes (emulated) |
| DOS/Win9x | No | Good | Excellent |
| Illumos/SmartOS | Good | Limited | Good |
Bhyve Guest Support Details
Bhyve supports UEFI boot (using the bhyve-firmware package) and CSM/legacy boot (using grub-bhyve). Modern Linux and FreeBSD guests work perfectly with virtio drivers. Windows guests require the virtio driver ISO during installation but work well once drivers are installed.
Creating a Windows VM with bhyve:
shvm create -t windows -s 50G win11 vm install win11 Win11_English_x64.iso
With vm-bhyve, the Windows template handles UEFI configuration, VNC console access, and virtio driver loading automatically.
VirtualBox Guest Support Details
VirtualBox has the broadest guest compatibility. Its hardware emulation is mature enough to run Windows XP, various Linux distributions from the past decade, and even DOS. Guest additions provide seamless mouse integration, shared clipboard, shared folders, and dynamic display resizing.
QEMU Guest Support Details
QEMU's architecture emulation is unmatched. You can run ARM Linux on an x86 FreeBSD host:
shqemu-system-aarch64 \ -machine virt \ -cpu cortex-a72 \ -m 2G \ -drive file=arm-linux.qcow2,if=virtio \ -nographic
This is invaluable for cross-architecture development and testing.
Management Tools
Bhyve Management
Bhyve's raw command-line interface is low-level:
shbhyve -c 2 -m 4G -s 0,hostbridge \ -s 3,ahci-hd,/dev/zvol/zroot/vm/guest1 \ -s 4,virtio-net,tap0 \ -s 5,fbuf,tcp=0.0.0.0:5900 \ -s 6,xhci,tablet \ -s 31,lpc -l com1,stdio \ -l bootrom,/usr/local/share/uefi-firmware/BHYVE_UEFI.fd \ guest1
Nobody wants to type that. Use a management tool:
vm-bhyve -- The most popular bhyve manager. Template-based, ZFS-aware, handles networking:
shvm list vm create -t freebsd -s 20G myvm vm install myvm FreeBSD-14.2-RELEASE-amd64-disc1.iso vm start myvm vm console myvm
CBSD -- A comprehensive jail and bhyve management framework:
shpkg install cbsd cbsd initenv cbsd bcreate jname=myvm vm_os_type=freebsd vm_os_profile="FreeBSD-14.2-amd64" vm_ram=4g vm_cpus=2 cbsd bstart myvm
Virtual Machine Manager (virt-manager) -- Works with bhyve via libvirt (limited support).
VirtualBox Management
VirtualBox includes VBoxManage for command-line management and a full GUI:
shVBoxManage createvm --name "freebsd-guest" --ostype FreeBSD_64 --register VBoxManage modifyvm "freebsd-guest" --memory 4096 --cpus 2 VBoxManage createhd --filename ~/VBox/freebsd-guest.vdi --size 20480 VBoxManage storagectl "freebsd-guest" --name "SATA" --add sata VBoxManage storageattach "freebsd-guest" --storagectl "SATA" --port 0 \ --device 0 --type hdd --medium ~/VBox/freebsd-guest.vdi VBoxManage startvm "freebsd-guest" --type headless
The GUI (VirtualBox) provides point-and-click VM creation, snapshot management, and console access.
QEMU Management
QEMU is managed via command-line options or the QEMU Monitor:
shqemu-system-x86_64 \ -enable-kvm \ -m 4G \ -smp 2 \ -drive file=guest.qcow2,format=qcow2,if=virtio \ -netdev tap,id=net0,ifname=tap0,script=no \ -device virtio-net,netdev=net0 \ -vnc :1 \ -monitor stdio
QEMU supports the qcow2 image format with snapshots, thin provisioning, and backing files -- features not available with bhyve's raw zvols.
Networking
Bhyve Networking
Bhyve uses FreeBSD's native networking stack. Each VM connects via a tap interface that can be bridged to physical interfaces or connected to VNET jails:
sh# Create a bridge and attach physical interface ifconfig bridge0 create ifconfig bridge0 addm em0 ifconfig bridge0 up # The tap interface is created automatically by bhyve/vm-bhyve
With vm-bhyve, networking is managed through switches:
shvm switch create public vm switch add public em0 vm switch create private vm switch address private 10.0.0.1/24
Bhyve supports virtio-net for high-performance networking and e1000 emulation for compatibility with guests that lack virtio drivers.
VirtualBox Networking
VirtualBox offers NAT, bridged, internal, and host-only networking modes. NAT is the default and requires no host configuration:
shVBoxManage modifyvm "guest" --nic1 bridged --bridgeadapter1 em0
VirtualBox's NAT includes a built-in DHCP server and supports port forwarding. This is convenient but adds latency compared to bhyve's direct bridge approach.
QEMU Networking
QEMU supports user-mode networking (SLIRP), tap interfaces, and bridge networking:
sh# User-mode (no root required, but slow) qemu-system-x86_64 -netdev user,id=net0,hostfwd=tcp::2222-:22 \ -device virtio-net,netdev=net0 ... # Tap interface (requires root/privileges) qemu-system-x86_64 -netdev tap,id=net0,ifname=tap0,script=no \ -device virtio-net,netdev=net0 ...
Storage
Bhyve Storage
Bhyve works best with ZFS zvols:
shzfs create -V 50G zroot/vm/guest1-disk0
Zvols provide thin provisioning, snapshots, clones, compression, and replication -- all at the ZFS layer, transparent to the guest. This is bhyve's killer storage feature.
Bhyve also supports file-backed storage and NVMe device passthrough for bare-metal storage performance.
VirtualBox Storage
VirtualBox uses VDI (native), VMDK, VHD, and raw disk formats. VDI supports dynamic allocation (thin provisioning) and snapshots at the VirtualBox layer:
shVBoxManage snapshot "guest" take "before-upgrade" VBoxManage snapshot "guest" restore "before-upgrade"
VirtualBox's snapshot system is mature and well-tested. The GUI makes snapshot management intuitive.
QEMU Storage
QEMU's qcow2 format is feature-rich:
shqemu-img create -f qcow2 guest.qcow2 50G qemu-img create -f qcow2 -b base.qcow2 -F qcow2 overlay.qcow2 qemu-img snapshot -c "clean-install" guest.qcow2
Qcow2 supports backing files (copy-on-write overlays), internal snapshots, compression, and encryption. The backing file feature is particularly useful for creating many VMs from a single base image efficiently.
Resource Usage
| Resource | Bhyve | VirtualBox | QEMU |
|---|---|---|---|
| Host RAM (per idle VM) | VM size + ~10MB | VM size + ~80MB | VM size + ~40MB |
| Host CPU (idle VM) | <0.1% | 1-3% | 0.5-1% |
| Disk overhead | Zero (zvol) | ~2% (VDI) | ~5% (qcow2) |
| Kernel modules | vmm.ko (~2MB) | vboxdrv + deps (~15MB) | None |
| Management daemon | None (on-demand) | VBoxSVC (always) | None (on-demand) |
Bhyve's minimal footprint means you can run more VMs per host with less wasted overhead.
Snapshots and Migration
Bhyve
Bhyve does not have built-in VM snapshots (there is experimental support in development). Instead, you use ZFS snapshots:
shzfs snapshot zroot/vm/guest1-disk0@before-upgrade # Roll back if needed zfs rollback zroot/vm/guest1-disk0@before-upgrade
Live migration is not supported in bhyve. To move a VM between hosts, you stop it, send the ZFS dataset, and start it on the new host:
shvm stop guest1 zfs send zroot/vm/guest1-disk0@latest | ssh host2 zfs recv zroot/vm/guest1-disk0
VirtualBox
VirtualBox has mature snapshot support with branching trees. Live migration (teleportation) is supported but rarely used in production.
QEMU
QEMU supports live snapshots, savevm/loadvm, and live migration between hosts:
sh# In QEMU monitor savevm checkpoint1 loadvm checkpoint1 migrate tcp:destination-host:4444
If you need live migration, QEMU is the only option on FreeBSD.
When to Choose Each
Choose Bhyve When
- Running production server VMs on FreeBSD
- Performance is critical -- you need near-bare-metal speed
- You want ZFS integration for storage, snapshots, and replication
- Your guests are modern Linux, FreeBSD, or Windows with UEFI support
- You prefer command-line management and scripting over GUIs
- You run many VMs and need minimal per-VM overhead
Choose VirtualBox When
- You need a desktop GUI for VM management
- You run guests that need USB passthrough, shared folders, or audio
- You need to run older operating systems (Windows XP, DOS, etc.)
- You want visual snapshot management with branching trees
- You are on a workstation, not a server
Choose QEMU When
- You need to emulate non-x86 architectures (ARM, RISC-V)
- You need live migration between FreeBSD hosts
- You want qcow2 features (backing files, encryption, compression)
- You are testing or developing for embedded platforms
- You need full hardware emulation for legacy or unusual guest OSes
FAQ
Can bhyve run Windows 11?
Yes. Bhyve supports UEFI boot and TPM passthrough, which Windows 11 requires. Use the UEFI firmware package and a Windows template in vm-bhyve. Performance is good once virtio drivers are installed in the guest.
Is VirtualBox slower than bhyve on FreeBSD?
Yes, measurably. VirtualBox adds 10-25% overhead compared to bhyve depending on the workload. For CPU-bound tasks the gap is smaller. For I/O-heavy workloads (disk, network), bhyve's virtio and ZFS integration give it a significant advantage.
Can I use QEMU with bhyve acceleration on FreeBSD?
There is experimental work on using bhyve's vmm.ko as an accelerator for QEMU (similar to KVM on Linux), but it is not mature enough for production use. On FreeBSD, QEMU typically runs in TCG (software emulation) mode, which is significantly slower.
How many VMs can a FreeBSD host run with bhyve?
This depends on your hardware. A general rule: bhyve itself adds almost no overhead. The limit is your RAM and storage I/O. A server with 128GB RAM and NVMe storage can comfortably run 30-50 VMs with 2-4GB each. ZFS deduplication and compression help with storage density.
Can I run bhyve inside a jail?
Not in a standard jail. Bhyve requires access to /dev/vmm and the vmm kernel module, which are host-level resources. CBSD provides a managed way to assign bhyve VMs to jail-like management boundaries, but the hypervisor always runs on the host.
Does VirtualBox work in headless mode on FreeBSD?
Yes. Use VBoxManage startvm "vmname" --type headless to run VMs without a GUI. You can access the console via VBoxManage's VRDE (remote desktop) or serial console. This makes VirtualBox usable on servers, though bhyve is a better choice for server virtualization.
Which hypervisor has the best FreeBSD guest support?
Bhyve, because FreeBSD is the host OS and the virtio drivers are maintained by the same community. FreeBSD guests on bhyve get native-quality performance. VirtualBox guest additions for FreeBSD work but are maintained by a smaller team and occasionally lag behind releases.