Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Last couple of weeks played around with Ubuntu 12.10. This is running as a guest on Virtualbox hosted at Windows 7. There have been some challenges with the Unity 3D stuff. Particular due to not supporting X11 release 1.13 till very recently. Since today we are able to download Virtualbox version 4.2.2 which has through guest additions also support for X11 release 1.13. SO far great work everybody.

Since Unity now only runs in 3D mode it would be nice to access the graphics card directly from Virtualbox. lshw -c display shows: VGA compatible controller; product: VirtualBox Graphics Adapter.

QUESTION: how to get the 3D and other graphics directly supported by the hardware ie Nvidia GeForce M310

share|improve this question
The only way is to ditch VBox and install Ubuntu on real hardware as dual boot or with the Windows installer. –  mikewhatever Oct 19 '12 at 10:21

3 Answers 3

PCI passthrough

PCI passthrough is experimentally supported in recent Virtual Box closed source (PUEL) versions. However there are several limitation, i.e. for a graphics card we can read from the Virtual Box User Manual:

AGP and certain PCI Express cards are not supported at the moment if they rely on GART

I cant tell if this is the case with the Nvidia M310, you will have to figure this out first before you try.

To get PCI passthrough working we also need a motherboard with an enabled IOMMU from BIOS settings (i.e. VT-d for Intel, AMD-Vi for AMD).

There are several additional prerequisites to be met (see Virtual Box Manual for details):

  • Your motherboard has an IOMMU unit.
  • Your CPU supports the IOMMU.
  • The IOMMU is enabled in the BIOS.
  • The VM must run with VT-x/AMD-V and nested paging enabled.
  • Your Linux kernel was compiled with IOMMU support, DMA remapping, and the PCI stub driver.
  • Your Linux kernel recognizes and uses the IOMMU unit.

We can then attach a PCI device with its bus:device.function properties read from lspci to our virtual machine using:

VBoxManage modifyvm "VM name" --pciattach <host-bus>:<host-device>.<host-function>@<guest-bus>:<guest-device>.<guest-function>.

See in the guest with lspci if the device was attached properly before installing drivers for this device.

Please also refer to the Virtual Box Manual for further limitations.

share|improve this answer
How about now, a few days to year 2015? Has "PCI passthrough" fully implemented in Virtual Box? –  user280121 Dec 27 '14 at 9:19

Have been able to determine that my system is not supporting PCI passthrough for the time being. This implies I will have to live with llvmpipe which software emulates the 3D graphics from Unity! I will leave Unity and go back to the old GNOME GUI on 12.10.

Trust that Canoncial will one of these days understand the impact of their decision. Many of us want to pilot in virtual space before going to install for production. It's a pitty.

share|improve this answer
Unity works in a Precise VM and I have Windows 8 working in a VirtualBox VM with enabled 3D support. 3D support and detection just needs do be getting worked on, but VirtualBox/Oracle are not much of help with their update policy. Doesn't matter if you use Windows or Linux. But of course Windows 8 has to be a great disaster because some people don't like it. –  LiveWireBT Oct 23 '12 at 4:05

Today I did install Virtual Box version 4.2.6_82870. I had been triggered by the changelog which stated that some 3D changes/bugs got fixed.

The performance of Ubuntu 12.10 is now very acceptable. Thanks to all working on the performance of Unity3D. My full support now goes to this, including the llvmpipe solution!

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.