If you have tried to install VMware Tools on a VMware ESX (probably Workstation too) Fedora 14 virtual machine, then you probably noticed that there are no suitable pre-compiled VMware Tools modules available for the kernel version that the Fedora runs and also it is not that easy to make the modules to compile from the sources.
First of all, the VMware Tools configuration script is looking for header files of the running kernel. It goes without saying, that the kernel-devel package must be present on the system to proceed further. However, the configuration script is looking for a variable named UTS_RELEASE, which is not present in the latest Fedora kernel headers – the utsversion.h is just not there. A simple workaround for this is to add the UTS_RELEASE definition into version.h header file.
This command should do it:
echo "#define UTS_RELEASE "$(uname -r)"" >> /usr/src/kernels/$(uname -r)*/include/linux/version.h
The expected content should be like this:
#define LINUX_VERSION_CODE 132643 #define KERNEL_VERSION(a,b,c) (((a) << 16) + ((b) << 8) + (c)) #define UTS_RELEASE "2.6.35.6-48.fc14.i686" |
This change will allow to pass by the header checks. To check whether that works, the vmware-config-tools.pl script should be executed and the kernel header path (include directory) should be specified.
Another issue happens, when the configuration script tries to compile the vmxnet kernel module. A compilation error like the following would probably appear:
CC [M] /tmp/vmware-config0/vmxnet-only/vmxnet.o
/tmp/vmware-config0/vmxnet-only/vmxnet.c: In function mxnet_probe_device
/tmp/vmware-config0/vmxnet-only/vmxnet.c:714:26: error: mxnet_change_mtu undeclared (first use in this function)
/tmp/vmware-config0/vmxnet-only/vmxnet.c:714:26: note: each undeclared identifier is reported only once for each function it appears in
/tmp/vmware-config0/vmxnet-only/vmxnet.c: In function mxnet_load_multicast
/tmp/vmware-config0/vmxnet-only/vmxnet.c:2378:34: error: truct net_device has no member named c_listr
/tmp/vmware-config0/vmxnet-only/vmxnet.c:2388:24: error: truct net_device has no member named c_countr
/tmp/vmware-config0/vmxnet-only/vmxnet.c:2389:13: error: dereferencing pointer to incomplete type
/tmp/vmware-config0/vmxnet-only/vmxnet.c:2390:13: error: dereferencing pointer to incomplete type
make[2]: *** [/tmp/vmware-config0/vmxnet-only/vmxnet.o] Error 1
make[1]: *** [_module_/tmp/vmware-config0/vmxnet-only] Error 2
make[1]: Leaving directory `/usr/src/kernels/2.6.35.6-48.fc14.i686'
make: *** [vmxnet.ko] Error 2
make: Leaving directory `/tmp/vmware-config0/vmxnet-only'
Unable to build the vmxnet module.
First of all, from the Linux kernel version 2.6.35 the net_device structure changed a bit. The netdevice.h does not have the definition for HAVE_CHANGE_MTU specified, which the vmxnet.c expects. Also, the multicast address and count (mc_list and mc_count) are replaced. I have done the following changes in vmxnet.c, which do work for me:
The patch was made for VMwareTools-7304-283373.i386. Use at your own risk!
diff -Naur vmxnet-only-old/vmxnet.c vmxnet-only/vmxnet.c --- vmxnet.c 2010-08-05 00:59:07.000000000 +0300 +++ vmxnet.c 2010-11-27 17:02:29.477469153 +0200 @@ -80,9 +80,7 @@ static void vmxnet_set_multicast_list(struct net_device *dev); static int vmxnet_set_mac_address(struct net_device *dev, void *addr); static struct net_device_stats *vmxnet_get_stats(struct net_device *dev); -#ifdef HAVE_CHANGE_MTU static int vmxnet_change_mtu(struct net_device *dev, int new_mtu); -#endif static int vmxnet_probe_device(struct pci_dev *pdev, const struct pci_device_id *id); static void vmxnet_remove_device(struct pci_dev *pdev); @@ -187,7 +185,6 @@ .remove = vmxnet_remove_device, }; -#ifdef HAVE_CHANGE_MTU static int vmxnet_change_mtu(struct net_device *dev, int new_mtu) { @@ -205,7 +202,6 @@ return 0; } -#endif #ifdef SET_ETHTOOL_OPS @@ -1055,9 +1051,7 @@ dev->stop = &vmxnet_close; dev->get_stats = &vmxnet_get_stats; dev->set_multicast_list = &vmxnet_set_multicast_list; -#ifdef HAVE_CHANGE_MTU dev->change_mtu = &vmxnet_change_mtu; -#endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,3,43) dev->tx_timeout = &vmxnet_tx_timeout; #endif @@ -2375,7 +2369,7 @@ { struct Vmxnet_Private *lp = netdev_priv(dev); volatile u16 *mcast_table = (u16 *)lp->dd->LADRF; - struct dev_mc_list *dmi = dev->mc_list; + struct netdev_hw_addr *dmi; char *addrs; int i, j, bit, byte; u32 crc, poly = CRC_POLYNOMIAL_LE; @@ -2385,9 +2379,8 @@ lp->dd->LADRF[1] = 0; /* Add addresses */ - for (i = 0; i < dev->mc_count; i++){ - addrs = dmi->dmi_addr; - dmi = dmi->next; + netdev_for_each_mc_addr(dmi, dev){ + addrs = dmi->addr; /* multicast address? */ if (!(*addrs & 1)) |
The patch should be applied on vmxnet-only/vmxnet.c file which is in /usr/lib/vmware-tools/modules/source/vmxnet.tar archive. After reassembling the archive with the patched vmxnet.c, the vmware-tools-config.pl should succeed without any further errors.







Did not work.
#define UTS_RELEASE “2.6.35.6-48.fc14.i686″ does the trick, it is different from
#define UTS_RELEASE 2.6.35.6-48.fc14.i686
A lot of compile errors vmhgfs-only/driver.c ‘struct inode’ has no member named ‘u’
But even with errors the vmware could be launched and running, seemed working.
This didnt work….