Windows Server 2008 R2 IP Address Binding order

ethernetipv4tcpipwindows-server-2008

How do I set the order of multiple IP addresses all bound to one ethernet interface?

Best Answer

I ran into this same issue today. It appears that Windows uses the lowest numbered IP address on an interface as the primary interface IP in the route table, no matter what ordered they are specified or added. I cannot find a source to confirm this though.

In order to add additional IPs to an interface, and be assured that they are not used as the source IP for outbound connections, you must use the following command:

netsh interface ipv4 add address "Interface Name Here or Index #" address=x.x.x.x mask=y.y.y.y skipassource=true

The key part being skipassource=true.

You can confirm this worked correctly with the following command:

netsh int ipv4 show ipaddresses level=verbose

Unfortunately, you cannot make this change on an existing IP address, so it must be deleted and re-added.