Link to home
Start Free TrialLog in
Avatar of AL_XResearch
AL_XResearchFlag for United Kingdom of Great Britain and Northern Ireland

asked on

What does "Replicate physical network connection state" actually mean ?

I realise this may seem a simple question but:

 As far as I am aware this means that if you are using a mobile address the virtual adapter will be updated with the latest IP address.

However since you are connecting to a physical NIC, which is presumably using DHCP, won't the machine pick up the latest assigned IP address as a physical NIC would (even if it is a wireless NIC) ?
Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

"Replicate physical network connection state" actually mean"

the state is the LINK, which is either UP or DOWN. (1 or 0).

when the cable is disconnected, reflect this setting in the computer, e.g. disconnected state, or connected.

In a VMware environment, this is the VM network interface connection to the Virtual Switch, the VM does not have the ability to "see/detect" the physical network interface in the host.

Now you may state, well isn't the virtual nic always connected - that depends on it's setting, because you have two settings, Connected and Connected at Power On, so it's even possible with a virtual machine to disconnect the virtual cable between VM and Virtual Switch.

However since you are connecting to a physical NIC, which is presumably using DHCP, won't the machine pick up the latest assigned IP address as a physical NIC would (even if it is a wireless NIC) ?

VMs are connected to a virtual machine portgroup, which is connected to a Virtual Switch (vSwitch), which is connected to a physical network interface, which does not have an IP Address.

Traffic flows from the physical switch port - through the physical network interface, into the virtual switch, into the vitual machine portgroup, to the virtual machine, which has an IP Address allocated.

see my EE Article

HOW TO: Configure basic networking on a VMware vSphere Hypervisor 5.1 (ESXi 5.1) Host Server

any questions please ask.
Avatar of AL_XResearch

ASKER

Sorry, perhaps I should have clarified I am talking about VMware workstation - which I think makes things much simpler.
exactly the same!

As far as I am aware this means that if you are using a mobile address the virtual adapter will be updated with the latest IP address.

Correct.


However since you are connecting to a physical NIC, which is presumably using DHCP, won't the machine pick up the latest assigned IP address as a physical NIC would (even if it is a wireless NIC) ?


However since you are connecting to a physical NIC, which is presumably using DHCP, won't the machine pick up the latest assigned IP address as a physical NIC would (even if it is a wireless NIC) ?

Also correct, BUT if you change WiFi networks, and it's DHCP, and it's a different WiFi, it forces a "refresh" on the internal networking, to ensure you get a IP on the new network, of you could have an IP from the old network, until DHCP renewal time.
VMware Workstation has a hidden NAT, Bridged or Host virtual switch.

in addition - VMware also states -

When the Replicate physical connection state option is selected, the IP address is automatically renewed when you move from one wired or wireless network to another. This setting is useful for virtual machines than run on laptops or other mobile devices.

So depending on the physical device, changing states, will force a request
That is just were I am getting lost. Why do you need the setting to renew there IP address when the physical NIC and dhcp will do this automatically.

Please note that in all the VMs I use i have the virtual NIC card set to 'connected' and 'connect at power on'
it's nothing to do with the physical nic or DHCP on the host nic. That's working completely independently to the VM nic. e.g. you could have no IP Address on the HOST nic, but bridge will still function.

because if you change networks, your VM maybe not get a new IP Address from DHCP, on the new network, until the DHCP renewal of refresh of half life.
Sorry I am getting a little confused now.

I appreciate that the VM and physical NIC are of course completely separate but since the vSwitch is connected to the pNIC - like any other machine when connected to the physical LAN (that uses DHCP) the machine will either be assigned a new IP address or re-assigned the number from an existing lease if present.

So the pNIC does have an effect on the vNIC if set to bridged mode and in that case my question still stands: like a physical machine it will automatically be assigned an IP so why do you have to tick an extra box to make it aware of it's state because when you disconnect from one network and connect to another the new IP will 'bubble down' to the vNIC as it would to a pNIC.
ASKER CERTIFIED SOLUTION
Avatar of Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Andrew Hancock (VMware vExpert PRO / EE Fellow/British Beekeeper)
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Yes of course I completely understand that if you try to use an IP address on a different subnet you are not going to connect.

Can I just try and clarify this: are you saying that the "Replicate physical network connection state" is basically a confusing way of saying "Notify the vSwitch / VM when the pNIC is switched / 'cable' unplugged" ?
Can I just try and clarify this: are you saying that the "Replicate physical network connection state" is basically a confusing way of saying "Notify the vSwitch / VM when the pNIC is switched / 'cable' unplugged" ?

Yes.
So I come back to my original question: why doesn't the VM guest OS (Windows) pickup that the cable has been disconnected \ adaptor changed and request a new IP address from the new network's DHCP like the Windows on the host does ? Sometimes Windows is slow but it will pick up a new IP address on the new subnet itself.

Or is this because the vNetwork components are not as functional as the physical equivalents ?
it's virtual, and does not have a line detect in the interface, like a physical nic.
So without "Replicate physical network connection state" ticked even if the vNIC is set to 'Connected' and 'Connect at power on' the vNetwork is only going to pick up the IP address once at connection / startup time ?
Yes, and you can test this, by selecting different WiFi networks with different IP Addresses ranges, and you will notice that the VM, unless "Replicate physical network connection state" is ticked, the VM will not get a new DHCP IP Address from the new LAN.

the VM will sit on the old IP Address.
So if you 'forced' a refresh with a command like 'ipconfig /renew' would it be able to get the new IP address or not ?

Likewise if you disconnected the vNIC, via settings, and re-connected would this pick up the new subnet and IP ?
So if you 'forced' a refresh with a command like 'ipconfig /renew' would it be able to get the new IP address or not ?

Likewise if you disconnected the vNIC, via settings, and re-connected would this pick up the new subnet and IP ?

Yes, that would work, because you are forcing a DHcP request, and by disconnecting and reconnecting that would also cause the internal NIC to refresh.
Excellent. Thank you so much for all your responses. It has helped explain something that has been puzzling me for a while.