Vmware: mount shared folder in guest (Ubuntu 18.4)

  1. set up the shared folder in Vmware station, with the guess os turned off: go to settings/Options/Shared Folders, choose the folders, and make sure you choose “Always enabled” as the “folder sharing” option.
  2. power on Ubuntu 18.4, and install open-vm-tools: sudo apt install open-vm-tools open-vm-tools-desktop
  3. make a folder: sudo mkdir -p /mnt/hgfs
  4. mount the shared folder:

sudo /usr/bin/vmhgfs-fuse .host:/ /mnt/hgfs -o subtype=vmhgfs-fuse,allow_other

or sudo mount -t fuse.vmhgfs-fuse .host:/ /mnt/hgfs -o allow_other

then the shared folder will appear in /mnt/hgfs/

reference link: https://gist.github.com/darrenpmeyer/b69242a45197901f17bfe06e78f4dee3