Page 1 of 1

[SOLVED] How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 03:21
by virubix
In my VB on Mac mini I have created shared folders pointing to a folder in my home directory with full access as permanent mount. However I do not know where should this directory (folder) appear in Nautilus on Ubuntu? Under Network there is an icon named Windows Network, however clicking on it gives me an error saying that it failed to retrieve share list from the server. I have then also added the pertinent folder in Mac's Shared Folders in System Preferences, but nothing changed even after rebooting VB for every change I made.

Can anybody tell me what I am missing.

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 03:35
by Perryg
Network share or the VirtualBox shared folders?
VirtualBox shared folders you should read 4.3 Shared folders in your VirtualBox users guide.

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 03:53
by virubix
Perryg wrote:Network share or the VirtualBox shared folders?
VirtualBox shared folders you should read 4.3 Shared folders in your VirtualBox users guide.
I read all of that many times. I have this working on my Linux host with windows guests. As well as on iMac host also with windows. Trouble is on my Mac mini hpost and Linux guest! 4.3 in VB Manual tells you nothing new which basically I have already described in my 1st post.

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 03:57
by virubix
There is some hope :P

Code: Select all

mount -t vboxfs [-o OPTIONS] sharename mountpoint
I only do not know what options are required :?:

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:00
by Perryg
Most generally you would use the rw gid uid
These options are in the man page of your guest.
Here is a generic one to follow.

Code: Select all

sudo mount -t vboxsf -o rw,uid=1000,gid=1000 <share name>  <mount point>
Of course you should verify your uid and gid type id in a terminal and it will tell you.
Oh and the guest additions must be installed (in the guest) before this will work.

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:14
by virubix
I did all that and it blows up

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:19
by Perryg
What do you mean by blows up?

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:22
by virubix
Thank you very much, I got it working. I did not notice that vboxfs is not spelled naturally! It is actually vboxsf :P :P :P

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:25
by Perryg
OK now if you would like these to mount at boot. Just edit the /etc/rc.local file and add the same line in there. Be sure exit 0 is the last line.

Re: How to share Mac host's folders with Ubuntu guest

Posted: 16. Dec 2011, 04:41
by virubix
Yes, I was going to do that only why the rc.local? istn't the fstab the proper place to do that?

Re: [SOLVED] How to share Mac host's folders with Ubuntu gue

Posted: 16. Dec 2011, 05:01
by virubix
Perryg, thank you again. It was a true pleasure to talk to you.

Re: [SOLVED] How to share Mac host's folders with Ubuntu gue

Posted: 16. Dec 2011, 05:18
by Perryg
Because the fstab is sometimes loaded before the VBox modules and have at times failed. It can even halt the boot process if you make a mistake like the vboxfs instead of the vboxsf. The /etc/rc.local is run last after everything else and is more forgiving.

Your welcome.