Skip to content

Instantly share code, notes, and snippets.

@roelds
Created September 5, 2024 21:17
Show Gist options
  • Save roelds/874b99551a566c62a40574b1c7ae3b60 to your computer and use it in GitHub Desktop.
Save roelds/874b99551a566c62a40574b1c7ae3b60 to your computer and use it in GitHub Desktop.
HyperV New-VMSwitch - Static Subnet, No DHCP, Allowed Static MACs
New-VMSwitch -SwitchName AllInternal69 -SwitchType Internal
Get-NetAdapter
New-NetIPAddress -IPAddress 192.168.69.1 -PrefixLength 24 -InterfaceIndex INDEX
New-NetNat -Name AllInternal69 -InternalIPInterfaceAddressPrefix 192.168.69.0/24
# Local Static MACs:
# x2-xx-xx-xx-xx-xx
# x6-xx-xx-xx-xx-xx
# xA-xx-xx-xx-xx-xx
# xE-xx-xx-xx-xx-xx
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment