8

After having upgraded my guest ubuntu to linux-image-3.13.0-46 I got an error install vmware-tools and I cannot share folders any more.

I ran vmware player 7.0.0 build-2305329 both in Windows 8 and Ubuntu 14.04 LTS host machine and during the installation I got the following error log out:

                 from /tmp/modconfig-NVbKuD/vmhgfs-only/inode.c:29:
include/linux/kernel.h:793:27: error: ‘struct dentry’ has no member named ‘d_alias’
  const typeof( ((type *)0)->member ) *__mptr = (ptr); \
                           ^

Is there any workaround about this issue?

Thanks

marcom
  • 101
  • 1
  • 4
  • I'm voting to close this question as off-topic and suggest you to ask this either on `serverfault.com` OR on `unix.stackexchange.com` OR on `superuser.com`! – Am_I_Helpful Feb 18 '15 at 09:17

4 Answers4

11

vmware-tools-distrib-9.9.2-2496486:

I have fixed the problem by going to the directory where vmhgfs.tar is located (in my case /usr/lib/vmware-tools/modules/source), unpack the tar and manually edit inode.c.

At line 1925(just search for "d_alias" to find the exact line) you need to add an if. In the end looks like that:

#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
                           d_alias) {
#else
                           d_u.d_alias) {
#endif

Then again around line 1983 (search again for "d_alias"):

#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 13, 0)
         struct dentry *dentry = list_entry(pos, struct dentry, d_alias);
#else
         struct dentry *dentry = list_entry(pos, struct dentry, d_u.d_alias);
#endif

Caveat: Not sure on the kernel version but I have put there 3,13,0 though my Ubuntu reports:

# uname -a
Linux md-ubuntu 3.13.0-46-generic #76-Ubuntu SMP Thu Feb 26 18:52:13 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

And this was working fine with 3.13.0-45.

So probably if you downgrade the kernel the above hack will not work properly.

Then you need to pack again the tar archive (just move the old one out of the way:

# mv vmhgfs.tar vmhgfs.tar.orig

and pack again the directory:

# tar cvf vmhgfs.tar vmhgfs-only

)

Hope it helps.

Mircea Damian
  • 151
  • 1
  • 4
  • Worked on VMWare Workstation 11.1.0 and Linux linux6405 3.13.0-46-generic #76-Ubuntu SMP Thu Feb 26 18:52:13 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux – Mark Thomas Mar 02 '15 at 12:59
  • It worked for me on VMWare Fusion 6.0.5 (on MacBook Pro). Thanks! – HEKTO Mar 05 '15 at 15:36
  • 1
    In VMwareTools-9.9.0-2304977.tar.gz, on Linux ubuntu 3.16.0-31-generic, it looks like the vmhgfs.tar is re-created each time when running the install script. So you have to carefully monitor when the tar gets created in the interactive install, once the tar is created, make changes, and then continue the interactive install script... – xwl Mar 05 '15 at 16:20
  • 1
    @xwl - I never use the interactive install script. I used to untar the `VMwareTools*` tarfile, then `cd` into its directory (it's called `vmware-tools-distrib` on my machine) and run the `vmware-install.pl` script – HEKTO Mar 05 '15 at 19:57
  • On VMware 10, VMwareTools-9.6.2-1688356 and Linux 3.13.0-46-generic #77-Ubuntu, it worked for me. Except that I only had one occurence to change instead of 2, at line 1903. – John Jefferies Mar 06 '15 at 23:29
  • this also worked on Debian Wheezy 3.16.0-0.bpo.4-amd64 & workstation 11.10 - full instructions @ https://xpressubuntu.wordpress.com/2015/03/04/how-to-fix-no-shared-folders-in-vmware-player-7/ – Stuart Cardall Mar 23 '15 at 18:11
1

This patch should fix the problem.

Edit Working Gist patch

Instructions for use:

cd vmware-tools-distrib/lib/modules/source/
tar -xvf vmhgfs.tar
cd vmhgfs-only
patch inode.c < inode.patch
cd ..
mv vmhgfs.tar vmhgfs.tar.orig
tar cvf vmhgfs.tar vmhgfs-only
cd vmware-tools-distrib
sudo ./vmware-install.pl
Brian
  • 2,294
  • 6
  • 30
  • 51
iwlagn
  • 477
  • 3
  • 10
  • I followed the [Quick Start](https://github.com/rasa/vmware-tools-patches) but it does not solved the problem. When I apply the patch I see a message *** Skipping vmhgfs/vmhgfs-d_count-kernel-3.11-tools-9.6.0.patch: did not apply cleanly – marcom Feb 18 '15 at 09:26
  • Can you try to apply this patch without any wrappers and tell precise output? Copy vmhgfs-d_count-kernel-3.11-tools-9.6.0.patch to vmhgfs folder, cd to it and run 'patch -p1 < vmhgfs-d_count-kernel-3.11-tools-9.6.0.patch' – iwlagn Feb 18 '15 at 10:46
  • It seems the patch does not match the inode.c of VMwareTools-9.9.0-2304977.tar.gz `File inode.c is read-only; trying to patch anyway patching file inode.c Hunk #1 succeeded at 31 with fuzz 1. Hunk #2 FAILED at 1893. Hunk #3 FAILED at 1946. 2 out of 3 hunks FAILED -- saving rejects to file inode.c.rej` – marcom Feb 18 '15 at 14:07
  • OK, lets take another approach. Can you create a gist with full trace of error during compilation? The one, that ends with "from /tmp/modconfig-NVbKuD/vmhgfs-only/inode.c:29:" – iwlagn Feb 18 '15 at 15:01
  • [Here](https://gist.github.com/m-marini/5ec4cf80abdb66ad26af) is the gist with error log of update-and-patch-and-compile.sh. I added also the icon.c.orig, icon.c and icon.c.rej created manually running patch command. The error shows a problem at line 29 of icon.c that is before the first patch change (line 31) so maybe the patch does not fix the problem. – marcom Feb 18 '15 at 16:49
0

As for VMWare Fusion, the bug was fixed at 7.1.2 release [1]. The version of vmware-tools is 9.9.3.

[1] VMware Fusion 7.1.2 Release Notes https://www.vmware.com/support/fusion/doc/fusion-712-release-notes.html

shino
  • 839
  • 5
  • 9
0

open-vm-tools is supported and recommended by VMware for Ubuntu. So, you can easily install open-vm-tools if you have really trouble with VMware Tools. Hope it helps.

Ceyhun
  • 1