When I tried to install VMWare Player 17.5.1 on Ubuntu 24.04, I got the below error messages.
Message: 'stderr: [AppLoader] Use shipped Linux kernel AIO access library.
An up-to-date "libaio" or "libaio1" package from your system is preferred.
[AppLoader] GLib does not have GSettings support.
Using kernel build system.
warning: the compiler differs from the one used to build the kernel
The kernel was built by: x86_64-linux-gnu-gcc-13 (Ubuntu 13.2.0-23ubuntu4) 13.2.0
You are using: gcc (Ubuntu 13.2.0-23ubuntu4) 13.2.0
/tmp/modconfig-i3MEkp/vmmon-only/common/crosspage.o: warning: objtool: CrossPage_CodePage+0x207: \'naked\' return found in RETHUNK build
make[3]: *** [scripts/Makefile.build:243: /tmp/modconfig-i3MEkp/vmmon-only/common/crosspage.o] Error 255
make[3]: *** Deleting file \'/tmp/modconfig-i3MEkp/vmmon-only/common/crosspage.o\'
make[3]: *** Waiting for unfinished jobs....
/tmp/modconfig-i3MEkp/vmmon-only/linux/hostif.c:2926:1: warning: no previous prototype for \u2018HostIFCheckTrackedMPN\u2019 [-Wmissing-prototypes]
2926 | HostIFCheckTrackedMPN(VMDriver *vm, // IN: The VM instance
| ^~~~~~~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmmon-only/linux/hostif.c:3046:1: warning: no previous prototype for \u2018HostIFWritePhysicalWork\u2019 [-Wmissing-prototypes]
3046 | HostIFWritePhysicalWork(MA ma, // MA to be written to
| ^~~~~~~~~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmmon-only/linux/hostif.c:3205:1: warning: no previous prototype for \u2018HostIFStartTimer\u2019 [-Wmissing-prototypes]
3205 | HostIFStartTimer(Bool rateChanged, //IN: Did rate change?
| ^~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmmon-only/linux/driver.c:271:1: warning: no previous prototype for \u2018LinuxDriverInit\u2019 [-Wmissing-prototypes]
271 | LinuxDriverInit(void)
| ^~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmmon-only/linux/driver.c:339:1: warning: no previous prototype for \u2018LinuxDriverExit\u2019 [-Wmissing-prototypes]
339 | LinuxDriverExit(void)
| ^~~~~~~~~~~~~~~
make[2]: *** [/usr/src/linux-headers-6.8.0-31-generic/Makefile:1926: /tmp/modconfig-i3MEkp/vmmon-only] Error 2
make[1]: *** [Makefile:240: __sub-make] Error 2
make: *** [Makefile:117: vmmon.ko] Error 2
Using kernel build system.
warning: the compiler differs from the one used to build the kernel
The kernel was built by: x86_64-linux-gnu-gcc-13 (Ubuntu 13.2.0-23ubuntu4) 13.2.0
You are using: gcc (Ubuntu 13.2.0-23ubuntu4) 13.2.0
/tmp/modconfig-i3MEkp/vmnet-only/userif.c:1091:1: warning: no previous prototype for \u2018VNetUserIf_Create\u2019 [-Wmissing-prototypes]
1091 | VNetUserIf_Create(VNetPort **ret) // OUT
| ^~~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmnet-only/netif.c:173:1: warning: no previous prototype for \u2018VNetNetIf_Create\u2019 [-Wmissing-prototypes]
173 | VNetNetIf_Create(char *devName, // IN:
| ^~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmnet-only/bridge.c:258:1: warning: no previous prototype for \u2018VNetBridge_Create\u2019 [-Wmissing-prototypes]
258 | VNetBridge_Create(const char *devName, // IN: name of device (e.g., "eth0")
| ^~~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmnet-only/bridge.c:1411:1: warning: no previous prototype for \u2018VNetBridgeSendLargePacket\u2019 [-Wmissing-prototypes]
1411 | VNetBridgeSendLargePacket(struct sk_buff *skb, // IN: packet to split
| ^~~~~~~~~~~~~~~~~~~~~~~~~
/tmp/modconfig-i3MEkp/vmnet-only/userif.o: warning: objtool: VNetCsumAndCopyToUser+0x2d: call to csum_partial_copy_nocheck() with UACCESS enabled
/tmp/modconfig-i3MEkp/vmnet-only/vnetUserListener.c:87:1: warning: no previous prototype for \u2018VNetUserListener_Create\u2019 [-Wmissing-prototypes]
87 | VNetUserListener_Create(uint32 classMask, // IN: the listener\'s class mask
| ^~~~~~~~~~~~~~~~~~~~~~~
Skipping BTF generation for /tmp/modconfig-i3MEkp/vmnet-only/vmnet.ko due to unavailability of vmlinux
Unable to install all modules. See log for details.
But the VMWare Player icon shows up in the menu. When I launch it, it will try to compile VMWare Tools and then fail.
I'm not sure from which version of Ubuntu onwards, there have been build issues with the vmmon and vmnet modules.
The solution is to build the vmmon and vmnet modules by yourself.
Go to here download the source code
https://github.com/mkubecek/vmware-host-modules/tree/workstation-17.5.1
Then, check the INSTALL instructions for building these two modules.
I follow the below instructions to resolve the problem.
2b. Build and install modules - replacing the original source tarballs
----------------------------------------------------------------------
Manual build and installation of host modules may be natural for developers
and power users but those who prefer to "just use" would appreciate if they
could rely on standard VMware tools. To this goal, we need to replace the
module source tarballs with patched versions.
In local checked out repository, the replacement tarballs can be created
with
make tarballs
This command creates files vmmon.tar and vmnet.tar which can be used to
replace the original tarballs provided with the VMware product. Note that
this command creates the tarball from current HEAD (in git language), i.e.
they do not contain any uncommited local changes (e.g. files created by
test build).
When using a downloaded tarball, simply run
tar -cf vmmon.tar vmmon-only
tar -cf vmnet.tar vmnet-only
to create the tarballs. In this case, there is no protection against
unwanted local changes.
Whatever way you used to create the tarballs, replace the original ones
provided by VMware
/usr/lib/vmware/modules/source/vmmon.tar
/usr/lib/vmware/modules/source/vmnet.tar
by patched versions. It is highly recommended to backup the original
tarballs before replacing them.
Once patched tarballs are installed, you can rebuild the modules as usual:
vmware-modconfig --console --install-all
or let the GUI run the command for you.
Replacing the original tarballs prevents having to rebuild and install the
modules manually with every new kernel version. However, once the VMware
product is upgraded or reinstalled, tarballs are replaced so that if the
new VMware version doesn't build/work with a recent kernel, you still need
to repeat the process. The same also holds if there is a new kernel which
requires updated version of the patches.]