Solution for the Internet-interrupt issue of VMware Ubuntu virtual machine (VM) that happens after the VM was suspended

P.S. This article was originally printed on my cnblog site. The original one was written in Chinese.

Operation Environment:

OS (host machine): Windows 11 Home
OS (virtual machine): Ubuntu 20.04.3 LTS 64bits
Version of VM: VMware® Workstation 16 Pro 16.1.0
Network adapter of VM: NAT mode

Reason of the issue

It occurred when I tried to suspend the operation of VMware to unload cpu since I wanted to tranquilize the fans at that time. However, when I woke up the VM again, an error reminder popped up and said:

VMware Workstation non-recoverable: (vcpu-0),Exception 0xc0000005 (access violation) has occurred.
Transmission (VMDB) Error -14: Pipe connection has been broken.

Then, when I tried to use the Ubuntu for web browsing, it was found that the internet was disconnected. Therefore, it was necessary for me to fix the problem.

Process of recovery

In the beginning, since my firefox browser reminded me the server was disconnected, I believed that the issue occurred on the DNS server connection. Following the steps on the internet, I just need to replace the current nameserver with the 8.8.8.8 offered by Google in the resolve.conf file [1]. However, the internet was still disconnected, so I replaced the DNS address with 180.76.76.76 which is offered by Baidu. Nevertheless, it was still disconnected, so I thought the issue was not about the DNS server connection.

Afterward, a new opinion was put forward that the issue occurred due to my host machine. After searching, I found that the above-mentioned vcpu-0 error was caused by the clash between Hyper-v and VMware, and what should I do was disable Hyper-v. Therefore, I tried to disable Hyper-v from PowerShell as administrator [2]:

1
bcdedit /set hypervisorlaunchtype off

However, it did not function as well. I also tried to reset the interfaces file referring to [3], however, it was useless.

Solution

The solution that repaired my VMware was the proposal put forward in [4]. Making short for long, it is divided into three steps:

  1. Changing the network adapter to host mode.
  2. Inputting the following commands in Ubuntu:
    1
    2
    3
    sudo service network-manager stop
    sudo rm /var/lib/NetworkManager/NetworkManager.state
    sudo service network-manager start
  3. Changing the network adapter back to NAT/bridge/other modes.

After finishing the above steps, the internet connection of my Ubuntu VMware machines returned back to normal.

Improvement

Although the above-mentioned disabling Hyper-v method does not function on re-motivate VMware’s Internet, it can repair the vcpu-0 error; however, the VMDB error still exists and the suspension of my VMware still does not work. Besides, there are very a few solutions to resolve the VMDB problem on Internet (especially Chinese Internet). Therefore, this issue should be solved later if it is possible.

Reference

[1]. https://www.cnblogs.com/lxjshuju/p/7133599.html
[2]. https://blog.csdn.net/m0_43406494/article/details/121065440
[3]. https://blog.csdn.net/CaoMei_HuaCha/article/details/84846845
[4]. https://www.cnblogs.com/jlf0103/p/9501892.html