Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have set up a virtual machine with Virtual Box. But I cant ping the virtual machine from the host Windows 7 if I have NAT on the virtual machine.

I know it works with bridged but I would like it to work with NAT, is that possible?

share|improve this question

Not really as with NAT, you are only pinging the actual host/router that is performing NAT (in this case, the virtual network interface/similar of your machine).

Whilst you can usually port forward from the NAT interface to the virtual IP behind it (this is basically a virtual router), ICMP packets (which are needed for ping) will not forward as it sort of goes against the whole purpose of providing NAT.

If you need a direct IP connection from one machine to another, you really need to bridge/have a routed IP... I am not sure/can't remember, but, I don't think it is possible to forward ICMP packets using Virtual Boxe's NAT.

share|improve this answer
Ok but it works with VMware. The "money talks" in this case? – Chris_45 Dec 30 '11 at 19:14
I would think that unless you actually forwarded NAT ICMP (which I don't think you can do), you were only pinging the host, not the virtual machine. and if you were pinging via the NAT private IP, then, it was VMWare doing routing, not an actual ping via NAT as such. – William Hilsum Dec 30 '11 at 20:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .