VMware Workstation

 View Only

 Ubuntu and Vmware workstation pro after installation of new kernel

Paolo Meravigliao's profile image
Paolo Meravigliao posted Jul 01, 2025 07:10 AM

Hi, each time that Ubuntu release e new kernel and I install it I have to do the following command, otherwise the VM doesn't start with VMNET error:

openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MOK.der -nodes -days 36500 -subj "/CN=My Name/"
sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file sha256 ./MOK.priv ./MOK.der $(modinfo -n vmmon)
sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file sha256 ./MOK.priv ./MOK.der $(modinfo -n vmnet)
sudo mokutil --import MOK.der ---"insert a password"
now reboot and re-enroll your key.

But with the installation of the last kernel the network of the Windows VM doesn't work anymore, with the following error:
Could not connect 'Ethernet0' to virtual network '/dev/vmnet8'

I tryed to find a solution but nothing until now.

Are correct the command I do after installation of new kernel?
Any suggestion for the error "Could not connect 'Ethernet0' to virtual network '/dev/vmnet8'"

Thanks

goldeneye_007's profile image
goldeneye_007

IIRC I ran into this many times in the past. launch workstation as root user.

Go into Edit>Preferences and then to Virtual Network Editor.

I really had to mess around in there for awhile and you may run into various bugs that

will be difficult to get around but ultimately I think removing the virtual network vmnet8 and re-adding it did the trick.

I may have also after the fact removed the NIC in the VM and re-added it. I don't fully recall. It's been awhile. The good news

is it is fixable.

Ian Forbes's profile image
Broadcom Employee Ian Forbes

Can you share the output of `lsmod` and `dmesg`.

Paolo Meravigliao's profile image
Paolo Meravigliao

ivan@ivan-NUC10i7FNH:~$ sudo lsmod
Module                  Size  Used by
joydev                 32768  0
hid_vivaldi            12288  0
hid_vivaldi_common     12288  1 hid_vivaldi
uhid                   20480  1
vmw_vsock_vmci_transport    49152  0
vsock                  61440  1 vmw_vsock_vmci_transport
vmw_vmci              106496  1 vmw_vsock_vmci_transport
vmmon                 167936  0
ccm                    20480  9
snd_seq_dummy          12288  0
snd_hrtimer            12288  2
qrtr                   53248  2
rfcomm                102400  6
cmac                   12288  3
algif_hash             16384  1
algif_skcipher         16384  1
af_alg                 32768  6 algif_hash,algif_skcipher
bnep                   32768  2
snd_ctl_led            24576  0
snd_hda_codec_realtek   212992  1
snd_hda_codec_generic   122880  1 snd_hda_codec_realtek
snd_hda_scodec_component    20480  1 snd_hda_codec_realtek
snd_sof_pci_intel_cnl    20480  0
snd_sof_intel_hda_generic    36864  1 snd_sof_pci_intel_cnl
soundwire_intel        77824  1 snd_sof_intel_hda_generic
soundwire_cadence      45056  1 soundwire_intel
snd_sof_intel_hda_common   192512  2 snd_sof_intel_hda_generic,snd_sof_pci_intel_cnl
binfmt_misc            24576  1
snd_soc_hdac_hda       24576  1 snd_sof_intel_hda_common
snd_sof_intel_hda_mlink    45056  3 soundwire_intel,snd_sof_intel_hda_common,snd_sof_intel_hda_generic
snd_sof_intel_hda      24576  2 snd_sof_intel_hda_common,snd_sof_intel_hda_generic
snd_hda_codec_hdmi     98304  1
snd_sof_pci            24576  2 snd_sof_intel_hda_generic,snd_sof_pci_intel_cnl
intel_rapl_msr         20480  0
snd_sof_xtensa_dsp     12288  1 snd_sof_intel_hda_generic
intel_rapl_common      53248  1 intel_rapl_msr
snd_sof               401408  5 snd_sof_pci,snd_sof_intel_hda_common,snd_sof_intel_hda_generic,snd_sof_intel_hda,snd_sof_pci_intel_cnl
intel_uncore_frequency    16384  0
intel_uncore_frequency_common    16384  1 intel_uncore_frequency
snd_sof_utils          16384  1 snd_sof
snd_soc_acpi_intel_match   131072  2 snd_sof_intel_hda_generic,snd_sof_pci_intel_cnl
snd_soc_acpi_intel_sdca_quirks    12288  1 snd_soc_acpi_intel_match
soundwire_generic_allocation    24576  1 soundwire_intel
snd_soc_acpi           16384  2 snd_soc_acpi_intel_match,snd_sof_intel_hda_generic
soundwire_bus         126976  3 soundwire_intel,soundwire_generic_allocation,soundwire_cadence
snd_soc_sdca           12288  2 snd_soc_acpi_intel_sdca_quirks,soundwire_bus
x86_pkg_temp_thermal    20480  0
intel_powerclamp       24576  0
snd_soc_avs           204800  0
coretemp               24576  0
snd_soc_hda_codec      24576  1 snd_soc_avs
snd_hda_ext_core       32768  6 snd_soc_avs,snd_soc_hda_codec,snd_sof_intel_hda_common,snd_soc_hdac_hda,snd_sof_intel_hda_mlink,snd_sof_intel_hda
kvm_intel             483328  0
snd_soc_core          434176  6 snd_soc_avs,snd_soc_hda_codec,soundwire_intel,snd_sof,snd_sof_intel_hda_common,snd_soc_hdac_hda
snd_compress           36864  2 snd_soc_avs,snd_soc_core
ac97_bus               12288  1 snd_soc_core
kvm                  1429504  1 kvm_intel
snd_pcm_dmaengine      16384  1 snd_soc_core
snd_hda_intel          65536  1
snd_intel_dspcfg       45056  5 snd_soc_avs,snd_hda_intel,snd_sof,snd_sof_intel_hda_common,snd_sof_intel_hda_generic
snd_intel_sdw_acpi     16384  2 snd_intel_dspcfg,snd_sof_intel_hda_generic
irqbypass              12288  1 kvm
polyval_clmulni        12288  0
snd_hda_codec         204800  8 snd_hda_codec_generic,snd_soc_avs,snd_hda_codec_hdmi,snd_soc_hda_codec,snd_hda_intel,snd_hda_codec_realtek,snd_soc_hdac_hda,snd_sof_intel_hda
polyval_generic        12288  1 polyval_clmulni
ghash_clmulni_intel    16384  0
nls_iso8859_1          12288  1
iwlmvm                913408  0
i915                 4743168  90
snd_usb_audio         561152  1
uvcvideo              147456  0
sha256_ssse3           32768  1
snd_hda_core          147456  11 snd_hda_codec_generic,snd_soc_avs,snd_hda_codec_hdmi,snd_soc_hda_codec,snd_hda_intel,snd_hda_ext_core,snd_hda_codec,snd_hda_codec_realtek,snd_sof_intel_hda_common,snd_soc_hdac_hda,snd_sof_intel_hda
snd_usbmidi_lib        57344  1 snd_usb_audio
sha1_ssse3             32768  0
mac80211             1818624  1 iwlmvm
videobuf2_vmalloc      20480  1 uvcvideo
snd_hwdep              20480  2 snd_usb_audio,snd_hda_codec
snd_ump                45056  1 snd_usb_audio
aesni_intel           122880  10
uvc                    12288  1 uvcvideo
snd_seq_midi           24576  0
btusb                  73728  0
crypto_simd            16384  1 aesni_intel
videobuf2_memops       16384  1 videobuf2_vmalloc
snd_seq_midi_event     16384  1 snd_seq_midi
libarc4                12288  1 mac80211
btrtl                  36864  1 btusb
cryptd                 24576  3 crypto_simd,ghash_clmulni_intel
cmdlinepart            16384  0
videobuf2_v4l2         36864  1 uvcvideo
drm_buddy              24576  1 i915
snd_rawmidi            57344  3 snd_seq_midi,snd_usbmidi_lib,snd_ump
snd_seq               122880  15 snd_seq_midi,snd_seq_midi_event,snd_seq_dummy
btintel                69632  1 btusb
rapl                   20480  0
videobuf2_common       90112  4 videobuf2_vmalloc,videobuf2_v4l2,uvcvideo,videobuf2_memops
spi_nor               163840  0
ttm                   118784  1 i915
ee1004                 16384  0
intel_cstate           20480  0
snd_pcm               196608  14 snd_soc_avs,snd_hda_codec_hdmi,snd_hda_intel,snd_usb_audio,snd_hda_codec,soundwire_intel,snd_sof,snd_sof_intel_hda_common,snd_compress,snd_sof_intel_hda_generic,snd_soc_core,snd_sof_utils,snd_hda_core,snd_pcm_dmaengine
snd_seq_device         16384  4 snd_seq,snd_seq_midi,snd_ump,snd_rawmidi
btbcm                  24576  1 btusb
iwlwifi               659456  1 iwlmvm
mei_pxp                16384  0
mei_hdcp               28672  0
mtd                   102400  3 spi_nor,cmdlinepart
videodev              364544  2 videobuf2_v4l2,uvcvideo
drm_display_helper    282624  1 i915
i2c_i801               36864  0
snd_timer              53248  3 snd_seq,snd_hrtimer,snd_pcm
tps6598x               90112  0
btmtk                  36864  1 btusb
spi_intel_pci          12288  0
typec                 118784  1 tps6598x
mc                     86016  5 videodev,snd_usb_audio,videobuf2_v4l2,uvcvideo,videobuf2_common
intel_wmi_thunderbolt    16384  0
wmi_bmof               12288  0
snd                   143360  26 snd_ctl_led,snd_hda_codec_generic,snd_seq,snd_seq_device,snd_hda_codec_hdmi,snd_hwdep,snd_hda_intel,snd_usb_audio,snd_usbmidi_lib,snd_hda_codec,snd_hda_codec_realtek,snd_sof,snd_timer,snd_compress,snd_soc_core,snd_ump,snd_pcm,snd_rawmidi
cec                    94208  2 drm_display_helper,i915
i2c_smbus              20480  1 i2c_i801
mei_me                 57344  2
spi_intel              36864  1 spi_intel_pci
cfg80211             1437696  3 iwlmvm,iwlwifi,mac80211
bluetooth            1015808  36 btrtl,btmtk,btintel,btbcm,bnep,btusb,rfcomm
soundcore              16384  2 snd_ctl_led,snd
i2c_mux                16384  1 i2c_i801
rc_core                73728  1 cec
i2c_algo_bit           20480  1 i915
mei                   176128  5 mei_hdcp,mei_pxp,mei_me
serial_multi_instantiate    16384  0
intel_pch_thermal      20480  0
intel_pmc_core        126976  0
pmt_telemetry          16384  1 intel_pmc_core
pmt_class              16384  1 pmt_telemetry
acpi_pad              184320  0
acpi_tad               20480  0
intel_vsec             20480  1 intel_pmc_core
input_leds             12288  0
mac_hid                12288  0
sch_fq_codel           24576  3
msr                    12288  0
parport_pc             53248  0
ppdev                  24576  0
lp                     28672  0
parport                73728  3 parport_pc,lp,ppdev
efi_pstore             12288  0
nfnetlink              20480  1
dmi_sysfs              24576  0
ip_tables              36864  0
x_tables               65536  1 ip_tables
autofs4                57344  2
r8153_ecm              12288  0
cdc_ether              24576  1 r8153_ecm
usbnet                 61440  2 r8153_ecm,cdc_ether
r8152                 143360  1 r8153_ecm
mii                    20480  2 usbnet,r8152
hid_generic            12288  0
usbhid                 77824  0
hid                   266240  5 usbhid,hid_vivaldi_common,hid_vivaldi,hid_generic,uhid
sdhci_pci             102400  0
nvme                   61440  3
sdhci_uhs2             36864  1 sdhci_pci
nvme_core             229376  4 nvme
intel_lpss_pci         28672  0
thunderbolt           544768  0
video                  77824  1 i915
sdhci                  98304  2 sdhci_uhs2,sdhci_pci
ahci                   49152  0
e1000e                360448  0
intel_lpss             12288  1 intel_lpss_pci
nvme_auth              28672  1 nvme_core
cqhci                  40960  1 sdhci_pci
libahci                53248  1 ahci
idma64                 20480  0
wmi                    28672  3 video,intel_wmi_thunderbolt,wmi_bmof
pinctrl_cannonlake     36864  0

Paolo Meravigliao's profile image
Paolo Meravigliao

The commad I do after installation of new kernel are correct?

dmesg output attached.

Thanks

Attachment  View in library
dmesg.txt 258 KB
goldeneye_007's profile image
goldeneye_007

It looks like you do not have vmnet as a running module. Also a common problem with kernel changes.

There is an unofficial patch you can use but I didn't see what version of vmware you are using.

This is the process for getting the unofficial fix to compile for 17.5.1 and higher. This is an advanced

hack to make it work. If you aren't comfortable with editing and compiling code this might not be the

fix for you.

Do this if there is no source
----
cd /tmp
sudo bash
git clone github.com/mkubecek/vmware-host-modules.git cd vmware-host-modules git switch workstation-17.5.1 
-----

Then

 in the vmmon-only/include/ directory find pgtbl.h
 
 91#if LINUX_VERSION_CODE >= KERNEL_VERSION(6,5,0)
 92             pte_t *pte = pte_offset_kernel(pmd, addr);
 93 #else
 94             pte_t *pte = pte_offset_map(pmd, addr);
 95 #endif
...

On line 94 of pgtbl.h: replace pte_offset_map with pte_offset_kernel (shown below) to make kernel version check invalid

 94             pte_t *pte = pte_offset_kernel(pmd, addr);

Then in directory /vmnet-only/ find bridge.c.

...
  28
  29 #if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 4, 10)
  30 #include <net/gso.h>
  31 #endif
...

On line 28: add #include <net/gso.h> so that net/gso.h will be included anyway

  28 #include <net/gso.h>

(sometimes gso.h is already in there) 

Ultimately,  Make the files look like this:
  
    pgtbl.h

...
 91#if LINUX_VERSION_CODE >= KERNEL_VERSION(6,5,0)
 92             pte_t *pte = pte_offset_kernel(pmd, addr);
 93 #else
 94             pte_t *pte = pte_offset_kernel(pmd, addr);//replace "pte_offset_map" with "pte_offset_kernel" to make kernel version check invalid
 95 #endif
...

    bridge.c

...
  28 #include <net/gso.h> //add this line so that net/gso.h will be included anyway
  29 #if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 4, 10)
  30 #include <net/gso.h>
  31 #endif

Finally inside the downloaded modules directory (there will be a file named Makefile in there) Run 

make 
make install

If I recall you'll need your distros kernel source, make and cc installed. I have used this process several times.

Paolo Meravigliao's profile image
Paolo Meravigliao

Hi,

thanks very much for the reply, I have attacched my system config. Your solution is a bit too advanced for me, but I can try. You confirm your solution is suitable for my system?

The command I do after each installation of new kernel are correct?

openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MOK.der -nodes -days 36500 -subj "/CN=My Name/"
sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file sha256 ./MOK.priv ./MOK.der $(modinfo -n vmmon)
sudo /usr/src/linux-headers-$(uname -r)/scripts/sign-file sha256 ./MOK.priv ./MOK.der $(modinfo -n vmnet)
sudo mokutil --import MOK.der ---"insert a password"
now reboot and re-enroll your key.

Thanks

Ivan