Forum Discussion
Bala Sundaram
Sep 24, 2018Brass Contributor
Hyper-V Default switch IP address range change. Ver 1809 Build 17763.1
Can one confirm IP address range changed to 192.168.X.Y Subnet 255.255.255.240 from 172.X.X.X Also changes the subnet randomly on every Hyper-V services startup. 192.168.X.Y . X can change from 5...
sn00p
Sep 04, 2019Copper Contributor
HotCakeX NAT is not about routes, it's about network address translation. And that switch is for NAT isn't it? But it's black-boxed and the only configuration parameter opened (static IP address) is simply broken, changing randomly every time you boot your computer. Why? No clues, nobody does this except MS. And documentation either not complete or it's just a bug.
Again, switch is not allowed to change it's own address randomly if configured statically. If MS made it intentionally, they should fire their developers and hire professionals.
This scenario is a dead horse. It's usable only in few cases. Again, all other virtualization software do things right in few clicks but not MS. Why? No clues.
Windows costs money. And the thing you have to buy yet another software to make it works is just bad. Because it's working pretty weird out of the box and workarounds are broken too.
mlmathews
Sep 11, 2019Brass Contributor
sn00p The recreation of the Default Switch with a new subnet on every host reboot is definitely a bug. I'm migrating from VMware, where I use a virtual NAT network for all my VM's. I knew going in to the migration that Hyper-V has limited capabilities compared to VMware, but I didn't expect the networking to be so limited. Here's the issues I've run in to:
* - Default switch reconfigures on every host restart and there is no way to prevent it.
* - Default switch is the only way to have VM's on a virtual NAT...it's not possible to create a Internal Switch with NAT (correct?) that doesn't get reconfigured on every host restart
* - External switch must bridge to a specific host NIC. My host is a laptop that is sometimes docked and connected via ethernet and sometimes connected via wifi.
I'm new to Hyper-V (but not new to working with VMs and networking), so please correct me if I've overlooked solutions to any of the above.
- HotCakeXSep 11, 2019MVPI'm not sure about that part where you mentioned Hyper-V has limited functionality compared to VMware. I have worked VMware workstation 15 and its previous versions for years, each has it's own set of features.
Hyper-V default virtual switch is exactly made for the type of the environment you work at.
sometimes you connect to WIFI network and sometimes you connect using Ethernet cable.
each of those networks can have different set of IP addresses and subnets.
now if the default virtual switch were to create persistent routes instead of temporary ones (as it does now), it would have created problems for you because you'd have to jump in CMD each time the networks changed and set the correct routing table.
right now default Hyper-v virtual switch takes care of it automatically and it's for quick VM set up, casual VM works.
but if you want to set up servers in Hyper-V like i do, you should use external Hyper-v virtual switch. it has more functions and it gives the guest VM a static IP because it bounds it to a Real physical network adapter. that's exactly what server admins Need. usually servers use more than 1 physical network adapter. so using the external virtual switch, they can properly and separately assign each of them to a specific external virtual switch and utilize them perfectly in the guest OSes (servers). servers do need static IP addresses.
but if you just want to install a Windows 10 pro or home and do casual works then the default switch should suffice.- mlmathewsSep 11, 2019Brass Contributor
With VMware, I could configure my virtual NAT network subnet...I had it set to 192.168.5.X and the host and guest IP addresses on the subnet where static. So no matter where I happened to be working, my VM's were isolated on a NAT network with static IP addresses (which is important for the type of work I do)
With the Hyper-V Default Switch changing the subnet on every reboot, I'm having to log in the to my main VM (Windows Server 2016) and tell it that the "new network" that it is now connected to is a private network.
- cbj4074Oct 04, 2019Brass Contributor
mlmathews It sounds as though our respective use-cases may be similar.
(Edit to add: I had missed your most recent reply, as I failed to notice page 2; I will look into the PowerShell-based solution! Thank you!)
I'm a web developer who works primarily with VMs running GNU/Linux. I work in a Windows-driven, corporate ecosystem, though, so my primary development machine runs Windows 10 with Hyper-V.
I have many different VMs that I spin-up on a regular basis, oftentimes freshly-provisioned (that is, built dynamically and booted for the first time on each use). The provisioning process is 100% automated, which I mention only to make clear that there is no room for "manual tweaking" nor GUI configuration in my workflow; any networking configuration has to be automated during provisioning.
Further, I have many VM configurations in which one VM needs to communicate with one or more other VMs on the same subnet, which requires that each source VM knows any potential destination VM's IP address (a hostname could work, too, if hostname resolution was configured correctly, which I haven't yet attempted with Hyper-V).
More importantly, I need this subnet to be completely isolated from my physical NIC so that there is zero possibility of another machine on my LAN communicating with any of the VMs running in Hyper-V.
But I also need for the VMs to be able to connect to the Internet.
So, here's where I'm stuck:
1.) Default Switch: IP address assigned to VMs changes at random on host system reboot, so without hostname resolution across multiple VMs on VLAN, this configuration is untenable.
2.) External Network: This makes my VMs visible on our corporate LAN, which is a no-go.
3.) Internal Network: My VMs cannot obtain IPv4 addresses for some reason; only IPv6. No idea why this is.
4.) Private Network: Doesn't allow VMs access to internet, so not viable.
HotCakeXDo you have a clever solution that will meet my requirements?
- mlmathewsSep 11, 2019Brass ContributorP.S. I'm running on build 1903