Monday, October 7, 2019

kernel - Errors compiling vmnet for VMWare Player, 3.13.0-27-generic



Update: This problem went away after rebooting in 3.13.0-29-generic.







I am trying to install and run VMWare Player on Ubuntu 14.04, kernel 3.13.0-27-generic. I downloaded and executed the latest official bundle VMware-Player-6.0.2-1744117.x86_64.bundle . But it's not able to build the "vmnet" kernel module required to run.



I have installed packages linux-headers-3.13.0-27, linux-headers-3.13.0-27-generic, linux-image-3.13.0-27-generic, linux-image-extra-3.13.0-27-generic.



I tried applying the patch described at the answer https://askubuntu.com/a/444375/285902 . That might have improved things but didn't solve all the issues.



Each attempt creates a file /tmp/vmware-root/vmware-modconfig-*.log. One possible issue repeated in those files looks like:




2014-06-01T10:41:33.896-05:00| vthread-3| I120: Failed to find /lib/modules/3.13.0-27-generic/build/include/linux/version.h
2014-06-01T10:41:33.896-05:00| vthread-3| I120: /lib/modules/3.13.0-27-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.


but that might not be serious, since /lib/modules/3.13.0-27-generic/build/include/generated/uapi/linux/version.h does exist. Otherwise, the only thing that stands out is the last two lines:



2014-06-01T10:41:34.570-05:00| vthread-3| I120: Building module with command "/usr/bin/make -j6 -C /tmp/modconfig-vzryEa/vmnet-only auto-build HEADER_DIR=/lib/modules/3.13.0-27-generic/build/include CC=/usr/bin/gcc IS_GCC_3=no"
2014-06-01T10:41:36.174-05:00| vthread-3| W110: Failed to build vmnet. Failed to execute the build command.



A manual command sudo vmware-modconfig --console --install-all outputs this:



Stopping VMware services:
VMware Authentication Daemon done
VM communication interface socket family done
Virtual machine communication interface done
Virtual machine monitor done
Blocking file system done
Using 2.6.x kernel build system.
make: Entering directory `/tmp/modconfig-oZb2a1/vmmon-only'

/usr/bin/make -C /lib/modules/3.13.0-27-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. \
MODULEBUILDDIR= modules
make[1]: Entering directory `/usr/src/linux-headers-3.13.0-27-generic'
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/linux/driver.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/linux/driverLog.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/linux/hostif.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/apic.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/comport.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/cpuid.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/hashFunc.o

CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/memtrack.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/phystrack.o
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/task.o
In file included from include/linux/rtc.h:28:0,
from include/linux/mc146818rtc.h:15,
from /tmp/modconfig-oZb2a1/vmmon-only/linux/hostif.c:76:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
CC [M] /tmp/modconfig-oZb2a1/vmmon-only/common/vmx86.o

CC [M] /tmp/modconfig-oZb2a1/vmmon-only/vmcore/moduleloop.o
make[2]: *** [/tmp/modconfig-oZb2a1/vmmon-only/linux/hostif.o] Error 1
make[2]: *** Waiting for unfinished jobs....
/tmp/modconfig-oZb2a1/vmmon-only/linux/driver.c:1342:1: warning: always_inline function might not be inlinable [-Wattributes]
LinuxDriverSyncReadTSCs(uint64 *delta) // OUT: TSC max - TSC min
^
make[1]: *** [_module_/tmp/modconfig-oZb2a1/vmmon-only] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.13.0-27-generic'
make: *** [vmmon.ko] Error 2
make: Leaving directory `/tmp/modconfig-oZb2a1/vmmon-only'

Using 2.6.x kernel build system.
make: Entering directory `/tmp/modconfig-oZb2a1/vmnet-only'
/usr/bin/make -C /lib/modules/3.13.0-27-generic/build/include/.. SUBDIRS=$PWD SRCROOT=$PWD/. \
MODULEBUILDDIR= modules
make[1]: Entering directory `/usr/src/linux-headers-3.13.0-27-generic'
CC [M] /tmp/modconfig-oZb2a1/vmnet-only/driver.o
CC [M] /tmp/modconfig-oZb2a1/vmnet-only/hub.o
CC [M] /tmp/modconfig-oZb2a1/vmnet-only/userif.o
CC [M] /tmp/modconfig-oZb2a1/vmnet-only/netif.o
CC [M] /tmp/modconfig-oZb2a1/vmnet-only/bridge.o

CC [M] /tmp/modconfig-oZb2a1/vmnet-only/filter.o
In file included from include/linux/dmaengine.h:24:0,
from include/linux/skbuff.h:31,
from include/linux/if_ether.h:23,
from /tmp/modconfig-oZb2a1/vmnet-only/filter.c:23:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
In file included from include/linux/pm_qos.h:10:0,
from include/linux/netdevice.h:28,

from /tmp/modconfig-oZb2a1/vmnet-only/driver.c:32:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
In file included from include/linux/pm_qos.h:10:0,
from include/linux/netdevice.h:28,
from /tmp/modconfig-oZb2a1/vmnet-only/hub.c:29:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^

In file included from include/linux/pm_qos.h:10:0,
from include/linux/netdevice.h:28,
from /tmp/modconfig-oZb2a1/vmnet-only/bridge.c:29:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
In file included from include/linux/dmaengine.h:24:0,
from include/linux/skbuff.h:31,
from include/linux/if_ether.h:23,
from /tmp/modconfig-oZb2a1/vmnet-only/userif.c:27:

include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
In file included from include/linux/pm_qos.h:10:0,
from include/linux/netdevice.h:28,
from /tmp/modconfig-oZb2a1/vmnet-only/netif.c:29:
include/linux/device.h:601:6: error: unknown type name ‘dv_match_t’
dv_match_t match, void *match_data);
^
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:213:1: error: conflicting types for ‘VNetFilterHookFn’

VNetFilterHookFn(unsigned int hooknum, // IN:
^
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:64:18: note: previous declaration of ‘VNetFilterHookFn’ was here
static nf_hookfn VNetFilterHookFn;
^
/tmp/modconfig-oZb2a1/vmnet-only/filter.c: In function ‘VNetFilterHookFn’:
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:264:16: error: ‘ops’ undeclared (first use in this function)
transmit = (ops->hooknum == VMW_NF_INET_POST_ROUTING);
^
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:264:16: note: each undeclared identifier is reported only once for each function it appears in

/tmp/modconfig-oZb2a1/vmnet-only/filter.c: At top level:
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:64:18: warning: ‘VNetFilterHookFn’ used but never defined [enabled by default]
static nf_hookfn VNetFilterHookFn;
^
/tmp/modconfig-oZb2a1/vmnet-only/filter.c:213:1: warning: ‘VNetFilterHookFn’ defined but not used [-Wunused-function]
VNetFilterHookFn(unsigned int hooknum, // IN:
^
make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/hub.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/driver.o] Error 1

make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/filter.o] Error 1
make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/userif.o] Error 1
make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/netif.o] Error 1
make[2]: *** [/tmp/modconfig-oZb2a1/vmnet-only/bridge.o] Error 1
make[1]: *** [_module_/tmp/modconfig-oZb2a1/vmnet-only] Error 2
make[1]: Leaving directory `/usr/src/linux-headers-3.13.0-27-generic'
make: *** [vmnet.ko] Error 2
make: Leaving directory `/tmp/modconfig-oZb2a1/vmnet-only'
Unable to install all modules. See log for details.



A Google search for some of those compiler messages turns up absolutely nothing.



What could I try next? I'm willing to switch kernel versions if it might help.



Install a newer kernel version and reboot.



For me, the problem disappeared when using kernel 3.13.0-29-generic.


No comments:

Post a Comment

11.10 - Can't boot from USB after installing Ubuntu

I bought a Samsung series 5 notebook and a very strange thing happened: I installed Ubuntu 11.10 from a usb pen drive but when I restarted (...