vibrations
Contributor
Contributor

Failed to build vmnet. Failed to execute the build command when installing VMworkstation 14.1.7 on ubuntu 18

When installing VMware-Workstation-Full-14.1.7-12989993.x86_64.bundle on ubuntu 18, on first run after install I get the error Failed to build vmnet.  Failed to execute the build command in the log

sudo cat /tmp/vmware-root/vmware-27004.log

2019-09-18T01:12:13.516Z| vthread-1| I125: Log for VMware Workstation pid=27004 version=14.1.7 build=build-12989993 option=Release

2019-09-18T01:12:13.516Z| vthread-1| I125: The process is 64-bit.

2019-09-18T01:12:13.516Z| vthread-1| I125: Host codepage=UTF-8 encoding=UTF-8

2019-09-18T01:12:13.516Z| vthread-1| I125: Host is Linux 5.0.0-29-generic Ubuntu 18.04.3 LTS

2019-09-18T01:12:13.516Z| vthread-1| I125: DictionaryLoad: Cannot open file "/usr/lib/vmware/settings": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: [msg.dictionary.load.openFailed] Cannot open file "/usr/lib/vmware/settings": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: PREF Optional preferences file not found at /usr/lib/vmware/settings. Using default values.

2019-09-18T01:12:13.516Z| vthread-1| I125: DictionaryLoad: Cannot open file "/home/vmdovs/.vmware/config": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: [msg.dictionary.load.openFailed] Cannot open file "/home/vmdovs/.vmware/config": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: PREF Optional preferences file not found at /home/vmdovs/.vmware/config. Using default values.

2019-09-18T01:12:13.516Z| vthread-1| I125: DictionaryLoad: Cannot open file "/home/vmdovs/.vmware/preferences": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: [msg.dictionary.load.openFailed] Cannot open file "/home/vmdovs/.vmware/preferences": No such file or directory.

2019-09-18T01:12:13.516Z| vthread-1| I125: PREF Optional preferences file not found at /home/vmdovs/.vmware/preferences. Using default values.

2019-09-18T01:12:13.556Z| vthread-1| W115: Logging to /tmp/vmware-root/vmware-27004.log

2019-09-18T01:12:13.567Z| vthread-1| I125: Obtaining info using the running kernel.

2019-09-18T01:12:13.567Z| vthread-1| I125: Created new pathsHash.

2019-09-18T01:12:13.567Z| vthread-1| I125: Setting header path for 5.0.0-29-generic to "/lib/modules/5.0.0-29-generic/build/include".

2019-09-18T01:12:13.567Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.567Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.567Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.567Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.576Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.576Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:13.716Z| vthread-1| I125: found symbol version file /lib/modules/5.0.0-29-generic/build/Module.symvers

2019-09-18T01:12:13.716Z| vthread-1| I125: Reading symbol versions from /lib/modules/5.0.0-29-generic/build/Module.symvers.

2019-09-18T01:12:13.735Z| vthread-1| I125: Read 23264 symbol versions

2019-09-18T01:12:13.735Z| vthread-1| I125: Reading in info for the vmmon module.

2019-09-18T01:12:13.735Z| vthread-1| I125: Reading in info for the vmnet module.

2019-09-18T01:12:13.735Z| vthread-1| I125: Reading in info for the vmblock module.

2019-09-18T01:12:13.735Z| vthread-1| I125: Reading in info for the vmci module.

2019-09-18T01:12:13.735Z| vthread-1| I125: Reading in info for the vsock module.

2019-09-18T01:12:13.735Z| vthread-1| I125: Setting vsock to depend on vmci.

2019-09-18T01:12:13.735Z| vthread-1| I125: Invoking modinfo on "vmmon".

2019-09-18T01:12:13.737Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:13.737Z| vthread-1| I125: Invoking modinfo on "vmnet".

2019-09-18T01:12:13.739Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:13.739Z| vthread-1| I125: Invoking modinfo on "vmblock".

2019-09-18T01:12:13.741Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:13.741Z| vthread-1| I125: Invoking modinfo on "vmci".

2019-09-18T01:12:13.742Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:13.742Z| vthread-1| I125: Invoking modinfo on "vsock".

2019-09-18T01:12:13.744Z| vthread-1| I125: "/sbin/modinfo" exited with status 0.

2019-09-18T01:12:13.757Z| vthread-1| I125: to be installed: vmmon status: 0

2019-09-18T01:12:13.757Z| vthread-1| I125: to be installed: vmnet status: 0

2019-09-18T01:12:13.769Z| vthread-1| I125: Obtaining info using the running kernel.

2019-09-18T01:12:13.769Z| vthread-1| I125: Setting header path for 5.0.0-29-generic to "/lib/modules/5.0.0-29-generic/build/include".

2019-09-18T01:12:13.769Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.769Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.769Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.769Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.777Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.777Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:13.916Z| vthread-1| I125: found symbol version file /lib/modules/5.0.0-29-generic/build/Module.symvers

2019-09-18T01:12:13.916Z| vthread-1| I125: Reading symbol versions from /lib/modules/5.0.0-29-generic/build/Module.symvers.

2019-09-18T01:12:13.933Z| vthread-1| I125: Read 23264 symbol versions

2019-09-18T01:12:13.933Z| vthread-1| I125: Kernel header path retrieved from FileEntry: /lib/modules/5.0.0-29-generic/build/include

2019-09-18T01:12:13.933Z| vthread-1| I125: Update kernel header path to /lib/modules/5.0.0-29-generic/build/include

2019-09-18T01:12:13.933Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.933Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.933Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.933Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.942Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.942Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:13.943Z| vthread-1| I125: Found compiler at "/usr/bin/gcc"

2019-09-18T01:12:13.946Z| vthread-1| I125: Got gcc version "7".

2019-09-18T01:12:13.946Z| vthread-1| I125: The GCC version matches the kernel GCC minor version like a glove.

2019-09-18T01:12:13.950Z| vthread-1| I125: Got gcc version "7".

2019-09-18T01:12:13.950Z| vthread-1| I125: The GCC version matches the kernel GCC minor version like a glove.

2019-09-18T01:12:13.951Z| vthread-1| I125: Trying to find a suitable PBM set for kernel "5.0.0-29-generic".

2019-09-18T01:12:13.951Z| vthread-1| I125: No matching PBM set was found for kernel "5.0.0-29-generic".

2019-09-18T01:12:13.951Z| vthread-1| I125: The GCC version matches the kernel GCC minor version like a glove.

2019-09-18T01:12:13.951Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.951Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.951Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.951Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.959Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.959Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:13.962Z| vthread-1| I125: The GCC version matches the kernel GCC minor version like a glove.

2019-09-18T01:12:13.962Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.962Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.962Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.962Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.971Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.971Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:13.971Z| vthread-1| I125: Using temp dir "/tmp".

2019-09-18T01:12:13.974Z| vthread-1| I125: Obtaining info using the running kernel.

2019-09-18T01:12:13.974Z| vthread-1| I125: Setting header path for 5.0.0-29-generic to "/lib/modules/5.0.0-29-generic/build/include".

2019-09-18T01:12:13.974Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:12:13.974Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:12:13.974Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:12:13.974Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:12:13.984Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:12:13.984Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:12:14.129Z| vthread-1| I125: found symbol version file /lib/modules/5.0.0-29-generic/build/Module.symvers

2019-09-18T01:12:14.129Z| vthread-1| I125: Reading symbol versions from /lib/modules/5.0.0-29-generic/build/Module.symvers.

2019-09-18T01:12:14.146Z| vthread-1| I125: Read 23264 symbol versions

2019-09-18T01:12:14.146Z| vthread-1| I125: Invoking modinfo on "vmmon".

2019-09-18T01:12:14.148Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:14.148Z| vthread-1| I125: Invoking modinfo on "vmnet".

2019-09-18T01:12:14.150Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:12:14.596Z| vthread-1| I125: Setting destination path for vmmon to "/lib/modules/5.0.0-29-generic/misc/vmmon.ko".

2019-09-18T01:12:14.596Z| vthread-1| I125: Extracting the vmmon source from "/usr/lib/vmware/modules/source/vmmon.tar".

2019-09-18T01:12:14.603Z| vthread-1| I125: Successfully extracted the vmmon source.

2019-09-18T01:12:14.603Z| vthread-1| I125: Building module with command "/usr/bin/make -j8 -C /tmp/modconfig-vBuSLm/vmmon-only auto-build HEADER_DIR=/lib/modules/5.0.0-29-generic/build/include CC=/usr/bin/gcc IS_GCC_3=no"

2019-09-18T01:12:16.377Z| vthread-1| W115: Failed to build vmmon.  Failed to execute the build command.

2019-09-18T01:12:16.379Z| vthread-1| I125: Setting destination path for vmnet to "/lib/modules/5.0.0-29-generic/misc/vmnet.ko".

2019-09-18T01:12:16.380Z| vthread-1| I125: Extracting the vmnet source from "/usr/lib/vmware/modules/source/vmnet.tar".

2019-09-18T01:12:16.384Z| vthread-1| I125: Successfully extracted the vmnet source.

2019-09-18T01:12:16.385Z| vthread-1| I125: Building module with command "/usr/bin/make -j8 -C /tmp/modconfig-vBuSLm/vmnet-only auto-build HEADER_DIR=/lib/modules/5.0.0-29-generic/build/include CC=/usr/bin/gcc IS_GCC_3=no"

2019-09-18T01:12:18.857Z| vthread-1| W115: Failed to build vmnet.  Failed to execute the build command.

2019-09-18T01:15:31.748Z| vthread-1| I125: The GCC version matches the kernel GCC minor version like a glove.

2019-09-18T01:15:31.748Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:15:31.748Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:15:31.748Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:15:31.748Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:15:31.756Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:15:31.756Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:15:31.756Z| vthread-1| I125: Using temp dir "/tmp".

2019-09-18T01:15:31.757Z| vthread-1| I125: Obtaining info using the running kernel.

2019-09-18T01:15:31.757Z| vthread-1| I125: Setting header path for 5.0.0-29-generic to "/lib/modules/5.0.0-29-generic/build/include".

2019-09-18T01:15:31.757Z| vthread-1| I125: Validating path "/lib/modules/5.0.0-29-generic/build/include" for kernel release "5.0.0-29-generic".

2019-09-18T01:15:31.757Z| vthread-1| I125: Failed to find /lib/modules/5.0.0-29-generic/build/include/linux/version.h

2019-09-18T01:15:31.757Z| vthread-1| I125: /lib/modules/5.0.0-29-generic/build/include/linux/version.h not found, looking for generated/uapi/linux/version.h instead.

2019-09-18T01:15:31.757Z| vthread-1| I125: using /usr/bin/gcc-7 for preprocess check

2019-09-18T01:15:31.763Z| vthread-1| I125: Preprocessed UTS_RELEASE, got value "5.0.0-29-generic".

2019-09-18T01:15:31.763Z| vthread-1| I125: The header path "/lib/modules/5.0.0-29-generic/build/include" for the kernel "5.0.0-29-generic" is valid.  Whoohoo!

2019-09-18T01:15:31.902Z| vthread-1| I125: found symbol version file /lib/modules/5.0.0-29-generic/build/Module.symvers

2019-09-18T01:15:31.902Z| vthread-1| I125: Reading symbol versions from /lib/modules/5.0.0-29-generic/build/Module.symvers.

2019-09-18T01:15:31.920Z| vthread-1| I125: Read 23264 symbol versions

2019-09-18T01:15:31.920Z| vthread-1| I125: Invoking modinfo on "vmmon".

2019-09-18T01:15:31.923Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:15:31.923Z| vthread-1| I125: Invoking modinfo on "vmnet".

2019-09-18T01:15:31.926Z| vthread-1| I125: "/sbin/modinfo" exited with status 256.

2019-09-18T01:15:32.327Z| vthread-1| I125: Setting destination path for vmmon to "/lib/modules/5.0.0-29-generic/misc/vmmon.ko".

2019-09-18T01:15:32.327Z| vthread-1| I125: Extracting the vmmon source from "/usr/lib/vmware/modules/source/vmmon.tar".

2019-09-18T01:15:32.341Z| vthread-1| I125: Successfully extracted the vmmon source.

2019-09-18T01:15:32.341Z| vthread-1| I125: Building module with command "/usr/bin/make -j8 -C /tmp/modconfig-OUZaeQ/vmmon-only auto-build HEADER_DIR=/lib/modules/5.0.0-29-generic/build/include CC=/usr/bin/gcc IS_GCC_3=no"

2019-09-18T01:15:34.166Z| vthread-1| W115: Failed to build vmmon.  Failed to execute the build command.

2019-09-18T01:15:34.169Z| vthread-1| I125: Setting destination path for vmnet to "/lib/modules/5.0.0-29-generic/misc/vmnet.ko".

2019-09-18T01:15:34.169Z| vthread-1| I125: Extracting the vmnet source from "/usr/lib/vmware/modules/source/vmnet.tar".

2019-09-18T01:15:34.176Z| vthread-1| I125: Successfully extracted the vmnet source.

2019-09-18T01:15:34.176Z| vthread-1| I125: Building module with command "/usr/bin/make -j8 -C /tmp/modconfig-OUZaeQ/vmnet-only auto-build HEADER_DIR=/lib/modules/5.0.0-29-generic/build/include CC=/usr/bin/gcc IS_GCC_3=no"

2019-09-18T01:15:36.718Z| vthread-1| W115: Failed to build vmnet.  Failed to execute the build command.

5 Replies
vibrations
Contributor
Contributor

I found the solution on another post

#!/bin/bash

VMWARE_VERSION=workstation-14.1.7

TMP_FOLDER=/tmp/patch-vmware

rm -fdr $TMP_FOLDER

mkdir -p $TMP_FOLDER

cd $TMP_FOLDER

git clone https://github.com/mkubecek/vmware-host-modules.git

cd $TMP_FOLDER/vmware-host-modules

git checkout $VMWARE_VERSION

git fetch

make

sudo make install

sudo rm /usr/lib/vmware/lib/libz.so.1/libz.so.1

sudo ln -s /lib/x86_64-linux-gnu/libz.so.1

/usr/lib/vmware/lib/libz.so.1/libz.so.1

sudo /etc/init.d/vmware restart

Aadniz
Contributor
Contributor

Yes! this worked!

But there is some "sketchy" commands here.

Like: "sudo ln -s /lib/x86_64-linux-gnu/libz.so.1" and "/usr/lib/vmware/lib/libz.so.1/libz.so.1"

You should try to avoid using symlinks

0 Kudos
saldon
Enthusiast
Enthusiast

This worked but I had to install git first.

sudo apt install git

- Tom
0 Kudos
chengwengao
Contributor
Contributor

ubutu20 also encountered this problem. This answer solved my problem perfectly. After executing the script, there is no need to restart.
0 Kudos
Aadniz
Contributor
Contributor

I've bookmarked this thread, and I keep coming back to your answer.

Why do I have to run this script every month or so?

Why aren't VMware making a complete fix for this?

0 Kudos