码迷,mamicode.com
首页 > Windows程序 > 详细

VMWare Workstation中实现Win7和linux虚拟机之间的文件共享

时间:2016-04-09 17:19:41      阅读:243      评论:0      收藏:0      [点我收藏+]

标签:linux   虚拟机   shared   

共享文件夹有几步操作:


设置共享文件夹,设置共享之前把虚拟机关闭(这点很重要)

去VMWare中,VM->Settings:

默认的文件共享:Options->Shared Folders:Always Enabled:

然后再去添加文件夹:Add Shared Folder,这里要设置共享文件夹的目录和名称(暂且叫shared)

最后一步是启用共享:Enable this share


打开虚拟机,检测我们共享模块是否安装:

cd /mnt
[root@localhost www]# cd /mnt
[root@localhost mnt]# ll
total 5
dr-xr-xr-x. 1 root root 4192 Apr  8 18:13 hgfs

看到有hgfs文件夹,我们共享的文件夹正学的话,都应该在这个目录下,如果目录下没有我们设置的共享文件夹,再次运行命令:

[root@localhost mnt]# modprobe vmhgfs

如果返回

FATAL: Module vmhgfs not found.

那需要重新安装vmware tools

vm->reinstall vmware tools

最后再运行pl脚本即可

ubuntu系统
sudo vmware-config-tools.pl 
centos
vmware-config-tools.pl

最后我们来看一下效果

[root@localhost mnt]# cd hgfs/
[root@localhost hgfs]# ll
total 0
drwxrwxrwx. 1 root root 0 Apr  8 18:06 shared




本文出自 “开心编程_永无止境” 博客,请务必保留此出处http://happyliu.blog.51cto.com/501986/1761985

VMWare Workstation中实现Win7和linux虚拟机之间的文件共享

标签:linux   虚拟机   shared   

原文地址:http://happyliu.blog.51cto.com/501986/1761985

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!