I'm trying to install the Guest Additions in VirtualBox 4.04.on ubuntu 11.10

I have this error:

The headers for the current running kernel were not found.
If the module compilation fails then this could be the reason.

Note that I have already installed the headers but still get this error.

Do you have you an ideas please?

  • the headers have already installed !! – user78022 Jul 19 '12 at 14:34
  • i have done apt-get install virtualbox-guest-additions and in the restart i have this message: modprobe vboxsf failed! starting the virtualbox-guest-additions fail ! – user78022 Jul 19 '12 at 16:54
  • Did you install the guest additions in the guest? (Edited my answer to make that clear). – Takkat Jul 19 '12 at 20:37
  • @Takkat yes i have done apt-get install virtualbox-guest-additions in ubuntu 11.10 now i canot open the virtual machine 11.10 i don't know why , have you an idea please it display that starting the virtualbox-guest-additions fail ! it still blocked – user78022 Jul 20 '12 at 12:21
  • Is this a duplicate of askubuntu.com/questions/98416/… ? – David Cary Sep 17 '14 at 21:31

I found that installing dkms with

sudo apt-get install dkms

resolved this error/warning for me. See this answer.

| improve this answer | |

This command will install the kernel headers:

sudo apt-get install linux-headers-$(uname -r)

Now, try to install the Guest Additions again.

| improve this answer | |

For me (Ubuntu 12.04 LTS host; Ubuntu 13.04 guest; virtualbox 4.1.18 running on the host), it seems that the downloaded guest-additions iso on the host was old, so installing by mounting that iso through vbox's menus failed consistently. There was no package virtualbox-guest-additions available on the guest, so I installed

$ sudo apt-get install virtualbox-guest-dkms

instead, which also pulled in dkms, fakeroot, virtualbox-guest-utils, and virtualbox-guest-x11. Then I rebooted the guest, and copy/paste worked (also, the resolution jumped up).

| improve this answer | |
  • This worked for me! – Mike Pelley Jul 19 '13 at 22:04

It seems that ubuntu 11.10 does not ship compiler by default. Try apt-get install gcc gcc-4.7

| improve this answer | |

The message you get may not be related to the failure building the Guest Additions. I usually do see this message but Guest Additions build fine and run as expected.

Here are some steps we can try in case we cannot install the guest additions:

  • We may just try to install them again after rebooting the guest OS. If that still does not succeed we can also try to install guest additions as root from command line.

  • It may also be worth to update the guest OS before we install the Guest Additions.

  • Older versions of virtual box may have bugs that stand against a successful install of the GA. Update Virtual Box to the current version (at present 4.1.18).

  • If all fails you can also download and install the ready-built guest additions from the repositories (these will also run with the PUEL version of Virtual Box but they may be out-dated in some aspects) by running the following in the guest Ubuntu:

     sudo apt-get install virtualbox-guest-additions
| improve this answer | |

First of all find your kernel version by:

$ uname -a
Linux ibm **3.5.0-24**-generic #37-Ubuntu SMP Thu Feb 7 01:50:30 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

Next update apt by:

$ sudo apt-get update

Finally install your kernel version (3.5.0-24) header package by apt

$ sudo apt-get install linux-headers-3.5.0-24-generic
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy