VMware Workstation Error After Linux Update

On Linux, the following error may occur in the VMWare Workstation application after a Linux kernel update:

VMWare Workstation error message after Linux kernel update

Error:
Could not open /dev/-
vmmon: No such file or
directory.
Please make sure that the kernel module 'vmmon' is loaded.

Solving the problem

The solution is quite simple, thanks to mkubecek: you just have to integrate the appropriate host modules vmmon and vmnet, which he has provided via a GitHub repository, into the kernel.

git clone https://github.com/mkubecek/vmware-host-modules
cd vmware-host-modules
git checkout workstation-17.0.2
sudo make ; sudo make install
sudo modprobe -a vmw_vmci vmmon vmnet

For more installation options, see INSTALL.

Version and license note

With the update to VMWare Workstation Pro 17.5.2, following the acquisition by Broadcom, the application is now freely available for personal use and VMWare Player has been discontinued. When updating from 17.5.1 to 17.5.2, the basic functionality remains the same, so no host module changes are required.

Kernel 6.9 issue

For problems when using a kernel 6.9, please refer to the GitHub repository of nan0desu. Remedy in the corresponding branches.
There is also brief information on this on the website of mkubecek.

VM network error

I also often had the problem of the network not working in a VM afterwards.

Could not connect to Ethernet0 to virtual network

In this case, simply restart the VMware Workstation network service.

sudo /usr/bin/vmware-networks --stop
sudo /usr/bin/vmware-networks --start