Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Experts. I've successfully installed VMware tools for Ubuntu. Everything seems to work fine, but shared folders were not mounted automatically.
How do I get them to work?

If I run vmware-hgfsclient in terminal, I get the list of shared folders, but ls -l /mnt/hgfs is empty. Actually there's no hgfs dir in /mnt. I know I should probably use the vmware-hgfsclient tool, but I realy don't know how.

P.S. I wouldn't ask if I could understand the vmware-hgfsclient help I've read.

Any suggestions?

share|improve this question
@Mods, could someone create the 'shared-folders' and 'vmware-tools' tags ? – V-Light Mar 6 '11 at 17:23

7 Answers

up vote 16 down vote accepted

I have set up on Windows 7 host with Ubuntu 11.04 Desktop with VMware Tools installed on.

Virtual Machine settings

  • Folder sharing = Always Enabled
  • Make sure you have at least one Folder shared between the host and guest

On the Ubuntu Guest

  • check /mnt/hgfs that you can access your shared folder.

    If you don't see your shared folders (automounted) inside /mnt/hgfs , run VMware configuration tools:

    sudo vmware-config-tools.pl

  • update your fstab using the details below:

    gksu gedit /etc/fstab

    (I am using ubuntu desktop so use other text editor to enter the next line at the end of the file)

    .host:/{shared-folder} /{path-to-mount-on} vmhgfs defaults,ttl=5,uid=1000,gid=1000 0 0

  • Restart your vm (You may need to restart few times or get error message saying unable to mount just skip the error and restart)

share|improve this answer
1  
with {shared-fodler} you mean the NAME or something else ? For instance, if I'll run vmware-hgfsclient i'll get hst_dwnloads and hst_ebooks. So I should use on of them? so for hst_ebooks it should look like: .host:/hst_dwnloads<white-space>/mnt/hgfs/ vmhgfs defaults,ttl=5,uid=1000,gid=1000 0 0 or not ? – V-Light May 11 '11 at 9:10
@V-Light if you cd /mnt/hgfs/ then ls -a you'll see that share folders are auto mounted there. When you do sudo mount -t vmhgfs .host:/hst_ebooks ~/hst_ebooks this will mount hst_ebooks into your home directory. What you might be wanting to do is making is easy for you to use shared folders for that try above. – Azizur May 11 '11 at 20:32
that's the problem. There's NOTHING in /mnt/hgfs/ The dir ist empty. – V-Light May 11 '11 at 21:46
@V-Light take a look at How to Share folders with your Ubuntu Virtual Machine (guest) – Azizur May 12 '11 at 9:17
@Aizur, the guide didn't help. But after 'cleaning' (uninstalling open- and 'normal'-vmwaretools) I was finally able to install open-vm-tools and mount shared folders. Thank you for you advice with fstab – V-Light May 12 '11 at 22:56
show 1 more comment

run vmware-config-tools.pl, AGAIN!

Refer: http://www.laotudou.com/vmware-player-share-folder.html

share|improve this answer
2  
Simple as that, and it worked just fine! – ysap Sep 25 '12 at 19:29
vmware-config-tools.pl is not available if using open-vm-tools from Ubuntu-Software-Center or compiled from source from sourceforge. In that case user must use vmware-hgfsmounter as @snth describes in his answer. It may be possible to use open-vm-toolbox, tools and components for VMware guest systems (GUI tools) package from the Ubuntu software repository – Mark Mikofski Jan 3 at 21:13

I've been having the same problem but I think I have just been able to make some progress.

Type vmware-hfgs and then press the <Tab> key which will show you that there is also a vmware-hgfsmounter command. If you call that without any options it will print some help that shows you how to call this as part of the `mount' command. Using that info I then ran the following which worked for me:

cd /mnt
sudo mkdir win7share
sudo mount -t vmhgfs .host:/win7share /mnt/win7share

I was then able to access the Win 7 share and copy files to and from there.

If you want to make this permanent then I suspect that you will need to edit the /etc/fstab file but I can't help you there yet.

share|improve this answer
If i execute sudo mount -t vmhgfs .host:/hst_ebooks /mnt/hgfs/hst_ebooks i get an Error: Error: cannot mount filesystem: No such device – V-Light May 11 '11 at 9:29
Have you created the /mnt/hgfs/hst_ebooks mount point? I think in my case /mnt/hgfs already existed and in case there were any special event handlers watching that directory I rather created a directory under /mnt directly. Therefore try sudo mkdir /mnt/hst_ebooks and then try running the command again. – snth May 12 '11 at 7:21
sudo vmware-hgfsmounter <host:sharename> <dir> runs the same commands as sudo mount -t vmhgfs <host:sharename> <dir> where <sharename> is vmware-hgfsclient – Mark Mikofski Jan 3 at 5:41

I had a similar problem. The folder /mnt/hgfs/ appeared back again when I assured that open-vm was uninstalled. As follows

sudo apt-get purge open-vm-tools
sudo apt-get purge open-vm-dkms

and reinstalled vmware-tools

share|improve this answer

(applies to Mac VMware Fusion and Ubuntu file sharing) When you are asked in vmware-config-tools.pl about whether you want HGFS, say yes! (The default is 'no' and you may have skipped over it when hitting enter/return). This should give you /mnt/hgfs after the tools are installed.

share|improve this answer

this worked for me:

cd /mnt
sudo mkdir hgfs
sudo vmware-hgfsmounter .host:`vmware-hgfsclient` /mnt/hgfs

assuming of course that I had already enabled a shared folder from the host machine in vmware player settings

share|improve this answer

You need to install the VMWare tools first, after that the vmware-config-tools can be used globally. For a more detailed guide, you can see here.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.