Can't see shared folders in VirtualBox Ubuntu VM?

20,197

Short Answer:

sudo apt-get install virtualbox-guest-utils

Long Answer:

I had the same problem.

Assuming that we have already added the shared folder in the virtual box:

{

1) Machine -> Settings -> Shared Folders

2) Click on the "Add new shared folder" icon

enter image description here

3) Choose the path for the host folder you want to share (for example "C:\hostFolder")

4) Give "Folder Name" a name (for example "sharedFolderName")

5) Check "Auto-mount"

}

However, after starting the VM, there was nothing in my /media/.

But as soon as I ran:

sudo apt install virtualbox-guest-utils

I could see the sh_ folder:

ls /media/

Although you can access the content of your host folder through media, I suggest creating another folder:

mkdir ~/guestFolder

and then:

sudo mount -t vboxsf sharedFolderName ~/guestFolder

Now you can see content of the host folder here:

ls ~/guestFolder

Share:
20,197

Related videos on Youtube

jjwood1600
Author by

jjwood1600

Updated on September 18, 2022

Comments

  • jjwood1600
    jjwood1600 over 1 year

    I've been using VirtualBox for the first time to run Ubuntu and am having some problems with shared folders. I've done everything that I can think of after googling and looking around but still can't seem to find them anywhere.

    • I've added the user to "vboxsf"
    • I've installed the guest additions
    • I have permanent, Auto-Mount folders created on my host PC and shown in the "shared folders" at the top

    However, I cannot find these folders anywhere on the guest OS that I can use to access and bring files across/share them with my normal windows OS.

    Any help would be appreciated! Thanks!

    • Takkat
      Takkat over 6 years
    • George Udosen
      George Udosen over 6 years
      Did you restart the guest OS?
    • jjwood1600
      jjwood1600 over 6 years
      @George - Yes I did!
    • George Udosen
      George Udosen over 6 years
      Then re-install the Guest Additions again, might be a glitch!
    • jjwood1600
      jjwood1600 over 6 years
      @Takkat - Thanks for the links, however I tried to mount it following the steps and still got a "protocol error" which is strange..
    • jjwood1600
      jjwood1600 over 6 years
      @George - Just want to say, thanks so much! It now works! I didn't naturally think of reinstalling since I didn't think it was related to Guest Additions!