Linux headers update breaking virtualbox folder sharing?

7,274

Virtual Box shared folders functionality depends on guest additions kernel modules. A kernel update should automatically reload all modules using dkms (which should be installed by default).

Unfortunately this does not always work as expected. Then we have to reinstall the guest additions:

Guest additions will then be available after a reboot of the guest.

If this fails it is worth to try again as sometimes the installation does not work as expected (without errors or warnings).

It may also worth to try to remove the guest additions before we install them again using the uninstall script (replace x.x.xxx with your version of Virtual Box):

cd /opt/<VirtualBoxAddtions-x.x.xx>/
sudo ./uninstall.sh
Share:
7,274

Related videos on Youtube

ptr
Author by

ptr

Updated on September 18, 2022

Comments

  • ptr
    ptr over 1 year

    I have a virtualbox running ubuntu 13.10 (running on a 13.10 host) that has two shared folders on the host that are mounted at boot. A while ago the guest ran some updates that broke the folder sharing, the guest could no longer see the devices to mount them. I had a hunch from reading around that it might be something to do with the guest additions, as getting the 4.3 release of virtualbox from the oracle repo and updating the guest additions solved the problem. The issue is, today's linux headers update broke the mount again, and there doesn't appear to be an updated guest additions to go to! (re-installing them doesn't work).

    Obviously at a basic level, not installing the updates would prevent this problem. However I'd be interested in finding out exactly why it's behaving like this.

    I'm a bit out of my depth here but if someone could point me in the right direction of a solution I'd appreciate it.

    If there's more useful info I can provide let me know.

    Full error message I'm now getting when trying to use the manager to mount the Guest Additions CD Image:

    Unable to access "VBOXADDITIONS_4.3.4_91027"

    Error mounting /dev/sr0 at /media/ptinkler/VBOXADDITIONS_4.3.4_91027: Command-line 'mount -t "iso9660" -o "uheper=udisks2,nodev,nosuid,uid=100,gid=1000,iocharset=utf8,mode=0400,dmode=0500" "/dev/sr0" "/media/maplecroft/VBOXADDITIONS_4.3.4_91027" exited with non-zero exit stats 32: mount: unknown filesystem type 'iso9660'

    • Takkat
      Takkat over 10 years
      What error do you get on failing to resinstall the guest additions?
    • ptr
      ptr over 10 years
      No error, it just doesn't fix the problem.
    • Takkat
      Takkat over 10 years
      See if the virtualbox shared folders kernel module is loaded with lsmod | grep vboxsf.
    • ptr
      ptr over 10 years
      no output at all from that command, lsmod | grep vbox has no output at all either actually.
    • Takkat
      Takkat over 10 years
      Then you need to reinstall the guest additions. Sometime we have to do this more than once to finally get them working...
  • ptr
    ptr over 10 years
    Looks like dkms wasn't installed on the guest. Installed it now. I'd like to reinstall the guest additions, however now when I try to mount the Guest Additions CD Image, I get an error: Unable to mount VBOXADDITIONS_4.3.4_91027 to do with unknown filesystem type 'iso9660'
  • ptr
    ptr over 10 years
    That's what I'm trying to do.
  • ptr
    ptr over 10 years
    Added the full error message to the OP
  • ptr
    ptr over 10 years
    would you prefer I make the secondary issue a separate question?
  • ptr
    ptr over 10 years
    fairly certain the .iso is ok, I tried it and it worked just fine on an older cloned .vdi of the virtual machine. How do I mount manually?
  • ptr
    ptr over 10 years
    To be honest it turned out to be easier just to go back to the old clone and build everything up from there. having dkms installed meant that when it did the updates, everything carried on working just fine.
  • Takkat
    Takkat over 10 years
    Glad you got it sorted out! I will now delete all my comments above for cleanup :)