After installed Virtualbox 4.0.2 on Ubuntu 11.04 Natty, I found it cannot create a new virtual machine using virtualbox. I searched on Google and finally found out a solution.

As we know, Ubuntu 11.04 use kernel 2.6.38 as default Linux kernel. It’s said that the problem has something to do with the new Linux kernel. And it can be fixed by following two commands:

sudo find /usr/share/virtualbox/src/vboxhost -name *.h -exec perl -pi -w -e 's/linux\/autoconf/generated\/autoconf/g;' {} \;

sudo /etc/init.d/vboxdrv setup

Hope this could help!