Previously, I post a question about an error of installing VMware-tools in a Ubuntu under a virtual machine. I have not got any solution yet.
So I installed another Ubuntu 14.04 LTS
under the virtual machine. Everything was new. I did software updates, and then directly tried to install VMware-tools. I have got an error, always about the shared folder. The whole log is here:
This problem of shared folder really is killing me... Hope someone could help...
PS: I use OS X 10.9.2
and a virtual machine 6.0.5 VMware Fusion
.
PPS: I guess something has been written to some files of VMware Fusion, I would need to reset that or overwrite that. Unfortunately, I could not reinstall VMware Fusion (because I have Windows and other things inside).
答案1
The problem seems to be a missing or an erroneous declaration / erroneous call of the function vfs_readlink()
in HgfsReadLink()
in link.c
:
/tmp/modconfig-NAS1rK/vmhgfs-only/link.c: In function ‘HgfsReadlink’:
/tmp/modconfig-NAS1rK/vmhgfs-only/link.c:186:10: error: implicit declaration of function ‘vfs_readlink’ [-Werror=implicit-function-declaration]
This might be fixed by editing one of the header files included in link.c
or by editing link.c
itself, but the easiest (and probably fastest) way would be to just patch the faulty file. There's this patcher around which between other vmware-tools
bugs also specifically addresses your issue: Github.com: vmware-tools-patches.
I've checked the patches included and I found out that between those included specifically for your version of vmware-tools
(9.6.2
) two of them affect the offending function over two different kernels (04-vmblock-vfs_readlink-kernel-3.15-tools-9.6.2.patch
> kernel 3.15 and 10-vmhgfs-vfs_readlink-kernel-3.16-tools-9.6.2.patch
> kernel 3.16).
Since the vmware-tools
installer you used messes with kernel modules, and since as you suggested some files probably have been written already during the previous attempt to install, considering furthermore that you have just reinstalled the system, instead of going through unnecessary headaches i highly suggest you to clean reinstall Ubuntu
on the virtual machine once again before running the patcher and installing vmware-tools
again.
Inside the virtual machine:
- Download and install
git
:sudo apt-get install git
- Download the patcher/patches somewhere, let's say in
~/
:cd ~/ && git clone https://github.com/rasa/vmware-tools-patches.git
- Move the
vmware-tools
tarball to~/vmware-tools-patches
:cp ~/Downloads/<vmware_tools_tarball_name> ~/vmware-tools-patches
- Run the patcher:
cd vmware-tools-patches && ./untar-and-patch.sh
- Install
vmware-tools
:./compile.sh
答案2
Take the easy way!
The software you are using to virtualize is now outdated.
Download VirtualBox and install Virtualbox tools and you will find your problem solved.
https://www.virtualbox.org/wiki/Downloads
There is always a non free alternative called Parallels for Mac that does all the work for you, it will install Ubuntu 14.04 with everything you need, it also has other options such as Android and Chrome OS.
答案3
If do you want to archieve a shared folders like behavior without installing vmware-tools
you can enable SSH on OS X in the system settings, as shown in the image.
Then, in the guest machine do this:
Open a Nautilus (a.k.a File Manager) window.
Click on
Connect to Server
as seen in the picture.Type
sftp://YOUR_MAC_HOSTNAME
in the dialog that pops up (whereYOUR_MAC_HOSTNAME
is the text that comes in the "Computer Name" field of your OS X Sharing configuration)Press enter
If all is ok, you will be browsing your OS X filesystem.