VirtualBox host-only network, ping works only from guest to host
I have a Windows 7 VM running on a Ubuntu 15.04 host using the latest Virtual Box 5 release. I've configured a host-only network. The configuration of the host-only adapter is:
Adapter IP 192.168.56.1
Subnetmask 255.255.255.0
DHCP enabled
Server 192.168.56.100
Mask 255.255.255.0
from 192.168.56.101
to 192.168.56.254
With the adapter being created by VirtualBox, ifconfig vboxnet0
displays:
vboxnet0 Link encap:Ethernet HWaddr 0a:00:27:00:00:00
inet addr:192.168.56.1 Bcast:192.168.56.255 Mask:255.255.255.0
inet6 addr: fe80::800:27ff:fe00:0/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:960 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:112330 (112.3 KB)
The Windows 7 guest receives an IP from the DHCP Server and also seem to have a properly configured interface:
Ethernet adapter Local Area Connection:
Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::18e1:2f8e:907a:e280%11
IPv4 Address. . . . . . . . . . . : 192.168.56.101
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . :
The issue I'm currently facing is that I can ping the Ubuntu host from the Windows 7 guest using ping 192.168.56.1
. However, I can't ping the guest using ping 192.168.56.101
from my host system. Wireshark tells me that echo requests are sent just fine, but there are no replies coming back. The guest system is a fresh installed Windows 7.
This could be a firewall issue. The Windows 7 firewall blocks ICMP echo requests by default. Try to disable the firewall or to add an exception rule for ICMP echo requests.