CentOS7 set up and use open-vm-tools to share folders
1. Install open-vm-tools:
yum install open-vm-tools
After the installation is complete, shut down the server init 0
and set up a shared folder.
The default configuration is sufficient when using the Add Shared Folder Wizard.
If you set the shared folder in the virtual machine settings in advance, you can directly enter the command to restart after installing open-vm-tools . Enter the server, enter:reboot
vmware-hgfsclient
As shown in the figure, if the previously set shared file name appears, it means that it can be mounted. (The name of the shared folder I created before is share )
Create a mount directory and mount:
mkdir /mnt/hgfs
vmhgfs-fuse .host:/ /mnt/hgfs
Points to note:
1. Root user authority is required to mount.
2. Need to remount (execute vmhgfs-fuse .host:/ /mnt/hgfs
) every time you boot
Reference: https://www.jianshu.com/p/c7e965bfce8b