Virtualbox – PING from virtual machine results in (DUP!) duplicate packages


Virtual machine random network connectivity issues with VirtualBox. Using pingcommand results in:

# ping
PING ( 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=57 time=22.2 ms
64 bytes from icmp_seq=1 ttl=56 time=22.3 ms (DUP!)
64 bytes from icmp_seq=2 ttl=57 time=22.1 ms
64 bytes from icmp_seq=2 ttl=56 time=22.2 ms (DUP!)
--- ping statistics ---
2 packets transmitted, 2 received, +2 duplicates, 0% packet loss, time 1009ms
rtt min/avg/max/mdev = 22.106/22.248/22.368/0.142 ms


Disable host operating system’s IP forwarding:

# sysctl -w net.ipv4.ip_forward=0
net.ipv4.ip_forward = 0

If sysctl command is not available execute:

# echo 0 > /proc/sys/net/ipv4/ip_forward