Recently there was a post on DB mirroring not working on a VM, in the post I had suggested checking the network connectivity and NIC configurations in the VM software since there are different ways that the VM software assigns IP to the Virtual devices. For the purpose of this post I am using VMware as the example but most of it holds true for HyperV as well.
Here is a screenshot of the different types of Network connections that can be established via VMware
As you can see in the above example I have used a bridged connection, this means that the VM is treated like another machine on the same network as the host.
Nat or Network address translation is used when there are limited IP addresses usually you find something similar when using the cloud since the Cloud provider has a limited number of IP addresses available.
In this case the VM translates (catches and redirects) any request from the Guest and passes it on to the Host so that the network sees only the host IP address and not the IP of the Guest OS.
Host Only – A connection shared with the host only in other words this guest had no access to the network. The Guest and the Host share their own private network created using a Virtual DHCP available within the VM software itself.
As you can see depending on how the NIC is configured the Router or DHCP server sees different IP addresses and therefore firewalls and mirroring endpoints need to be configured differently.