Skip to content

Instantly share code, notes, and snippets.

@n-mam
Last active April 17, 2021 06:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save n-mam/ca498ca735d211622f154fbbb110f388 to your computer and use it in GitHub Desktop.
Save n-mam/ca498ca735d211622f154fbbb110f388 to your computer and use it in GitHub Desktop.
Hyper-V internal network
Hyper-V internal network allows communication to happen only across VMs and between the host and VM.
Assign the VM's network adapter to the Hyper-V internal switch.
We can change the ip address range on the internal hyper-v network switch to say 10.0.0.1 with subnet mask of 255.255.255.0
Assign VM a static ip address to match the ip address range of the internal switch. ex:
--------------------------------------
#iface eth0 inet dhcp
iface eth0 inet static
address 10.0.0.2
netmask 255.255.255.0
gateway 10.0.0.1
--------------------------------------
Allow the host to recieve p from the VMs. From powershell:
Set-NetFirewallRule -Name "FPS-ICMP4-ERQ-In" -Enabled True
Verify ping works both ways i.e. host-to-vm and vm-to-host
Few other settings (need to verify)
On the hyper-v network adaptor settings:
Advanced features -- MAC address -- select "static"
VLAN is can remain unchecked.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment