7

When I try to mount my shared folder on my Ubuntu virtual machine, I get this error:

/sbin/mount.vboxsf: shared folder '/home/john/shared' was not found (check VM settings / spelling)
  1. I have installed these packages:

    sudo apt-get install -y build-essential linux-headers-`uname -r`
    
  2. I have successfully installed Guest Auditions.

  3. I have created a mount point for the shared folder on the virtual machine:

    mountpoint

  4. I have set sharing on VM settings:

    sharing settings on VirtualBox

  5. I am trying to mount it using the command:

    sudo mount -t vboxsf shared ~/shared
    

The host computer runs Windows 10, the Ubuntu version is 20.04.1 LTS and the VirtualBox version is 6.1.

Am I missing something?

3
  • 3
    Does this answer your question? How to access a shared folder in VirtualBox?
    – N0rbert
    Commented Jul 30, 2021 at 19:02
  • 1
    It does not directly answer it, but thanks to it I found out, that name of the shared folder set in virtualbox settings cannot be the same as the name of directory you want to mount it into. In my case "shared" "shared". So after I renamed my directory to /home/john/shared_folder it started to work. Commented Jul 31, 2021 at 6:54
  • Thanks guys, I didn't realize that we are not supposed to name the two shared folders by the same name! Your comments did help resolve my issue.
    – Kris Stern
    Commented Aug 6, 2021 at 4:36

1 Answer 1

10

Eventually I found out, that a shared folder on Ubuntu cannot have the same name as the one I set in VirtualBox settings (steps 3 and 4 in my question).

So, instead of creating directory called shared on Ubuntu, I created directory called shared_folder. It works now.

So now, it looks like this:

share settings on VirtualBox

renamed shared directory

2
  • 1
    Thanks! I would have never guessed it... Why in the world can't they have the same name?
    – mitchus
    Commented Sep 17, 2021 at 13:18
  • I also note that you can have the same if: 1, you use the Auto mount option, or 2, you use the cli mount. e.g.: mount -t vboxsf data /data Commented May 22, 2023 at 0:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .