Linux Virtual machine can’t ping Google, while Host can do it

icmplinuxnetworkingpingvmware-workstation

Assumptions:

  1. You have a Windows 7 Ultimate as your host.
  2. You have a Linux Kali 2 as a VMWare Workstation virtual machine on this host.
  3. Your network adapter is bridged on the VMWare(Version 10.0.3).
  4. Host IP address = 10.0.0.81
  5. Virtual Machine IP address = 10.0.0.38
  6. Host Gateway = 10.0.0.60
  7. Virtual machine Gateway = 10.0.0.60
  8. Virtual Machine and Host can ping each other and also the gateway successfully.

Problem:

While Host can ping 46.228.47.114 (Yahoo) successfully, the virtual machine can't! In the other words, ICMP requests from host to Yahoo, have ICMP reply packets, but ICMP requests from the virtual machine haven't!

What am I did so far?

  1. I replaced my host IP address with the virtual machine IP address, and vice versa, but nothing changed.
  2. I tried other virtual machines. For all Linux virtual machines I have this issue, while all Windows virtual machines are working fine!
  3. I tried different versions of VMware® Workstation and VMWare VSphere softwares. Issue doesn't solved for my Linux virtual machines.

Differences between ICMP requests:

Windows 7:

enter image description here

Kali Linux:
enter image description here

As you see above, there are some difference between requests. Is these difference origin of the problem? If so, how can I handle it?

Note that:

Formerly I even can't ping the Gateway on the Virtual Machine! By sniffing I noticed that MAC address of gateway in the Virtual machine is not correct, so I set it statically with the correct value and after that I pinged it successfully. Now this is the new problem!

Update:

I'm just see that I have Internet access on the virtual machine! I only can't ping it!

Look:
enter image description here

Any way I need to see the ping reply packet!

Best Answer

As a workaround (or arguably a fix), disable any network offloading settings on the physical NIC on the host.

  1. Open Control Panel, System, Device Manager
  2. Expand "Network Adapters"
  3. Double-click on your physical NIC to bring up properties.
  4. Select the "Advanced" tab
  5. Disable all properties with "Offload" in the name (varies by network card).

NOTE: You may want to record the initial settings should you want to revert later.

Related Question