How to map host PCI device to virtualbox?
Solution 1:
VirtualBox can in fact pass PCI devices through in recent versions, though it takes some special configuration and certain limitations apply. In short, you need the following support on the host to make it even possible:
- IOMMU hardware support (VT-d from Intel or AMD-Vi)
- BIOS that has the IOMMU support enabled
- The guest machine needs Nested Paging enabled
- Modern enough Linux kernel (version 2.6.31 or later) with IOMMU support compiled in
- VirtualBox 4.1.x or later (not sure exactly when support was added)
If you have met those requirements you can use the VBoxManage modifyvm --pciattach
and VBoxManage modifyvm --pcidetach
to enable or disable a specific device for a given VM.
Please read the relevant section of the user manual for more complete info: https://www.virtualbox.org/manual/ch09.html#pcipassthrough